@sap-ux/fiori-mcp-server 0.4.8 → 0.4.9
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.js +5 -5
- package/package.json +11 -11
package/dist/index.js
CHANGED
|
@@ -424,7 +424,7 @@ ${f}`),n?i.reset(f):f}function Wwn(e,t,r,n={}){if(!yNt){yNt=!0;let a="Passing li
|
|
|
424
424
|
|
|
425
425
|
%s
|
|
426
426
|
`)}),ANt=(e,t,r)=>{typeof t=="string"&&(r=t,t=null);try{try{return JSON.parse(e,t)}catch(n){throw Xwn(e,t),n}}catch(n){n.message=n.message.replace(/\n/g,"");let i=n.message.match(/in JSON at position (\d+) while parsing/),a=new SNt(n);if(r&&(a.fileName=r),i&&i.length>0){let o=new Jwn(e),s=Number(i[1]),c=o.locationForIndex(s),u=Zwn(e,{start:{line:c.line+1,column:c.column+1}},{highlightCode:!0});a.codeFrame=u}throw a}};ANt.JSONError=SNt;CNt.exports=ANt});var DW=y((ir,zNt)=>{ir=zNt.exports=tn;var Bn;typeof process=="object"&&process.env&&process.env.NODE_DEBUG&&/\bsemver\b/i.test(process.env.NODE_DEBUG)?Bn=function(){var e=Array.prototype.slice.call(arguments,0);e.unshift("SEMVER"),console.log.apply(console,e)}:Bn=function(){};ir.SEMVER_SPEC_VERSION="2.0.0";var lj=256,_W=Number.MAX_SAFE_INTEGER||9007199254740991,PAe=16,Qwn=lj-6,pj=ir.re=[],yi=ir.safeRe=[],Ce=ir.src=[],Yr=0,LAe="[a-zA-Z0-9-]",DAe=[["\\s",1],["\\d",lj],[LAe,Qwn]];function CW(e){for(var t=0;t<DAe.length;t++){var r=DAe[t][0],n=DAe[t][1];e=e.split(r+"*").join(r+"{0,"+n+"}").split(r+"+").join(r+"{1,"+n+"}")}return e}var tD=Yr++;Ce[tD]="0|[1-9]\\d*";var rD=Yr++;Ce[rD]="\\d+";var kAe=Yr++;Ce[kAe]="\\d*[a-zA-Z-]"+LAe+"*";var DNt=Yr++;Ce[DNt]="("+Ce[tD]+")\\.("+Ce[tD]+")\\.("+Ce[tD]+")";var NNt=Yr++;Ce[NNt]="("+Ce[rD]+")\\.("+Ce[rD]+")\\.("+Ce[rD]+")";var NAe=Yr++;Ce[NAe]="(?:"+Ce[tD]+"|"+Ce[kAe]+")";var IAe=Yr++;Ce[IAe]="(?:"+Ce[rD]+"|"+Ce[kAe]+")";var $Ae=Yr++;Ce[$Ae]="(?:-("+Ce[NAe]+"(?:\\."+Ce[NAe]+")*))";var MAe=Yr++;Ce[MAe]="(?:-?("+Ce[IAe]+"(?:\\."+Ce[IAe]+")*))";var RAe=Yr++;Ce[RAe]=LAe+"+";var dj=Yr++;Ce[dj]="(?:\\+("+Ce[RAe]+"(?:\\."+Ce[RAe]+")*))";var FAe=Yr++,INt="v?"+Ce[DNt]+Ce[$Ae]+"?"+Ce[dj]+"?";Ce[FAe]="^"+INt+"$";var jAe="[v=\\s]*"+Ce[NNt]+Ce[MAe]+"?"+Ce[dj]+"?",qAe=Yr++;Ce[qAe]="^"+jAe+"$";var sD=Yr++;Ce[sD]="((?:<|>)?=?)";var xW=Yr++;Ce[xW]=Ce[rD]+"|x|X|\\*";var TW=Yr++;Ce[TW]=Ce[tD]+"|x|X|\\*";var EO=Yr++;Ce[EO]="[v=\\s]*("+Ce[TW]+")(?:\\.("+Ce[TW]+")(?:\\.("+Ce[TW]+")(?:"+Ce[$Ae]+")?"+Ce[dj]+"?)?)?";var iD=Yr++;Ce[iD]="[v=\\s]*("+Ce[xW]+")(?:\\.("+Ce[xW]+")(?:\\.("+Ce[xW]+")(?:"+Ce[MAe]+")?"+Ce[dj]+"?)?)?";var RNt=Yr++;Ce[RNt]="^"+Ce[sD]+"\\s*"+Ce[EO]+"$";var LNt=Yr++;Ce[LNt]="^"+Ce[sD]+"\\s*"+Ce[iD]+"$";var kNt=Yr++;Ce[kNt]="(?:^|[^\\d])(\\d{1,"+PAe+"})(?:\\.(\\d{1,"+PAe+"}))?(?:\\.(\\d{1,"+PAe+"}))?(?:$|[^\\d])";var wW=Yr++;Ce[wW]="(?:~>?)";var aD=Yr++;Ce[aD]="(\\s*)"+Ce[wW]+"\\s+";pj[aD]=new RegExp(Ce[aD],"g");yi[aD]=new RegExp(CW(Ce[aD]),"g");var ePn="$1~",$Nt=Yr++;Ce[$Nt]="^"+Ce[wW]+Ce[EO]+"$";var MNt=Yr++;Ce[MNt]="^"+Ce[wW]+Ce[iD]+"$";var PW=Yr++;Ce[PW]="(?:\\^)";var oD=Yr++;Ce[oD]="(\\s*)"+Ce[PW]+"\\s+";pj[oD]=new RegExp(Ce[oD],"g");yi[oD]=new RegExp(CW(Ce[oD]),"g");var tPn="$1^",FNt=Yr++;Ce[FNt]="^"+Ce[PW]+Ce[EO]+"$";var jNt=Yr++;Ce[jNt]="^"+Ce[PW]+Ce[iD]+"$";var VAe=Yr++;Ce[VAe]="^"+Ce[sD]+"\\s*("+jAe+")$|^$";var UAe=Yr++;Ce[UAe]="^"+Ce[sD]+"\\s*("+INt+")$|^$";var _O=Yr++;Ce[_O]="(\\s*)"+Ce[sD]+"\\s*("+jAe+"|"+Ce[EO]+")";pj[_O]=new RegExp(Ce[_O],"g");yi[_O]=new RegExp(CW(Ce[_O]),"g");var rPn="$1$2$3",qNt=Yr++;Ce[qNt]="^\\s*("+Ce[EO]+")\\s+-\\s+("+Ce[EO]+")\\s*$";var VNt=Yr++;Ce[VNt]="^\\s*("+Ce[iD]+")\\s+-\\s+("+Ce[iD]+")\\s*$";var UNt=Yr++;Ce[UNt]="(<|>)?=?\\s*\\*";for(Lm=0;Lm<Yr;Lm++)Bn(Lm,Ce[Lm]),pj[Lm]||(pj[Lm]=new RegExp(Ce[Lm]),yi[Lm]=new RegExp(CW(Ce[Lm])));var Lm;ir.parse=xO;function xO(e,t){if((!t||typeof t!="object")&&(t={loose:!!t,includePrerelease:!1}),e instanceof tn)return e;if(typeof e!="string"||e.length>lj)return null;var r=t.loose?yi[qAe]:yi[FAe];if(!r.test(e))return null;try{return new tn(e,t)}catch{return null}}ir.valid=nPn;function nPn(e,t){var r=xO(e,t);return r?r.version:null}ir.clean=iPn;function iPn(e,t){var r=xO(e.trim().replace(/^[=v]+/,""),t);return r?r.version:null}ir.SemVer=tn;function tn(e,t){if((!t||typeof t!="object")&&(t={loose:!!t,includePrerelease:!1}),e instanceof tn){if(e.loose===t.loose)return e;e=e.version}else if(typeof e!="string")throw new TypeError("Invalid Version: "+e);if(e.length>lj)throw new TypeError("version is longer than "+lj+" characters");if(!(this instanceof tn))return new tn(e,t);Bn("SemVer",e,t),this.options=t,this.loose=!!t.loose;var r=e.trim().match(t.loose?yi[qAe]:yi[FAe]);if(!r)throw new TypeError("Invalid Version: "+e);if(this.raw=e,this.major=+r[1],this.minor=+r[2],this.patch=+r[3],this.major>_W||this.major<0)throw new TypeError("Invalid major version");if(this.minor>_W||this.minor<0)throw new TypeError("Invalid minor version");if(this.patch>_W||this.patch<0)throw new TypeError("Invalid patch version");r[4]?this.prerelease=r[4].split(".").map(function(n){if(/^[0-9]+$/.test(n)){var i=+n;if(i>=0&&i<_W)return i}return n}):this.prerelease=[],this.build=r[5]?r[5].split("."):[],this.format()}tn.prototype.format=function(){return this.version=this.major+"."+this.minor+"."+this.patch,this.prerelease.length&&(this.version+="-"+this.prerelease.join(".")),this.version};tn.prototype.toString=function(){return this.version};tn.prototype.compare=function(e){return Bn("SemVer.compare",this.version,this.options,e),e instanceof tn||(e=new tn(e,this.options)),this.compareMain(e)||this.comparePre(e)};tn.prototype.compareMain=function(e){return e instanceof tn||(e=new tn(e,this.options)),nD(this.major,e.major)||nD(this.minor,e.minor)||nD(this.patch,e.patch)};tn.prototype.comparePre=function(e){if(e instanceof tn||(e=new tn(e,this.options)),this.prerelease.length&&!e.prerelease.length)return-1;if(!this.prerelease.length&&e.prerelease.length)return 1;if(!this.prerelease.length&&!e.prerelease.length)return 0;var t=0;do{var r=this.prerelease[t],n=e.prerelease[t];if(Bn("prerelease compare",t,r,n),r===void 0&&n===void 0)return 0;if(n===void 0)return 1;if(r===void 0)return-1;if(r===n)continue;return nD(r,n)}while(++t)};tn.prototype.inc=function(e,t){switch(e){case"premajor":this.prerelease.length=0,this.patch=0,this.minor=0,this.major++,this.inc("pre",t);break;case"preminor":this.prerelease.length=0,this.patch=0,this.minor++,this.inc("pre",t);break;case"prepatch":this.prerelease.length=0,this.inc("patch",t),this.inc("pre",t);break;case"prerelease":this.prerelease.length===0&&this.inc("patch",t),this.inc("pre",t);break;case"major":(this.minor!==0||this.patch!==0||this.prerelease.length===0)&&this.major++,this.minor=0,this.patch=0,this.prerelease=[];break;case"minor":(this.patch!==0||this.prerelease.length===0)&&this.minor++,this.patch=0,this.prerelease=[];break;case"patch":this.prerelease.length===0&&this.patch++,this.prerelease=[];break;case"pre":if(this.prerelease.length===0)this.prerelease=[0];else{for(var r=this.prerelease.length;--r>=0;)typeof this.prerelease[r]=="number"&&(this.prerelease[r]++,r=-2);r===-1&&this.prerelease.push(0)}t&&(this.prerelease[0]===t?isNaN(this.prerelease[1])&&(this.prerelease=[t,0]):this.prerelease=[t,0]);break;default:throw new Error("invalid increment argument: "+e)}return this.format(),this.raw=this.version,this};ir.inc=aPn;function aPn(e,t,r,n){typeof r=="string"&&(n=r,r=void 0);try{return new tn(e,r).inc(t,n).version}catch{return null}}ir.diff=oPn;function oPn(e,t){if(BAe(e,t))return null;var r=xO(e),n=xO(t),i="";if(r.prerelease.length||n.prerelease.length){i="pre";var a="prerelease"}for(var o in r)if((o==="major"||o==="minor"||o==="patch")&&r[o]!==n[o])return i+o;return a}ir.compareIdentifiers=nD;var PNt=/^[0-9]+$/;function nD(e,t){var r=PNt.test(e),n=PNt.test(t);return r&&n&&(e=+e,t=+t),e===t?0:r&&!n?-1:n&&!r?1:e<t?-1:1}ir.rcompareIdentifiers=sPn;function sPn(e,t){return nD(t,e)}ir.major=cPn;function cPn(e,t){return new tn(e,t).major}ir.minor=uPn;function uPn(e,t){return new tn(e,t).minor}ir.patch=lPn;function lPn(e,t){return new tn(e,t).patch}ir.compare=uv;function uv(e,t,r){return new tn(e,r).compare(new tn(t,r))}ir.compareLoose=pPn;function pPn(e,t){return uv(e,t,!0)}ir.rcompare=fPn;function fPn(e,t,r){return uv(t,e,r)}ir.sort=dPn;function dPn(e,t){return e.sort(function(r,n){return ir.compare(r,n,t)})}ir.rsort=hPn;function hPn(e,t){return e.sort(function(r,n){return ir.rcompare(r,n,t)})}ir.gt=fj;function fj(e,t,r){return uv(e,t,r)>0}ir.lt=OW;function OW(e,t,r){return uv(e,t,r)<0}ir.eq=BAe;function BAe(e,t,r){return uv(e,t,r)===0}ir.neq=BNt;function BNt(e,t,r){return uv(e,t,r)!==0}ir.gte=zAe;function zAe(e,t,r){return uv(e,t,r)>=0}ir.lte=HAe;function HAe(e,t,r){return uv(e,t,r)<=0}ir.cmp=SW;function SW(e,t,r,n){switch(t){case"===":return typeof e=="object"&&(e=e.version),typeof r=="object"&&(r=r.version),e===r;case"!==":return typeof e=="object"&&(e=e.version),typeof r=="object"&&(r=r.version),e!==r;case"":case"=":case"==":return BAe(e,r,n);case"!=":return BNt(e,r,n);case">":return fj(e,r,n);case">=":return zAe(e,r,n);case"<":return OW(e,r,n);case"<=":return HAe(e,r,n);default:throw new TypeError("Invalid operator: "+t)}}ir.Comparator=Cf;function Cf(e,t){if((!t||typeof t!="object")&&(t={loose:!!t,includePrerelease:!1}),e instanceof Cf){if(e.loose===!!t.loose)return e;e=e.value}if(!(this instanceof Cf))return new Cf(e,t);e=e.trim().split(/\s+/).join(" "),Bn("comparator",e,t),this.options=t,this.loose=!!t.loose,this.parse(e),this.semver===hj?this.value="":this.value=this.operator+this.semver.version,Bn("comp",this)}var hj={};Cf.prototype.parse=function(e){var t=this.options.loose?yi[VAe]:yi[UAe],r=e.match(t);if(!r)throw new TypeError("Invalid comparator: "+e);this.operator=r[1],this.operator==="="&&(this.operator=""),r[2]?this.semver=new tn(r[2],this.options.loose):this.semver=hj};Cf.prototype.toString=function(){return this.value};Cf.prototype.test=function(e){return Bn("Comparator.test",e,this.options.loose),this.semver===hj?!0:(typeof e=="string"&&(e=new tn(e,this.options)),SW(e,this.operator,this.semver,this.options))};Cf.prototype.intersects=function(e,t){if(!(e instanceof Cf))throw new TypeError("a Comparator is required");(!t||typeof t!="object")&&(t={loose:!!t,includePrerelease:!1});var r;if(this.operator==="")return r=new na(e.value,t),AW(this.value,r,t);if(e.operator==="")return r=new na(this.value,t),AW(e.semver,r,t);var n=(this.operator===">="||this.operator===">")&&(e.operator===">="||e.operator===">"),i=(this.operator==="<="||this.operator==="<")&&(e.operator==="<="||e.operator==="<"),a=this.semver.version===e.semver.version,o=(this.operator===">="||this.operator==="<=")&&(e.operator===">="||e.operator==="<="),s=SW(this.semver,"<",e.semver,t)&&(this.operator===">="||this.operator===">")&&(e.operator==="<="||e.operator==="<"),c=SW(this.semver,">",e.semver,t)&&(this.operator==="<="||this.operator==="<")&&(e.operator===">="||e.operator===">");return n||i||a&&o||s||c};ir.Range=na;function na(e,t){if((!t||typeof t!="object")&&(t={loose:!!t,includePrerelease:!1}),e instanceof na)return e.loose===!!t.loose&&e.includePrerelease===!!t.includePrerelease?e:new na(e.raw,t);if(e instanceof Cf)return new na(e.value,t);if(!(this instanceof na))return new na(e,t);if(this.options=t,this.loose=!!t.loose,this.includePrerelease=!!t.includePrerelease,this.raw=e.trim().split(/\s+/).join(" "),this.set=this.raw.split("||").map(function(r){return this.parseRange(r.trim())},this).filter(function(r){return r.length}),!this.set.length)throw new TypeError("Invalid SemVer Range: "+this.raw);this.format()}na.prototype.format=function(){return this.range=this.set.map(function(e){return e.join(" ").trim()}).join("||").trim(),this.range};na.prototype.toString=function(){return this.range};na.prototype.parseRange=function(e){var t=this.options.loose,r=t?yi[VNt]:yi[qNt];e=e.replace(r,OPn),Bn("hyphen replace",e),e=e.replace(yi[_O],rPn),Bn("comparator trim",e,yi[_O]),e=e.replace(yi[aD],ePn),e=e.replace(yi[oD],tPn);var n=t?yi[VAe]:yi[UAe],i=e.split(" ").map(function(a){return gPn(a,this.options)},this).join(" ").split(/\s+/);return this.options.loose&&(i=i.filter(function(a){return!!a.match(n)})),i=i.map(function(a){return new Cf(a,this.options)},this),i};na.prototype.intersects=function(e,t){if(!(e instanceof na))throw new TypeError("a Range is required");return this.set.some(function(r){return r.every(function(n){return e.set.some(function(i){return i.every(function(a){return n.intersects(a,t)})})})})};ir.toComparators=mPn;function mPn(e,t){return new na(e,t).set.map(function(r){return r.map(function(n){return n.value}).join(" ").trim().split(" ")})}function gPn(e,t){return Bn("comp",e,t),e=bPn(e,t),Bn("caret",e),e=yPn(e,t),Bn("tildes",e),e=_Pn(e,t),Bn("xrange",e),e=TPn(e,t),Bn("stars",e),e}function pu(e){return!e||e.toLowerCase()==="x"||e==="*"}function yPn(e,t){return e.trim().split(/\s+/).map(function(r){return vPn(r,t)}).join(" ")}function vPn(e,t){var r=t.loose?yi[MNt]:yi[$Nt];return e.replace(r,function(n,i,a,o,s){Bn("tilde",e,n,i,a,o,s);var c;return pu(i)?c="":pu(a)?c=">="+i+".0.0 <"+(+i+1)+".0.0":pu(o)?c=">="+i+"."+a+".0 <"+i+"."+(+a+1)+".0":s?(Bn("replaceTilde pr",s),c=">="+i+"."+a+"."+o+"-"+s+" <"+i+"."+(+a+1)+".0"):c=">="+i+"."+a+"."+o+" <"+i+"."+(+a+1)+".0",Bn("tilde return",c),c})}function bPn(e,t){return e.trim().split(/\s+/).map(function(r){return EPn(r,t)}).join(" ")}function EPn(e,t){Bn("caret",e,t);var r=t.loose?yi[jNt]:yi[FNt];return e.replace(r,function(n,i,a,o,s){Bn("caret",e,n,i,a,o,s);var c;return pu(i)?c="":pu(a)?c=">="+i+".0.0 <"+(+i+1)+".0.0":pu(o)?i==="0"?c=">="+i+"."+a+".0 <"+i+"."+(+a+1)+".0":c=">="+i+"."+a+".0 <"+(+i+1)+".0.0":s?(Bn("replaceCaret pr",s),i==="0"?a==="0"?c=">="+i+"."+a+"."+o+"-"+s+" <"+i+"."+a+"."+(+o+1):c=">="+i+"."+a+"."+o+"-"+s+" <"+i+"."+(+a+1)+".0":c=">="+i+"."+a+"."+o+"-"+s+" <"+(+i+1)+".0.0"):(Bn("no pr"),i==="0"?a==="0"?c=">="+i+"."+a+"."+o+" <"+i+"."+a+"."+(+o+1):c=">="+i+"."+a+"."+o+" <"+i+"."+(+a+1)+".0":c=">="+i+"."+a+"."+o+" <"+(+i+1)+".0.0"),Bn("caret return",c),c})}function _Pn(e,t){return Bn("replaceXRanges",e,t),e.split(/\s+/).map(function(r){return xPn(r,t)}).join(" ")}function xPn(e,t){e=e.trim();var r=t.loose?yi[LNt]:yi[RNt];return e.replace(r,function(n,i,a,o,s,c){Bn("xRange",e,n,i,a,o,s,c);var u=pu(a),l=u||pu(o),p=l||pu(s),f=p;return i==="="&&f&&(i=""),u?i===">"||i==="<"?n="<0.0.0":n="*":i&&f?(l&&(o=0),s=0,i===">"?(i=">=",l?(a=+a+1,o=0,s=0):(o=+o+1,s=0)):i==="<="&&(i="<",l?a=+a+1:o=+o+1),n=i+a+"."+o+"."+s):l?n=">="+a+".0.0 <"+(+a+1)+".0.0":p&&(n=">="+a+"."+o+".0 <"+a+"."+(+o+1)+".0"),Bn("xRange return",n),n})}function TPn(e,t){return Bn("replaceStars",e,t),e.trim().replace(yi[UNt],"")}function OPn(e,t,r,n,i,a,o,s,c,u,l,p,f){return pu(r)?t="":pu(n)?t=">="+r+".0.0":pu(i)?t=">="+r+"."+n+".0":t=">="+t,pu(c)?s="":pu(u)?s="<"+(+c+1)+".0.0":pu(l)?s="<"+c+"."+(+u+1)+".0":p?s="<="+c+"."+u+"."+l+"-"+p:s="<="+s,(t+" "+s).trim()}na.prototype.test=function(e){if(!e)return!1;typeof e=="string"&&(e=new tn(e,this.options));for(var t=0;t<this.set.length;t++)if(SPn(this.set[t],e,this.options))return!0;return!1};function SPn(e,t,r){for(var n=0;n<e.length;n++)if(!e[n].test(t))return!1;if(t.prerelease.length&&!r.includePrerelease){for(n=0;n<e.length;n++)if(Bn(e[n].semver),e[n].semver!==hj&&e[n].semver.prerelease.length>0){var i=e[n].semver;if(i.major===t.major&&i.minor===t.minor&&i.patch===t.patch)return!0}return!1}return!0}ir.satisfies=AW;function AW(e,t,r){try{t=new na(t,r)}catch{return!1}return t.test(e)}ir.maxSatisfying=APn;function APn(e,t,r){var n=null,i=null;try{var a=new na(t,r)}catch{return null}return e.forEach(function(o){a.test(o)&&(!n||i.compare(o)===-1)&&(n=o,i=new tn(n,r))}),n}ir.minSatisfying=CPn;function CPn(e,t,r){var n=null,i=null;try{var a=new na(t,r)}catch{return null}return e.forEach(function(o){a.test(o)&&(!n||i.compare(o)===1)&&(n=o,i=new tn(n,r))}),n}ir.minVersion=wPn;function wPn(e,t){e=new na(e,t);var r=new tn("0.0.0");if(e.test(r)||(r=new tn("0.0.0-0"),e.test(r)))return r;r=null;for(var n=0;n<e.set.length;++n){var i=e.set[n];i.forEach(function(a){var o=new tn(a.semver.version);switch(a.operator){case">":o.prerelease.length===0?o.patch++:o.prerelease.push(0),o.raw=o.format();case"":case">=":(!r||fj(r,o))&&(r=o);break;case"<":case"<=":break;default:throw new Error("Unexpected operation: "+a.operator)}})}return r&&e.test(r)?r:null}ir.validRange=PPn;function PPn(e,t){try{return new na(e,t).range||"*"}catch{return null}}ir.ltr=DPn;function DPn(e,t,r){return GAe(e,t,"<",r)}ir.gtr=NPn;function NPn(e,t,r){return GAe(e,t,">",r)}ir.outside=GAe;function GAe(e,t,r,n){e=new tn(e,n),t=new na(t,n);var i,a,o,s,c;switch(r){case">":i=fj,a=HAe,o=OW,s=">",c=">=";break;case"<":i=OW,a=zAe,o=fj,s="<",c="<=";break;default:throw new TypeError('Must provide a hilo val of "<" or ">"')}if(AW(e,t,n))return!1;for(var u=0;u<t.set.length;++u){var l=t.set[u],p=null,f=null;if(l.forEach(function(d){d.semver===hj&&(d=new Cf(">=0.0.0")),p=p||d,f=f||d,i(d.semver,p.semver,n)?p=d:o(d.semver,f.semver,n)&&(f=d)}),p.operator===s||p.operator===c||(!f.operator||f.operator===s)&&a(e,f.semver))return!1;if(f.operator===c&&o(e,f.semver))return!1}return!0}ir.prerelease=IPn;function IPn(e,t){var r=xO(e,t);return r&&r.prerelease.length?r.prerelease:null}ir.intersects=RPn;function RPn(e,t,r){return e=new na(e,r),t=new na(t,r),e.intersects(t)}ir.coerce=LPn;function LPn(e){if(e instanceof tn)return e;if(typeof e!="string")return null;var t=e.match(yi[kNt]);return t==null?null:xO(t[1]+"."+(t[2]||"0")+"."+(t[3]||"0"))}});var KAe=y((a4i,kPn)=>{kPn.exports=["0BSD","3D-Slicer-1.0","AAL","ADSL","AFL-1.1","AFL-1.2","AFL-2.0","AFL-2.1","AFL-3.0","AGPL-1.0-only","AGPL-1.0-or-later","AGPL-3.0-only","AGPL-3.0-or-later","AMD-newlib","AMDPLPA","AML","AML-glslang","AMPAS","ANTLR-PD","ANTLR-PD-fallback","APAFML","APL-1.0","APSL-1.0","APSL-1.1","APSL-1.2","APSL-2.0","ASWF-Digital-Assets-1.0","ASWF-Digital-Assets-1.1","Abstyles","AdaCore-doc","Adobe-2006","Adobe-Display-PostScript","Adobe-Glyph","Adobe-Utopia","Afmparse","Aladdin","Apache-1.0","Apache-1.1","Apache-2.0","App-s2p","Arphic-1999","Artistic-1.0","Artistic-1.0-Perl","Artistic-1.0-cl8","Artistic-2.0","BSD-1-Clause","BSD-2-Clause","BSD-2-Clause-Darwin","BSD-2-Clause-Patent","BSD-2-Clause-Views","BSD-2-Clause-first-lines","BSD-3-Clause","BSD-3-Clause-Attribution","BSD-3-Clause-Clear","BSD-3-Clause-HP","BSD-3-Clause-LBNL","BSD-3-Clause-Modification","BSD-3-Clause-No-Military-License","BSD-3-Clause-No-Nuclear-License","BSD-3-Clause-No-Nuclear-License-2014","BSD-3-Clause-No-Nuclear-Warranty","BSD-3-Clause-Open-MPI","BSD-3-Clause-Sun","BSD-3-Clause-acpica","BSD-3-Clause-flex","BSD-4-Clause","BSD-4-Clause-Shortened","BSD-4-Clause-UC","BSD-4.3RENO","BSD-4.3TAHOE","BSD-Advertising-Acknowledgement","BSD-Attribution-HPND-disclaimer","BSD-Inferno-Nettverk","BSD-Protection","BSD-Source-Code","BSD-Source-beginning-file","BSD-Systemics","BSD-Systemics-W3Works","BSL-1.0","BUSL-1.1","Baekmuk","Bahyph","Barr","Beerware","BitTorrent-1.0","BitTorrent-1.1","Bitstream-Charter","Bitstream-Vera","BlueOak-1.0.0","Boehm-GC","Borceux","Brian-Gladman-2-Clause","Brian-Gladman-3-Clause","C-UDA-1.0","CAL-1.0","CAL-1.0-Combined-Work-Exception","CATOSL-1.1","CC-BY-1.0","CC-BY-2.0","CC-BY-2.5","CC-BY-2.5-AU","CC-BY-3.0","CC-BY-3.0-AT","CC-BY-3.0-AU","CC-BY-3.0-DE","CC-BY-3.0-IGO","CC-BY-3.0-NL","CC-BY-3.0-US","CC-BY-4.0","CC-BY-NC-1.0","CC-BY-NC-2.0","CC-BY-NC-2.5","CC-BY-NC-3.0","CC-BY-NC-3.0-DE","CC-BY-NC-4.0","CC-BY-NC-ND-1.0","CC-BY-NC-ND-2.0","CC-BY-NC-ND-2.5","CC-BY-NC-ND-3.0","CC-BY-NC-ND-3.0-DE","CC-BY-NC-ND-3.0-IGO","CC-BY-NC-ND-4.0","CC-BY-NC-SA-1.0","CC-BY-NC-SA-2.0","CC-BY-NC-SA-2.0-DE","CC-BY-NC-SA-2.0-FR","CC-BY-NC-SA-2.0-UK","CC-BY-NC-SA-2.5","CC-BY-NC-SA-3.0","CC-BY-NC-SA-3.0-DE","CC-BY-NC-SA-3.0-IGO","CC-BY-NC-SA-4.0","CC-BY-ND-1.0","CC-BY-ND-2.0","CC-BY-ND-2.5","CC-BY-ND-3.0","CC-BY-ND-3.0-DE","CC-BY-ND-4.0","CC-BY-SA-1.0","CC-BY-SA-2.0","CC-BY-SA-2.0-UK","CC-BY-SA-2.1-JP","CC-BY-SA-2.5","CC-BY-SA-3.0","CC-BY-SA-3.0-AT","CC-BY-SA-3.0-DE","CC-BY-SA-3.0-IGO","CC-BY-SA-4.0","CC-PDDC","CC0-1.0","CDDL-1.0","CDDL-1.1","CDL-1.0","CDLA-Permissive-1.0","CDLA-Permissive-2.0","CDLA-Sharing-1.0","CECILL-1.0","CECILL-1.1","CECILL-2.0","CECILL-2.1","CECILL-B","CECILL-C","CERN-OHL-1.1","CERN-OHL-1.2","CERN-OHL-P-2.0","CERN-OHL-S-2.0","CERN-OHL-W-2.0","CFITSIO","CMU-Mach","CMU-Mach-nodoc","CNRI-Jython","CNRI-Python","CNRI-Python-GPL-Compatible","COIL-1.0","CPAL-1.0","CPL-1.0","CPOL-1.02","CUA-OPL-1.0","Caldera","Caldera-no-preamble","Catharon","ClArtistic","Clips","Community-Spec-1.0","Condor-1.1","Cornell-Lossless-JPEG","Cronyx","Crossword","CrystalStacker","Cube","D-FSL-1.0","DEC-3-Clause","DL-DE-BY-2.0","DL-DE-ZERO-2.0","DOC","DRL-1.0","DRL-1.1","DSDP","Dotseqn","ECL-1.0","ECL-2.0","EFL-1.0","EFL-2.0","EPICS","EPL-1.0","EPL-2.0","EUDatagrid","EUPL-1.0","EUPL-1.1","EUPL-1.2","Elastic-2.0","Entessa","ErlPL-1.1","Eurosym","FBM","FDK-AAC","FSFAP","FSFAP-no-warranty-disclaimer","FSFUL","FSFULLR","FSFULLRWD","FTL","Fair","Ferguson-Twofish","Frameworx-1.0","FreeBSD-DOC","FreeImage","Furuseth","GCR-docs","GD","GFDL-1.1-invariants-only","GFDL-1.1-invariants-or-later","GFDL-1.1-no-invariants-only","GFDL-1.1-no-invariants-or-later","GFDL-1.1-only","GFDL-1.1-or-later","GFDL-1.2-invariants-only","GFDL-1.2-invariants-or-later","GFDL-1.2-no-invariants-only","GFDL-1.2-no-invariants-or-later","GFDL-1.2-only","GFDL-1.2-or-later","GFDL-1.3-invariants-only","GFDL-1.3-invariants-or-later","GFDL-1.3-no-invariants-only","GFDL-1.3-no-invariants-or-later","GFDL-1.3-only","GFDL-1.3-or-later","GL2PS","GLWTPL","GPL-1.0-only","GPL-1.0-or-later","GPL-2.0-only","GPL-2.0-or-later","GPL-3.0-only","GPL-3.0-or-later","Giftware","Glide","Glulxe","Graphics-Gems","Gutmann","HP-1986","HP-1989","HPND","HPND-DEC","HPND-Fenneberg-Livingston","HPND-INRIA-IMAG","HPND-Intel","HPND-Kevlin-Henney","HPND-MIT-disclaimer","HPND-Markus-Kuhn","HPND-Pbmplus","HPND-UC","HPND-UC-export-US","HPND-doc","HPND-doc-sell","HPND-export-US","HPND-export-US-acknowledgement","HPND-export-US-modify","HPND-export2-US","HPND-merchantability-variant","HPND-sell-MIT-disclaimer-xserver","HPND-sell-regexpr","HPND-sell-variant","HPND-sell-variant-MIT-disclaimer","HPND-sell-variant-MIT-disclaimer-rev","HTMLTIDY","HaskellReport","Hippocratic-2.1","IBM-pibs","ICU","IEC-Code-Components-EULA","IJG","IJG-short","IPA","IPL-1.0","ISC","ISC-Veillard","ImageMagick","Imlib2","Info-ZIP","Inner-Net-2.0","Intel","Intel-ACPI","Interbase-1.0","JPL-image","JPNIC","JSON","Jam","JasPer-2.0","Kastrup","Kazlib","Knuth-CTAN","LAL-1.2","LAL-1.3","LGPL-2.0-only","LGPL-2.0-or-later","LGPL-2.1-only","LGPL-2.1-or-later","LGPL-3.0-only","LGPL-3.0-or-later","LGPLLR","LOOP","LPD-document","LPL-1.0","LPL-1.02","LPPL-1.0","LPPL-1.1","LPPL-1.2","LPPL-1.3a","LPPL-1.3c","LZMA-SDK-9.11-to-9.20","LZMA-SDK-9.22","Latex2e","Latex2e-translated-notice","Leptonica","LiLiQ-P-1.1","LiLiQ-R-1.1","LiLiQ-Rplus-1.1","Libpng","Linux-OpenIB","Linux-man-pages-1-para","Linux-man-pages-copyleft","Linux-man-pages-copyleft-2-para","Linux-man-pages-copyleft-var","Lucida-Bitmap-Fonts","MIT","MIT-0","MIT-CMU","MIT-Festival","MIT-Khronos-old","MIT-Modern-Variant","MIT-Wu","MIT-advertising","MIT-enna","MIT-feh","MIT-open-group","MIT-testregex","MITNFA","MMIXware","MPEG-SSG","MPL-1.0","MPL-1.1","MPL-2.0","MPL-2.0-no-copyleft-exception","MS-LPL","MS-PL","MS-RL","MTLL","Mackerras-3-Clause","Mackerras-3-Clause-acknowledgment","MakeIndex","Martin-Birgmeier","McPhee-slideshow","Minpack","MirOS","Motosoto","MulanPSL-1.0","MulanPSL-2.0","Multics","Mup","NAIST-2003","NASA-1.3","NBPL-1.0","NCBI-PD","NCGL-UK-2.0","NCL","NCSA","NGPL","NICTA-1.0","NIST-PD","NIST-PD-fallback","NIST-Software","NLOD-1.0","NLOD-2.0","NLPL","NOSL","NPL-1.0","NPL-1.1","NPOSL-3.0","NRL","NTP","NTP-0","Naumen","Net-SNMP","NetCDF","Newsletr","Nokia","Noweb","O-UDA-1.0","OAR","OCCT-PL","OCLC-2.0","ODC-By-1.0","ODbL-1.0","OFFIS","OFL-1.0","OFL-1.0-RFN","OFL-1.0-no-RFN","OFL-1.1","OFL-1.1-RFN","OFL-1.1-no-RFN","OGC-1.0","OGDL-Taiwan-1.0","OGL-Canada-2.0","OGL-UK-1.0","OGL-UK-2.0","OGL-UK-3.0","OGTSL","OLDAP-1.1","OLDAP-1.2","OLDAP-1.3","OLDAP-1.4","OLDAP-2.0","OLDAP-2.0.1","OLDAP-2.1","OLDAP-2.2","OLDAP-2.2.1","OLDAP-2.2.2","OLDAP-2.3","OLDAP-2.4","OLDAP-2.5","OLDAP-2.6","OLDAP-2.7","OLDAP-2.8","OLFL-1.3","OML","OPL-1.0","OPL-UK-3.0","OPUBL-1.0","OSET-PL-2.1","OSL-1.0","OSL-1.1","OSL-2.0","OSL-2.1","OSL-3.0","OpenPBS-2.3","OpenSSL","OpenSSL-standalone","OpenVision","PADL","PDDL-1.0","PHP-3.0","PHP-3.01","PPL","PSF-2.0","Parity-6.0.0","Parity-7.0.0","Pixar","Plexus","PolyForm-Noncommercial-1.0.0","PolyForm-Small-Business-1.0.0","PostgreSQL","Python-2.0","Python-2.0.1","QPL-1.0","QPL-1.0-INRIA-2004","Qhull","RHeCos-1.1","RPL-1.1","RPL-1.5","RPSL-1.0","RSA-MD","RSCPL","Rdisc","Ruby","SAX-PD","SAX-PD-2.0","SCEA","SGI-B-1.0","SGI-B-1.1","SGI-B-2.0","SGI-OpenGL","SGP4","SHL-0.5","SHL-0.51","SISSL","SISSL-1.2","SL","SMLNJ","SMPPL","SNIA","SPL-1.0","SSH-OpenSSH","SSH-short","SSLeay-standalone","SSPL-1.0","SWL","Saxpath","SchemeReport","Sendmail","Sendmail-8.23","SimPL-2.0","Sleepycat","Soundex","Spencer-86","Spencer-94","Spencer-99","SugarCRM-1.1.3","Sun-PPP","Sun-PPP-2000","SunPro","Symlinks","TAPR-OHL-1.0","TCL","TCP-wrappers","TGPPL-1.0","TMate","TORQUE-1.1","TOSL","TPDL","TPL-1.0","TTWL","TTYP0","TU-Berlin-1.0","TU-Berlin-2.0","TermReadKey","UCAR","UCL-1.0","UMich-Merit","UPL-1.0","URT-RLE","Unicode-3.0","Unicode-DFS-2015","Unicode-DFS-2016","Unicode-TOU","UnixCrypt","Unlicense","VOSTROM","VSL-1.0","Vim","W3C","W3C-19980720","W3C-20150513","WTFPL","Watcom-1.0","Widget-Workshop","Wsuipa","X11","X11-distribute-modifications-variant","XFree86-1.1","XSkat","Xdebug-1.03","Xerox","Xfig","Xnet","YPL-1.0","YPL-1.1","ZPL-1.1","ZPL-2.0","ZPL-2.1","Zed","Zeeff","Zend-2.0","Zimbra-1.3","Zimbra-1.4","Zlib","any-OSI","bcrypt-Solar-Designer","blessing","bzip2-1.0.6","check-cvs","checkmk","copyleft-next-0.3.0","copyleft-next-0.3.1","curl","cve-tou","diffmark","dtoa","dvipdfm","eGenix","etalab-2.0","fwlw","gSOAP-1.3b","gnuplot","gtkbook","hdparm","iMatix","libpng-2.0","libselinux-1.0","libtiff","libutil-David-Nugent","lsof","magaz","mailprio","metamail","mpi-permissive","mpich2","mplus","pkgconf","pnmstitch","psfrag","psutils","python-ldap","radvd","snprintf","softSurfer","ssh-keyscan","swrule","threeparttable","ulem","w3m","xinetd","xkeyboard-config-Zinoviev","xlock","xpp","xzoom","zlib-acknowledgement"]});var HNt=y((o4i,$Pn)=>{$Pn.exports=["AGPL-1.0","AGPL-3.0","BSD-2-Clause-FreeBSD","BSD-2-Clause-NetBSD","GFDL-1.1","GFDL-1.2","GFDL-1.3","GPL-1.0","GPL-2.0","GPL-2.0-with-GCC-exception","GPL-2.0-with-autoconf-exception","GPL-2.0-with-bison-exception","GPL-2.0-with-classpath-exception","GPL-2.0-with-font-exception","GPL-3.0","GPL-3.0-with-GCC-exception","GPL-3.0-with-autoconf-exception","LGPL-2.0","LGPL-2.1","LGPL-3.0","Nunit","StandardML-NJ","bzip2-1.0.5","eCos-2.0","wxWindows"]});var GNt=y((s4i,MPn)=>{MPn.exports=["389-exception","Asterisk-exception","Autoconf-exception-2.0","Autoconf-exception-3.0","Autoconf-exception-generic","Autoconf-exception-generic-3.0","Autoconf-exception-macro","Bison-exception-1.24","Bison-exception-2.2","Bootloader-exception","Classpath-exception-2.0","CLISP-exception-2.0","cryptsetup-OpenSSL-exception","DigiRule-FOSS-exception","eCos-exception-2.0","Fawkes-Runtime-exception","FLTK-exception","fmt-exception","Font-exception-2.0","freertos-exception-2.0","GCC-exception-2.0","GCC-exception-2.0-note","GCC-exception-3.1","Gmsh-exception","GNAT-exception","GNOME-examples-exception","GNU-compiler-exception","gnu-javamail-exception","GPL-3.0-interface-exception","GPL-3.0-linking-exception","GPL-3.0-linking-source-exception","GPL-CC-1.0","GStreamer-exception-2005","GStreamer-exception-2008","i2p-gpl-java-exception","KiCad-libraries-exception","LGPL-3.0-linking-exception","libpri-OpenH323-exception","Libtool-exception","Linux-syscall-note","LLGPL","LLVM-exception","LZMA-exception","mif-exception","OCaml-LGPL-linking-exception","OCCT-exception-1.0","OpenJDK-assembly-exception-1.0","openvpn-openssl-exception","PS-or-PDF-font-exception-20170817","QPL-1.0-INRIA-2004-exception","Qt-GPL-exception-1.0","Qt-LGPL-exception-1.1","Qwt-exception-1.0","SANE-exception","SHL-2.0","SHL-2.1","stunnel-exception","SWI-exception","Swift-exception","Texinfo-exception","u-boot-exception-2.0","UBDL-exception","Universal-FOSS-exception-1.0","vsftpd-openssl-exception","WxWindows-exception-3.1","x11vnc-openssl-exception"]});var YNt=y((c4i,KNt)=>{"use strict";var FPn=[].concat(KAe()).concat(HNt()),jPn=GNt();KNt.exports=function(e){var t=0;function r(){return t<e.length}function n(h){if(h instanceof RegExp){var m=e.slice(t),v=m.match(h);if(v)return t+=v[0].length,v[0]}else if(e.indexOf(h,t)===t)return t+=h.length,h}function i(){n(/[ ]*/)}function a(){for(var h,m=["WITH","AND","OR","(",")",":","+"],v=0;v<m.length&&(h=n(m[v]),!h);v++);if(h==="+"&&t>1&&e[t-2]===" ")throw new Error("Space before `+`");return h&&{type:"OPERATOR",string:h}}function o(){return n(/[A-Za-z0-9-.]+/)}function s(){var h=o();if(!h)throw new Error("Expected idstring at offset "+t);return h}function c(){if(n("DocumentRef-")){var h=s();return{type:"DOCUMENTREF",string:h}}}function u(){if(n("LicenseRef-")){var h=s();return{type:"LICENSEREF",string:h}}}function l(){var h=t,m=o();if(FPn.indexOf(m)!==-1)return{type:"LICENSE",string:m};if(jPn.indexOf(m)!==-1)return{type:"EXCEPTION",string:m};t=h}function p(){return a()||c()||u()||l()}for(var f=[];r()&&(i(),!!r());){var d=p();if(!d)throw new Error("Unexpected `"+e[t]+"` at offset "+t);f.push(d)}return f}});var XNt=y((u4i,WNt)=>{"use strict";WNt.exports=function(e){var t=0;function r(){return t<e.length}function n(){return r()?e[t]:null}function i(){if(!r())throw new Error;t++}function a(m){var v=n();if(v&&v.type==="OPERATOR"&&m===v.string)return i(),v.string}function o(){if(a("WITH")){var m=n();if(m&&m.type==="EXCEPTION")return i(),m.string;throw new Error("Expected exception after `WITH`")}}function s(){var m=t,v="",_=n();if(_.type==="DOCUMENTREF"&&(i(),v+="DocumentRef-"+_.string+":",!a(":")))throw new Error("Expected `:` after `DocumentRef-...`");if(_=n(),_.type==="LICENSEREF")return i(),v+="LicenseRef-"+_.string,{license:v};t=m}function c(){var m=n();if(m&&m.type==="LICENSE"){i();var v={license:m.string};a("+")&&(v.plus=!0);var _=o();return _&&(v.exception=_),v}}function u(){var m=a("(");if(m){var v=d();if(!a(")"))throw new Error("Expected `)`");return v}}function l(){return u()||s()||c()}function p(m,v){return function _(){var T=v();if(T){if(!a(m))return T;var O=_();if(!O)throw new Error("Expected expression");return{left:T,conjunction:m.toLowerCase(),right:O}}}}var f=p("AND",l),d=p("OR",f),h=d();if(!h||r())throw new Error("Syntax error");return h}});var YAe=y((l4i,JNt)=>{"use strict";var qPn=YNt(),VPn=XNt();JNt.exports=function(e){return VPn(qPn(e))}});var aIt=y((p4i,iIt)=>{var UPn=YAe(),BPn=KAe();function NW(e){try{return UPn(e),!0}catch{return!1}}var ZNt=[["APGL","AGPL"],["Gpl","GPL"],["GLP","GPL"],["APL","Apache"],["ISD","ISC"],["GLP","GPL"],["IST","ISC"],["Claude","Clause"],[" or later","+"],[" International",""],["GNU","GPL"],["GUN","GPL"],["+",""],["GNU GPL","GPL"],["GNU/GPL","GPL"],["GNU GLP","GPL"],["GNU General Public License","GPL"],["Gnu public license","GPL"],["GNU Public License","GPL"],["GNU GENERAL PUBLIC LICENSE","GPL"],["MTI","MIT"],["Mozilla Public License","MPL"],["Universal Permissive License","UPL"],["WTH","WTF"],["-License",""]],zPn=0,HPn=1,QNt=[function(e){return e.toUpperCase()},function(e){return e.trim()},function(e){return e.replace(/\./g,"")},function(e){return e.replace(/\s+/g,"")},function(e){return e.replace(/\s+/g,"-")},function(e){return e.replace("v","-")},function(e){return e.replace(/,?\s*(\d)/,"-$1")},function(e){return e.replace(/,?\s*(\d)/,"-$1.0")},function(e){return e.replace(/,?\s*(V\.|v\.|V|v|Version|version)\s*(\d)/,"-$2")},function(e){return e.replace(/,?\s*(V\.|v\.|V|v|Version|version)\s*(\d)/,"-$2.0")},function(e){return e[0].toUpperCase()+e.slice(1)},function(e){return e.replace("/","-")},function(e){return e.replace(/\s*V\s*(\d)/,"-$1").replace(/(\d)$/,"$1.0")},function(e){return e.indexOf("3.0")!==-1?e+"-or-later":e+"-only"},function(e){return e+"only"},function(e){return e.replace(/(\d)$/,"-$1.0")},function(e){return e.replace(/(-| )?(\d)$/,"-$2-Clause")},function(e){return e.replace(/(-| )clause(-| )(\d)/,"-$3-Clause")},function(e){return e.replace(/\b(Modified|New|Revised)(-| )?BSD((-| )License)?/i,"BSD-3-Clause")},function(e){return e.replace(/\bSimplified(-| )?BSD((-| )License)?/i,"BSD-2-Clause")},function(e){return e.replace(/\b(Free|Net)(-| )?BSD((-| )License)?/i,"BSD-2-Clause-$1BSD")},function(e){return e.replace(/\bClear(-| )?BSD((-| )License)?/i,"BSD-3-Clause-Clear")},function(e){return e.replace(/\b(Old|Original)(-| )?BSD((-| )License)?/i,"BSD-4-Clause")},function(e){return"CC-"+e},function(e){return"CC-"+e+"-4.0"},function(e){return e.replace("Attribution","BY").replace("NonCommercial","NC").replace("NoDerivatives","ND").replace(/ (\d)/,"-$1").replace(/ ?International/,"")},function(e){return"CC-"+e.replace("Attribution","BY").replace("NonCommercial","NC").replace("NoDerivatives","ND").replace(/ (\d)/,"-$1").replace(/ ?International/,"")+"-4.0"}],WAe=BPn.map(function(e){var t=/^(.*)-\d+\.\d+$/.exec(e);return t?[t[0],t[1]]:[e,null]}).reduce(function(e,t){var r=t[1];return e[r]=e[r]||[],e[r].push(t[0]),e},{}),GPn=Object.keys(WAe).map(function(t){return[t,WAe[t]]}).filter(function(t){return t[1].length===1&&t[0]!==null&&t[0]!=="APL"}).map(function(t){return[t[0],t[1][0]]});WAe=void 0;var eIt=[["UNLI","Unlicense"],["WTF","WTFPL"],["2 CLAUSE","BSD-2-Clause"],["2-CLAUSE","BSD-2-Clause"],["3 CLAUSE","BSD-3-Clause"],["3-CLAUSE","BSD-3-Clause"],["AFFERO","AGPL-3.0-or-later"],["AGPL","AGPL-3.0-or-later"],["APACHE","Apache-2.0"],["ARTISTIC","Artistic-2.0"],["Affero","AGPL-3.0-or-later"],["BEER","Beerware"],["BOOST","BSL-1.0"],["BSD","BSD-2-Clause"],["CDDL","CDDL-1.1"],["ECLIPSE","EPL-1.0"],["FUCK","WTFPL"],["GNU","GPL-3.0-or-later"],["LGPL","LGPL-3.0-or-later"],["GPLV1","GPL-1.0-only"],["GPL-1","GPL-1.0-only"],["GPLV2","GPL-2.0-only"],["GPL-2","GPL-2.0-only"],["GPL","GPL-3.0-or-later"],["MIT +NO-FALSE-ATTRIBS","MITNFA"],["MIT","MIT"],["MPL","MPL-2.0"],["X11","X11"],["ZLIB","Zlib"]].concat(GPn),KPn=0,YPn=1,tIt=function(e){for(var t=0;t<QNt.length;t++){var r=QNt[t](e).trim();if(r!==e&&NW(r))return r}return null},rIt=function(e){for(var t=e.toUpperCase(),r=0;r<eIt.length;r++){var n=eIt[r];if(t.indexOf(n[KPn])>-1)return n[YPn]}return null},nIt=function(e,t){for(var r=0;r<ZNt.length;r++){var n=ZNt[r],i=n[zPn];if(e.indexOf(i)>-1){var a=e.replace(i,n[HPn]),o=t(a);if(o!==null)return o}}return null};iIt.exports=function(e,t){t=t||{};var r=t.upgrade===void 0?!0:!!t.upgrade;function n(s){return r?WPn(s):s}var i=typeof e=="string"&&e.trim().length!==0;if(!i)throw Error("Invalid argument. Expected non-empty string.");if(e=e.trim(),NW(e))return n(e);var a=e.replace(/\+$/,"").trim();if(NW(a))return n(a);var o=tIt(e);return o!==null||(o=nIt(e,function(s){return NW(s)?s:tIt(s)}),o!==null)||(o=rIt(e),o!==null)||(o=nIt(e,rIt),o!==null)?n(o):null};function WPn(e){return["GPL-1.0","LGPL-1.0","AGPL-1.0","GPL-2.0","LGPL-2.0","AGPL-2.0","LGPL-2.1"].indexOf(e)!==-1?e+"-only":["GPL-1.0+","GPL-2.0+","GPL-3.0+","LGPL-2.0+","LGPL-2.1+","LGPL-3.0+","AGPL-1.0+","AGPL-3.0+"].indexOf(e)!==-1?e.replace(/\+$/,"-or-later"):["GPL-3.0","LGPL-3.0","AGPL-3.0"].indexOf(e)!==-1?e+"-or-later":e}});var uIt=y((f4i,cIt)=>{var XPn=YAe(),JPn=aIt(),oIt='license should be a valid SPDX license expression (without "LicenseRef"), "UNLICENSED", or "SEE LICENSE IN <filename>"',ZPn=/^SEE LICEN[CS]E IN (.+)$/;function sIt(e,t){return t.slice(0,e.length)===e}function XAe(e){if(e.hasOwnProperty("license")){var t=e.license;return sIt("LicenseRef",t)||sIt("DocumentRef",t)}else return XAe(e.left)||XAe(e.right)}cIt.exports=function(e){var t;try{t=XPn(e)}catch{var r;if(e==="UNLICENSED"||e==="UNLICENCED")return{validForOldPackages:!0,validForNewPackages:!0,unlicensed:!0};if(r=ZPn.exec(e))return{validForOldPackages:!0,validForNewPackages:!0,inFile:r[1]};var n={validForOldPackages:!1,validForNewPackages:!1,warnings:[oIt]};if(e.trim().length!==0){var i=JPn(e);i&&n.warnings.push('license is similar to the valid expression "'+i+'"')}return n}return XAe(t)?{validForNewPackages:!1,validForOldPackages:!1,spdx:!0,warnings:[oIt]}:{validForNewPackages:!0,validForOldPackages:!0,spdx:!0}}});var JAe=y((d4i,fIt)=>{"use strict";var mj=fIt.exports={github:{protocols:["git","http","git+ssh","git+https","ssh","https"],domain:"github.com",treepath:"tree",filetemplate:"https://{auth@}raw.githubusercontent.com/{user}/{project}/{committish}/{path}",bugstemplate:"https://{domain}/{user}/{project}/issues",gittemplate:"git://{auth@}{domain}/{user}/{project}.git{#committish}",tarballtemplate:"https://codeload.{domain}/{user}/{project}/tar.gz/{committish}"},bitbucket:{protocols:["git+ssh","git+https","ssh","https"],domain:"bitbucket.org",treepath:"src",tarballtemplate:"https://{domain}/{user}/{project}/get/{committish}.tar.gz"},gitlab:{protocols:["git+ssh","git+https","ssh","https"],domain:"gitlab.com",treepath:"tree",bugstemplate:"https://{domain}/{user}/{project}/issues",httpstemplate:"git+https://{auth@}{domain}/{user}/{projectPath}.git{#committish}",tarballtemplate:"https://{domain}/{user}/{project}/repository/archive.tar.gz?ref={committish}",pathmatch:/^[/]([^/]+)[/]((?!.*(\/-\/|\/repository\/archive\.tar\.gz\?=.*|\/repository\/[^/]+\/archive.tar.gz$)).*?)(?:[.]git|[/])?$/},gist:{protocols:["git","git+ssh","git+https","ssh","https"],domain:"gist.github.com",pathmatch:/^[/](?:([^/]+)[/])?([a-z0-9]{32,})(?:[.]git)?$/,filetemplate:"https://gist.githubusercontent.com/{user}/{project}/raw{/committish}/{path}",bugstemplate:"https://{domain}/{project}",gittemplate:"git://{domain}/{project}.git{#committish}",sshtemplate:"git@{domain}:/{project}.git{#committish}",sshurltemplate:"git+ssh://git@{domain}/{project}.git{#committish}",browsetemplate:"https://{domain}/{project}{/committish}",browsefiletemplate:"https://{domain}/{project}{/committish}{#path}",docstemplate:"https://{domain}/{project}{/committish}",httpstemplate:"git+https://{domain}/{project}.git{#committish}",shortcuttemplate:"{type}:{project}{#committish}",pathtemplate:"{project}{#committish}",tarballtemplate:"https://codeload.github.com/gist/{project}/tar.gz/{committish}",hashformat:function(e){return"file-"+pIt(e)}}},lIt={sshtemplate:"git@{domain}:{user}/{project}.git{#committish}",sshurltemplate:"git+ssh://git@{domain}/{user}/{project}.git{#committish}",browsetemplate:"https://{domain}/{user}/{project}{/tree/committish}",browsefiletemplate:"https://{domain}/{user}/{project}/{treepath}/{committish}/{path}{#fragment}",docstemplate:"https://{domain}/{user}/{project}{/tree/committish}#readme",httpstemplate:"git+https://{auth@}{domain}/{user}/{project}.git{#committish}",filetemplate:"https://{domain}/{user}/{project}/raw/{committish}/{path}",shortcuttemplate:"{type}:{user}/{project}{#committish}",pathtemplate:"{user}/{project}{#committish}",pathmatch:/^[/]([^/]+)[/]([^/]+?)(?:[.]git|[/])?$/,hashformat:pIt};Object.keys(mj).forEach(function(e){Object.keys(lIt).forEach(function(t){mj[e][t]||(mj[e][t]=lIt[t])}),mj[e].protocols_re=RegExp("^("+mj[e].protocols.map(function(t){return t.replace(/([\\+*{}()[\]$^|])/g,"\\$1")}).join("|")+"):$")});function pIt(e){return e.toLowerCase().replace(/^\W+|\/|\W+$/g,"").replace(/\W+/g,"-")}});var mIt=y((h4i,hIt)=>{"use strict";var dIt=JAe(),cD=Object.assign||function(t,r){if(r===null||typeof r!="object")return t;for(var n=Object.keys(r),i=n.length;i--;)t[n[i]]=r[n[i]];return t};hIt.exports=yc;function yc(e,t,r,n,i,a,o){var s=this;s.type=e,Object.keys(dIt[e]).forEach(function(c){s[c]=dIt[e][c]}),s.user=t,s.auth=r,s.project=n,s.committish=i,s.default=a,s.opts=o||{}}yc.prototype.hash=function(){return this.committish?"#"+this.committish:""};yc.prototype._fill=function(e,t){if(e){var r=cD({},t);r.path=r.path?r.path.replace(/^[/]+/g,""):"",t=cD(cD({},this.opts),t);var n=this;Object.keys(this).forEach(function(l){n[l]!=null&&r[l]==null&&(r[l]=n[l])});var i=r.auth,a=r.committish,o=r.fragment,s=r.path,c=r.project;Object.keys(r).forEach(function(l){var p=r[l];(l==="path"||l==="project")&&typeof p=="string"?r[l]=p.split("/").map(function(f){return encodeURIComponent(f)}).join("/"):r[l]=encodeURIComponent(p)}),r["auth@"]=i?i+"@":"",r["#fragment"]=o?"#"+this.hashformat(o):"",r.fragment=r.fragment?r.fragment:"",r["#path"]=s?"#"+this.hashformat(s):"",r["/path"]=r.path?"/"+r.path:"",r.projectPath=c.split("/").map(encodeURIComponent).join("/"),t.noCommittish?(r["#committish"]="",r["/tree/committish"]="",r["/committish"]="",r.committish=""):(r["#committish"]=a?"#"+a:"",r["/tree/committish"]=r.committish?"/"+r.treepath+"/"+r.committish:"",r["/committish"]=r.committish?"/"+r.committish:"",r.committish=r.committish||"master");var u=e;return Object.keys(r).forEach(function(l){u=u.replace(new RegExp("[{]"+l+"[}]","g"),r[l])}),t.noGitPlus?u.replace(/^git[+]/,""):u}};yc.prototype.ssh=function(e){return this._fill(this.sshtemplate,e)};yc.prototype.sshurl=function(e){return this._fill(this.sshurltemplate,e)};yc.prototype.browse=function(e,t,r){return typeof e=="string"?(typeof t!="string"&&(r=t,t=null),this._fill(this.browsefiletemplate,cD({fragment:t,path:e},r))):this._fill(this.browsetemplate,e)};yc.prototype.docs=function(e){return this._fill(this.docstemplate,e)};yc.prototype.bugs=function(e){return this._fill(this.bugstemplate,e)};yc.prototype.https=function(e){return this._fill(this.httpstemplate,e)};yc.prototype.git=function(e){return this._fill(this.gittemplate,e)};yc.prototype.shortcut=function(e){return this._fill(this.shortcuttemplate,e)};yc.prototype.path=function(e){return this._fill(this.pathtemplate,e)};yc.prototype.tarball=function(e){var t=cD({},e,{noCommittish:!1});return this._fill(this.tarballtemplate,t)};yc.prototype.file=function(e,t){return this._fill(this.filetemplate,cD({path:e},t))};yc.prototype.getDefaultRepresentation=function(){return this.default};yc.prototype.toString=function(e){return this.default&&typeof this[this.default]=="function"?this[this.default](e):this.sshurl(e)}});var yIt=y((m4i,QAe)=>{"use strict";var IW=require("url"),gIt=JAe(),QPn=QAe.exports=mIt(),eDn={"git+ssh:":"sshurl","git+https:":"https","ssh:":"sshurl","git:":"git"};function tDn(e){return eDn[e]||e.slice(0,-1)}var rDn={"git:":!0,"https:":!0,"git+https:":!0,"http:":!0,"git+http:":!0},ZAe={};QAe.exports.fromUrl=function(e,t){if(typeof e=="string"){var r=e+JSON.stringify(t||{});return r in ZAe||(ZAe[r]=nDn(e,t)),ZAe[r]}};function nDn(e,t){if(!(e==null||e==="")){var r=aDn(iDn(e)?"github:"+e:e),n=oDn(r),i=r.match(/^([^:]+):(?:[^@]+@)?(?:([^/]*)\/)?([^#]+)/),a=Object.keys(gIt).map(function(o){try{var s=gIt[o],c=null;n.auth&&rDn[n.protocol]&&(c=n.auth);var u=n.hash?decodeURIComponent(n.hash.substr(1)):null,l=null,p=null,f=null;if(i&&i[1]===o)l=i[2]&&decodeURIComponent(i[2]),p=decodeURIComponent(i[3].replace(/\.git$/,"")),f="shortcut";else{if(n.host&&n.host!==s.domain&&n.host.replace(/^www[.]/,"")!==s.domain||!s.protocols_re.test(n.protocol)||!n.path)return;var d=s.pathmatch,h=n.path.match(d);if(!h)return;h[1]!==null&&h[1]!==void 0&&(l=decodeURIComponent(h[1].replace(/^:/,""))),p=decodeURIComponent(h[2]),f=tDn(n.protocol)}return new QPn(o,l,c,p,u,f,t)}catch(m){if(!(m instanceof URIError))throw m}}).filter(function(o){return o});if(a.length===1)return a[0]}}function iDn(e){return/^[^:@%/\s.-][^:@%/\s]*[/][^:@\s/%]+(?:#.*)?$/.test(e)}function aDn(e){var t=IW.parse(e);return t.protocol==="gist:"&&t.host&&!t.path?t.protocol+"/"+t.host:e}function oDn(e){var t=e.match(/^([^@]+)@([^:/]+):[/]?((?:[^/]+[/])?[^/]+?)(?:[.]git)?(#.*)?$/);if(!t){var r=IW.parse(e);if(r.auth&&typeof IW.URL=="function"){var n=e.match(/[^@]+@[^:/]+/);if(n){var i=new IW.URL(n[0]);r.auth=i.username||"",i.password&&(r.auth+=":"+i.password)}}return r}return{protocol:"git+ssh:",slashes:!0,auth:t[1],host:t[2],port:null,hostname:t[2],hash:t[4],search:null,query:null,pathname:"/"+t[3],path:"/"+t[3],href:"git+ssh://"+t[1]+"@"+t[2]+"/"+t[3]+(t[4]||"")}}});var eCe=y((g4i,vIt)=>{"use strict";var sDn=require("os");vIt.exports=sDn.homedir||function(){var t=process.env.HOME,r=process.env.LOGNAME||process.env.USER||process.env.LNAME||process.env.USERNAME;return process.platform==="win32"?process.env.USERPROFILE||process.env.HOMEDRIVE+process.env.HOMEPATH||t||null:process.platform==="darwin"?t||(r?"/Users/"+r:null):process.platform==="linux"?t||(process.getuid()===0?"/root":r?"/home/"+r:null):t||null}});var tCe=y((y4i,bIt)=>{bIt.exports=function(){var e=Error.prepareStackTrace;Error.prepareStackTrace=function(r,n){return n};var t=new Error().stack;return Error.prepareStackTrace=e,t[2].getFileName()}});var EIt=y((v4i,gj)=>{"use strict";var cDn=process.platform==="win32",uDn=/^(((?:[a-zA-Z]:|[\\\/]{2}[^\\\/]+[\\\/]+[^\\\/]+)?[\\\/]?)(?:[^\\\/]*[\\\/])*)((\.{1,2}|[^\\\/]+?|)(\.[^.\/\\]*|))[\\\/]*$/,rCe={};function lDn(e){return uDn.exec(e).slice(1)}rCe.parse=function(e){if(typeof e!="string")throw new TypeError("Parameter 'pathString' must be a string, not "+typeof e);var t=lDn(e);if(!t||t.length!==5)throw new TypeError("Invalid path '"+e+"'");return{root:t[1],dir:t[0]===t[1]?t[0]:t[0].slice(0,-1),base:t[2],ext:t[4],name:t[3]}};var pDn=/^((\/?)(?:[^\/]*\/)*)((\.{1,2}|[^\/]+?|)(\.[^.\/]*|))[\/]*$/,nCe={};function fDn(e){return pDn.exec(e).slice(1)}nCe.parse=function(e){if(typeof e!="string")throw new TypeError("Parameter 'pathString' must be a string, not "+typeof e);var t=fDn(e);if(!t||t.length!==5)throw new TypeError("Invalid path '"+e+"'");return{root:t[1],dir:t[0].slice(0,-1),base:t[2],ext:t[4],name:t[3]}};cDn?gj.exports=rCe.parse:gj.exports=nCe.parse;gj.exports.posix=nCe.parse;gj.exports.win32=rCe.parse});var iCe=y((b4i,OIt)=>{var TIt=require("path"),_It=TIt.parse||EIt(),dDn=/^([A-Za-z]:)/,hDn=/^\\\\/,xIt=function(t,r){var n="/";dDn.test(t)?n="":hDn.test(t)&&(n="\\\\");for(var i=[t],a=_It(t);a.dir!==i[i.length-1];)i.push(a.dir),a=_It(a.dir);return i.reduce(function(o,s){return o.concat(r.map(function(c){return TIt.resolve(n,s,c)}))},[])};OIt.exports=function(t,r,n){var i=r&&r.moduleDirectory?[].concat(r.moduleDirectory):["node_modules"];if(r&&typeof r.paths=="function")return r.paths(n,t,function(){return xIt(t,i)},r);var a=xIt(t,i);return r&&r.paths?a.concat(r.paths):a}});var aCe=y((E4i,SIt)=>{SIt.exports=function(e,t){return t||{}}});var AIt=y((_4i,mDn)=>{mDn.exports={assert:!0,"node:assert":[">= 14.18 && < 15",">= 16"],"assert/strict":">= 15","node:assert/strict":">= 16",async_hooks:">= 8","node:async_hooks":[">= 14.18 && < 15",">= 16"],buffer_ieee754:">= 0.5 && < 0.9.7",buffer:!0,"node:buffer":[">= 14.18 && < 15",">= 16"],child_process:!0,"node:child_process":[">= 14.18 && < 15",">= 16"],cluster:">= 0.5","node:cluster":[">= 14.18 && < 15",">= 16"],console:!0,"node:console":[">= 14.18 && < 15",">= 16"],constants:!0,"node:constants":[">= 14.18 && < 15",">= 16"],crypto:!0,"node:crypto":[">= 14.18 && < 15",">= 16"],_debug_agent:">= 1 && < 8",_debugger:"< 8",dgram:!0,"node:dgram":[">= 14.18 && < 15",">= 16"],diagnostics_channel:[">= 14.17 && < 15",">= 15.1"],"node:diagnostics_channel":[">= 14.18 && < 15",">= 16"],dns:!0,"node:dns":[">= 14.18 && < 15",">= 16"],"dns/promises":">= 15","node:dns/promises":">= 16",domain:">= 0.7.12","node:domain":[">= 14.18 && < 15",">= 16"],events:!0,"node:events":[">= 14.18 && < 15",">= 16"],freelist:"< 6",fs:!0,"node:fs":[">= 14.18 && < 15",">= 16"],"fs/promises":[">= 10 && < 10.1",">= 14"],"node:fs/promises":[">= 14.18 && < 15",">= 16"],_http_agent:">= 0.11.1","node:_http_agent":[">= 14.18 && < 15",">= 16"],_http_client:">= 0.11.1","node:_http_client":[">= 14.18 && < 15",">= 16"],_http_common:">= 0.11.1","node:_http_common":[">= 14.18 && < 15",">= 16"],_http_incoming:">= 0.11.1","node:_http_incoming":[">= 14.18 && < 15",">= 16"],_http_outgoing:">= 0.11.1","node:_http_outgoing":[">= 14.18 && < 15",">= 16"],_http_server:">= 0.11.1","node:_http_server":[">= 14.18 && < 15",">= 16"],http:!0,"node:http":[">= 14.18 && < 15",">= 16"],http2:">= 8.8","node:http2":[">= 14.18 && < 15",">= 16"],https:!0,"node:https":[">= 14.18 && < 15",">= 16"],inspector:">= 8","node:inspector":[">= 14.18 && < 15",">= 16"],"inspector/promises":[">= 19"],"node:inspector/promises":[">= 19"],_linklist:"< 8",module:!0,"node:module":[">= 14.18 && < 15",">= 16"],net:!0,"node:net":[">= 14.18 && < 15",">= 16"],"node-inspect/lib/_inspect":">= 7.6 && < 12","node-inspect/lib/internal/inspect_client":">= 7.6 && < 12","node-inspect/lib/internal/inspect_repl":">= 7.6 && < 12",os:!0,"node:os":[">= 14.18 && < 15",">= 16"],path:!0,"node:path":[">= 14.18 && < 15",">= 16"],"path/posix":">= 15.3","node:path/posix":">= 16","path/win32":">= 15.3","node:path/win32":">= 16",perf_hooks:">= 8.5","node:perf_hooks":[">= 14.18 && < 15",">= 16"],process:">= 1","node:process":[">= 14.18 && < 15",">= 16"],punycode:">= 0.5","node:punycode":[">= 14.18 && < 15",">= 16"],querystring:!0,"node:querystring":[">= 14.18 && < 15",">= 16"],readline:!0,"node:readline":[">= 14.18 && < 15",">= 16"],"readline/promises":">= 17","node:readline/promises":">= 17",repl:!0,"node:repl":[">= 14.18 && < 15",">= 16"],"node:sea":[">= 20.12 && < 21",">= 21.7"],smalloc:">= 0.11.5 && < 3","node:sqlite":[">= 22.13 && < 23",">= 23.4"],_stream_duplex:">= 0.9.4","node:_stream_duplex":[">= 14.18 && < 15",">= 16"],_stream_transform:">= 0.9.4","node:_stream_transform":[">= 14.18 && < 15",">= 16"],_stream_wrap:">= 1.4.1","node:_stream_wrap":[">= 14.18 && < 15",">= 16"],_stream_passthrough:">= 0.9.4","node:_stream_passthrough":[">= 14.18 && < 15",">= 16"],_stream_readable:">= 0.9.4","node:_stream_readable":[">= 14.18 && < 15",">= 16"],_stream_writable:">= 0.9.4","node:_stream_writable":[">= 14.18 && < 15",">= 16"],stream:!0,"node:stream":[">= 14.18 && < 15",">= 16"],"stream/consumers":">= 16.7","node:stream/consumers":">= 16.7","stream/promises":">= 15","node:stream/promises":">= 16","stream/web":">= 16.5","node:stream/web":">= 16.5",string_decoder:!0,"node:string_decoder":[">= 14.18 && < 15",">= 16"],sys:[">= 0.4 && < 0.7",">= 0.8"],"node:sys":[">= 14.18 && < 15",">= 16"],"test/reporters":">= 19.9 && < 20.2","node:test/reporters":[">= 18.17 && < 19",">= 19.9",">= 20"],"test/mock_loader":">= 22.3 && < 22.7","node:test/mock_loader":">= 22.3 && < 22.7","node:test":[">= 16.17 && < 17",">= 18"],timers:!0,"node:timers":[">= 14.18 && < 15",">= 16"],"timers/promises":">= 15","node:timers/promises":">= 16",_tls_common:">= 0.11.13","node:_tls_common":[">= 14.18 && < 15",">= 16"],_tls_legacy:">= 0.11.3 && < 10",_tls_wrap:">= 0.11.3","node:_tls_wrap":[">= 14.18 && < 15",">= 16"],tls:!0,"node:tls":[">= 14.18 && < 15",">= 16"],trace_events:">= 10","node:trace_events":[">= 14.18 && < 15",">= 16"],tty:!0,"node:tty":[">= 14.18 && < 15",">= 16"],url:!0,"node:url":[">= 14.18 && < 15",">= 16"],util:!0,"node:util":[">= 14.18 && < 15",">= 16"],"util/types":">= 15.3","node:util/types":">= 16","v8/tools/arguments":">= 10 && < 12","v8/tools/codemap":[">= 4.4 && < 5",">= 5.2 && < 12"],"v8/tools/consarray":[">= 4.4 && < 5",">= 5.2 && < 12"],"v8/tools/csvparser":[">= 4.4 && < 5",">= 5.2 && < 12"],"v8/tools/logreader":[">= 4.4 && < 5",">= 5.2 && < 12"],"v8/tools/profile_view":[">= 4.4 && < 5",">= 5.2 && < 12"],"v8/tools/splaytree":[">= 4.4 && < 5",">= 5.2 && < 12"],v8:">= 1","node:v8":[">= 14.18 && < 15",">= 16"],vm:!0,"node:vm":[">= 14.18 && < 15",">= 16"],wasi:[">= 13.4 && < 13.5",">= 18.17 && < 19",">= 20"],"node:wasi":[">= 18.17 && < 19",">= 20"],worker_threads:">= 11.7","node:worker_threads":[">= 14.18 && < 15",">= 16"],zlib:">= 0.5","node:zlib":[">= 14.18 && < 15",">= 16"]}});var yj=y((x4i,PIt)=>{"use strict";var gDn=hL();function yDn(e,t){for(var r=e.split("."),n=t.split(" "),i=n.length>1?n[0]:"=",a=(n.length>1?n[1]:n[0]).split("."),o=0;o<3;++o){var s=parseInt(r[o]||0,10),c=parseInt(a[o]||0,10);if(s!==c)return i==="<"?s<c:i===">="?s>=c:!1}return i===">="}function CIt(e,t){var r=t.split(/ ?&& ?/);if(r.length===0)return!1;for(var n=0;n<r.length;++n)if(!yDn(e,r[n]))return!1;return!0}function vDn(e,t){if(typeof t=="boolean")return t;var r=typeof e>"u"?process.versions&&process.versions.node:e;if(typeof r!="string")throw new TypeError(typeof e>"u"?"Unable to determine current node version":"If provided, a valid node version is required");if(t&&typeof t=="object"){for(var n=0;n<t.length;++n)if(CIt(r,t[n]))return!0;return!1}return CIt(r,t)}var wIt=AIt();PIt.exports=function(t,r){return gDn(wIt,t)&&vDn(r,wIt[t])}});var IIt=y((T4i,NIt)=>{var TO=require("fs"),bDn=eCe(),so=require("path"),EDn=tCe(),_Dn=iCe(),xDn=aCe(),TDn=yj(),ODn=process.platform!=="win32"&&TO.realpath&&typeof TO.realpath.native=="function"?TO.realpath.native:TO.realpath,SDn=/^(?:\.\.?(?:\/|$)|\/|([A-Za-z]:)?[/\\])/,ADn=/^\w:[/\\]*$/,CDn=/[/\\]node_modules[/\\]*$/,DIt=bDn(),wDn=function(){return[so.join(DIt,".node_modules"),so.join(DIt,".node_libraries")]},PDn=function(t,r){TO.stat(t,function(n,i){return n?n.code==="ENOENT"||n.code==="ENOTDIR"?r(null,!1):r(n):r(null,i.isFile()||i.isFIFO())})},DDn=function(t,r){TO.stat(t,function(n,i){return n?n.code==="ENOENT"||n.code==="ENOTDIR"?r(null,!1):r(n):r(null,i.isDirectory())})},NDn=function(t,r){ODn(t,function(n,i){n&&n.code!=="ENOENT"?r(n):r(null,n?t:i)})},vj=function(t,r,n,i){n&&n.preserveSymlinks===!1?t(r,i):i(null,r)},IDn=function(t,r,n){t(r,function(i,a){if(i)n(i);else try{var o=JSON.parse(a);n(null,o)}catch{n(null)}})},RDn=function(t,r,n){for(var i=_Dn(r,n,t),a=0;a<i.length;a++)i[a]=so.join(i[a],t);return i};NIt.exports=function(t,r,n){var i=n,a=r;if(typeof r=="function"&&(i=a,a={}),typeof t!="string"){var o=new TypeError("Path must be a string.");return process.nextTick(function(){i(o)})}a=xDn(t,a);var s=a.isFile||PDn,c=a.isDirectory||DDn,u=a.readFile||TO.readFile,l=a.realpath||NDn,p=a.readPackage||IDn;if(a.readFile&&a.readPackage){var f=new TypeError("`readFile` and `readPackage` are mutually exclusive.");return process.nextTick(function(){i(f)})}var d=a.packageIterator,h=a.extensions||[".js"],m=a.includeCoreModules!==!1,v=a.basedir||so.dirname(EDn()),_=a.filename||v;a.paths=a.paths||wDn();var T=so.resolve(v);vj(l,T,a,function(L,B){L?i(L):S(B)});var O;function S(L){if(SDn.test(t))O=so.resolve(L,t),(t==="."||t===".."||t.slice(-1)==="/")&&(O+="/"),t.slice(-1)==="/"&&O===L?j(O,a.package,A):P(O,a.package,A);else{if(m&&TDn(t))return i(null,t);z(t,L,function(B,X,Z){if(B)i(B);else{if(X)return vj(l,X,a,function(q,G){q?i(q):i(null,G,Z)});var V=new Error("Cannot find module '"+t+"' from '"+_+"'");V.code="MODULE_NOT_FOUND",i(V)}})}}function A(L,B,X){L?i(L):B?i(null,B,X):j(O,function(Z,V,q){if(Z)i(Z);else if(V)vj(l,V,a,function(K,pe){K?i(K):i(null,pe,q)});else{var G=new Error("Cannot find module '"+t+"' from '"+_+"'");G.code="MODULE_NOT_FOUND",i(G)}})}function P(L,B,X){var Z=B,V=X;typeof Z=="function"&&(V=Z,Z=void 0);var q=[""].concat(h);G(q,L,Z);function G(K,pe,Me){if(K.length===0)return V(null,void 0,Me);var ue=pe+K[0],Ke=Me;Ke?xt(null,Ke):I(so.dirname(ue),xt);function xt(We,fe,Te){if(Ke=fe,We)return V(We);if(Te&&Ke&&a.pathFilter){var Pt=so.relative(Te,ue),Ae=Pt.slice(0,Pt.length-K[0].length),at=a.pathFilter(Ke,pe,Ae);if(at)return G([""].concat(h.slice()),so.resolve(Te,at),Ke)}s(ue,At)}function At(We,fe){if(We)return V(We);if(fe)return V(null,ue,Ke);G(K.slice(1),pe,Ke)}}}function I(L,B){if(L===""||L==="/"||process.platform==="win32"&&ADn.test(L)||CDn.test(L))return B(null);vj(l,L,a,function(X,Z){if(X)return I(so.dirname(L),B);var V=so.join(Z,"package.json");s(V,function(q,G){if(!G)return I(so.dirname(L),B);p(u,V,function(K,pe){K&&B(K);var Me=pe;Me&&a.packageFilter&&(Me=a.packageFilter(Me,V)),B(null,Me,L)})})})}function j(L,B,X){var Z=X,V=B;typeof V=="function"&&(Z=V,V=a.package),vj(l,L,a,function(q,G){if(q)return Z(q);var K=so.join(G,"package.json");s(K,function(pe,Me){if(pe)return Z(pe);if(!Me)return P(so.join(L,"index"),V,Z);p(u,K,function(ue,Ke){if(ue)return Z(ue);var xt=Ke;if(xt&&a.packageFilter&&(xt=a.packageFilter(xt,K)),xt&&xt.main){if(typeof xt.main!="string"){var At=new TypeError("package \u201C"+xt.name+"\u201D `main` must be a string");return At.code="INVALID_PACKAGE_MAIN",Z(At)}(xt.main==="."||xt.main==="./")&&(xt.main="index"),P(so.resolve(L,xt.main),xt,function(We,fe,Te){if(We)return Z(We);if(fe)return Z(null,fe,Te);if(!Te)return P(so.join(L,"index"),Te,Z);var Pt=so.resolve(L,Te.main);j(Pt,Te,function(Ae,at,ce){if(Ae)return Z(Ae);if(at)return Z(null,at,ce);P(so.join(L,"index"),ce,Z)})});return}P(so.join(L,"/index"),xt,Z)})})})}function k(L,B){if(B.length===0)return L(null,void 0);var X=B[0];c(so.dirname(X),Z);function Z(G,K){if(G)return L(G);if(!K)return k(L,B.slice(1));P(X,a.package,V)}function V(G,K,pe){if(G)return L(G);if(K)return L(null,K,pe);j(X,a.package,q)}function q(G,K,pe){if(G)return L(G);if(K)return L(null,K,pe);k(L,B.slice(1))}}function z(L,B,X){var Z=function(){return RDn(L,B,a)};k(X,d?d(L,B,Z,a):Z())}}});var RIt=y((O4i,LDn)=>{LDn.exports={assert:!0,"node:assert":[">= 14.18 && < 15",">= 16"],"assert/strict":">= 15","node:assert/strict":">= 16",async_hooks:">= 8","node:async_hooks":[">= 14.18 && < 15",">= 16"],buffer_ieee754:">= 0.5 && < 0.9.7",buffer:!0,"node:buffer":[">= 14.18 && < 15",">= 16"],child_process:!0,"node:child_process":[">= 14.18 && < 15",">= 16"],cluster:">= 0.5","node:cluster":[">= 14.18 && < 15",">= 16"],console:!0,"node:console":[">= 14.18 && < 15",">= 16"],constants:!0,"node:constants":[">= 14.18 && < 15",">= 16"],crypto:!0,"node:crypto":[">= 14.18 && < 15",">= 16"],_debug_agent:">= 1 && < 8",_debugger:"< 8",dgram:!0,"node:dgram":[">= 14.18 && < 15",">= 16"],diagnostics_channel:[">= 14.17 && < 15",">= 15.1"],"node:diagnostics_channel":[">= 14.18 && < 15",">= 16"],dns:!0,"node:dns":[">= 14.18 && < 15",">= 16"],"dns/promises":">= 15","node:dns/promises":">= 16",domain:">= 0.7.12","node:domain":[">= 14.18 && < 15",">= 16"],events:!0,"node:events":[">= 14.18 && < 15",">= 16"],freelist:"< 6",fs:!0,"node:fs":[">= 14.18 && < 15",">= 16"],"fs/promises":[">= 10 && < 10.1",">= 14"],"node:fs/promises":[">= 14.18 && < 15",">= 16"],_http_agent:">= 0.11.1","node:_http_agent":[">= 14.18 && < 15",">= 16"],_http_client:">= 0.11.1","node:_http_client":[">= 14.18 && < 15",">= 16"],_http_common:">= 0.11.1","node:_http_common":[">= 14.18 && < 15",">= 16"],_http_incoming:">= 0.11.1","node:_http_incoming":[">= 14.18 && < 15",">= 16"],_http_outgoing:">= 0.11.1","node:_http_outgoing":[">= 14.18 && < 15",">= 16"],_http_server:">= 0.11.1","node:_http_server":[">= 14.18 && < 15",">= 16"],http:!0,"node:http":[">= 14.18 && < 15",">= 16"],http2:">= 8.8","node:http2":[">= 14.18 && < 15",">= 16"],https:!0,"node:https":[">= 14.18 && < 15",">= 16"],inspector:">= 8","node:inspector":[">= 14.18 && < 15",">= 16"],"inspector/promises":[">= 19"],"node:inspector/promises":[">= 19"],_linklist:"< 8",module:!0,"node:module":[">= 14.18 && < 15",">= 16"],net:!0,"node:net":[">= 14.18 && < 15",">= 16"],"node-inspect/lib/_inspect":">= 7.6 && < 12","node-inspect/lib/internal/inspect_client":">= 7.6 && < 12","node-inspect/lib/internal/inspect_repl":">= 7.6 && < 12",os:!0,"node:os":[">= 14.18 && < 15",">= 16"],path:!0,"node:path":[">= 14.18 && < 15",">= 16"],"path/posix":">= 15.3","node:path/posix":">= 16","path/win32":">= 15.3","node:path/win32":">= 16",perf_hooks:">= 8.5","node:perf_hooks":[">= 14.18 && < 15",">= 16"],process:">= 1","node:process":[">= 14.18 && < 15",">= 16"],punycode:">= 0.5","node:punycode":[">= 14.18 && < 15",">= 16"],querystring:!0,"node:querystring":[">= 14.18 && < 15",">= 16"],readline:!0,"node:readline":[">= 14.18 && < 15",">= 16"],"readline/promises":">= 17","node:readline/promises":">= 17",repl:!0,"node:repl":[">= 14.18 && < 15",">= 16"],"node:sea":[">= 20.12 && < 21",">= 21.7"],smalloc:">= 0.11.5 && < 3","node:sqlite":[">= 22.13 && < 23",">= 23.4"],_stream_duplex:">= 0.9.4","node:_stream_duplex":[">= 14.18 && < 15",">= 16"],_stream_transform:">= 0.9.4","node:_stream_transform":[">= 14.18 && < 15",">= 16"],_stream_wrap:">= 1.4.1","node:_stream_wrap":[">= 14.18 && < 15",">= 16"],_stream_passthrough:">= 0.9.4","node:_stream_passthrough":[">= 14.18 && < 15",">= 16"],_stream_readable:">= 0.9.4","node:_stream_readable":[">= 14.18 && < 15",">= 16"],_stream_writable:">= 0.9.4","node:_stream_writable":[">= 14.18 && < 15",">= 16"],stream:!0,"node:stream":[">= 14.18 && < 15",">= 16"],"stream/consumers":">= 16.7","node:stream/consumers":">= 16.7","stream/promises":">= 15","node:stream/promises":">= 16","stream/web":">= 16.5","node:stream/web":">= 16.5",string_decoder:!0,"node:string_decoder":[">= 14.18 && < 15",">= 16"],sys:[">= 0.4 && < 0.7",">= 0.8"],"node:sys":[">= 14.18 && < 15",">= 16"],"test/reporters":">= 19.9 && < 20.2","node:test/reporters":[">= 18.17 && < 19",">= 19.9",">= 20"],"test/mock_loader":">= 22.3 && < 22.7","node:test/mock_loader":">= 22.3 && < 22.7","node:test":[">= 16.17 && < 17",">= 18"],timers:!0,"node:timers":[">= 14.18 && < 15",">= 16"],"timers/promises":">= 15","node:timers/promises":">= 16",_tls_common:">= 0.11.13","node:_tls_common":[">= 14.18 && < 15",">= 16"],_tls_legacy:">= 0.11.3 && < 10",_tls_wrap:">= 0.11.3","node:_tls_wrap":[">= 14.18 && < 15",">= 16"],tls:!0,"node:tls":[">= 14.18 && < 15",">= 16"],trace_events:">= 10","node:trace_events":[">= 14.18 && < 15",">= 16"],tty:!0,"node:tty":[">= 14.18 && < 15",">= 16"],url:!0,"node:url":[">= 14.18 && < 15",">= 16"],util:!0,"node:util":[">= 14.18 && < 15",">= 16"],"util/types":">= 15.3","node:util/types":">= 16","v8/tools/arguments":">= 10 && < 12","v8/tools/codemap":[">= 4.4 && < 5",">= 5.2 && < 12"],"v8/tools/consarray":[">= 4.4 && < 5",">= 5.2 && < 12"],"v8/tools/csvparser":[">= 4.4 && < 5",">= 5.2 && < 12"],"v8/tools/logreader":[">= 4.4 && < 5",">= 5.2 && < 12"],"v8/tools/profile_view":[">= 4.4 && < 5",">= 5.2 && < 12"],"v8/tools/splaytree":[">= 4.4 && < 5",">= 5.2 && < 12"],v8:">= 1","node:v8":[">= 14.18 && < 15",">= 16"],vm:!0,"node:vm":[">= 14.18 && < 15",">= 16"],wasi:[">= 13.4 && < 13.5",">= 18.17 && < 19",">= 20"],"node:wasi":[">= 18.17 && < 19",">= 20"],worker_threads:">= 11.7","node:worker_threads":[">= 14.18 && < 15",">= 16"],zlib:">= 0.5","node:zlib":[">= 14.18 && < 15",">= 16"]}});var MIt=y((S4i,$It)=>{"use strict";var kDn=yj(),LIt=RIt(),kIt={};for(RW in LIt)Object.prototype.hasOwnProperty.call(LIt,RW)&&(kIt[RW]=kDn(RW));var RW;$It.exports=kIt});var jIt=y((A4i,FIt)=>{var $Dn=yj();FIt.exports=function(t){return $Dn(t)}});var UIt=y((C4i,VIt)=>{var MDn=yj(),OO=require("fs"),vc=require("path"),FDn=eCe(),jDn=tCe(),qDn=iCe(),VDn=aCe(),UDn=process.platform!=="win32"&&OO.realpathSync&&typeof OO.realpathSync.native=="function"?OO.realpathSync.native:OO.realpathSync,BDn=/^(?:\.\.?(?:\/|$)|\/|([A-Za-z]:)?[/\\])/,zDn=/^\w:[/\\]*$/,HDn=/[/\\]node_modules[/\\]*$/,qIt=FDn(),GDn=function(){return[vc.join(qIt,".node_modules"),vc.join(qIt,".node_libraries")]},KDn=function(t){try{var r=OO.statSync(t,{throwIfNoEntry:!1})}catch(n){if(n&&(n.code==="ENOENT"||n.code==="ENOTDIR"))return!1;throw n}return!!r&&(r.isFile()||r.isFIFO())},YDn=function(t){try{var r=OO.statSync(t,{throwIfNoEntry:!1})}catch(n){if(n&&(n.code==="ENOENT"||n.code==="ENOTDIR"))return!1;throw n}return!!r&&r.isDirectory()},WDn=function(t){try{return UDn(t)}catch(r){if(r.code!=="ENOENT")throw r}return t},bj=function(t,r,n){return n&&n.preserveSymlinks===!1?t(r):r},XDn=function(t,r){var n=t(r);try{var i=JSON.parse(n);return i}catch{}},JDn=function(t,r,n){for(var i=qDn(r,n,t),a=0;a<i.length;a++)i[a]=vc.join(i[a],t);return i};VIt.exports=function(t,r){if(typeof t!="string")throw new TypeError("Path must be a string.");var n=VDn(t,r),i=n.isFile||KDn,a=n.readFileSync||OO.readFileSync,o=n.isDirectory||YDn,s=n.realpathSync||WDn,c=n.readPackageSync||XDn;if(n.readFileSync&&n.readPackageSync)throw new TypeError("`readFileSync` and `readPackageSync` are mutually exclusive.");var u=n.packageIterator,l=n.extensions||[".js"],p=n.includeCoreModules!==!1,f=n.basedir||vc.dirname(jDn()),d=n.filename||f;n.paths=n.paths||GDn();var h=bj(s,vc.resolve(f),n);if(BDn.test(t)){var m=vc.resolve(h,t);(t==="."||t===".."||t.slice(-1)==="/")&&(m+="/");var v=O(m)||A(m);if(v)return bj(s,v,n)}else{if(p&&MDn(t))return t;var _=P(t,h);if(_)return bj(s,_,n)}var T=new Error("Cannot find module '"+t+"' from '"+d+"'");throw T.code="MODULE_NOT_FOUND",T;function O(I){var j=S(vc.dirname(I));if(j&&j.dir&&j.pkg&&n.pathFilter){var k=vc.relative(j.dir,I),z=n.pathFilter(j.pkg,I,k);z&&(I=vc.resolve(j.dir,z))}if(i(I))return I;for(var L=0;L<l.length;L++){var B=I+l[L];if(i(B))return B}}function S(I){if(!(I===""||I==="/")&&!(process.platform==="win32"&&zDn.test(I))&&!HDn.test(I)){var j=vc.join(bj(s,I,n),"package.json");if(!i(j))return S(vc.dirname(I));var k=c(a,j);return k&&n.packageFilter&&(k=n.packageFilter(k,I)),{pkg:k,dir:I}}}function A(I){var j=vc.join(bj(s,I,n),"/package.json");if(i(j)){try{var k=c(a,j)}catch{}if(k&&n.packageFilter&&(k=n.packageFilter(k,I)),k&&k.main){if(typeof k.main!="string"){var z=new TypeError("package \u201C"+k.name+"\u201D `main` must be a string");throw z.code="INVALID_PACKAGE_MAIN",z}(k.main==="."||k.main==="./")&&(k.main="index");try{var L=O(vc.resolve(I,k.main));if(L)return L;var B=A(vc.resolve(I,k.main));if(B)return B}catch{}}}return O(vc.join(I,"/index"))}function P(I,j){for(var k=function(){return JDn(I,j,n)},z=u?u(I,j,k,n):k(),L=0;L<z.length;L++){var B=z[L];if(o(vc.dirname(B))){var X=O(B);if(X)return X;var Z=A(B);if(Z)return Z}}}}});var oCe=y((w4i,BIt)=>{var LW=IIt();LW.core=MIt();LW.isCore=jIt();LW.sync=UIt();BIt.exports=LW});var HIt=y((P4i,zIt)=>{zIt.exports=ZDn;function ZDn(e){if(e&&e!=="ERROR: No README data found!"){e=e.trim().split(`
|
|
427
|
-
`);for(var t=0;e[t]&&e[t].trim().match(/^(#|$)/);t++);for(var r=e.length,n=t+1;n<r&&e[n].trim();n++);return e.slice(t,n).join(" ").trim()}}});var GIt=y((D4i,QDn)=>{QDn.exports={topLevel:{dependancies:"dependencies",dependecies:"dependencies",depdenencies:"dependencies",devEependencies:"devDependencies",depends:"dependencies","dev-dependencies":"devDependencies",devDependences:"devDependencies",devDepenencies:"devDependencies",devdependencies:"devDependencies",repostitory:"repository",repo:"repository",prefereGlobal:"preferGlobal",hompage:"homepage",hampage:"homepage",autohr:"author",autor:"author",contributers:"contributors",publicationConfig:"publishConfig",script:"scripts"},bugs:{web:"url",name:"url"},script:{server:"start",tests:"test"}}});var XIt=y((I4i,WIt)=>{var KIt=DW(),eNn=uIt(),kW=yIt(),tNn=oCe().isCore,rNn=["dependencies","devDependencies","optionalDependencies"],nNn=HIt(),sCe=require("url"),OE=GIt(),N4i=WIt.exports={warn:function(){},fixRepositoryField:function(e){if(e.repositories&&(this.warn("repositories"),e.repository=e.repositories[0]),!e.repository)return this.warn("missingRepository");typeof e.repository=="string"&&(e.repository={type:"git",url:e.repository});var t=e.repository.url||"";if(t){var r=kW.fromUrl(t);r&&(t=e.repository.url=r.getDefaultRepresentation()=="shortcut"?r.https():r.toString())}t.match(/github.com\/[^\/]+\/[^\/]+\.git\.git$/)&&this.warn("brokenGitUrl",t)},fixTypos:function(e){Object.keys(OE.topLevel).forEach(function(t){e.hasOwnProperty(t)&&this.warn("typo",t,OE.topLevel[t])},this)},fixScriptsField:function(e){if(e.scripts){if(typeof e.scripts!="object"){this.warn("nonObjectScripts"),delete e.scripts;return}Object.keys(e.scripts).forEach(function(t){typeof e.scripts[t]!="string"?(this.warn("nonStringScript"),delete e.scripts[t]):OE.script[t]&&!e.scripts[OE.script[t]]&&this.warn("typo",t,OE.script[t],"scripts")},this)}},fixFilesField:function(e){var t=e.files;t&&!Array.isArray(t)?(this.warn("nonArrayFiles"),delete e.files):e.files&&(e.files=e.files.filter(function(r){return!r||typeof r!="string"?(this.warn("invalidFilename",r),!1):!0},this))},fixBinField:function(e){if(e.bin&&typeof e.bin=="string"){var t={},r;(r=e.name.match(/^@[^/]+[/](.*)$/))?t[r[1]]=e.bin:t[e.name]=e.bin,e.bin=t}},fixManField:function(e){e.man&&typeof e.man=="string"&&(e.man=[e.man])},fixBundleDependenciesField:function(e){var t="bundledDependencies",r="bundleDependencies";e[t]&&!e[r]&&(e[r]=e[t],delete e[t]),e[r]&&!Array.isArray(e[r])?(this.warn("nonArrayBundleDependencies"),delete e[r]):e[r]&&(e[r]=e[r].filter(function(n){return!n||typeof n!="string"?(this.warn("nonStringBundleDependency",n),!1):(e.dependencies||(e.dependencies={}),e.dependencies.hasOwnProperty(n)||(this.warn("nonDependencyBundleDependency",n),e.dependencies[n]="*"),!0)},this))},fixDependencies:function(e,t){var r=!t;pNn(e,this.warn),uNn(e,this.warn),this.fixBundleDependenciesField(e),["dependencies","devDependencies"].forEach(function(n){if(n in e){if(!e[n]||typeof e[n]!="object"){this.warn("nonObjectDependencies",n),delete e[n];return}Object.keys(e[n]).forEach(function(i){var a=e[n][i];typeof a!="string"&&(this.warn("nonStringDependency",i,JSON.stringify(a)),delete e[n][i]);var o=kW.fromUrl(e[n][i]);o&&(e[n][i]=o.toString())},this)}},this)},fixModulesField:function(e){e.modules&&(this.warn("deprecatedModules"),delete e.modules)},fixKeywordsField:function(e){typeof e.keywords=="string"&&(e.keywords=e.keywords.split(/,\s+/)),e.keywords&&!Array.isArray(e.keywords)?(delete e.keywords,this.warn("nonArrayKeywords")):e.keywords&&(e.keywords=e.keywords.filter(function(t){return typeof t!="string"||!t?(this.warn("nonStringKeyword"),!1):!0},this))},fixVersionField:function(e,t){var r=!t;if(!e.version)return e.version="",!0;if(!KIt.valid(e.version,r))throw new Error('Invalid version: "'+e.version+'"');return e.version=KIt.clean(e.version,r),!0},fixPeople:function(e){YIt(e,sNn),YIt(e,cNn)},fixNameField:function(e,t){typeof t=="boolean"?t={strict:t}:typeof t>"u"&&(t={});var r=t.strict;if(!e.name&&!r){e.name="";return}if(typeof e.name!="string")throw new Error("name field must be a string.");r||(e.name=e.name.trim()),oNn(e.name,r,t.allowLegacyCase),tNn(e.name)&&this.warn("conflictingName",e.name)},fixDescriptionField:function(e){e.description&&typeof e.description!="string"&&(this.warn("nonStringDescription"),delete e.description),e.readme&&!e.description&&(e.description=nNn(e.readme)),e.description===void 0&&delete e.description,e.description||this.warn("missingDescription")},fixReadmeField:function(e){e.readme||(this.warn("missingReadme"),e.readme="ERROR: No README data found!")},fixBugsField:function(e){if(!e.bugs&&e.repository&&e.repository.url){var t=kW.fromUrl(e.repository.url);t&&t.bugs()&&(e.bugs={url:t.bugs()})}else if(e.bugs){var r=/^.+@.*\..+$/;if(typeof e.bugs=="string")r.test(e.bugs)?e.bugs={email:e.bugs}:sCe.parse(e.bugs).protocol?e.bugs={url:e.bugs}:this.warn("nonEmailUrlBugsString");else{fNn(e.bugs,this.warn);var n=e.bugs;e.bugs={},n.url&&(typeof n.url=="string"&&sCe.parse(n.url).protocol?e.bugs.url=n.url:this.warn("nonUrlBugsUrlField")),n.email&&(typeof n.email=="string"&&r.test(n.email)?e.bugs.email=n.email:this.warn("nonEmailBugsEmailField"))}!e.bugs.email&&!e.bugs.url&&(delete e.bugs,this.warn("emptyNormalizedBugs"))}},fixHomepageField:function(e){if(!e.homepage&&e.repository&&e.repository.url){var t=kW.fromUrl(e.repository.url);t&&t.docs()&&(e.homepage=t.docs())}if(e.homepage){if(typeof e.homepage!="string")return this.warn("nonUrlHomepage"),delete e.homepage;sCe.parse(e.homepage).protocol||(e.homepage="http://"+e.homepage)}},fixLicenseField:function(e){if(e.license)typeof e.license!="string"||e.license.length<1||e.license.trim()===""?this.warn("invalidLicense"):eNn(e.license).validForNewPackages||this.warn("invalidLicense");else return this.warn("missingLicense")}};function iNn(e){if(e.charAt(0)!=="@")return!1;var t=e.slice(1).split("/");return t.length!==2?!1:t[0]&&t[1]&&t[0]===encodeURIComponent(t[0])&&t[1]===encodeURIComponent(t[1])}function aNn(e){return!e.match(/[\/@\s\+%:]/)&&e===encodeURIComponent(e)}function oNn(e,t,r){if(e.charAt(0)==="."||!(iNn(e)||aNn(e))||t&&!r&&e!==e.toLowerCase()||e.toLowerCase()==="node_modules"||e.toLowerCase()==="favicon.ico")throw new Error("Invalid name: "+JSON.stringify(e))}function YIt(e,t){return e.author&&(e.author=t(e.author)),["maintainers","contributors"].forEach(function(r){Array.isArray(e[r])&&(e[r]=e[r].map(t))}),e}function sNn(e){if(typeof e=="string")return e;var t=e.name||"",r=e.url||e.web,n=r?" ("+r+")":"",i=e.email||e.mail,a=i?" <"+i+">":"";return t+a+n}function cNn(e){if(typeof e!="string")return e;var t=e.match(/^([^\(<]+)/),r=e.match(/\(([^\)]+)\)/),n=e.match(/<([^>]+)>/),i={};return t&&t[0].trim()&&(i.name=t[0].trim()),n&&(i.email=n[1]),r&&(i.url=r[1]),i}function uNn(e,t){var r=e.optionalDependencies;if(r){var n=e.dependencies||{};Object.keys(r).forEach(function(i){n[i]=r[i]}),e.dependencies=n}}function lNn(e,t,r){if(!e)return{};if(typeof e=="string"&&(e=e.trim().split(/[\n\r\s\t ,]+/)),!Array.isArray(e))return e;r("deprecatedArrayDependencies",t);var n={};return e.filter(function(i){return typeof i=="string"}).forEach(function(i){i=i.trim().split(/(:?[@\s><=])/);var a=i.shift(),o=i.join("");o=o.trim(),o=o.replace(/^@/,""),n[a]=o}),n}function pNn(e,t){rNn.forEach(function(r){e[r]&&(e[r]=lNn(e[r],r,t))})}function fNn(e,t){e&&Object.keys(e).forEach(function(r){OE.bugs[r]&&(t("typo",r,OE.bugs[r],"bugs"),e[OE.bugs[r]]=e[r],delete e[r])})}});var JIt=y((R4i,dNn)=>{dNn.exports={repositories:"'repositories' (plural) Not supported. Please pick one as the 'repository' field",missingRepository:"No repository field.",brokenGitUrl:"Probably broken git url: %s",nonObjectScripts:"scripts must be an object",nonStringScript:"script values must be string commands",nonArrayFiles:"Invalid 'files' member",invalidFilename:"Invalid filename in 'files' list: %s",nonArrayBundleDependencies:"Invalid 'bundleDependencies' list. Must be array of package names",nonStringBundleDependency:"Invalid bundleDependencies member: %s",nonDependencyBundleDependency:"Non-dependency in bundleDependencies: %s",nonObjectDependencies:"%s field must be an object",nonStringDependency:"Invalid dependency: %s %s",deprecatedArrayDependencies:"specifying %s as array is deprecated",deprecatedModules:"modules field is deprecated",nonArrayKeywords:"keywords should be an array of strings",nonStringKeyword:"keywords should be an array of strings",conflictingName:"%s is also the name of a node core module.",nonStringDescription:"'description' field should be a string",missingDescription:"No description",missingReadme:"No README data",missingLicense:"No license field.",nonEmailUrlBugsString:"Bug string field must be url, email, or {email,url}",nonUrlBugsUrlField:"bugs.url field must be a string url. Deleted.",nonEmailBugsEmailField:"bugs.email field must be a string email. Deleted.",emptyNormalizedBugs:"Normalized value of bugs field is an empty object. Deleted.",nonUrlHomepage:"homepage field must be a string url. Deleted.",invalidLicense:"license should be a valid SPDX license expression",typo:"%s should probably be %s."}});var eRt=y((L4i,QIt)=>{var ZIt=require("util"),cCe=JIt();QIt.exports=function(){var e=Array.prototype.slice.call(arguments,0),t=e.shift();if(t=="typo")return hNn.apply(null,e);var r=cCe[t]?cCe[t]:t+": '%s'";return e.unshift(r),ZIt.format.apply(null,e)};function hNn(e,t,r){return r&&(e=r+"['"+e+"']",t=r+"['"+t+"']"),ZIt.format(cCe.typo,e,t)}});var pCe=y((k4i,nRt)=>{nRt.exports=tRt;var uCe=XIt();tRt.fixer=uCe;var mNn=eRt(),gNn=["name","version","description","repository","modules","scripts","files","bin","man","bugs","keywords","readme","homepage","license"],yNn=["dependencies","people","typos"],lCe=gNn.map(function(e){return rRt(e)+"Field"});lCe=lCe.concat(yNn);function tRt(e,t,r){t===!0&&(t=null,r=!0),r||(r=!1),(!t||e.private)&&(t=function(n){}),e.scripts&&e.scripts.install==="node-gyp rebuild"&&!e.scripts.preinstall&&(e.gypfile=!0),uCe.warn=function(){t(mNn.apply(null,arguments))},lCe.forEach(function(n){uCe["fix"+rRt(n)](e,r)}),e._id=e.name+"@"+e.version}function rRt(e){return e.charAt(0).toUpperCase()+e.slice(1)}});var sRt=y(($4i,fCe)=>{"use strict";var{promisify:vNn}=require("util"),iRt=require("fs"),aRt=require("path"),oRt=wNt(),bNn=vNn(iRt.readFile);fCe.exports=async e=>{e={cwd:process.cwd(),normalize:!0,...e};let t=aRt.resolve(e.cwd,"package.json"),r=oRt(await bNn(t,"utf8"));return e.normalize&&pCe()(r),r};fCe.exports.sync=e=>{e={cwd:process.cwd(),normalize:!0,...e};let t=aRt.resolve(e.cwd,"package.json"),r=oRt(iRt.readFileSync(t,"utf8"));return e.normalize&&pCe()(r),r}});var pRt=y((M4i,dCe)=>{"use strict";var cRt=require("path"),uRt=zDt(),lRt=sRt();dCe.exports=async e=>{let t=await uRt("package.json",e);if(t)return{packageJson:await lRt({...e,cwd:cRt.dirname(t)}),path:t}};dCe.exports.sync=e=>{let t=uRt.sync("package.json",e);if(t)return{packageJson:lRt.sync({...e,cwd:cRt.dirname(t)}),path:t}}});var hRt=y(Ej=>{"use strict";var dRt=Ej&&Ej.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(Ej,"__esModule",{value:!0});Ej.findInstalledPackages=SNn;var ENn=QP(),_Nn=rOe(),xNn=dRt(gK()),hCe=require("node:path"),TNn=dRt(pRt()),fRt=ET(),ONn=async(e,t)=>{let r=await(0,TNn.default)({cwd:e});if(r)return t&&(0,fRt.lt)((0,fRt.coerce)(r.packageJson.version),t)?void 0:{packageJsonPath:r.path,packageInfo:r.packageJson,path:(0,hCe.join)(e,r.packageJson.main??"/generators/app")}};async function SNn(e,t){let r=await ANn(t?.vscWorkspaceConfig),n=[],i=[];for await(let a of r){let o=await(0,xNn.default)(`**/*${e}*`,{cwd:a,deep:2,onlyDirectories:!0,absolute:!0});o.length>0&&i.push(...o)}for await(let a of i){let o=await ONn(a,t?.minVersion);o&&(!t?.keyword||t.keyword&&o.packageInfo.keywords?.includes(t.keyword))&&n.push(o)}return n}async function ANn(e){let t=[];if(e){let o=e?.get("ApplicationWizard.installationLocation");o&&t.push((0,hCe.join)(o,"node_modules"))}let r=new _Nn.CommandRunner,n=process.platform==="win32"?"npm.cmd":"npm",i=await r.run(n,["-g","root"]).then(a=>a).catch(()=>{});return i&&t.push((0,hCe.join)(i.trim())),(0,ENn.isAppStudio)()&&process.env.NODE_PATH&&t.push(...process.env.NODE_PATH.split(":").filter(a=>a.endsWith("node_modules"))),t}});var mRt=y(_j=>{"use strict";var CNn=_j&&_j.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(_j,"__esModule",{value:!0});_j.setGlobalRejectUnauthorized=wNn;var $W=CNn(require("https"));function wNn(e){$W.default.globalAgent.options&&($W.default.globalAgent.options.rejectUnauthorized=e),$W.default.globalAgent.fallbackAgent?.options&&($W.default.globalAgent.fallbackAgent.options.rejectUnauthorized=e)}});var yRt=y(km=>{"use strict";Object.defineProperty(km,"__esModule",{value:!0});km.ProxyValidationStatus=void 0;km.validateProxySettings=NNn;km.ProxyValidationStatus={NO_PROXY:"no-proxy",MATCH:"match",MISMATCH:"mismatch",ENV_ONLY:"env-only",PARAM_ONLY:"param-only"};var PNn=["HTTP_PROXY","http_proxy","HTTPS_PROXY","https_proxy"],DNn=()=>{for(let e of PNn){let t=process.env[e];if(t&&t.trim()!=="")return t}},gRt=e=>{let t=e?.trim().toLowerCase();for(;t?.endsWith("/");)t=t.slice(0,-1);return t||void 0};function NNn(e){let t=DNn(),r=gRt(t),n=gRt(e);return r||n?r&&!n?{isValid:!1,status:km.ProxyValidationStatus.ENV_ONLY,message:"Using environment proxy settings.",envProxy:r,providedProxy:void 0}:!r&&n?{isValid:!1,status:km.ProxyValidationStatus.PARAM_ONLY,message:`Using provided (${n}) proxy settings.`,envProxy:void 0,providedProxy:n}:r===n?{isValid:!0,status:km.ProxyValidationStatus.MATCH,message:"Proxy settings match.",envProxy:r,providedProxy:n}:{isValid:!1,status:km.ProxyValidationStatus.MISMATCH,message:`Proxy settings conflict between environment (${r}) and parameter (${n}).`,envProxy:r,providedProxy:n}:{isValid:!0,status:km.ProxyValidationStatus.NO_PROXY,message:"No proxy settings configured.",providedProxy:void 0,envProxy:t}}});var mCe=y($m=>{"use strict";var INn=$m&&$m.__createBinding||(Object.create?function(e,t,r,n){n===void 0&&(n=r);var i=Object.getOwnPropertyDescriptor(t,r);(!i||("get"in i?!t.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,i)}:function(e,t,r,n){n===void 0&&(n=r),e[n]=t[r]}),MW=$m&&$m.__exportStar||function(e,t){for(var r in e)r!=="default"&&!Object.prototype.hasOwnProperty.call(t,r)&&INn(t,e,r)};Object.defineProperty($m,"__esModule",{value:!0});MW(rOe(),$m);MW(hRt(),$m);MW(mRt(),$m);MW(yRt(),$m)});var SRt=y(rl=>{"use strict";Object.defineProperty(rl,"__esModule",{value:!0});rl.OdataVersion=rl.FioriElementsVersion=rl.PAGETYPE_VIEW_EXTENSION_TEMPLATE_MAP=rl.PageType=rl.PageTypeV4=rl.PageTypeV2=void 0;var uD;(function(e){e.ObjectPage="ObjectPage",e.ListReport="ListReport",e.OverviewPage="OverviewPage",e.CustomPage="CustomPage",e.AnalyticalListPage="AnalyticalListPage"})(uD||(rl.PageTypeV2=uD={}));var ECe;(function(e){e.ObjectPage="ObjectPage",e.ListReport="ListReport",e.CustomPage="CustomPage",e.FPMCustomPage="FPMCustomPage",e.AnalyticalListPage="AnalyticalListPage"})(ECe||(rl.PageTypeV4=ECe={}));rl.PageType={...uD,...ECe};rl.PAGETYPE_VIEW_EXTENSION_TEMPLATE_MAP=new Map([[uD.ListReport,"sap.suite.ui.generic.template.ListReport.view.ListReport"],[uD.AnalyticalListPage,"sap.suite.ui.generic.template.AnalyticalListPage.view.AnalyticalListPage"],[uD.ObjectPage,"sap.suite.ui.generic.template.ObjectPage.view.Details"]]);var TRt;(function(e){e.v2="v2",e.v4="v4"})(TRt||(rl.FioriElementsVersion=TRt={}));var ORt;(function(e){e.v2="v2",e.v4="v4"})(ORt||(rl.OdataVersion=ORt={}))});var KRt=y(Ge=>{"use strict";Object.defineProperty(Ge,"__esModule",{value:!0});Ge.RuleName=Ge.MacrosPropertyType=Ge.FRAGMENTNAMEPART=Ge.DATESETTINGSPATH=Ge.QUICKVARPATHX=Ge.QUICKVARPATH=Ge.UIVOCABULARYALPHADOT=Ge.UIVOCABULARYDOT=Ge.UIVOCABULARY=Ge.VOCWITHCOLONS=Ge.VOCWITHSLASH=Ge.MANIFESTPATH=Ge.SchemaKeyName=Ge.SchemaTag=Ge.PropertyName=Ge.DefinitionName=Ge.ViewTemplateType=Ge.BINDINGPROPERTYREGEXSTRING=Ge.FacetBase=Ge.defaultExportResult=Ge.ChangeIndicator=Ge.ACTIONTITLEPREFIX=Ge.FACETTITLEPREFIX=Ge.FileName=Ge.DirName=Ge.Visualization=Ge.ControlType=Ge.ActionType=Ge.ArtifactType=Ge.SectionType=Ge.ALPViewType=Ge.ExportArtifacts=Ge.CreationFieldType=Ge.SchemaType=Ge.FlexChangeLayer=Ge.FlexibleColumnLayoutType=void 0;var ARt;(function(e){e.OneColumn="OneColumn",e.TwoColumnsBeginExpanded="TwoColumnsBeginExpanded",e.TwoColumnsMidExpanded="TwoColumnsMidExpanded",e.MidColumnFullScreen="MidColumnFullScreen",e.ThreeColumnsMidExpanded="ThreeColumnsMidExpanded",e.ThreeColumnsEndExpanded="ThreeColumnsEndExpanded",e.ThreeColumnsMidExpandedEndHidden="ThreeColumnsMidExpandedEndHidden",e.ThreeColumnsBeginExpandedEndHidden="ThreeColumnsBeginExpandedEndHidden",e.EndColumnFullScreen="EndColumnFullScreen"})(ARt||(Ge.FlexibleColumnLayoutType=ARt={}));var CRt;(function(e){e.Vendor="VENDOR",e.Customer="CUSTOMER_BASE"})(CRt||(Ge.FlexChangeLayer=CRt={}));var wRt;(function(e){e.Application="Application",e.ObjectPage="ObjectPage",e.ListReport="ListReport",e.OverviewPage="OverviewPage",e.AnalyticalListPage="AnalyticalListPage",e.FreestylePage="FreestylePage",e.FPMCustomPage="FPMCustomPage",e.BuildingBlocks="BuildingBlocks"})(wRt||(Ge.SchemaType=wRt={}));var PRt;(function(e){e.Field="Field",e.FieldGroup="FieldGroup"})(PRt||(Ge.CreationFieldType=PRt={}));var DRt;(function(e){e.flex="flex",e.manifest="manifest"})(DRt||(Ge.ExportArtifacts=DRt={}));var NRt;(function(e){e.Primary="primary",e.Secondary="secondary"})(NRt||(Ge.ALPViewType=NRt={}));var IRt;(function(e){e.Section="Section",e.SubSection="SubSection",e.HeaderSection="HeaderSection"})(IRt||(Ge.SectionType=IRt={}));var RRt;(function(e){e.Manifest="Manifest",e.FlexChange="FlexChange",e.Annotation="Annotation",e.XMLProperty="XMLProperty"})(RRt||(Ge.ArtifactType=RRt={}));var LRt;(function(e){e.Annotation="Annotation",e.Copy="Copy",e.Criticality="Criticality",e.Custom="Custom",e.RelatedApps="RelatedApps",e.Standard="Standard"})(LRt||(Ge.ActionType=LRt={}));var kRt;(function(e){e.Table="sap.m.Table",e.TableColumn="sap.m.Column",e.SmartTable="sap.ui.comp.smarttable.SmartTable",e.SmartFilterBar="sap.ui.comp.smartfilterbar.SmartFilterBar",e.SmartChart="sap.ui.comp.smartchart.SmartChart",e.Group="sap.ui.comp.smartform.Group",e.GroupElement="sap.ui.comp.smartform.GroupElement",e.Button="sap.m.Button",e.ToolbarButton="sap.m.OverflowToolbarButton",e.Avatar="sap.f.Avatar",e.ObjectPageDynamicHeaderTitle="sap.uxap.ObjectPageDynamicHeaderTitle",e.ObjectPageGridProperties="sap.ui.layout.GridData",e.ObjectPageHeader="sap.uxap.ObjectPageHeader",e.ObjectPageLayout="sap.uxap.ObjectPageLayout",e.HeaderAction="sap.uxap.ObjectPageHeaderActionButton",e.ObjectPageHeaderSection="sap.m.VBox",e.DynamicPage="sap.f.DynamicPage",e.Form="sap.ui.layout.form",e.Chart="sap.suite.ui.microchart",e.Section="sap.uxap.ObjectPageSection",e.SubSection="sap.uxap.ObjectPageSubSection"})(kRt||(Ge.ControlType=kRt={}));var $Rt;(function(e){e.LineItem="LineItem",e.Chart="Chart"})($Rt||(Ge.Visualization=$Rt={}));var MRt;(function(e){e.Sapux="src",e.Schemas=".schemas",e.Pages="pages",e.Webapp="webapp",e.Temp=".tmp",e.Changes="changes",e.LocalService="localService",e.Controller="controller",e.View="view",e.Fragment="fragment",e.Ext="ext",e.VSCode=".vscode"})(MRt||(Ge.DirName=MRt={}));var FRt;(function(e){e.App="app.json"})(FRt||(Ge.FileName=FRt={}));Ge.FACETTITLEPREFIX="Facet ID: ";Ge.ACTIONTITLEPREFIX="Action ID: ";var _Ce;(function(e){e.NoChange="NoChange",e.Created="Created",e.Updated="Updated",e.Deleted="Deleted"})(_Ce||(Ge.ChangeIndicator=_Ce={}));Ge.defaultExportResult={manifest:{"sap.ui5":{flexEnabled:!0,routing:{targets:{}}},"sap.app":{}},manifestChangeIndicator:_Ce.NoChange,flexChanges:[],fragments:[],views:[]};var jRt;(function(e){e.LineItem="LineItem",e.CollectionFacet="CollectionFacet",e.Chart="Chart",e.Form="Form",e.Identification="Identification",e.DataPoint="DataPoint",e.Address="Address",e.Contact="Contact",e.PresentationVariant="PresentationVariant",e.SelectionPresentationVariant="SelectionPresentationVariant",e.Unknown=""})(jRt||(Ge.FacetBase=jRt={}));Ge.BINDINGPROPERTYREGEXSTRING="^{[A-Za-z0-9{}&$!@#%? _|,<>'()[\\]\\/:=.]+}$";var qRt;(function(e){e.ResponsiveTableColumnsExtension="ResponsiveTableColumnsExtension",e.AnalyticalTableColumnsExtension="AnalyticalTableColumnsExtension",e.TreeTableColumnsExtension="TreeTableColumnsExtension",e.GridTableColumnsExtension="GridTableColumnsExtension",e.ResponsiveTableCellsExtension="ResponsiveTableCellsExtension"})(qRt||(Ge.ViewTemplateType=qRt={}));var VRt;(function(e){e.Action="Action",e.Actions="Actions",e.ActionsLR="Actions<LineItems>",e.ALPChart="ALPChart",e.ALPChartView="ALPChartView",e.ALPTable="ALPTable",e.ALPTableView="ALPTableView",e.AnalyticalListPageFilterBar="AnalyticalListPageFilterBar",e.AnnotationPathAsObject="AnnotationPathAsObject",e.ChartSettings="ChartSettings",e.ChartToolBarAction="ChartToolBarAction",e.CommonHeaderFacetSettings="CommonHeaderFacetSettings",e.CompactFilters="CompactFilters",e.CustomFooterActionOP="CustomFooterActionOP",e.CustomHeaderAction="CustomHeaderAction",e.CustomHeaderActionOP="CustomHeaderActionOP",e.CustomFormActionOP="CustomFormActionOP",e.CustomTableAction="CustomTableAction",e.CustomTableActionOP="CustomTableActionOP",e.CustomColumn="TableCustomColumn",e.CustomColumnOP="TableCustomColumnOP",e.CustomColumns="TableCustomColumns",e.CustomSections="CustomSections",e.FieldPath="FieldPath",e.Field="Field",e.Fields="Fields",e.Fields4Dialog="Fields4Dialog",e.FilterBar="FilterBar",e.FilterBarVisualFilters="FilterBarVisualFilters",e.Footer="Footer",e.FooterAction="FooterAction",e.FooterActionV4="FooterActionV4",e.FooterActions="FooterActions",e.FooterActionsLR="FooterActions<LineItems>",e.Form="Form",e.FormAction="FormAction",e.FormActionBase="FormActionBase",e.ObjectPageFormActionGroup="ObjectPageFormActionGroup",e.GenericActions="GenericActions",e.GenericColumnsOP="GenericColumnsOP",e.GenericFooter="GenericFooter",e.GenericSections="GenericSections",e.GenericSubSections="GenericSubSections",e.GlobalTableSettings="GlobalTableSettings",e.Header="Header",e.HeaderActions="HeaderActions",e.HeaderActionsStandard="HeaderActionsStandard",e.HeaderActionStandard="HeaderActionStandard",e.ObjectPageHeaderAction="ObjectPageHeaderAction",e.ObjectPageHeaderActionBase="ObjectPageHeaderActionBase",e.ObjectPageHeaderActionGroup="ObjectPageHeaderActionGroup",e.ObjectPageHeaderActionStandard="ObjectPageHeaderActionStandard",e.ObjectPageHeaderActions="ObjectPageHeaderActions",e.HeaderSections="HeaderSections",e.LineItem="LineItem",e.LineItems="LineItems",e.LineItemsOfView="LineItemsOfView",e.ListReportFilterBar="ListReportFilterBar",e.LRTableView="LRTableView",e.LRChartView="LRChartView",e.MultiEditV2="MultiEdit",e.MultiTableModeV4="MultiTableModeV4",e.ObjectPageChart="ObjectPageChart",e.ObjectPageCustomHeaderSectionFragment="ObjectPageCustomHeaderSectionFragment",e.ObjectPageCustomSectionFragment="ObjectPageCustomSectionFragment",e.ObjectPageCustomSubSectionFragment="ObjectPageCustomSubSectionFragment",e.ObjectPageForm="ObjectPageForm",e.ObjectPageFooter="ObjectPageFooter",e.ObjectPageFooterAction="ObjectPageFooterAction",e.ObjectPageFooterActions="ObjectPageFooterActions",e.ObjectPageFooterActionStandard="ObjectPageFooterActionStandard",e.ObjectPageHeader="ObjectPageHeader",e.ObjectPageHeaderSectionForm="ObjectPageHeaderSectionForm",e.ObjectPageHeaderSectionChart="ObjectPageHeaderSectionChart",e.ObjectPageHeaderSectionDataPoint="ObjectPageHeaderSectionDataPoint",e.ObjectPageHeaderSectionContact="ObjectPageHeaderSectionContact",e.ObjectPageHeaderSectionAddress="ObjectPageHeaderSectionAddress",e.ObjectPageLayout="ObjectPageLayout",e.ObjectPagePresentationVariant="ObjectPagePresentationVariant",e.ObjectPageSectionAddress="ObjectPageSectionAddress",e.ObjectPageSectionChart="ObjectPageSectionChart",e.ObjectPageSectionContact="ObjectPageSectionContact",e.ObjectPageSectionDataPoint="ObjectPageSectionDataPoint",e.ObjectPageSectionForm="ObjectPageSectionForm",e.ObjectPageSectionPresentationVariant="ObjectPageSectionPresentationVariant",e.ObjectPageSectionTableV4="ObjectPageSectionTableV4",e.ObjectPageSubSections="ObjectPageSubSections",e.ObjectPageResponsiveTableV4="ObjectPageResponsiveTableV4",e.ObjectPageAnalyticalTableV4="ObjectPageAnalyticalTableV4",e.ObjectPageGridTableV4="ObjectPageGridTableV4",e.ObjectPageTreeTableV4="ObjectPageTreeTableV4",e.ObjectPageTable="ObjectPageTable",e.ObjectPageTableColumn="ObjectPageTableColumn",e.ObjectPageToolBar="ObjectPageToolBar",e.ObjectPageToolBarAction="ObjectPageToolBarAction",e.ObjectPageToolBarActionBase="ObjectPageToolBarActionBase",e.ObjectPageToolBarActionGroup="ObjectPageToolBarActionGroup",e.ObjectPageToolBarActions="ObjectPageToolBarActions",e.Position="Position",e.PositionOP="PositionOP",e.QuickVariant="QuickVariant",e.QuickVariantSelectionOP="QuickVariantSelectionOP",e.QuickVariantSelectionV4OP="QuickVariantSelectionV4OP",e.RelatedFacetKeys="RelatedFacetKeys",e.RowCountMode="RowCountMode",e.Sections="Sections",e.SectionActions="SectionActions",e.SelectionFields="SelectionFields",e.Table="Table",e.TableSPV="TableSPV",e.TableColumn="TableColumn",e.TableCreationModeLR="TableCreationModeLR",e.TableViewExtension="TableViewExtension",e.ToolBarAction="ToolBarAction",e.ToolBarActionBase="ToolBarActionBase",e.ToolBarActionGroup="ToolBarActionGroup",e.ToolBarLR="ToolBar<LineItems>",e.ToolBar="ToolBar",e.ViewTableColumn="ViewTableColumn",e.ViewCustomColumn="ViewTableCustomColumn",e.ViewCustomAction="ViewTableCustomAction",e.ViewChartToolBar="ViewChartToolBar",e.ViewToolBarActionGroup="ViewToolBarActionGroup",e.ViewToolBarAction="ViewToolBarAction",e.ViewToolBarActionBase="ViewToolBarActionBase",e.ViewPosition="ViewPosition",e.ViewCustomActionPosition="ViewCustomActionPosition",e.VisualFilters="VisualFilters",e.VisualFilter="VisualFilter",e.CustomActionPosition="CustomActionPosition",e.CustomActionPositionOP="CustomActionPositionOP",e.CustomHeaderActionPosition="CustomHeaderActionPosition",e.CustomHeaderActionPositionOP="CustomHeaderActionPositionOP",e.CustomFooterActionPositionOP="CustomFooterActionPositionOP",e.CustomExtensionFragment="CustomExtensionFragment",e.CustomFilterField="CustomFilterField",e.CustomFilterFieldPosition="CustomFilterFieldPosition",e.SaveAndEdit="SaveAndEdit",e.ObjectPageCustomSectionActions="ObjectPageCustomSectionActions",e.CustomSectionActionOP="CustomSectionActionOP",e.CustomSectionActionPositionOP="CustomSectionActionPositionOP",e.TableCreationModeCreationDialogOPTable="TableCreationModeCreationDialogOPTable",e.TableCreationModeCreationDialogOPTreeTable="TableCreationModeCreationDialogOPTreeTable",e.AnalyticalConfiguration="AnalyticalConfiguration",e.ViewAnalyticalConfiguration="ViewAnalyticalConfiguration",e.HeaderSectionFields="HeaderSectionFields",e.SectionFields="SectionFields",e.CustomField="CustomField",e.CustomFieldPosition="CustomFieldPosition"})(VRt||(Ge.DefinitionName=VRt={}));var URt;(function(e){e.actions="actions",e.annotationPath="annotationPath",e.chart="chart",e.columns="columns",e.createInPlace="createInPlace",e.creationFields="creationFields",e.creationMode="creationMode",e.defaultPath="defaultPath",e.defaultTemplateAnnotationPath="defaultTemplateAnnotationPath",e.footer="footer",e.header="header",e.isCreateEnabled="isCreateEnabled",e.sections="sections",e.table="table",e.tableSettings="tableSettings",e.views="views",e.visualFilters="visualFilters",e.selectionFields="selectionFields",e.analyticalConfiguration="analyticalConfiguration",e.fields="fields"})(URt||(Ge.PropertyName=URt={}));var BRt;(function(e){e.actionType="actionType",e.annotationPath="annotationPath",e.annotationType="annotationType",e.artifactType="artifactType",e.controlId="controlId",e.controlType="controlType",e.conversionExit="conversionExit",e.dataType="dataType",e.deletable="deletable",e.descriptionSrcURL="descriptionSrcURL",e.fullyQualifiedName="fullyQualifiedName",e.hidden="hidden",e.icon="icon",e.isViewNode="isViewNode",e.key="key",e.keys="keys",e.manifestPath="manifestPath",e.messages="messages",e.propertyIndex="propertyIndex",e.target="target",e.defaultControlProperty="defaultControlProperty",e.controlProperty="controlProperty"})(BRt||(Ge.SchemaTag=BRt={}));var zRt;(function(e){e.id="ID",e.value="Value",e.action="Action",e.target="Target",e.key="Key",e.semanticObject="SemanticObject"})(zRt||(Ge.SchemaKeyName=zRt={}));Ge.MANIFESTPATH="webapp/manifest.json";Ge.VOCWITHSLASH="/@com.sap.vocabularies";Ge.VOCWITHCOLONS="::@com.sap.vocabularies";Ge.UIVOCABULARY="com.sap.vocabularies.UI.v1";Ge.UIVOCABULARYDOT="com.sap.vocabularies.UI.v1.";Ge.UIVOCABULARYALPHADOT="@com.sap.vocabularies.UI.v1.";Ge.QUICKVARPATH="/quickVariantSelection";Ge.QUICKVARPATHX="/quickVariantSelectionX";Ge.DATESETTINGSPATH="/filterSettings/dateSettings";Ge.FRAGMENTNAMEPART=".fragment.";var HRt;(function(e){e.Control="Control",e.Property="Property",e.Aggregation="Aggregation",e.Event="Event"})(HRt||(Ge.MacrosPropertyType=HRt={}));var GRt;(function(e){e.LRCreationModeForAnalyticalTable="LRCreationModeForAnalyticalTable",e.LRCreationModeForNonTreeTable="LRCreationModeForNonTreeTable",e.LRCreationModeForNonCreationDialogMode="LRCreationModeForNonCreationDialogMode",e.LRAnalyticalConfigurationForNonAnalyticalTable="LRAnalyticalConfigurationForNonAnalyticalTable"})(GRt||(Ge.RuleName=GRt={}))});var QRt=y(wf=>{"use strict";Object.defineProperty(wf,"__esModule",{value:!0});wf.CloudDevAdaptationStatus=wf.FlexibleColumnLayoutAggregations=wf.StatePreservationMode=wf.TableColumnVerticalAlignment=wf.DraftDiscardEnabledSettings=void 0;var YRt;(function(e){e.restricted="restricted"})(YRt||(wf.DraftDiscardEnabledSettings=YRt={}));var WRt;(function(e){e.Top="Top",e.Middle="Middle",e.Bottom="Bottom"})(WRt||(wf.TableColumnVerticalAlignment=WRt={}));var XRt;(function(e){e.persistence="persistence",e.discovery="discovery"})(XRt||(wf.StatePreservationMode=XRt={}));var JRt;(function(e){e.BeginColumnPages="beginColumnPages",e.MidColumnPages="midColumnPages",e.EndColumnPages="endColumnPages"})(JRt||(wf.FlexibleColumnLayoutAggregations=JRt={}));var ZRt;(function(e){e.Released="released",e.Deprecated="deprecated",e.Obsolete="obsolete"})(ZRt||(wf.CloudDevAdaptationStatus=ZRt={}))});var rLt=y(Mm=>{"use strict";Object.defineProperty(Mm,"__esModule",{value:!0});Mm.ColorPaletteDefinitionType=Mm.GENERICAPPSETTINGS=Mm.ManifestSection=Mm.DataSourceType=void 0;var eLt;(function(e){e.OData="OData",e.ODataAnnotation="ODataAnnotation"})(eLt||(Mm.DataSourceType=eLt={}));var xCe;(function(e){e.ui="sap.ui",e.app="sap.app",e.generic="sap.ui.generic.app",e.ovp="sap.ovp",e.ui5="sap.ui5",e.fiori="sap.fiori",e.fe="sap.fe"})(xCe||(Mm.ManifestSection=xCe={}));Mm.GENERICAPPSETTINGS=`${xCe.generic}/settings`;var tLt;(function(e){e.SemanticColoring="SemanticColoring",e.StableColoring="StableColoring",e.MapDimensionValues="MapDimensionValues"})(tLt||(Mm.ColorPaletteDefinitionType=tLt={}))});var iLt=y(nLt=>{"use strict";Object.defineProperty(nLt,"__esModule",{value:!0})});var oLt=y(Pf=>{"use strict";Object.defineProperty(Pf,"__esModule",{value:!0});Pf.SAPUI5_FRAGMENT_CLASS=Pf.SAPUI5_VIEW_CLASS=Pf.ViewTypes=Pf.FIORI_FCL_ROOT_ID=Pf.FIORI_FCL_ROOT_VIEW_NAME=void 0;Pf.FIORI_FCL_ROOT_VIEW_NAME="sap.fe.templates.RootContainer.view.Fcl";Pf.FIORI_FCL_ROOT_ID="appRootView";var aLt;(function(e){e.XML="XML",e.HTML="HTML",e.JSON="JSON"})(aLt||(Pf.ViewTypes=aLt={}));Pf.SAPUI5_VIEW_CLASS="sap.ui.core.mvc.View";Pf.SAPUI5_FRAGMENT_CLASS="sap.ui.core.Fragment"});var sLt=y(lv=>{"use strict";var RNn=lv&&lv.__createBinding||(Object.create?function(e,t,r,n){n===void 0&&(n=r);var i=Object.getOwnPropertyDescriptor(t,r);(!i||("get"in i?!t.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,i)}:function(e,t,r,n){n===void 0&&(n=r),e[n]=t[r]}),TCe=lv&&lv.__exportStar||function(e,t){for(var r in e)r!=="default"&&!Object.prototype.hasOwnProperty.call(t,r)&&RNn(t,e,r)};Object.defineProperty(lv,"__esModule",{value:!0});TCe(rLt(),lv);TCe(iLt(),lv);TCe(oLt(),lv)});var uLt=y(BW=>{"use strict";Object.defineProperty(BW,"__esModule",{value:!0});BW.ChartColor=void 0;var cLt;(function(e){e.sapUiChartPaletteQualitativeHue1="sapUiChartPaletteQualitativeHue1",e.sapUiChartPaletteQualitativeHue2="sapUiChartPaletteQualitativeHue2",e.sapUiChartPaletteQualitativeHue3="sapUiChartPaletteQualitativeHue3",e.sapUiChartPaletteQualitativeHue4="sapUiChartPaletteQualitativeHue4",e.sapUiChartPaletteQualitativeHue5="sapUiChartPaletteQualitativeHue5",e.sapUiChartPaletteQualitativeHue6="sapUiChartPaletteQualitativeHue6",e.sapUiChartPaletteQualitativeHue7="sapUiChartPaletteQualitativeHue7",e.sapUiChartPaletteQualitativeHue8="sapUiChartPaletteQualitativeHue8",e.sapUiChartPaletteQualitativeHue9="sapUiChartPaletteQualitativeHue9",e.sapUiChartPaletteQualitativeHue10="sapUiChartPaletteQualitativeHue10",e.sapUiChartPaletteQualitativeHue11="sapUiChartPaletteQualitativeHue11",e.sapUiChartPaletteQualitativeHue12="sapUiChartPaletteQualitativeHue12",e.sapUiChartPaletteQualitativeHue13="sapUiChartPaletteQualitativeHue13",e.sapUiChartPaletteQualitativeHue14="sapUiChartPaletteQualitativeHue14",e.sapUiChartPaletteQualitativeHue15="sapUiChartPaletteQualitativeHue15",e.sapUiChartPaletteQualitativeHue16="sapUiChartPaletteQualitativeHue16",e.sapUiChartPaletteQualitativeHue17="sapUiChartPaletteQualitativeHue17",e.sapUiChartPaletteQualitativeHue18="sapUiChartPaletteQualitativeHue18",e.sapUiChartPaletteQualitativeHue19="sapUiChartPaletteQualitativeHue19",e.sapUiChartPaletteQualitativeHue20="sapUiChartPaletteQualitativeHue20",e.sapUiChartPaletteQualitativeHue21="sapUiChartPaletteQualitativeHue21",e.sapUiChartPaletteQualitativeHue22="sapUiChartPaletteQualitativeHue22",e.sapUiChartPaletteSemanticBadLight3="sapUiChartPaletteSemanticBadLight3",e.sapUiChartPaletteSemanticBadLight2="sapUiChartPaletteSemanticBadLight2",e.sapUiChartPaletteSemanticBadLight1="sapUiChartPaletteSemanticBadLight1",e.sapUiChartPaletteSemanticBad="sapUiChartPaletteSemanticBad",e.sapUiChartPaletteSemanticBadDark1="sapUiChartPaletteSemanticBadDark1",e.sapUiChartPaletteSemanticBadDark2="sapUiChartPaletteSemanticBadDark2",e.sapUiChartPaletteSemanticCriticalLight3="sapUiChartPaletteSemanticCriticalLight3",e.sapUiChartPaletteSemanticCriticalLight2="sapUiChartPaletteSemanticCriticalLight2",e.sapUiChartPaletteSemanticCriticalLight1="sapUiChartPaletteSemanticCriticalLight1",e.sapUiChartPaletteSemanticCritical="sapUiChartPaletteSemanticCritical",e.sapUiChartPaletteSemanticCriticalDark1="sapUiChartPaletteSemanticCriticalDark1",e.sapUiChartPaletteSemanticCriticalDark2="sapUiChartPaletteSemanticCriticalDark2",e.sapUiChartPaletteSemanticGoodLight3="sapUiChartPaletteSemanticGoodLight3",e.sapUiChartPaletteSemanticGoodLight2="sapUiChartPaletteSemanticGoodLight2",e.sapUiChartPaletteSemanticGoodLight1="sapUiChartPaletteSemanticGoodLight1",e.sapUiChartPaletteSemanticGood="sapUiChartPaletteSemanticGood",e.sapUiChartPaletteSemanticGoodDark1="sapUiChartPaletteSemanticGoodDark1",e.sapUiChartPaletteSemanticGoodDark2="sapUiChartPaletteSemanticGoodDark2",e.sapUiChartPaletteSemanticNeutralLight3="sapUiChartPaletteSemanticNeutralLight3",e.sapUiChartPaletteSemanticNeutralLight2="sapUiChartPaletteSemanticNeutralLight2",e.sapUiChartPaletteSemanticNeutralLight1="sapUiChartPaletteSemanticNeutralLight1",e.sapUiChartPaletteSemanticNeutral="sapUiChartPaletteSemanticNeutral",e.sapUiChartPaletteSemanticNeutralDark1="sapUiChartPaletteSemanticNeutralDark1",e.sapUiChartPaletteSemanticNeutralDark2="sapUiChartPaletteSemanticNeutralDark2",e.sapUiChartPaletteNoSemDiv1Dark2="sapUiChartPaletteNoSemDiv1Dark2",e.sapUiChartPaletteNoSemDiv1Dark1="sapUiChartPaletteNoSemDiv1Dark1",e.sapUiChartPaletteNoSemDiv1="sapUiChartPaletteNoSemDiv1",e.sapUiChartPaletteNoSemDiv1Light1="sapUiChartPaletteNoSemDiv1Light1",e.sapUiChartPaletteNoSemDiv1Light2="sapUiChartPaletteNoSemDiv1Light2",e.sapUiChartPaletteNoSemDiv1Light3="sapUiChartPaletteNoSemDiv1Light3",e.sapUiChartPaletteSequentialHue1Light3="sapUiChartPaletteSequentialHue1Light3",e.sapUiChartPaletteSequentialHue1Light2="sapUiChartPaletteSequentialHue1Light2",e.sapUiChartPaletteSequentialHue1Light1="sapUiChartPaletteSequentialHue1Light1",e.sapUiChartPaletteSequentialHue1="sapUiChartPaletteSequentialHue1",e.sapUiChartPaletteSequentialHue1Dark1="sapUiChartPaletteSequentialHue1Dark1",e.sapUiChartPaletteSequentialHue1Dark2="sapUiChartPaletteSequentialHue1Dark2",e.sapUiChartPaletteSequentialHue2Light3="sapUiChartPaletteSequentialHue2Light3",e.sapUiChartPaletteSequentialHue2Light2="sapUiChartPaletteSequentialHue2Light2",e.sapUiChartPaletteSequentialHue2Light1="sapUiChartPaletteSequentialHue2Light1",e.sapUiChartPaletteSequentialHue2="sapUiChartPaletteSequentialHue2",e.sapUiChartPaletteSequentialHue2Dark1="sapUiChartPaletteSequentialHue2Dark1",e.sapUiChartPaletteSequentialHue2Dark2="sapUiChartPaletteSequentialHue2Dark2",e.sapUiChartPaletteSequentialHue3Light3="sapUiChartPaletteSequentialHue3Light3",e.sapUiChartPaletteSequentialHue3Light2="sapUiChartPaletteSequentialHue3Light2",e.sapUiChartPaletteSequentialHue3Light1="sapUiChartPaletteSequentialHue3Light1",e.sapUiChartPaletteSequentialHue3="sapUiChartPaletteSequentialHue3",e.sapUiChartPaletteSequentialHue3Dark1="sapUiChartPaletteSequentialHue3Dark1",e.sapUiChartPaletteSequentialHue3Dark2="sapUiChartPaletteSequentialHue3Dark2",e.sapUiChartPaletteSequentialHue6Light3="sapUiChartPaletteSequentialHue6Light3",e.sapUiChartPaletteSequentialHue6Light2="sapUiChartPaletteSequentialHue6Light2",e.sapUiChartPaletteSequentialHue6Light1="sapUiChartPaletteSequentialHue6Light1",e.sapUiChartPaletteSequentialHue6="sapUiChartPaletteSequentialHue6",e.sapUiChartPaletteSequentialHue6Dark1="sapUiChartPaletteSequentialHue6Dark1",e.sapUiChartPaletteSequentialHue6Dark2="sapUiChartPaletteSequentialHue6Dark2",e.sapUiChartPaletteSequentialNeutralLight3="sapUiChartPaletteSequentialNeutralLight3",e.sapUiChartPaletteSequentialNeutralLight2="sapUiChartPaletteSequentialNeutralLight2",e.sapUiChartPaletteSequentialNeutralLight1="sapUiChartPaletteSequentialNeutralLight1",e.sapUiChartPaletteSequentialNeutral="sapUiChartPaletteSequentialNeutral",e.sapUiChartPaletteSequentialNeutralDark1="sapUiChartPaletteSequentialNeutralDark1",e.sapUiChartPaletteSequentialNeutralDark2="sapUiChartPaletteSequentialNeutralDark2",e.sapUiChoroplethRegionBG="sapUiChoroplethRegionBG",e.sapUiChartZeroAxisColor="sapUiChartZeroAxisColor",e.sapUiNegativeElement="sapUiNegativeElement",e.sapUiCriticalElement="sapUiCriticalElement",e.sapUiPositiveElement="sapUiPositiveElement",e.sapUiNeutralElement="sapUiNeutralElement"})(cLt||(BW.ChartColor=cLt={}))});var lLt=y(Jd=>{"use strict";var LNn=Jd&&Jd.__createBinding||(Object.create?function(e,t,r,n){n===void 0&&(n=r);var i=Object.getOwnPropertyDescriptor(t,r);(!i||("get"in i?!t.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,i)}:function(e,t,r,n){n===void 0&&(n=r),e[n]=t[r]}),xj=Jd&&Jd.__exportStar||function(e,t){for(var r in e)r!=="default"&&!Object.prototype.hasOwnProperty.call(t,r)&&LNn(t,e,r)};Object.defineProperty(Jd,"__esModule",{value:!0});xj(SRt(),Jd);xj(KRt(),Jd);xj(QRt(),Jd);xj(sLt(),Jd);xj(uLt(),Jd)});var gLt=y(nl=>{"use strict";Object.defineProperty(nl,"__esModule",{value:!0});nl.Features=nl.CustomExtensionType=nl.TemplateType=nl.PropertyMessageType=nl.logSeverityLabel=nl.LogSeverity=void 0;var pLt;(function(e){e.Error="error",e.Warning="warning",e.Info="info"})(pLt||(nl.LogSeverity=pLt={}));nl.logSeverityLabel={error:"Error",warning:"Warning",info:"Information"};var fLt;(function(e){e.Error="error",e.Warning="warning",e.Info="info"})(fLt||(nl.PropertyMessageType=fLt={}));var dLt;(function(e){e.ListReportObjectPageV2="ListReportObjectPageV2",e.ListReportObjectPageV4="ListReportObjectPageV4",e.OverviewPageV2="OverviewPageV2",e.AnalyticalListPageV2="AnalyticalListPageV2",e.AnalyticalListPageV4="AnalyticalListPageV4",e.FreestylePageV4="FreestylePageV4"})(dLt||(nl.TemplateType=dLt={}));var hLt;(function(e){e.ControllerExtension="ControllerExtension",e.CustomAction="CustomAction",e.CustomColumn="CustomColumn",e.CustomFilterField="CustomFilterField",e.CustomHeaderSection="CustomHeaderSection",e.CustomPage="CustomPage",e.CustomSection="CustomSection",e.CustomSubSection="CustomSubSection",e.CustomView="CustomView",e.ListReport="ListReport",e.ObjectPage="ObjectPage",e.CustomField="CustomField"})(hLt||(nl.CustomExtensionType=hLt={}));var mLt;(function(e){e.BuildingBlocks="BuildingBlocks"})(mLt||(nl.Features=mLt={}))});var vLt=y(yLt=>{"use strict";Object.defineProperty(yLt,"__esModule",{value:!0})});var CLt=y(xa=>{"use strict";Object.defineProperty(xa,"__esModule",{value:!0});xa.LinkListFlavorType=xa.SortOrderType=xa.ListTypeType=xa.ListFlavorType=xa.MeasureAggregateValues=xa.CardSettingsType=xa.cardTemplateSettingsMap=xa.cardTemplateTypeMap=xa.CardTemplateType=xa.ChartCardType=void 0;var bLt;(function(e){e.cardBubble="cardBubble",e.cardchartsline="cardchartsline",e.cardchartsdonut="cardchartsdonut"})(bLt||(xa.ChartCardType=bLt={}));var ELt;(function(e){e.analytical="sap.ovp.cards.charts.analytical",e.analyticalv4="sap.ovp.cards.v4.charts.analytical",e.list="sap.ovp.cards.list",e.listv4="sap.ovp.cards.v4.list",e.linklist="sap.ovp.cards.linklist",e.linklistv4="sap.ovp.cards.v4.linklist",e.table="sap.ovp.cards.table",e.tablev4="sap.ovp.cards.v4.table",e.stack="sap.ovp.cards.stack"})(ELt||(xa.CardTemplateType=ELt={}));xa.cardTemplateTypeMap={"sap.ovp.cards.charts.analytical":"AnalyticalCard","sap.ovp.cards.v4.charts.analytical":"AnalyticalCard","sap.ovp.cards.list":"ListCard","sap.ovp.cards.v4.list":"ListCard","sap.ovp.cards.linklist":"LinklistCard","sap.ovp.cards.v4.linklist":"LinklistCard","sap.ovp.cards.table":"TableCard","sap.ovp.cards.v4.table":"TableCard","sap.ovp.cards.stack":"StackCard"};xa.cardTemplateSettingsMap={"sap.ovp.cards.charts.analytical":"AnalyticalCardSettings","sap.ovp.cards.v4.charts.analytical":"AnalyticalCardSettingsv4"};var _Lt;(function(e){e.analyticalCardSettings="analyticalCardSettings",e.analyticalCardSettingsv4="analyticalCardSettingsv4",e.listCardSettings="listCardSettings",e.listCardSettingsv4="listCardSettingsv4",e.stackCardSettings="stackCardSettings",e.linkListCardSettings="linkListCardSettings",e.tableCardSettings="tableCardSettings",e.tableCardSettingsv4="tableCardSettingsv4"})(_Lt||(xa.CardSettingsType=_Lt={}));var xLt;(function(e){e.average="average",e.max="max",e.min="min",e.sum="sum",e.count="$count"})(xLt||(xa.MeasureAggregateValues=xLt={}));var TLt;(function(e){e.standard="standard",e.bar="bar",e.carousel="carousel"})(TLt||(xa.ListFlavorType=TLt={}));var OLt;(function(e){e.extended="extended",e.condensed="condensed"})(OLt||(xa.ListTypeType=OLt={}));var SLt;(function(e){e.ascending="ascending",e.descending="descending"})(SLt||(xa.SortOrderType=SLt={}));var ALt;(function(e){e.standard="standard",e.carousel="carousel"})(ALt||(xa.LinkListFlavorType=ALt={}))});var PLt=y(wLt=>{"use strict";Object.defineProperty(wLt,"__esModule",{value:!0})});var RLt=y(SE=>{"use strict";Object.defineProperty(SE,"__esModule",{value:!0});SE.FilterPathType=SE.DefaultDateRangeValueType=SE.DateRangeType=void 0;var DLt;(function(e){e.DATERANGE="DATERANGE",e.DATE="DATE",e.FROM="FROM",e.TO="TO",e.DAYS="DAYS",e.LASTDAYS="LASTDAYS",e.LASTWEEKS="LASTWEEKS",e.WEEK="WEEK",e.LASTMONTHS="LASTMONTHS",e.MONTH="MONTH",e.QUARTER="QUARTER",e.LASTQUARTERS="LASTQUARTERS",e.LASTYEARS="LASTYEARS",e.LASTYEAR="LASTYEAR",e.YEAR="YEAR",e.NEXTDAYS="NEXTDAYS",e.NEXTWEEKS="NEXTWEEKS",e.NEXTMONTHS="NEXTMONTHS",e.NEXTQUARTERS="NEXTQUARTERS",e.NEXTYEARS="NEXTYEARS",e.NEXT="NEXT",e.SPECIFICMONTH="SPECIFICMONTH",e.YESTERDAY="YESTERDAY",e.YEARTODATE="YEARTODATE",e.TODAY="TODAY",e.TOMORROW="TOMORROW",e.THISWEEK="THISWEEK",e.LASTWEEK="LASTWEEK",e.LAST2WEEKS="LAST2WEEKS",e.LAST3WEEKS="LAST3WEEKS",e.LAST4WEEKS="LAST4WEEKS",e.LAST5WEEKS="LAST5WEEKS",e.NEXTWEEK="NEXTWEEK",e.NEXT2WEEKS="NEXT2WEEKS",e.NEXT3WEEKS="NEXT3WEEKS",e.NEXT4WEEKS="NEXT4WEEKS",e.NEXT5WEEKS="NEXT5WEEKS",e.THISMONTH="THISMONTH",e.LASTMONTH="LASTMONTH",e.NEXTMONTH="NEXTMONTH",e.THISQUARTER="THISQUARTER",e.LASTQUARTER="LASTQUARTER",e.NEXTQUARTER="NEXTQUARTER",e.QUARTER1="QUARTER1",e.QUARTER2="QUARTER2",e.QUARTER3="QUARTER3",e.QUARTER4="QUARTER4",e.TODAYFROMTO="TODAYFROMTO"})(DLt||(SE.DateRangeType=DLt={}));var NLt;(function(e){e.YESTERDAY="YESTERDAY",e.TODAY="TODAY",e.THISWEEK="THISWEEK",e.LASTWEEK="LASTWEEK",e.THISMONTH="THISMONTH",e.TOMORROW="TOMORROW",e.LASTMONTH="LASTMONTH",e.THISQUARTER="THISQUARTER",e.LASTQUARTER="LASTQUARTER",e.THISYEAR="THISYEAR",e.LASTYEAR="LASTYEAR",e.LAST2WEEKS="LAST2WEEKS",e.LAST3WEEKS="LAST3WEEKS",e.LAST4WEEKS="LAST4WEEKS",e.LAST5WEEKS="LAST5WEEKS",e.YEARTODATE="YEARTODATE",e.QUARTER1="QUARTER1",e.QUARTER2="QUARTER2",e.QUARTER3="QUARTER3",e.QUARTER4="QUARTER4",e.DATETOYEAR="DATETOYEAR"})(NLt||(SE.DefaultDateRangeValueType=NLt={}));var ILt;(function(e){e.key="key",e.catgory="category"})(ILt||(SE.FilterPathType=ILt={}))});var kLt=y(LLt=>{"use strict";Object.defineProperty(LLt,"__esModule",{value:!0})});var zLt=y(Qo=>{"use strict";Object.defineProperty(Qo,"__esModule",{value:!0});Qo.LoadDataOnAppLaunchSettings=Qo.DefaultFilterMode=Qo.DefaultContentView=Qo.IgnoredFieldsType=Qo.Strategy=Qo.TableColumnExtensionTypeV2=Qo.TableTypeV2=Qo.customColumnViewTypes=void 0;var $Lt;(function(e){e.XML="XML"})($Lt||(Qo.customColumnViewTypes=$Lt={}));var MLt;(function(e){e.ResponsiveTable="ResponsiveTable",e.GridTable="GridTable",e.AnalyticalTable="AnalyticalTable",e.TreeTable="TreeTable"})(MLt||(Qo.TableTypeV2=MLt={}));var FLt;(function(e){e.ResponsiveTableColumnsExtension="ResponsiveTableColumnsExtension",e.AnalyticalTableColumnsExtension="AnalyticalTableColumnsExtension",e.TreeTableColumnsExtension="TreeTableColumnsExtension",e.GridTableColumnsExtension="GridTableColumnsExtension"})(FLt||(Qo.TableColumnExtensionTypeV2=FLt={}));var jLt;(function(e){e.extension="extension"})(jLt||(Qo.Strategy=jLt={}));var qLt;(function(e){e.GENERICPROPERTY="GENERICPROPERTY"})(qLt||(Qo.IgnoredFieldsType=qLt={}));var VLt;(function(e){e.charttable="charttable",e.chart="chart",e.table="table"})(VLt||(Qo.DefaultContentView=VLt={}));var ULt;(function(e){e.visual="visual",e.compact="compact"})(ULt||(Qo.DefaultFilterMode=ULt={}));var BLt;(function(e){e.always="always",e.never="never",e.ifAnyFilterExist="ifAnyFilterExist"})(BLt||(Qo.LoadDataOnAppLaunchSettings=BLt={}))});var GLt=y(HLt=>{"use strict";Object.defineProperty(HLt,"__esModule",{value:!0})});var YLt=y(KLt=>{"use strict";Object.defineProperty(KLt,"__esModule",{value:!0})});var XLt=y(zW=>{"use strict";Object.defineProperty(zW,"__esModule",{value:!0});zW.ChartType=void 0;var WLt;(function(e){e.bar="bar",e.column="column",e.line="line",e.combination="combination",e.pie="pie",e.donut="donut",e.scatter="scatter",e.bubble="bubble",e.heatmap="heatmap",e.bullet="bullet",e.verticalBullet="vertical_bullet",e.stackedBar="stacked_bar",e.stackedColumn="stacked_column",e.stackedCombination="stacked_combination",e.horizontalStackedCombination="horizontal_stacked_combination",e.dualBar="dual_bar",e.dualColumn="dual_column",e.dualLine="dual_line",e.dualStackedBar="dual_stacked_bar",e.dualStackedColumn="dual_stacked_column",e.dualCombination="dual_combination",e.dualStackedCombination="dual_stacked_combination",e.dualHorizontalCombination="dual_horizontal_combination",e.dualHorizontalStackedCombination="dual_horizontal_stacked_combination",e.hundredStackedBar="100_stacked_bar",e.hundredStackedColumn="100_stacked_column",e.hundredDualStackedBar="100_dual_stacked_bar",e.hundredDualStackedColumn="100_dual_stacked_column",e.waterfall="waterfall",e.horizontalWaterfall="horizontal_waterfall"})(WLt||(zW.ChartType=WLt={}))});var ZLt=y(JLt=>{"use strict";Object.defineProperty(JLt,"__esModule",{value:!0})});var ekt=y(QLt=>{"use strict";Object.defineProperty(QLt,"__esModule",{value:!0})});var rkt=y(tkt=>{"use strict";Object.defineProperty(tkt,"__esModule",{value:!0})});var ikt=y(nkt=>{"use strict";Object.defineProperty(nkt,"__esModule",{value:!0})});var skt=y(lD=>{"use strict";Object.defineProperty(lD,"__esModule",{value:!0});lD.ExtensionFragmentTypes=lD.SectionPosition=void 0;var akt;(function(e){e.AfterFacet="AfterFacet",e.BeforeFacet="BeforeFacet",e.ReplaceFacet="ReplaceFacet"})(akt||(lD.SectionPosition=akt={}));var okt;(function(e){e.XML="XML"})(okt||(lD.ExtensionFragmentTypes=okt={}))});var ukt=y(ckt=>{"use strict";Object.defineProperty(ckt,"__esModule",{value:!0})});var pkt=y(lkt=>{"use strict";Object.defineProperty(lkt,"__esModule",{value:!0})});var dkt=y(HW=>{"use strict";Object.defineProperty(HW,"__esModule",{value:!0});HW.CreateMode=void 0;var fkt;(function(e){e.creationRows="creationRows",e.creationRowsHiddenInEditMode="creationRowsHiddenInEditMode",e.inline="inline"})(fkt||(HW.CreateMode=fkt={}))});var mkt=y(hkt=>{"use strict";Object.defineProperty(hkt,"__esModule",{value:!0})});var gkt=y(Wi=>{"use strict";var kNn=Wi&&Wi.__createBinding||(Object.create?function(e,t,r,n){n===void 0&&(n=r);var i=Object.getOwnPropertyDescriptor(t,r);(!i||("get"in i?!t.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,i)}:function(e,t,r,n){n===void 0&&(n=r),e[n]=t[r]}),es=Wi&&Wi.__exportStar||function(e,t){for(var r in e)r!=="default"&&!Object.prototype.hasOwnProperty.call(t,r)&&kNn(t,e,r)};Object.defineProperty(Wi,"__esModule",{value:!0});es(vLt(),Wi);es(CLt(),Wi);es(PLt(),Wi);es(RLt(),Wi);es(kLt(),Wi);es(zLt(),Wi);es(GLt(),Wi);es(YLt(),Wi);es(XLt(),Wi);es(ZLt(),Wi);es(ekt(),Wi);es(rkt(),Wi);es(ikt(),Wi);es(skt(),Wi);es(ukt(),Wi);es(pkt(),Wi);es(dkt(),Wi);es(mkt(),Wi)});var ykt=y(Fm=>{"use strict";Object.defineProperty(Fm,"__esModule",{value:!0});Fm.FE_TEMPLATE_V2_ALP=Fm.FE_TEMPLATE_V2_LIST_REPORT=Fm.FE_TEMPLATE_V2_OBJECT_PAGE=Fm.FE_TEMPLATE_V2=void 0;Fm.FE_TEMPLATE_V2="sap.suite.ui.generic.template";Fm.FE_TEMPLATE_V2_OBJECT_PAGE="sap.suite.ui.generic.template.ObjectPage";Fm.FE_TEMPLATE_V2_LIST_REPORT="sap.suite.ui.generic.template.ListReport";Fm.FE_TEMPLATE_V2_ALP="sap.suite.ui.generic.template.AnalyticalListPage"});var vkt=y(Df=>{"use strict";Object.defineProperty(Df,"__esModule",{value:!0});Df.SAPUI5_VIEW_EXTENSION_ANALYTICAL_LIST_PAGE=Df.SAPUI5_VIEW_EXTENSION_LIST_REPORT=Df.SAPUI5_VIEW_EXTENSION_OBJECT_PAGE=Df.SAPUI5_CONTROLLER_EXTENSION=Df.SAPUI5_VIEW_EXTENSION=void 0;Df.SAPUI5_VIEW_EXTENSION="sap.ui.viewExtensions";Df.SAPUI5_CONTROLLER_EXTENSION="sap.ui.controllerExtensions";Df.SAPUI5_VIEW_EXTENSION_OBJECT_PAGE="sap.suite.ui.generic.template.ObjectPage.view.Details";Df.SAPUI5_VIEW_EXTENSION_LIST_REPORT="sap.suite.ui.generic.template.ListReport.view.ListReport";Df.SAPUI5_VIEW_EXTENSION_ANALYTICAL_LIST_PAGE="sap.suite.ui.generic.template.AnalyticalListPage.view.AnalyticalListPage"});var Ekt=y(bkt=>{"use strict";Object.defineProperty(bkt,"__esModule",{value:!0})});var _kt=y(pv=>{"use strict";var $Nn=pv&&pv.__createBinding||(Object.create?function(e,t,r,n){n===void 0&&(n=r);var i=Object.getOwnPropertyDescriptor(t,r);(!i||("get"in i?!t.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,i)}:function(e,t,r,n){n===void 0&&(n=r),e[n]=t[r]}),OCe=pv&&pv.__exportStar||function(e,t){for(var r in e)r!=="default"&&!Object.prototype.hasOwnProperty.call(t,r)&&$Nn(t,e,r)};Object.defineProperty(pv,"__esModule",{value:!0});OCe(ykt(),pv);OCe(vkt(),pv);OCe(Ekt(),pv)});var xkt=y(SO=>{"use strict";var MNn=SO&&SO.__createBinding||(Object.create?function(e,t,r,n){n===void 0&&(n=r);var i=Object.getOwnPropertyDescriptor(t,r);(!i||("get"in i?!t.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,i)}:function(e,t,r,n){n===void 0&&(n=r),e[n]=t[r]}),FNn=SO&&SO.__exportStar||function(e,t){for(var r in e)r!=="default"&&!Object.prototype.hasOwnProperty.call(t,r)&&MNn(t,e,r)};Object.defineProperty(SO,"__esModule",{value:!0});FNn(_kt(),SO)});var Okt=y(Tkt=>{"use strict";Object.defineProperty(Tkt,"__esModule",{value:!0})});var Akt=y(Skt=>{"use strict";Object.defineProperty(Skt,"__esModule",{value:!0})});var wkt=y(Ckt=>{"use strict";Object.defineProperty(Ckt,"__esModule",{value:!0})});var Dkt=y(Pkt=>{"use strict";Object.defineProperty(Pkt,"__esModule",{value:!0})});var Ikt=y(Nkt=>{"use strict";Object.defineProperty(Nkt,"__esModule",{value:!0})});var Rkt=y(jm=>{"use strict";var jNn=jm&&jm.__createBinding||(Object.create?function(e,t,r,n){n===void 0&&(n=r);var i=Object.getOwnPropertyDescriptor(t,r);(!i||("get"in i?!t.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,i)}:function(e,t,r,n){n===void 0&&(n=r),e[n]=t[r]}),GW=jm&&jm.__exportStar||function(e,t){for(var r in e)r!=="default"&&!Object.prototype.hasOwnProperty.call(t,r)&&jNn(t,e,r)};Object.defineProperty(jm,"__esModule",{value:!0});GW(Akt(),jm);GW(wkt(),jm);GW(Dkt(),jm);GW(Ikt(),jm)});var $kt=y(KW=>{"use strict";Object.defineProperty(KW,"__esModule",{value:!0});KW.ContainerLayoutType=void 0;var Lkt;(function(e){e.always="always",e.never="never",e.ifAnyFilterExist="ifAnyFilterExist"})(Lkt||(Lkt={}));var kkt;(function(e){e.fixed="fixed",e.resizable="resizable"})(kkt||(KW.ContainerLayoutType=kkt={}))});var Fkt=y(Mkt=>{"use strict";Object.defineProperty(Mkt,"__esModule",{value:!0})});var qkt=y(jkt=>{"use strict";Object.defineProperty(jkt,"__esModule",{value:!0})});var Vkt=y(up=>{"use strict";var qNn=up&&up.__createBinding||(Object.create?function(e,t,r,n){n===void 0&&(n=r);var i=Object.getOwnPropertyDescriptor(t,r);(!i||("get"in i?!t.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,i)}:function(e,t,r,n){n===void 0&&(n=r),e[n]=t[r]}),AO=up&&up.__exportStar||function(e,t){for(var r in e)r!=="default"&&!Object.prototype.hasOwnProperty.call(t,r)&&qNn(t,e,r)};Object.defineProperty(up,"__esModule",{value:!0});AO(gkt(),up);AO(xkt(),up);AO(Okt(),up);AO(Rkt(),up);AO($kt(),up);AO(Fkt(),up);AO(qkt(),up)});var Bkt=y(YW=>{"use strict";Object.defineProperty(YW,"__esModule",{value:!0});YW.ActionPlacement=void 0;var Ukt;(function(e){e.After="After",e.Before="Before"})(Ukt||(YW.ActionPlacement=Ukt={}))});var Hkt=y(WW=>{"use strict";Object.defineProperty(WW,"__esModule",{value:!0});WW.FieldPlacement=void 0;var zkt;(function(e){e.After="After",e.Before="Before"})(zkt||(WW.FieldPlacement=zkt={}))});var Zkt=y(bc=>{"use strict";Object.defineProperty(bc,"__esModule",{value:!0});bc.OperationGroupingMode=bc.EMPTY_OPTION=bc.DefaultPathType=bc.InitialLoadType=bc.TableTypeV4=bc.RowCountMode=bc.SelectionMode=void 0;var Gkt;(function(e){e.Multi="Multi",e.None="None",e.Single="Single",e.Auto="Auto"})(Gkt||(bc.SelectionMode=Gkt={}));var Kkt;(function(e){e.Fixed="Fixed",e.Auto="Auto",e.Interactive="Interactive"})(Kkt||(bc.RowCountMode=Kkt={}));var Ykt;(function(e){e.ResponsiveTable="ResponsiveTable",e.GridTable="GridTable",e.AnalyticalTable="AnalyticalTable",e.TreeTable="TreeTable"})(Ykt||(bc.TableTypeV4=Ykt={}));var Wkt;(function(e){e.Disabled="Disabled",e.Enabled="Enabled",e.Auto="Auto"})(Wkt||(bc.InitialLoadType=Wkt={}));var Xkt;(function(e){e.Primary="primary",e.Secondary="secondary",e.Both="both"})(Xkt||(bc.DefaultPathType=Xkt={}));bc.EMPTY_OPTION="";var Jkt;(function(e){e.ChangeSet="ChangeSet",e.Isolated="Isolated"})(Jkt||(bc.OperationGroupingMode=Jkt={}))});var r$t=y(AE=>{"use strict";Object.defineProperty(AE,"__esModule",{value:!0});AE.FilterFieldPlacement=AE.InitialLayoutType=AE.LayoutType=void 0;var Qkt;(function(e){e.Compact="Compact",e.CompactVisual="CompactVisual"})(Qkt||(AE.LayoutType=Qkt={}));var e$t;(function(e){e.Compact="Compact",e.Visual="Visual"})(e$t||(AE.InitialLayoutType=e$t={}));var t$t;(function(e){e.After="After",e.Before="Before"})(t$t||(AE.FilterFieldPlacement=t$t={}))});var i$t=y(n$t=>{"use strict";Object.defineProperty(n$t,"__esModule",{value:!0})});var o$t=y(XW=>{"use strict";Object.defineProperty(XW,"__esModule",{value:!0});XW.SelectType=void 0;var a$t;(function(e){e.single="single",e.multi="multi"})(a$t||(XW.SelectType=a$t={}))});var c$t=y(s$t=>{"use strict";Object.defineProperty(s$t,"__esModule",{value:!0})});var SCe=y(u$t=>{"use strict";Object.defineProperty(u$t,"__esModule",{value:!0})});var p$t=y(l$t=>{"use strict";Object.defineProperty(l$t,"__esModule",{value:!0})});var d$t=y(f$t=>{"use strict";Object.defineProperty(f$t,"__esModule",{value:!0})});var m$t=y(JW=>{"use strict";Object.defineProperty(JW,"__esModule",{value:!0});JW.SectionLayoutType=void 0;var h$t;(function(e){e.Tabs="Tabs",e.Page="Page"})(h$t||(JW.SectionLayoutType=h$t={}))});var v$t=y(pD=>{"use strict";Object.defineProperty(pD,"__esModule",{value:!0});pD.CustomSectionViewTypesV4=pD.SectionPosition=void 0;var g$t;(function(e){e.After="After",e.Before="Before"})(g$t||(pD.SectionPosition=g$t={}));var y$t;(function(e){e.XML="XML"})(y$t||(pD.CustomSectionViewTypesV4=y$t={}))});var E$t=y(ZW=>{"use strict";Object.defineProperty(ZW,"__esModule",{value:!0});ZW.TableCreationModeType=void 0;var b$t;(function(e){e.NewPage="NewPage",e.InlineCreationRows="InlineCreationRows",e.Inline="Inline",e.CreationDialog="CreationDialog",e.External="External"})(b$t||(ZW.TableCreationModeType=b$t={}))});var x$t=y(_$t=>{"use strict";Object.defineProperty(_$t,"__esModule",{value:!0})});var T$t=y(Ua=>{"use strict";var VNn=Ua&&Ua.__createBinding||(Object.create?function(e,t,r,n){n===void 0&&(n=r);var i=Object.getOwnPropertyDescriptor(t,r);(!i||("get"in i?!t.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,i)}:function(e,t,r,n){n===void 0&&(n=r),e[n]=t[r]}),fu=Ua&&Ua.__exportStar||function(e,t){for(var r in e)r!=="default"&&!Object.prototype.hasOwnProperty.call(t,r)&&VNn(t,e,r)};Object.defineProperty(Ua,"__esModule",{value:!0});fu(Bkt(),Ua);fu(Hkt(),Ua);fu(Zkt(),Ua);fu(r$t(),Ua);fu(i$t(),Ua);fu(o$t(),Ua);fu(c$t(),Ua);fu(SCe(),Ua);fu(p$t(),Ua);fu(d$t(),Ua);fu(m$t(),Ua);fu(v$t(),Ua);fu(E$t(),Ua);fu(x$t(),Ua);fu(SCe(),Ua)});var S$t=y(Ec=>{"use strict";Object.defineProperty(Ec,"__esModule",{value:!0});Ec.SectionPositionV4=Ec.SAPUI5_FRAGMENT_TYPE_V4=Ec.FE_TEMPLATE_V4_ALP=Ec.FE_TEMPLATE_V4_LIST_REPORT=Ec.FE_TEMPLATE_V4_OBJECT_PAGE=Ec.FE_TEMPLATE_V4_CUSTOM_PAGE=Ec.FE_NAMESPACE_V4=void 0;Ec.FE_NAMESPACE_V4="sap.fe";Ec.FE_TEMPLATE_V4_CUSTOM_PAGE="sap.fe.core.fpm";Ec.FE_TEMPLATE_V4_OBJECT_PAGE="sap.fe.templates.ObjectPage";Ec.FE_TEMPLATE_V4_LIST_REPORT="sap.fe.templates.ListReport";Ec.FE_TEMPLATE_V4_ALP="sap.fe.templates.AnalyticalListPage";Ec.SAPUI5_FRAGMENT_TYPE_V4="XMLFragment";var O$t;(function(e){e.AfterFacet="AfterFacet",e.BeforeFacet="BeforeFacet"})(O$t||(Ec.SectionPositionV4=O$t={}))});var A$t=y(Nf=>{"use strict";Object.defineProperty(Nf,"__esModule",{value:!0});Nf.SAPUI5_VIEW_EXTENSION_LIST_REPORT=Nf.SAPUI5_VIEW_EXTENSION_OBJECT_PAGE=Nf.SAPUI5_CONTROLLER_EXTENSION=Nf.SAPUI5_DEPENDENCY_LIB_SAP_F=Nf.FIORI_FCL_ROUTER_CLASS=void 0;Nf.FIORI_FCL_ROUTER_CLASS="sap.f.routing.Router";Nf.SAPUI5_DEPENDENCY_LIB_SAP_F="sap.f";Nf.SAPUI5_CONTROLLER_EXTENSION="sap.ui.controllerExtensions";Nf.SAPUI5_VIEW_EXTENSION_OBJECT_PAGE="sap.fe.templates.ObjectPage.ObjectPageController";Nf.SAPUI5_VIEW_EXTENSION_LIST_REPORT="sap.fe.templates.ListReport.ListReportController"});var D$t=y(CE=>{"use strict";Object.defineProperty(CE,"__esModule",{value:!0});CE.HorizontalAlign=CE.Availability=CE.Placement=void 0;var C$t;(function(e){e.After="After",e.Before="Before"})(C$t||(CE.Placement=C$t={}));var w$t;(function(e){e.Default="Default",e.Adaptation="Adaptation",e.Hidden="Hidden"})(w$t||(CE.Availability=w$t={}));var P$t;(function(e){e.Begin="Begin",e.Center="Center",e.End="End"})(P$t||(CE.HorizontalAlign=P$t={}))});var N$t=y(fv=>{"use strict";var UNn=fv&&fv.__createBinding||(Object.create?function(e,t,r,n){n===void 0&&(n=r);var i=Object.getOwnPropertyDescriptor(t,r);(!i||("get"in i?!t.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,i)}:function(e,t,r,n){n===void 0&&(n=r),e[n]=t[r]}),ACe=fv&&fv.__exportStar||function(e,t){for(var r in e)r!=="default"&&!Object.prototype.hasOwnProperty.call(t,r)&&UNn(t,e,r)};Object.defineProperty(fv,"__esModule",{value:!0});ACe(S$t(),fv);ACe(A$t(),fv);ACe(D$t(),fv)});var I$t=y(CO=>{"use strict";var BNn=CO&&CO.__createBinding||(Object.create?function(e,t,r,n){n===void 0&&(n=r);var i=Object.getOwnPropertyDescriptor(t,r);(!i||("get"in i?!t.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,i)}:function(e,t,r,n){n===void 0&&(n=r),e[n]=t[r]}),zNn=CO&&CO.__exportStar||function(e,t){for(var r in e)r!=="default"&&!Object.prototype.hasOwnProperty.call(t,r)&&BNn(t,e,r)};Object.defineProperty(CO,"__esModule",{value:!0});zNn(N$t(),CO)});var L$t=y(R$t=>{"use strict";Object.defineProperty(R$t,"__esModule",{value:!0})});var $$t=y(QW=>{"use strict";Object.defineProperty(QW,"__esModule",{value:!0});QW.VariantManagementTypeObjectPage=void 0;var k$t;(function(e){e.None="None",e.Control="Control"})(k$t||(QW.VariantManagementTypeObjectPage=k$t={}))});var F$t=y(eX=>{"use strict";Object.defineProperty(eX,"__esModule",{value:!0});eX.VariantManagementTypeListReport=void 0;var M$t;(function(e){e.None="None",e.Control="Control",e.Page="Page"})(M$t||(eX.VariantManagementTypeListReport=M$t={}))});var q$t=y(j$t=>{"use strict";Object.defineProperty(j$t,"__esModule",{value:!0})});var V$t=y(dv=>{"use strict";var HNn=dv&&dv.__createBinding||(Object.create?function(e,t,r,n){n===void 0&&(n=r);var i=Object.getOwnPropertyDescriptor(t,r);(!i||("get"in i?!t.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,i)}:function(e,t,r,n){n===void 0&&(n=r),e[n]=t[r]}),CCe=dv&&dv.__exportStar||function(e,t){for(var r in e)r!=="default"&&!Object.prototype.hasOwnProperty.call(t,r)&&HNn(t,e,r)};Object.defineProperty(dv,"__esModule",{value:!0});CCe($$t(),dv);CCe(F$t(),dv);CCe(q$t(),dv)});var B$t=y(U$t=>{"use strict";Object.defineProperty(U$t,"__esModule",{value:!0})});var H$t=y(z$t=>{"use strict";Object.defineProperty(z$t,"__esModule",{value:!0})});var G$t=y(If=>{"use strict";var GNn=If&&If.__createBinding||(Object.create?function(e,t,r,n){n===void 0&&(n=r);var i=Object.getOwnPropertyDescriptor(t,r);(!i||("get"in i?!t.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,i)}:function(e,t,r,n){n===void 0&&(n=r),e[n]=t[r]}),fD=If&&If.__exportStar||function(e,t){for(var r in e)r!=="default"&&!Object.prototype.hasOwnProperty.call(t,r)&&GNn(t,e,r)};Object.defineProperty(If,"__esModule",{value:!0});fD(T$t(),If);fD(I$t(),If);fD(L$t(),If);fD(V$t(),If);fD(B$t(),If);fD(H$t(),If)});var xc=y(_c=>{"use strict";var K$t=_c&&_c.__createBinding||(Object.create?function(e,t,r,n){n===void 0&&(n=r);var i=Object.getOwnPropertyDescriptor(t,r);(!i||("get"in i?!t.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,i)}:function(e,t,r,n){n===void 0&&(n=r),e[n]=t[r]}),KNn=_c&&_c.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e.default=t}),Y$t=_c&&_c.__exportStar||function(e,t){for(var r in e)r!=="default"&&!Object.prototype.hasOwnProperty.call(t,r)&&K$t(t,e,r)},W$t=_c&&_c.__importStar||function(){var e=function(t){return e=Object.getOwnPropertyNames||function(r){var n=[];for(var i in r)Object.prototype.hasOwnProperty.call(r,i)&&(n[n.length]=i);return n},e(t)};return function(t){if(t&&t.__esModule)return t;var r={};if(t!=null)for(var n=e(t),i=0;i<n.length;i++)n[i]!=="default"&&K$t(r,t,n[i]);return KNn(r,t),r}}();Object.defineProperty(_c,"__esModule",{value:!0});_c.v4=_c.v2=void 0;Y$t(lLt(),_c);Y$t(gLt(),_c);_c.v2=W$t(Vkt());_c.v4=W$t(G$t())});var NX=y(Bm=>{"use strict";Object.defineProperty(Bm,"__esModule",{value:!0});Bm.TermApplicability=Bm.CDS_VOCABULARY_ALIAS=Bm.CDS_VOCABULARY_NAMESPACE=Bm.ENUM_VALUE_KIND=void 0;Bm.ENUM_VALUE_KIND="Member";Bm.CDS_VOCABULARY_NAMESPACE="com.sap.vocabularies.CDS.v1";Bm.CDS_VOCABULARY_ALIAS="CDS";var Q2t;(function(e){e[e.Applicable=0]="Applicable",e[e.TermNotApplicable=1]="TermNotApplicable",e[e.TypeNotApplicable=2]="TypeNotApplicable",e[e.UnknownTerm=3]="UnknownTerm",e[e.UnknownVocabulary=4]="UnknownVocabulary",e[e.UnSupportedVocabulary=5]="UnSupportedVocabulary",e[e.NotInApplicableTermsConstraint=6]="NotInApplicableTermsConstraint"})(Q2t||(Bm.TermApplicability=Q2t={}))});var tMt=y(mn=>{"use strict";Object.defineProperty(mn,"__esModule",{value:!0});mn.GHOST_FILENAME_PREFIX=mn.ANNOTATION_FILE_TYPE=mn.TARGET_TYPE=mn.NAMESPACE_TYPE=mn.REFERENCE_TYPE=mn.EDM_NAMESPACE_ALIAS=mn.EDMX_NAMESPACE_ALIAS=mn.ELEMENT_TYPE=mn.MultilineType=mn.TEXT_TYPE=mn.ATTRIBUTE_TYPE=void 0;mn.createAttributeNode=$In;mn.createTextNode=MIn;mn.createElementNode=FIn;mn.createTarget=jIn;mn.createNamespace=qIn;mn.createReference=VIn;mn.ATTRIBUTE_TYPE="attribute";mn.TEXT_TYPE="text";var eMt;(function(e){e.StripIndentation="StripIndentation",e.KeepIndentation="KeepIndentation"})(eMt||(mn.MultilineType=eMt={}));mn.ELEMENT_TYPE="element";mn.EDMX_NAMESPACE_ALIAS="Edmx";mn.EDM_NAMESPACE_ALIAS="Edm";mn.REFERENCE_TYPE="reference";mn.NAMESPACE_TYPE="namespace";mn.TARGET_TYPE="target";mn.ANNOTATION_FILE_TYPE="annotation-file";function $In(e,t,r,n){let i={type:mn.ATTRIBUTE_TYPE,name:e,value:t};return r&&(i.nameRange=r),n&&(i.valueRange=n),i}function MIn(e,t,r,n){let i={type:mn.TEXT_TYPE,text:e};return t&&(i.range=t),r&&(i.fragmentRanges=r),n&&(i.multilineType=n),i}function FIn({name:e,range:t,nameRange:r,attributes:n,content:i,contentRange:a,namespace:o,namespaceAlias:s}){let c={type:mn.ELEMENT_TYPE,name:e,attributes:n??{},content:i??[]};return t&&(c.range=t),r&&(c.nameRange=r),a&&(c.contentRange=a),o&&(c.namespace=o),s&&(c.namespaceAlias=s),c}mn.GHOST_FILENAME_PREFIX="!";function jIn(e){return{type:"target",name:e,terms:[],range:void 0,nameRange:void 0,termsRange:void 0}}function qIn(e,t,r){let{aliasRange:n,contentRange:i,nameRange:a,range:o}=r??{};return{type:"namespace",name:e,alias:t,range:o,nameRange:a,aliasRange:n,contentRange:i}}function VIn(e,t,r,n){let{aliasRange:i,uriRange:a,nameRange:o,range:s}=n??{};return{type:"reference",name:e,alias:t,uri:r,range:s,nameRange:o,aliasRange:i,uriRange:a}}});var rMt=y($r=>{"use strict";Object.defineProperty($r,"__esModule",{value:!0});$r.cacheKeyAnyTermName=$r.COLLECTION_KIND=$r.ASSOCIATION_SET_KIND=$r.FUNCTION_IMPORT_KIND=$r.ACTION_IMPORT_KIND=$r.SINGLETON_KIND=$r.ENTITY_SET_KIND=$r.NAVIGATION_PROPERTY_KIND=$r.PROPERTY_KIND=$r.ENTITY_CONTAINER_KIND=$r.ASSOCIATION_KIND=$r.FUNCTION_KIND=$r.ACTION_KIND=$r.ENTITY_TYPE_KIND=$r.TERM_KIND=$r.COMPLEX_TYPE_KIND=$r.ENUM_TYPE_KIND=$r.TYPE_DEFINITION_KIND=void 0;$r.TYPE_DEFINITION_KIND="TypeDefinition";$r.ENUM_TYPE_KIND="EnumType";$r.COMPLEX_TYPE_KIND="ComplexType";$r.TERM_KIND="Term";$r.ENTITY_TYPE_KIND="EntityType";$r.ACTION_KIND="Action";$r.FUNCTION_KIND="Function";$r.ASSOCIATION_KIND="Association";$r.ENTITY_CONTAINER_KIND="EntityContainer";$r.PROPERTY_KIND="Property";$r.NAVIGATION_PROPERTY_KIND="NavigationProperty";$r.ENTITY_SET_KIND="EntitySet";$r.SINGLETON_KIND="Singleton";$r.ACTION_IMPORT_KIND="ActionImport";$r.FUNCTION_IMPORT_KIND="FunctionImport";$r.ASSOCIATION_SET_KIND="AssociationSet";$r.COLLECTION_KIND="Collection";$r.cacheKeyAnyTermName="Impl.AnyTerm"});var aMt=y(xD=>{"use strict";Object.defineProperty(xD,"__esModule",{value:!0});xD.EdmType=xD.Edm=void 0;var nMt;(function(e){e.Action="Action",e.ActionImport="ActionImport",e.Add="Add",e.Alias="Alias",e.And="And",e.Annotation="Annotation",e.Annotations="Annotations",e.AnnotationPath="AnnotationPath",e.Association="Association",e.AssociationSet="AssociationSet",e.Apply="Apply",e.Binary="Binary",e.Bool="Bool",e.Cast="Cast",e.Collection="Collection",e.ComplexType="ComplexType",e.Date="Date",e.DateTimeOffset="DateTimeOffset",e.Decimal="Decimal",e.DefaultValue="DefaultValue",e.Div="Div",e.Duration="Duration",e.EntityContainer="EntityContainer",e.EntitySet="EntitySet",e.EntityType="EntityType",e.EnumMember="EnumMember",e.EnumType="EnumType",e.Eq="Eq",e.Float="Float",e.Function="Function",e.FunctionImport="FunctionImport",e.Ge="Ge",e.Gt="Gt",e.Guid="Guid",e.If="If",e.In="In",e.Include="Include",e.Int="Int",e.IsOf="IsOf",e.LabeledElement="LabeledElement",e.Le="Le",e.Lt="Lt",e.MaxLength="MaxLength",e.Member="Member",e.ModelElementPath="ModelElementPath",e.Mul="Mul",e.Name="Name",e.Namespace="Namespace",e.NavigationProperty="NavigationProperty",e.NavigationPropertyPath="NavigationPropertyPath",e.Ne="Ne",e.Neg="Neg",e.Not="Not",e.Null="Null",e.Nullable="Nullable",e.OnDelete="OnDelete",e.Parameter="Parameter",e.Path="Path",e.Precision="Precision",e.Property="Property",e.PropertyPath="PropertyPath",e.PropertyValue="PropertyValue",e.Or="Or",e.Qualifier="Qualifier",e.Record="Record",e.Reference="Reference",e.ReferentialConstraint="ReferentialConstraint",e.ReferencedProperty="ReferencedProperty",e.ReturnType="ReturnType",e.Scale="Scale",e.Schema="Schema",e.Singleton="Singleton",e.SRID="SRID",e.String="String",e.Sub="Sub",e.Target="Target",e.Term="Term",e.TimeOfDay="TimeOfDay",e.Type="Type",e.TypeDefinition="TypeDefinition",e.Unicode="Unicode",e.UrlRef="UrlRef"})(nMt||(xD.Edm=nMt={}));var iMt;(function(e){e.Binary="Edm.Binary",e.Boolean="Edm.Boolean",e.Byte="Edm.Byte",e.Date="Edm.Date",e.DateTimeOffset="Edm.DateTimeOffset",e.Decimal="Edm.Decimal",e.Double="Edm.Double",e.Duration="Edm.Duration",e.Guid="Edm.Guid",e.Int16="Edm.Int16",e.Int32="Edm.Int32",e.Int64="Edm.Int64",e.SByte="Edm.SByte",e.Single="Edm.Single",e.Stream="Edm.Stream",e.String="Edm.String",e.TimeOfDay="Edm.TimeOfDay",e.PrimitiveType="Edm.PrimitiveType",e.ComplexType="Edm.ComplexType",e.EntityType="Edm.EntityType",e.Untyped="Edm.Untyped",e.EntityTypeCollection="Edm.EntityTypeCollection",e.NonEntityTypeCollection="Edm.NonEntityTypeCollection",e.AnnotationPath="Edm.AnnotationPath",e.AnyPropertyPath="Edm.AnyPropertyPath",e.ModelElementPath="Edm.ModelElementPath",e.NavigationPropertyPath="Edm.NavigationPropertyPath",e.PropertyPath="Edm.PropertyPath",e.VirtualProperty="Edm.VirtualProperty",e.PrimitiveCollection="Edm.PrimitiveCollection",e.DataModelEnum="Edm.DataModelEnum"})(iMt||(xD.EdmType=iMt={}))});var uMt=y($f=>{"use strict";Object.defineProperty($f,"__esModule",{value:!0});$f.EDMX_ELEMENT_NAMES=$f.EdmxIncludeElementAttributeName=$f.EdmxReferenceElementAttributeName=$f.EdmxElementName=$f.Edmx=void 0;var oMt;(function(e){e.Alias="Alias",e.DataServices="DataServices",e.Edmx="Edmx",e.Import="Import",e.Include="Include",e.Namespace="Namespace",e.Reference="Reference",e.Uri="Uri",e.Version="Version"})(oMt||($f.Edmx=oMt={}));var $O;(function(e){e.DataServices="DataServices",e.Edmx="Edmx",e.Include="Include",e.IncludeAnnotations="IncludeAnnotations",e.Reference="Reference"})($O||($f.EdmxElementName=$O={}));var sMt;(function(e){e.Uri="Uri"})(sMt||($f.EdmxReferenceElementAttributeName=sMt={}));var cMt;(function(e){e.Alias="Alias",e.Namespace="Namespace"})(cMt||($f.EdmxIncludeElementAttributeName=cMt={}));$f.EDMX_ELEMENT_NAMES=new Set([$O.DataServices,$O.Edmx,$O.Include,$O.IncludeAnnotations,$O.Reference])});var lMt=y(TD=>{"use strict";Object.defineProperty(TD,"__esModule",{value:!0});TD.printOptions=TD.wrapInQuotes=void 0;var UIn=e=>`'${e}'`;TD.wrapInQuotes=UIn;TD.printOptions={printWidth:300,tabWidth:4,useTabs:!1,useSnippetSyntax:!0}});var fMt=y(pMt=>{"use strict";Object.defineProperty(pMt,"__esModule",{value:!0})});var dMt=y(gt=>{"use strict";Object.defineProperty(gt,"__esModule",{value:!0});gt.DEPRECATED_$VALUE_SYNTAX=gt.INVALID_PRIMITIVE_TYPE=gt.ODATA_PATH_SEPARATOR_RULE=gt.COMMON_CASE_ISSUE=gt.INCOMPLETE_PATH_WITH_COMPATIBLE_TYPES=gt.INCOMPLETE_PATH_WITH_TYPE=gt.NO_VALIDATION_FOR_SUBNODES=gt.INVALID_TYPE_TYPE=gt.INVALID_ENUM_MEMBER_TYPE=gt.INVALID_PATH_EXPRESSION=gt.IGNORE_DUPLICATE=gt.ODATA_FUNCTION_WRONG_RETURN_TYPE=gt.RECORD_COLLECTION_PATH_NOT_ALLOWED=gt.NOT_IN_APPLICABLE_TERMS_CONSTRAINT=gt.TERM_NOT_APPLICABLE=gt.MISSING_REQUIRED_VALUE_FOR_ATTRIBUTE=gt.MISSING_REQUIRED_ATTRIBUTE=gt.MISSING_REQUIRED_PROPERTY=gt.ATTRIBUTE_NOT_ALLOWED_HERE=gt.UN_SUPPORTED_VOCABULARY=gt.UNKNOWN_TERM=gt.IGNORE_TARGET_VALIDATION=gt.INCOMPLETE_EXPRESSION_FORWARD_SLASH=gt.INCOMPLETE_EXPRESSION_CC_FORWARD_SLASH=gt.NO_WHITESPACE_IN_PATH_EXPRESSION=gt.VALUE_REQUIRED=gt.MISSING_I18N_KEY=gt.NAME_CASE_ISSUE_PATH_VALUE=gt.NO_UNDEFINED_NAMESPACE_TYPE=gt.NO_UNUSED_NAMESPACE_TYPE=void 0;gt.NO_UNUSED_NAMESPACE_TYPE="no-unused-namespace";gt.NO_UNDEFINED_NAMESPACE_TYPE="no-undefined-namespace";gt.NAME_CASE_ISSUE_PATH_VALUE="name-case-issue-path-value";gt.MISSING_I18N_KEY="missing-i18n-key";gt.VALUE_REQUIRED="value-required";gt.NO_WHITESPACE_IN_PATH_EXPRESSION="no-whitespace-in-path-expression";gt.INCOMPLETE_EXPRESSION_CC_FORWARD_SLASH="incomplete-expression-cc-forward-slash";gt.INCOMPLETE_EXPRESSION_FORWARD_SLASH="incomplete-expression-forward-slash";gt.IGNORE_TARGET_VALIDATION="ignore-target-validation";gt.UNKNOWN_TERM="unknown-term";gt.UN_SUPPORTED_VOCABULARY="un-supported-vocabulary";gt.ATTRIBUTE_NOT_ALLOWED_HERE="attribute-not-allowed-here";gt.MISSING_REQUIRED_PROPERTY="missing-required-property";gt.MISSING_REQUIRED_ATTRIBUTE="missing-required-attribute";gt.MISSING_REQUIRED_VALUE_FOR_ATTRIBUTE="missing-required-value-for-attribute";gt.TERM_NOT_APPLICABLE="term-not-applicable";gt.NOT_IN_APPLICABLE_TERMS_CONSTRAINT="not-in-applicable-terms-constraint";gt.RECORD_COLLECTION_PATH_NOT_ALLOWED="record-collection-path-not-allowed";gt.ODATA_FUNCTION_WRONG_RETURN_TYPE="odata-function-wrong-return-type";gt.IGNORE_DUPLICATE="ignore-duplicate";gt.INVALID_PATH_EXPRESSION="invlid-path-expression";gt.INVALID_ENUM_MEMBER_TYPE="unknown-enum-member";gt.INVALID_TYPE_TYPE="invalid-type";gt.NO_VALIDATION_FOR_SUBNODES="no-validation-subnodes";gt.INCOMPLETE_PATH_WITH_TYPE="incomplete-path-with-type";gt.INCOMPLETE_PATH_WITH_COMPATIBLE_TYPES="incomplete-path-with-compatible-types";gt.COMMON_CASE_ISSUE="common-case-issue";gt.ODATA_PATH_SEPARATOR_RULE="no-odata-path-separator";gt.INVALID_PRIMITIVE_TYPE="invalid-primitive-type";gt.DEPRECATED_$VALUE_SYNTAX="deprecated-$value-syntax"});var mMt=y(hMt=>{"use strict";Object.defineProperty(hMt,"__esModule",{value:!0})});var gMt=y(MO=>{"use strict";var BIn=MO&&MO.__createBinding||(Object.create?function(e,t,r,n){n===void 0&&(n=r);var i=Object.getOwnPropertyDescriptor(t,r);(!i||("get"in i?!t.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,i)}:function(e,t,r,n){n===void 0&&(n=r),e[n]=t[r]}),zIn=MO&&MO.__exportStar||function(e,t){for(var r in e)r!=="default"&&!Object.prototype.hasOwnProperty.call(t,r)&&BIn(t,e,r)};Object.defineProperty(MO,"__esModule",{value:!0});zIn(mMt(),MO)});var yMt=y(ts=>{"use strict";Object.defineProperty(ts,"__esModule",{value:!0});ts.WorkspaceEdit=ts.TextEdit=ts.DiagnosticSeverity=ts.DiagnosticTag=ts.Diagnostic=ts.Position=ts.Range=ts.Location=void 0;var IE=lc();Object.defineProperty(ts,"Location",{enumerable:!0,get:function(){return IE.Location}});Object.defineProperty(ts,"Range",{enumerable:!0,get:function(){return IE.Range}});Object.defineProperty(ts,"Position",{enumerable:!0,get:function(){return IE.Position}});Object.defineProperty(ts,"Diagnostic",{enumerable:!0,get:function(){return IE.Diagnostic}});Object.defineProperty(ts,"DiagnosticTag",{enumerable:!0,get:function(){return IE.DiagnosticTag}});Object.defineProperty(ts,"DiagnosticSeverity",{enumerable:!0,get:function(){return IE.DiagnosticSeverity}});Object.defineProperty(ts,"TextEdit",{enumerable:!0,get:function(){return IE.TextEdit}});Object.defineProperty(ts,"WorkspaceEdit",{enumerable:!0,get:function(){return IE.WorkspaceEdit}})});var Ht=y($n=>{"use strict";var HIn=$n&&$n.__createBinding||(Object.create?function(e,t,r,n){n===void 0&&(n=r);var i=Object.getOwnPropertyDescriptor(t,r);(!i||("get"in i?!t.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,i)}:function(e,t,r,n){n===void 0&&(n=r),e[n]=t[r]}),RE=$n&&$n.__exportStar||function(e,t){for(var r in e)r!=="default"&&!Object.prototype.hasOwnProperty.call(t,r)&&HIn(t,e,r)};Object.defineProperty($n,"__esModule",{value:!0});$n.WorkspaceEdit=$n.TextEdit=$n.DiagnosticTag=$n.DiagnosticSeverity=$n.Diagnostic=$n.Position=$n.Range=$n.Location=void 0;RE(tMt(),$n);RE(rMt(),$n);RE(aMt(),$n);RE(uMt(),$n);RE(lMt(),$n);RE(fMt(),$n);RE(dMt(),$n);RE(gMt(),$n);var LE=yMt();Object.defineProperty($n,"Location",{enumerable:!0,get:function(){return LE.Location}});Object.defineProperty($n,"Range",{enumerable:!0,get:function(){return LE.Range}});Object.defineProperty($n,"Position",{enumerable:!0,get:function(){return LE.Position}});Object.defineProperty($n,"Diagnostic",{enumerable:!0,get:function(){return LE.Diagnostic}});Object.defineProperty($n,"DiagnosticSeverity",{enumerable:!0,get:function(){return LE.DiagnosticSeverity}});Object.defineProperty($n,"DiagnosticTag",{enumerable:!0,get:function(){return LE.DiagnosticTag}});Object.defineProperty($n,"TextEdit",{enumerable:!0,get:function(){return LE.TextEdit}});Object.defineProperty($n,"WorkspaceEdit",{enumerable:!0,get:function(){return LE.WorkspaceEdit}})});var vMt=y(nwe=>{"use strict";Object.defineProperty(nwe,"__esModule",{value:!0});nwe.default={$Version:"4.01",$Reference:{"https://oasis-tcs.github.io/odata-vocabularies/vocabularies/Org.OData.Core.V1.json":{$Include:[{$Namespace:"Org.OData.Core.V1",$Alias:"Core"}]},"https://oasis-tcs.github.io/odata-vocabularies/vocabularies/Org.OData.Validation.V1.json":{$Include:[{$Namespace:"Org.OData.Validation.V1",$Alias:"Validation"}]},"https://oasis-tcs.github.io/odata-vocabularies/vocabularies/Org.OData.Capabilities.V1.json":{$Include:[{$Namespace:"Org.OData.Capabilities.V1",$Alias:"Capabilities"}]}},"Org.OData.Aggregation.V1":{$Alias:"Aggregation","@Org.OData.Core.V1.Description":"Terms to describe which data in a given entity model can be aggregated, and how.","@Org.OData.Core.V1.LongDescription":"Related to the specification document [OData-Data-Agg-v4.0](http://docs.oasis-open.org/odata/odata-data-aggregation-ext/v4.0/odata-data-aggregation-ext-v4.0.html).","@Org.OData.Core.V1.Links":[{rel:"alternate",href:"https://oasis-tcs.github.io/odata-vocabularies/vocabularies/Org.OData.Aggregation.V1.xml"},{rel:"latest-version",href:"https://oasis-tcs.github.io/odata-vocabularies/vocabularies/Org.OData.Aggregation.V1.json"},{rel:"describedby",href:"https://github.com/oasis-tcs/odata-vocabularies/blob/main/vocabularies/Org.OData.Aggregation.V1.md"}],ApplySupported:{$Kind:"Term",$Type:"Org.OData.Aggregation.V1.ApplySupportedType",$AppliesTo:["EntitySet","Collection","EntityType"],"@Org.OData.Core.V1.AppliesViaContainer":!0,"@Org.OData.Core.V1.Description":"This entity set or collection supports the `$apply` system query option"},ApplySupportedDefaults:{$Kind:"Term",$Type:"Org.OData.Aggregation.V1.ApplySupportedBase",$AppliesTo:["EntityContainer"],"@Org.OData.Core.V1.Description":"Default support of the `$apply` system query option for all collection-valued resources in the container","@Org.OData.Core.V1.LongDescription":"Annotating term [`ApplySupported`](#ApplySupported) for a specific collection-valued resource overrides the default support with the specified properties using PATCH semantics:\n- Primitive or collection-valued properties specified in `ApplySupported` replace the corresponding properties specified in `ApplySupportedDefaults`\n- Complex-valued properties specified in `ApplySupported` override the corresponding properties specified in `ApplySupportedDefaults` using PATCH semantics recursively\n- Properties specified neither in `ApplySupported` nor in `ApplySupportedDefaults` have their default value"},ApplySupportedBase:{$Kind:"ComplexType","@Org.OData.Core.V1.LongDescription":"Services that do not fully implement a certain aggregation-related functionality may document\n this by annotating the [`ApplySupported`](#ApplySupported) or [`ApplySupportedDefaults`](#ApplySupportedDefaults)\n annotation with a description.",Transformations:{$Collection:!0,$Type:"Org.OData.Aggregation.V1.Transformation","@Org.OData.Core.V1.Description":"Transformations that can be used in `$apply`"},CustomAggregationMethods:{$Collection:!0,"@Org.OData.Core.V1.Description":"Qualified names of custom aggregation methods that can be used in `aggregate(...with...)`"},Rollup:{$Type:"Org.OData.Aggregation.V1.RollupType",$DefaultValue:"None","@Org.OData.Core.V1.Description":"The service supports rollup hierarchies in a `groupby` transformation"},From:{$Type:"Edm.Boolean",$DefaultValue:!1,"@Org.OData.Core.V1.Description":"The service supports the `from` keyword in an `aggregate` transformation"}},ApplySupportedType:{$Kind:"ComplexType",$BaseType:"Org.OData.Aggregation.V1.ApplySupportedBase",PropertyRestrictions:{$Type:"Edm.Boolean",$DefaultValue:!1,"@Org.OData.Core.V1.Revisions":[{Kind:"Deprecated",Description:"Deprecated since [`Groupable`](#Groupable) and [`Aggregatable`](#Aggregatable) are deprecated"}],"@Org.OData.Core.V1.Description":"Only properties marked as `Groupable` can be used in the `groupby` transformation, and only those marked as `Aggregatable` can be used in the `aggregate` transformation"},GroupableProperties:{$Collection:!0,$Type:"Edm.AnyPropertyPath","@Org.OData.Core.V1.Description":"A non-empty collection indicates that only the listed properties of the annotated target are supported by the `groupby` transformation"},AggregatableProperties:{$Collection:!0,$Type:"Org.OData.Aggregation.V1.AggregatablePropertyType","@Org.OData.Core.V1.Description":"A non-empty collection indicates that only the listed properties of the annotated target can be used in the `aggregate` transformation, optionally restricted to the specified aggregation methods"}},AggregatablePropertyType:{$Kind:"ComplexType",Property:{$Type:"Edm.PropertyPath","@Org.OData.Core.V1.Description":"Aggregatable property"},SupportedAggregationMethods:{$Collection:!0,$Type:"Org.OData.Aggregation.V1.AggregationMethod","@Org.OData.Core.V1.Description":"Standard and custom aggregation methods that can be applied to the property. If omitted, all aggregation methods can be applied"},RecommendedAggregationMethod:{$Type:"Org.OData.Aggregation.V1.AggregationMethod",$Nullable:!0,"@Org.OData.Core.V1.Description":"Recommended method for aggregating values of the property"}},Transformation:{$Kind:"TypeDefinition",$UnderlyingType:"Edm.String","@Org.OData.Core.V1.Description":"A transformation that can be used in `$apply`","@Org.OData.Validation.V1.AllowedValues":[{Value:"aggregate","@Org.OData.Core.V1.Description":"OData-Data-Agg-v4.0, section 3.2.1"},{Value:"groupby","@Org.OData.Core.V1.Description":"OData-Data-Agg-v4.0, section 3.2.3"},{Value:"concat","@Org.OData.Core.V1.Description":"OData-Data-Agg-v4.0, section 3.2.2"},{Value:"identity","@Org.OData.Core.V1.Description":"OData-Data-Agg-v4.0, section 3.4.1"},{Value:"filter","@Org.OData.Core.V1.Description":"OData-Data-Agg-v4.0, section 3.3.2"},{Value:"search","@Org.OData.Core.V1.Description":"OData-Data-Agg-v4.0, section 3.3.4"},{Value:"nest","@Org.OData.Core.V1.Description":"OData-Data-Agg-v4.0, section 3.5.2"},{Value:"addnested","@Org.OData.Core.V1.Description":"OData-Data-Agg-v4.0, section 3.4.3"},{Value:"join","@Org.OData.Core.V1.Description":"OData-Data-Agg-v4.0, section 3.5.1"},{Value:"outerjoin","@Org.OData.Core.V1.Description":"OData-Data-Agg-v4.0, section 3.5.1"},{Value:"compute","@Org.OData.Core.V1.Description":"OData-Data-Agg-v4.0, section 3.4.2"},{Value:"bottomcount","@Org.OData.Core.V1.Description":"OData-Data-Agg-v4.0, section 3.3.1.1"},{Value:"bottomsum","@Org.OData.Core.V1.Description":"OData-Data-Agg-v4.0, section 3.3.1.3"},{Value:"bottompercent","@Org.OData.Core.V1.Description":"OData-Data-Agg-v4.0, section 3.3.1.2"},{Value:"topcount","@Org.OData.Core.V1.Description":"OData-Data-Agg-v4.0, section 3.3.1.1"},{Value:"topsum","@Org.OData.Core.V1.Description":"OData-Data-Agg-v4.0, section 3.3.1.3"},{Value:"toppercent","@Org.OData.Core.V1.Description":"OData-Data-Agg-v4.0, section 3.3.1.2"},{Value:"orderby","@Org.OData.Core.V1.Description":"OData-Data-Agg-v4.0, section 3.3.3"},{Value:"top","@Org.OData.Core.V1.Description":"OData-Data-Agg-v4.0, section 3.3.6"},{Value:"skip","@Org.OData.Core.V1.Description":"OData-Data-Agg-v4.0, section 3.3.5"},{Value:"ancestors","@Org.OData.Core.V1.Description":"OData-Data-Agg-v4.0, section 6.2.1"},{Value:"descendants","@Org.OData.Core.V1.Description":"OData-Data-Agg-v4.0, section 6.2.1"},{Value:"traverse","@Org.OData.Core.V1.Description":"OData-Data-Agg-v4.0, section 6.2.2"}]},AggregationMethod:{$Kind:"TypeDefinition",$UnderlyingType:"Edm.String","@Org.OData.Core.V1.Description":"Standard or custom aggregation method","@Org.OData.Core.V1.LongDescription":"Custom aggregation methods MUST use a namespace-qualified name, that is contain at least one dot. ","@Org.OData.Validation.V1.AllowedValues":[{Value:"sum","@Org.OData.Core.V1.Description":"Can be applied to numeric values to return the sum of the non-null values, or null if there are no non-null values or the input set is empty"},{Value:"min","@Org.OData.Core.V1.Description":"Can be applied to values with a totally ordered domain to return the smallest of the non-null values, or null if there are no non-null values or the input set is empty"},{Value:"max","@Org.OData.Core.V1.Description":"Can be applied to values with a totally ordered domain to return the largest of the non-null values, or null if there are no non-null values or the input set is empty"},{Value:"average","@Org.OData.Core.V1.Description":"Can be applied to numeric values to return the sum of the non-null values divided by the count of the non-null values, or null if there are no non-null values or the input set is empty"},{Value:"countdistinct","@Org.OData.Core.V1.Description":"Counts the distinct values, omitting any null values","@Org.OData.Core.V1.LongDescription":`For navigation properties, it counts the distinct entities in the union of all entities related to entities in the input set.
|
|
427
|
+
`);for(var t=0;e[t]&&e[t].trim().match(/^(#|$)/);t++);for(var r=e.length,n=t+1;n<r&&e[n].trim();n++);return e.slice(t,n).join(" ").trim()}}});var GIt=y((D4i,QDn)=>{QDn.exports={topLevel:{dependancies:"dependencies",dependecies:"dependencies",depdenencies:"dependencies",devEependencies:"devDependencies",depends:"dependencies","dev-dependencies":"devDependencies",devDependences:"devDependencies",devDepenencies:"devDependencies",devdependencies:"devDependencies",repostitory:"repository",repo:"repository",prefereGlobal:"preferGlobal",hompage:"homepage",hampage:"homepage",autohr:"author",autor:"author",contributers:"contributors",publicationConfig:"publishConfig",script:"scripts"},bugs:{web:"url",name:"url"},script:{server:"start",tests:"test"}}});var XIt=y((I4i,WIt)=>{var KIt=DW(),eNn=uIt(),kW=yIt(),tNn=oCe().isCore,rNn=["dependencies","devDependencies","optionalDependencies"],nNn=HIt(),sCe=require("url"),OE=GIt(),N4i=WIt.exports={warn:function(){},fixRepositoryField:function(e){if(e.repositories&&(this.warn("repositories"),e.repository=e.repositories[0]),!e.repository)return this.warn("missingRepository");typeof e.repository=="string"&&(e.repository={type:"git",url:e.repository});var t=e.repository.url||"";if(t){var r=kW.fromUrl(t);r&&(t=e.repository.url=r.getDefaultRepresentation()=="shortcut"?r.https():r.toString())}t.match(/github.com\/[^\/]+\/[^\/]+\.git\.git$/)&&this.warn("brokenGitUrl",t)},fixTypos:function(e){Object.keys(OE.topLevel).forEach(function(t){e.hasOwnProperty(t)&&this.warn("typo",t,OE.topLevel[t])},this)},fixScriptsField:function(e){if(e.scripts){if(typeof e.scripts!="object"){this.warn("nonObjectScripts"),delete e.scripts;return}Object.keys(e.scripts).forEach(function(t){typeof e.scripts[t]!="string"?(this.warn("nonStringScript"),delete e.scripts[t]):OE.script[t]&&!e.scripts[OE.script[t]]&&this.warn("typo",t,OE.script[t],"scripts")},this)}},fixFilesField:function(e){var t=e.files;t&&!Array.isArray(t)?(this.warn("nonArrayFiles"),delete e.files):e.files&&(e.files=e.files.filter(function(r){return!r||typeof r!="string"?(this.warn("invalidFilename",r),!1):!0},this))},fixBinField:function(e){if(e.bin&&typeof e.bin=="string"){var t={},r;(r=e.name.match(/^@[^/]+[/](.*)$/))?t[r[1]]=e.bin:t[e.name]=e.bin,e.bin=t}},fixManField:function(e){e.man&&typeof e.man=="string"&&(e.man=[e.man])},fixBundleDependenciesField:function(e){var t="bundledDependencies",r="bundleDependencies";e[t]&&!e[r]&&(e[r]=e[t],delete e[t]),e[r]&&!Array.isArray(e[r])?(this.warn("nonArrayBundleDependencies"),delete e[r]):e[r]&&(e[r]=e[r].filter(function(n){return!n||typeof n!="string"?(this.warn("nonStringBundleDependency",n),!1):(e.dependencies||(e.dependencies={}),e.dependencies.hasOwnProperty(n)||(this.warn("nonDependencyBundleDependency",n),e.dependencies[n]="*"),!0)},this))},fixDependencies:function(e,t){var r=!t;pNn(e,this.warn),uNn(e,this.warn),this.fixBundleDependenciesField(e),["dependencies","devDependencies"].forEach(function(n){if(n in e){if(!e[n]||typeof e[n]!="object"){this.warn("nonObjectDependencies",n),delete e[n];return}Object.keys(e[n]).forEach(function(i){var a=e[n][i];typeof a!="string"&&(this.warn("nonStringDependency",i,JSON.stringify(a)),delete e[n][i]);var o=kW.fromUrl(e[n][i]);o&&(e[n][i]=o.toString())},this)}},this)},fixModulesField:function(e){e.modules&&(this.warn("deprecatedModules"),delete e.modules)},fixKeywordsField:function(e){typeof e.keywords=="string"&&(e.keywords=e.keywords.split(/,\s+/)),e.keywords&&!Array.isArray(e.keywords)?(delete e.keywords,this.warn("nonArrayKeywords")):e.keywords&&(e.keywords=e.keywords.filter(function(t){return typeof t!="string"||!t?(this.warn("nonStringKeyword"),!1):!0},this))},fixVersionField:function(e,t){var r=!t;if(!e.version)return e.version="",!0;if(!KIt.valid(e.version,r))throw new Error('Invalid version: "'+e.version+'"');return e.version=KIt.clean(e.version,r),!0},fixPeople:function(e){YIt(e,sNn),YIt(e,cNn)},fixNameField:function(e,t){typeof t=="boolean"?t={strict:t}:typeof t>"u"&&(t={});var r=t.strict;if(!e.name&&!r){e.name="";return}if(typeof e.name!="string")throw new Error("name field must be a string.");r||(e.name=e.name.trim()),oNn(e.name,r,t.allowLegacyCase),tNn(e.name)&&this.warn("conflictingName",e.name)},fixDescriptionField:function(e){e.description&&typeof e.description!="string"&&(this.warn("nonStringDescription"),delete e.description),e.readme&&!e.description&&(e.description=nNn(e.readme)),e.description===void 0&&delete e.description,e.description||this.warn("missingDescription")},fixReadmeField:function(e){e.readme||(this.warn("missingReadme"),e.readme="ERROR: No README data found!")},fixBugsField:function(e){if(!e.bugs&&e.repository&&e.repository.url){var t=kW.fromUrl(e.repository.url);t&&t.bugs()&&(e.bugs={url:t.bugs()})}else if(e.bugs){var r=/^.+@.*\..+$/;if(typeof e.bugs=="string")r.test(e.bugs)?e.bugs={email:e.bugs}:sCe.parse(e.bugs).protocol?e.bugs={url:e.bugs}:this.warn("nonEmailUrlBugsString");else{fNn(e.bugs,this.warn);var n=e.bugs;e.bugs={},n.url&&(typeof n.url=="string"&&sCe.parse(n.url).protocol?e.bugs.url=n.url:this.warn("nonUrlBugsUrlField")),n.email&&(typeof n.email=="string"&&r.test(n.email)?e.bugs.email=n.email:this.warn("nonEmailBugsEmailField"))}!e.bugs.email&&!e.bugs.url&&(delete e.bugs,this.warn("emptyNormalizedBugs"))}},fixHomepageField:function(e){if(!e.homepage&&e.repository&&e.repository.url){var t=kW.fromUrl(e.repository.url);t&&t.docs()&&(e.homepage=t.docs())}if(e.homepage){if(typeof e.homepage!="string")return this.warn("nonUrlHomepage"),delete e.homepage;sCe.parse(e.homepage).protocol||(e.homepage="http://"+e.homepage)}},fixLicenseField:function(e){if(e.license)typeof e.license!="string"||e.license.length<1||e.license.trim()===""?this.warn("invalidLicense"):eNn(e.license).validForNewPackages||this.warn("invalidLicense");else return this.warn("missingLicense")}};function iNn(e){if(e.charAt(0)!=="@")return!1;var t=e.slice(1).split("/");return t.length!==2?!1:t[0]&&t[1]&&t[0]===encodeURIComponent(t[0])&&t[1]===encodeURIComponent(t[1])}function aNn(e){return!e.match(/[\/@\s\+%:]/)&&e===encodeURIComponent(e)}function oNn(e,t,r){if(e.charAt(0)==="."||!(iNn(e)||aNn(e))||t&&!r&&e!==e.toLowerCase()||e.toLowerCase()==="node_modules"||e.toLowerCase()==="favicon.ico")throw new Error("Invalid name: "+JSON.stringify(e))}function YIt(e,t){return e.author&&(e.author=t(e.author)),["maintainers","contributors"].forEach(function(r){Array.isArray(e[r])&&(e[r]=e[r].map(t))}),e}function sNn(e){if(typeof e=="string")return e;var t=e.name||"",r=e.url||e.web,n=r?" ("+r+")":"",i=e.email||e.mail,a=i?" <"+i+">":"";return t+a+n}function cNn(e){if(typeof e!="string")return e;var t=e.match(/^([^\(<]+)/),r=e.match(/\(([^\)]+)\)/),n=e.match(/<([^>]+)>/),i={};return t&&t[0].trim()&&(i.name=t[0].trim()),n&&(i.email=n[1]),r&&(i.url=r[1]),i}function uNn(e,t){var r=e.optionalDependencies;if(r){var n=e.dependencies||{};Object.keys(r).forEach(function(i){n[i]=r[i]}),e.dependencies=n}}function lNn(e,t,r){if(!e)return{};if(typeof e=="string"&&(e=e.trim().split(/[\n\r\s\t ,]+/)),!Array.isArray(e))return e;r("deprecatedArrayDependencies",t);var n={};return e.filter(function(i){return typeof i=="string"}).forEach(function(i){i=i.trim().split(/(:?[@\s><=])/);var a=i.shift(),o=i.join("");o=o.trim(),o=o.replace(/^@/,""),n[a]=o}),n}function pNn(e,t){rNn.forEach(function(r){e[r]&&(e[r]=lNn(e[r],r,t))})}function fNn(e,t){e&&Object.keys(e).forEach(function(r){OE.bugs[r]&&(t("typo",r,OE.bugs[r],"bugs"),e[OE.bugs[r]]=e[r],delete e[r])})}});var JIt=y((R4i,dNn)=>{dNn.exports={repositories:"'repositories' (plural) Not supported. Please pick one as the 'repository' field",missingRepository:"No repository field.",brokenGitUrl:"Probably broken git url: %s",nonObjectScripts:"scripts must be an object",nonStringScript:"script values must be string commands",nonArrayFiles:"Invalid 'files' member",invalidFilename:"Invalid filename in 'files' list: %s",nonArrayBundleDependencies:"Invalid 'bundleDependencies' list. Must be array of package names",nonStringBundleDependency:"Invalid bundleDependencies member: %s",nonDependencyBundleDependency:"Non-dependency in bundleDependencies: %s",nonObjectDependencies:"%s field must be an object",nonStringDependency:"Invalid dependency: %s %s",deprecatedArrayDependencies:"specifying %s as array is deprecated",deprecatedModules:"modules field is deprecated",nonArrayKeywords:"keywords should be an array of strings",nonStringKeyword:"keywords should be an array of strings",conflictingName:"%s is also the name of a node core module.",nonStringDescription:"'description' field should be a string",missingDescription:"No description",missingReadme:"No README data",missingLicense:"No license field.",nonEmailUrlBugsString:"Bug string field must be url, email, or {email,url}",nonUrlBugsUrlField:"bugs.url field must be a string url. Deleted.",nonEmailBugsEmailField:"bugs.email field must be a string email. Deleted.",emptyNormalizedBugs:"Normalized value of bugs field is an empty object. Deleted.",nonUrlHomepage:"homepage field must be a string url. Deleted.",invalidLicense:"license should be a valid SPDX license expression",typo:"%s should probably be %s."}});var eRt=y((L4i,QIt)=>{var ZIt=require("util"),cCe=JIt();QIt.exports=function(){var e=Array.prototype.slice.call(arguments,0),t=e.shift();if(t=="typo")return hNn.apply(null,e);var r=cCe[t]?cCe[t]:t+": '%s'";return e.unshift(r),ZIt.format.apply(null,e)};function hNn(e,t,r){return r&&(e=r+"['"+e+"']",t=r+"['"+t+"']"),ZIt.format(cCe.typo,e,t)}});var pCe=y((k4i,nRt)=>{nRt.exports=tRt;var uCe=XIt();tRt.fixer=uCe;var mNn=eRt(),gNn=["name","version","description","repository","modules","scripts","files","bin","man","bugs","keywords","readme","homepage","license"],yNn=["dependencies","people","typos"],lCe=gNn.map(function(e){return rRt(e)+"Field"});lCe=lCe.concat(yNn);function tRt(e,t,r){t===!0&&(t=null,r=!0),r||(r=!1),(!t||e.private)&&(t=function(n){}),e.scripts&&e.scripts.install==="node-gyp rebuild"&&!e.scripts.preinstall&&(e.gypfile=!0),uCe.warn=function(){t(mNn.apply(null,arguments))},lCe.forEach(function(n){uCe["fix"+rRt(n)](e,r)}),e._id=e.name+"@"+e.version}function rRt(e){return e.charAt(0).toUpperCase()+e.slice(1)}});var sRt=y(($4i,fCe)=>{"use strict";var{promisify:vNn}=require("util"),iRt=require("fs"),aRt=require("path"),oRt=wNt(),bNn=vNn(iRt.readFile);fCe.exports=async e=>{e={cwd:process.cwd(),normalize:!0,...e};let t=aRt.resolve(e.cwd,"package.json"),r=oRt(await bNn(t,"utf8"));return e.normalize&&pCe()(r),r};fCe.exports.sync=e=>{e={cwd:process.cwd(),normalize:!0,...e};let t=aRt.resolve(e.cwd,"package.json"),r=oRt(iRt.readFileSync(t,"utf8"));return e.normalize&&pCe()(r),r}});var pRt=y((M4i,dCe)=>{"use strict";var cRt=require("path"),uRt=zDt(),lRt=sRt();dCe.exports=async e=>{let t=await uRt("package.json",e);if(t)return{packageJson:await lRt({...e,cwd:cRt.dirname(t)}),path:t}};dCe.exports.sync=e=>{let t=uRt.sync("package.json",e);if(t)return{packageJson:lRt.sync({...e,cwd:cRt.dirname(t)}),path:t}}});var hRt=y(Ej=>{"use strict";var dRt=Ej&&Ej.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(Ej,"__esModule",{value:!0});Ej.findInstalledPackages=SNn;var ENn=QP(),_Nn=rOe(),xNn=dRt(gK()),hCe=require("node:path"),TNn=dRt(pRt()),fRt=ET(),ONn=async(e,t)=>{let r=await(0,TNn.default)({cwd:e});if(r)return t&&(0,fRt.lt)((0,fRt.coerce)(r.packageJson.version),t)?void 0:{packageJsonPath:r.path,packageInfo:r.packageJson,path:(0,hCe.join)(e,r.packageJson.main??"/generators/app")}};async function SNn(e,t){let r=await ANn(t?.vscWorkspaceConfig),n=[],i=[];for(let a of r){let o=await(0,xNn.default)(`**/*${e}*`,{cwd:a,deep:2,onlyDirectories:!0,absolute:!0});o.length>0&&i.push(...o)}for(let a of i){let o=await ONn(a,t?.minVersion);o&&(!t?.keyword||t.keyword&&o.packageInfo.keywords?.includes(t.keyword))&&n.push(o)}return n}async function ANn(e){let t=[];if(e){let o=e?.get("ApplicationWizard.installationLocation");o&&t.push((0,hCe.join)(o,"node_modules"))}let r=new _Nn.CommandRunner,n=process.platform==="win32"?"npm.cmd":"npm",i=await r.run(n,["-g","root"]).then(a=>a).catch(()=>{});return i&&t.push((0,hCe.join)(i.trim())),(0,ENn.isAppStudio)()&&process.env.NODE_PATH&&t.push(...process.env.NODE_PATH.split(":").filter(a=>a.endsWith("node_modules"))),t}});var mRt=y(_j=>{"use strict";var CNn=_j&&_j.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(_j,"__esModule",{value:!0});_j.setGlobalRejectUnauthorized=wNn;var $W=CNn(require("https"));function wNn(e){$W.default.globalAgent.options&&($W.default.globalAgent.options.rejectUnauthorized=e),$W.default.globalAgent.fallbackAgent?.options&&($W.default.globalAgent.fallbackAgent.options.rejectUnauthorized=e)}});var yRt=y(km=>{"use strict";Object.defineProperty(km,"__esModule",{value:!0});km.ProxyValidationStatus=void 0;km.validateProxySettings=NNn;km.ProxyValidationStatus={NO_PROXY:"no-proxy",MATCH:"match",MISMATCH:"mismatch",ENV_ONLY:"env-only",PARAM_ONLY:"param-only"};var PNn=["HTTP_PROXY","http_proxy","HTTPS_PROXY","https_proxy"],DNn=()=>{for(let e of PNn){let t=process.env[e];if(t&&t.trim()!=="")return t}},gRt=e=>{let t=e?.trim().toLowerCase();for(;t?.endsWith("/");)t=t.slice(0,-1);return t||void 0};function NNn(e){let t=DNn(),r=gRt(t),n=gRt(e);return r||n?r&&!n?{isValid:!1,status:km.ProxyValidationStatus.ENV_ONLY,message:"Using environment proxy settings.",envProxy:r,providedProxy:void 0}:!r&&n?{isValid:!1,status:km.ProxyValidationStatus.PARAM_ONLY,message:`Using provided (${n}) proxy settings.`,envProxy:void 0,providedProxy:n}:r===n?{isValid:!0,status:km.ProxyValidationStatus.MATCH,message:"Proxy settings match.",envProxy:r,providedProxy:n}:{isValid:!1,status:km.ProxyValidationStatus.MISMATCH,message:`Proxy settings conflict between environment (${r}) and parameter (${n}).`,envProxy:r,providedProxy:n}:{isValid:!0,status:km.ProxyValidationStatus.NO_PROXY,message:"No proxy settings configured.",providedProxy:void 0,envProxy:t}}});var mCe=y($m=>{"use strict";var INn=$m&&$m.__createBinding||(Object.create?function(e,t,r,n){n===void 0&&(n=r);var i=Object.getOwnPropertyDescriptor(t,r);(!i||("get"in i?!t.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,i)}:function(e,t,r,n){n===void 0&&(n=r),e[n]=t[r]}),MW=$m&&$m.__exportStar||function(e,t){for(var r in e)r!=="default"&&!Object.prototype.hasOwnProperty.call(t,r)&&INn(t,e,r)};Object.defineProperty($m,"__esModule",{value:!0});MW(rOe(),$m);MW(hRt(),$m);MW(mRt(),$m);MW(yRt(),$m)});var SRt=y(rl=>{"use strict";Object.defineProperty(rl,"__esModule",{value:!0});rl.OdataVersion=rl.FioriElementsVersion=rl.PAGETYPE_VIEW_EXTENSION_TEMPLATE_MAP=rl.PageType=rl.PageTypeV4=rl.PageTypeV2=void 0;var uD;(function(e){e.ObjectPage="ObjectPage",e.ListReport="ListReport",e.OverviewPage="OverviewPage",e.CustomPage="CustomPage",e.AnalyticalListPage="AnalyticalListPage"})(uD||(rl.PageTypeV2=uD={}));var ECe;(function(e){e.ObjectPage="ObjectPage",e.ListReport="ListReport",e.CustomPage="CustomPage",e.FPMCustomPage="FPMCustomPage",e.AnalyticalListPage="AnalyticalListPage"})(ECe||(rl.PageTypeV4=ECe={}));rl.PageType={...uD,...ECe};rl.PAGETYPE_VIEW_EXTENSION_TEMPLATE_MAP=new Map([[uD.ListReport,"sap.suite.ui.generic.template.ListReport.view.ListReport"],[uD.AnalyticalListPage,"sap.suite.ui.generic.template.AnalyticalListPage.view.AnalyticalListPage"],[uD.ObjectPage,"sap.suite.ui.generic.template.ObjectPage.view.Details"]]);var TRt;(function(e){e.v2="v2",e.v4="v4"})(TRt||(rl.FioriElementsVersion=TRt={}));var ORt;(function(e){e.v2="v2",e.v4="v4"})(ORt||(rl.OdataVersion=ORt={}))});var KRt=y(Ge=>{"use strict";Object.defineProperty(Ge,"__esModule",{value:!0});Ge.RuleName=Ge.MacrosPropertyType=Ge.FRAGMENTNAMEPART=Ge.DATESETTINGSPATH=Ge.QUICKVARPATHX=Ge.QUICKVARPATH=Ge.UIVOCABULARYALPHADOT=Ge.UIVOCABULARYDOT=Ge.UIVOCABULARY=Ge.VOCWITHCOLONS=Ge.VOCWITHSLASH=Ge.MANIFESTPATH=Ge.SchemaKeyName=Ge.SchemaTag=Ge.PropertyName=Ge.DefinitionName=Ge.ViewTemplateType=Ge.BINDINGPROPERTYREGEXSTRING=Ge.FacetBase=Ge.defaultExportResult=Ge.ChangeIndicator=Ge.ACTIONTITLEPREFIX=Ge.FACETTITLEPREFIX=Ge.FileName=Ge.DirName=Ge.Visualization=Ge.ControlType=Ge.ActionType=Ge.ArtifactType=Ge.SectionType=Ge.ALPViewType=Ge.ExportArtifacts=Ge.CreationFieldType=Ge.SchemaType=Ge.FlexChangeLayer=Ge.FlexibleColumnLayoutType=void 0;var ARt;(function(e){e.OneColumn="OneColumn",e.TwoColumnsBeginExpanded="TwoColumnsBeginExpanded",e.TwoColumnsMidExpanded="TwoColumnsMidExpanded",e.MidColumnFullScreen="MidColumnFullScreen",e.ThreeColumnsMidExpanded="ThreeColumnsMidExpanded",e.ThreeColumnsEndExpanded="ThreeColumnsEndExpanded",e.ThreeColumnsMidExpandedEndHidden="ThreeColumnsMidExpandedEndHidden",e.ThreeColumnsBeginExpandedEndHidden="ThreeColumnsBeginExpandedEndHidden",e.EndColumnFullScreen="EndColumnFullScreen"})(ARt||(Ge.FlexibleColumnLayoutType=ARt={}));var CRt;(function(e){e.Vendor="VENDOR",e.Customer="CUSTOMER_BASE"})(CRt||(Ge.FlexChangeLayer=CRt={}));var wRt;(function(e){e.Application="Application",e.ObjectPage="ObjectPage",e.ListReport="ListReport",e.OverviewPage="OverviewPage",e.AnalyticalListPage="AnalyticalListPage",e.FreestylePage="FreestylePage",e.FPMCustomPage="FPMCustomPage",e.BuildingBlocks="BuildingBlocks"})(wRt||(Ge.SchemaType=wRt={}));var PRt;(function(e){e.Field="Field",e.FieldGroup="FieldGroup"})(PRt||(Ge.CreationFieldType=PRt={}));var DRt;(function(e){e.flex="flex",e.manifest="manifest"})(DRt||(Ge.ExportArtifacts=DRt={}));var NRt;(function(e){e.Primary="primary",e.Secondary="secondary"})(NRt||(Ge.ALPViewType=NRt={}));var IRt;(function(e){e.Section="Section",e.SubSection="SubSection",e.HeaderSection="HeaderSection"})(IRt||(Ge.SectionType=IRt={}));var RRt;(function(e){e.Manifest="Manifest",e.FlexChange="FlexChange",e.Annotation="Annotation",e.XMLProperty="XMLProperty"})(RRt||(Ge.ArtifactType=RRt={}));var LRt;(function(e){e.Annotation="Annotation",e.Copy="Copy",e.Criticality="Criticality",e.Custom="Custom",e.RelatedApps="RelatedApps",e.Standard="Standard"})(LRt||(Ge.ActionType=LRt={}));var kRt;(function(e){e.Table="sap.m.Table",e.TableColumn="sap.m.Column",e.SmartTable="sap.ui.comp.smarttable.SmartTable",e.SmartFilterBar="sap.ui.comp.smartfilterbar.SmartFilterBar",e.SmartChart="sap.ui.comp.smartchart.SmartChart",e.Group="sap.ui.comp.smartform.Group",e.GroupElement="sap.ui.comp.smartform.GroupElement",e.Button="sap.m.Button",e.ToolbarButton="sap.m.OverflowToolbarButton",e.Avatar="sap.f.Avatar",e.ObjectPageDynamicHeaderTitle="sap.uxap.ObjectPageDynamicHeaderTitle",e.ObjectPageGridProperties="sap.ui.layout.GridData",e.ObjectPageHeader="sap.uxap.ObjectPageHeader",e.ObjectPageLayout="sap.uxap.ObjectPageLayout",e.HeaderAction="sap.uxap.ObjectPageHeaderActionButton",e.ObjectPageHeaderSection="sap.m.VBox",e.DynamicPage="sap.f.DynamicPage",e.Form="sap.ui.layout.form",e.Chart="sap.suite.ui.microchart",e.Section="sap.uxap.ObjectPageSection",e.SubSection="sap.uxap.ObjectPageSubSection"})(kRt||(Ge.ControlType=kRt={}));var $Rt;(function(e){e.LineItem="LineItem",e.Chart="Chart"})($Rt||(Ge.Visualization=$Rt={}));var MRt;(function(e){e.Sapux="src",e.Schemas=".schemas",e.Pages="pages",e.Webapp="webapp",e.Temp=".tmp",e.Changes="changes",e.LocalService="localService",e.Controller="controller",e.View="view",e.Fragment="fragment",e.Ext="ext",e.VSCode=".vscode"})(MRt||(Ge.DirName=MRt={}));var FRt;(function(e){e.App="app.json"})(FRt||(Ge.FileName=FRt={}));Ge.FACETTITLEPREFIX="Facet ID: ";Ge.ACTIONTITLEPREFIX="Action ID: ";var _Ce;(function(e){e.NoChange="NoChange",e.Created="Created",e.Updated="Updated",e.Deleted="Deleted"})(_Ce||(Ge.ChangeIndicator=_Ce={}));Ge.defaultExportResult={manifest:{"sap.ui5":{flexEnabled:!0,routing:{targets:{}}},"sap.app":{}},manifestChangeIndicator:_Ce.NoChange,flexChanges:[],fragments:[],views:[]};var jRt;(function(e){e.LineItem="LineItem",e.CollectionFacet="CollectionFacet",e.Chart="Chart",e.Form="Form",e.Identification="Identification",e.DataPoint="DataPoint",e.Address="Address",e.Contact="Contact",e.PresentationVariant="PresentationVariant",e.SelectionPresentationVariant="SelectionPresentationVariant",e.Unknown=""})(jRt||(Ge.FacetBase=jRt={}));Ge.BINDINGPROPERTYREGEXSTRING="^{[A-Za-z0-9{}&$!@#%? _|,<>'()[\\]\\/:=.]+}$";var qRt;(function(e){e.ResponsiveTableColumnsExtension="ResponsiveTableColumnsExtension",e.AnalyticalTableColumnsExtension="AnalyticalTableColumnsExtension",e.TreeTableColumnsExtension="TreeTableColumnsExtension",e.GridTableColumnsExtension="GridTableColumnsExtension",e.ResponsiveTableCellsExtension="ResponsiveTableCellsExtension"})(qRt||(Ge.ViewTemplateType=qRt={}));var VRt;(function(e){e.Action="Action",e.Actions="Actions",e.ActionsLR="Actions<LineItems>",e.ALPChart="ALPChart",e.ALPChartView="ALPChartView",e.ALPTable="ALPTable",e.ALPTableView="ALPTableView",e.AnalyticalListPageFilterBar="AnalyticalListPageFilterBar",e.AnnotationPathAsObject="AnnotationPathAsObject",e.ChartSettings="ChartSettings",e.ChartToolBarAction="ChartToolBarAction",e.CommonHeaderFacetSettings="CommonHeaderFacetSettings",e.CompactFilters="CompactFilters",e.CustomFooterActionOP="CustomFooterActionOP",e.CustomHeaderAction="CustomHeaderAction",e.CustomHeaderActionOP="CustomHeaderActionOP",e.CustomFormActionOP="CustomFormActionOP",e.CustomTableAction="CustomTableAction",e.CustomTableActionOP="CustomTableActionOP",e.CustomColumn="TableCustomColumn",e.CustomColumnOP="TableCustomColumnOP",e.CustomColumns="TableCustomColumns",e.CustomSections="CustomSections",e.FieldPath="FieldPath",e.Field="Field",e.Fields="Fields",e.Fields4Dialog="Fields4Dialog",e.FilterBar="FilterBar",e.FilterBarVisualFilters="FilterBarVisualFilters",e.Footer="Footer",e.FooterAction="FooterAction",e.FooterActionV4="FooterActionV4",e.FooterActions="FooterActions",e.FooterActionsLR="FooterActions<LineItems>",e.Form="Form",e.FormAction="FormAction",e.FormActionBase="FormActionBase",e.ObjectPageFormActionGroup="ObjectPageFormActionGroup",e.GenericActions="GenericActions",e.GenericColumnsOP="GenericColumnsOP",e.GenericFooter="GenericFooter",e.GenericSections="GenericSections",e.GenericSubSections="GenericSubSections",e.GlobalTableSettings="GlobalTableSettings",e.Header="Header",e.HeaderActions="HeaderActions",e.HeaderActionsStandard="HeaderActionsStandard",e.HeaderActionStandard="HeaderActionStandard",e.ObjectPageHeaderAction="ObjectPageHeaderAction",e.ObjectPageHeaderActionBase="ObjectPageHeaderActionBase",e.ObjectPageHeaderActionGroup="ObjectPageHeaderActionGroup",e.ObjectPageHeaderActionStandard="ObjectPageHeaderActionStandard",e.ObjectPageHeaderActions="ObjectPageHeaderActions",e.HeaderSections="HeaderSections",e.LineItem="LineItem",e.LineItems="LineItems",e.LineItemsOfView="LineItemsOfView",e.ListReportFilterBar="ListReportFilterBar",e.LRTableView="LRTableView",e.LRChartView="LRChartView",e.MultiEditV2="MultiEdit",e.MultiTableModeV4="MultiTableModeV4",e.ObjectPageChart="ObjectPageChart",e.ObjectPageCustomHeaderSectionFragment="ObjectPageCustomHeaderSectionFragment",e.ObjectPageCustomSectionFragment="ObjectPageCustomSectionFragment",e.ObjectPageCustomSubSectionFragment="ObjectPageCustomSubSectionFragment",e.ObjectPageForm="ObjectPageForm",e.ObjectPageFooter="ObjectPageFooter",e.ObjectPageFooterAction="ObjectPageFooterAction",e.ObjectPageFooterActions="ObjectPageFooterActions",e.ObjectPageFooterActionStandard="ObjectPageFooterActionStandard",e.ObjectPageHeader="ObjectPageHeader",e.ObjectPageHeaderSectionForm="ObjectPageHeaderSectionForm",e.ObjectPageHeaderSectionChart="ObjectPageHeaderSectionChart",e.ObjectPageHeaderSectionDataPoint="ObjectPageHeaderSectionDataPoint",e.ObjectPageHeaderSectionContact="ObjectPageHeaderSectionContact",e.ObjectPageHeaderSectionAddress="ObjectPageHeaderSectionAddress",e.ObjectPageLayout="ObjectPageLayout",e.ObjectPagePresentationVariant="ObjectPagePresentationVariant",e.ObjectPageSectionAddress="ObjectPageSectionAddress",e.ObjectPageSectionChart="ObjectPageSectionChart",e.ObjectPageSectionContact="ObjectPageSectionContact",e.ObjectPageSectionDataPoint="ObjectPageSectionDataPoint",e.ObjectPageSectionForm="ObjectPageSectionForm",e.ObjectPageSectionPresentationVariant="ObjectPageSectionPresentationVariant",e.ObjectPageSectionTableV4="ObjectPageSectionTableV4",e.ObjectPageSubSections="ObjectPageSubSections",e.ObjectPageResponsiveTableV4="ObjectPageResponsiveTableV4",e.ObjectPageAnalyticalTableV4="ObjectPageAnalyticalTableV4",e.ObjectPageGridTableV4="ObjectPageGridTableV4",e.ObjectPageTreeTableV4="ObjectPageTreeTableV4",e.ObjectPageTable="ObjectPageTable",e.ObjectPageTableColumn="ObjectPageTableColumn",e.ObjectPageToolBar="ObjectPageToolBar",e.ObjectPageToolBarAction="ObjectPageToolBarAction",e.ObjectPageToolBarActionBase="ObjectPageToolBarActionBase",e.ObjectPageToolBarActionGroup="ObjectPageToolBarActionGroup",e.ObjectPageToolBarActions="ObjectPageToolBarActions",e.Position="Position",e.PositionOP="PositionOP",e.QuickVariant="QuickVariant",e.QuickVariantSelectionOP="QuickVariantSelectionOP",e.QuickVariantSelectionV4OP="QuickVariantSelectionV4OP",e.RelatedFacetKeys="RelatedFacetKeys",e.RowCountMode="RowCountMode",e.Sections="Sections",e.SectionActions="SectionActions",e.SelectionFields="SelectionFields",e.Table="Table",e.TableSPV="TableSPV",e.TableColumn="TableColumn",e.TableCreationModeLR="TableCreationModeLR",e.TableViewExtension="TableViewExtension",e.ToolBarAction="ToolBarAction",e.ToolBarActionBase="ToolBarActionBase",e.ToolBarActionGroup="ToolBarActionGroup",e.ToolBarLR="ToolBar<LineItems>",e.ToolBar="ToolBar",e.ViewTableColumn="ViewTableColumn",e.ViewCustomColumn="ViewTableCustomColumn",e.ViewCustomAction="ViewTableCustomAction",e.ViewChartToolBar="ViewChartToolBar",e.ViewToolBarActionGroup="ViewToolBarActionGroup",e.ViewToolBarAction="ViewToolBarAction",e.ViewToolBarActionBase="ViewToolBarActionBase",e.ViewPosition="ViewPosition",e.ViewCustomActionPosition="ViewCustomActionPosition",e.VisualFilters="VisualFilters",e.VisualFilter="VisualFilter",e.CustomActionPosition="CustomActionPosition",e.CustomActionPositionOP="CustomActionPositionOP",e.CustomHeaderActionPosition="CustomHeaderActionPosition",e.CustomHeaderActionPositionOP="CustomHeaderActionPositionOP",e.CustomFooterActionPositionOP="CustomFooterActionPositionOP",e.CustomExtensionFragment="CustomExtensionFragment",e.CustomFilterField="CustomFilterField",e.CustomFilterFieldPosition="CustomFilterFieldPosition",e.SaveAndEdit="SaveAndEdit",e.ObjectPageCustomSectionActions="ObjectPageCustomSectionActions",e.CustomSectionActionOP="CustomSectionActionOP",e.CustomSectionActionPositionOP="CustomSectionActionPositionOP",e.TableCreationModeCreationDialogOPTable="TableCreationModeCreationDialogOPTable",e.TableCreationModeCreationDialogOPTreeTable="TableCreationModeCreationDialogOPTreeTable",e.AnalyticalConfiguration="AnalyticalConfiguration",e.ViewAnalyticalConfiguration="ViewAnalyticalConfiguration",e.HeaderSectionFields="HeaderSectionFields",e.SectionFields="SectionFields",e.CustomField="CustomField",e.CustomFieldPosition="CustomFieldPosition"})(VRt||(Ge.DefinitionName=VRt={}));var URt;(function(e){e.actions="actions",e.annotationPath="annotationPath",e.chart="chart",e.columns="columns",e.createInPlace="createInPlace",e.creationFields="creationFields",e.creationMode="creationMode",e.defaultPath="defaultPath",e.defaultTemplateAnnotationPath="defaultTemplateAnnotationPath",e.footer="footer",e.header="header",e.isCreateEnabled="isCreateEnabled",e.sections="sections",e.table="table",e.tableSettings="tableSettings",e.views="views",e.visualFilters="visualFilters",e.selectionFields="selectionFields",e.analyticalConfiguration="analyticalConfiguration",e.fields="fields"})(URt||(Ge.PropertyName=URt={}));var BRt;(function(e){e.actionType="actionType",e.annotationPath="annotationPath",e.annotationType="annotationType",e.artifactType="artifactType",e.controlId="controlId",e.controlType="controlType",e.conversionExit="conversionExit",e.dataType="dataType",e.deletable="deletable",e.descriptionSrcURL="descriptionSrcURL",e.fullyQualifiedName="fullyQualifiedName",e.hidden="hidden",e.icon="icon",e.isViewNode="isViewNode",e.key="key",e.keys="keys",e.manifestPath="manifestPath",e.messages="messages",e.propertyIndex="propertyIndex",e.target="target",e.defaultControlProperty="defaultControlProperty",e.controlProperty="controlProperty"})(BRt||(Ge.SchemaTag=BRt={}));var zRt;(function(e){e.id="ID",e.value="Value",e.action="Action",e.target="Target",e.key="Key",e.semanticObject="SemanticObject"})(zRt||(Ge.SchemaKeyName=zRt={}));Ge.MANIFESTPATH="webapp/manifest.json";Ge.VOCWITHSLASH="/@com.sap.vocabularies";Ge.VOCWITHCOLONS="::@com.sap.vocabularies";Ge.UIVOCABULARY="com.sap.vocabularies.UI.v1";Ge.UIVOCABULARYDOT="com.sap.vocabularies.UI.v1.";Ge.UIVOCABULARYALPHADOT="@com.sap.vocabularies.UI.v1.";Ge.QUICKVARPATH="/quickVariantSelection";Ge.QUICKVARPATHX="/quickVariantSelectionX";Ge.DATESETTINGSPATH="/filterSettings/dateSettings";Ge.FRAGMENTNAMEPART=".fragment.";var HRt;(function(e){e.Control="Control",e.Property="Property",e.Aggregation="Aggregation",e.Event="Event"})(HRt||(Ge.MacrosPropertyType=HRt={}));var GRt;(function(e){e.LRCreationModeForAnalyticalTable="LRCreationModeForAnalyticalTable",e.LRCreationModeForNonTreeTable="LRCreationModeForNonTreeTable",e.LRCreationModeForNonCreationDialogMode="LRCreationModeForNonCreationDialogMode",e.LRAnalyticalConfigurationForNonAnalyticalTable="LRAnalyticalConfigurationForNonAnalyticalTable"})(GRt||(Ge.RuleName=GRt={}))});var QRt=y(wf=>{"use strict";Object.defineProperty(wf,"__esModule",{value:!0});wf.CloudDevAdaptationStatus=wf.FlexibleColumnLayoutAggregations=wf.StatePreservationMode=wf.TableColumnVerticalAlignment=wf.DraftDiscardEnabledSettings=void 0;var YRt;(function(e){e.restricted="restricted"})(YRt||(wf.DraftDiscardEnabledSettings=YRt={}));var WRt;(function(e){e.Top="Top",e.Middle="Middle",e.Bottom="Bottom"})(WRt||(wf.TableColumnVerticalAlignment=WRt={}));var XRt;(function(e){e.persistence="persistence",e.discovery="discovery"})(XRt||(wf.StatePreservationMode=XRt={}));var JRt;(function(e){e.BeginColumnPages="beginColumnPages",e.MidColumnPages="midColumnPages",e.EndColumnPages="endColumnPages"})(JRt||(wf.FlexibleColumnLayoutAggregations=JRt={}));var ZRt;(function(e){e.Released="released",e.Deprecated="deprecated",e.Obsolete="obsolete"})(ZRt||(wf.CloudDevAdaptationStatus=ZRt={}))});var rLt=y(Mm=>{"use strict";Object.defineProperty(Mm,"__esModule",{value:!0});Mm.ColorPaletteDefinitionType=Mm.GENERICAPPSETTINGS=Mm.ManifestSection=Mm.DataSourceType=void 0;var eLt;(function(e){e.OData="OData",e.ODataAnnotation="ODataAnnotation"})(eLt||(Mm.DataSourceType=eLt={}));var xCe;(function(e){e.ui="sap.ui",e.app="sap.app",e.generic="sap.ui.generic.app",e.ovp="sap.ovp",e.ui5="sap.ui5",e.fiori="sap.fiori",e.fe="sap.fe"})(xCe||(Mm.ManifestSection=xCe={}));Mm.GENERICAPPSETTINGS=`${xCe.generic}/settings`;var tLt;(function(e){e.SemanticColoring="SemanticColoring",e.StableColoring="StableColoring",e.MapDimensionValues="MapDimensionValues"})(tLt||(Mm.ColorPaletteDefinitionType=tLt={}))});var iLt=y(nLt=>{"use strict";Object.defineProperty(nLt,"__esModule",{value:!0})});var oLt=y(Pf=>{"use strict";Object.defineProperty(Pf,"__esModule",{value:!0});Pf.SAPUI5_FRAGMENT_CLASS=Pf.SAPUI5_VIEW_CLASS=Pf.ViewTypes=Pf.FIORI_FCL_ROOT_ID=Pf.FIORI_FCL_ROOT_VIEW_NAME=void 0;Pf.FIORI_FCL_ROOT_VIEW_NAME="sap.fe.templates.RootContainer.view.Fcl";Pf.FIORI_FCL_ROOT_ID="appRootView";var aLt;(function(e){e.XML="XML",e.HTML="HTML",e.JSON="JSON"})(aLt||(Pf.ViewTypes=aLt={}));Pf.SAPUI5_VIEW_CLASS="sap.ui.core.mvc.View";Pf.SAPUI5_FRAGMENT_CLASS="sap.ui.core.Fragment"});var sLt=y(lv=>{"use strict";var RNn=lv&&lv.__createBinding||(Object.create?function(e,t,r,n){n===void 0&&(n=r);var i=Object.getOwnPropertyDescriptor(t,r);(!i||("get"in i?!t.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,i)}:function(e,t,r,n){n===void 0&&(n=r),e[n]=t[r]}),TCe=lv&&lv.__exportStar||function(e,t){for(var r in e)r!=="default"&&!Object.prototype.hasOwnProperty.call(t,r)&&RNn(t,e,r)};Object.defineProperty(lv,"__esModule",{value:!0});TCe(rLt(),lv);TCe(iLt(),lv);TCe(oLt(),lv)});var uLt=y(BW=>{"use strict";Object.defineProperty(BW,"__esModule",{value:!0});BW.ChartColor=void 0;var cLt;(function(e){e.sapUiChartPaletteQualitativeHue1="sapUiChartPaletteQualitativeHue1",e.sapUiChartPaletteQualitativeHue2="sapUiChartPaletteQualitativeHue2",e.sapUiChartPaletteQualitativeHue3="sapUiChartPaletteQualitativeHue3",e.sapUiChartPaletteQualitativeHue4="sapUiChartPaletteQualitativeHue4",e.sapUiChartPaletteQualitativeHue5="sapUiChartPaletteQualitativeHue5",e.sapUiChartPaletteQualitativeHue6="sapUiChartPaletteQualitativeHue6",e.sapUiChartPaletteQualitativeHue7="sapUiChartPaletteQualitativeHue7",e.sapUiChartPaletteQualitativeHue8="sapUiChartPaletteQualitativeHue8",e.sapUiChartPaletteQualitativeHue9="sapUiChartPaletteQualitativeHue9",e.sapUiChartPaletteQualitativeHue10="sapUiChartPaletteQualitativeHue10",e.sapUiChartPaletteQualitativeHue11="sapUiChartPaletteQualitativeHue11",e.sapUiChartPaletteQualitativeHue12="sapUiChartPaletteQualitativeHue12",e.sapUiChartPaletteQualitativeHue13="sapUiChartPaletteQualitativeHue13",e.sapUiChartPaletteQualitativeHue14="sapUiChartPaletteQualitativeHue14",e.sapUiChartPaletteQualitativeHue15="sapUiChartPaletteQualitativeHue15",e.sapUiChartPaletteQualitativeHue16="sapUiChartPaletteQualitativeHue16",e.sapUiChartPaletteQualitativeHue17="sapUiChartPaletteQualitativeHue17",e.sapUiChartPaletteQualitativeHue18="sapUiChartPaletteQualitativeHue18",e.sapUiChartPaletteQualitativeHue19="sapUiChartPaletteQualitativeHue19",e.sapUiChartPaletteQualitativeHue20="sapUiChartPaletteQualitativeHue20",e.sapUiChartPaletteQualitativeHue21="sapUiChartPaletteQualitativeHue21",e.sapUiChartPaletteQualitativeHue22="sapUiChartPaletteQualitativeHue22",e.sapUiChartPaletteSemanticBadLight3="sapUiChartPaletteSemanticBadLight3",e.sapUiChartPaletteSemanticBadLight2="sapUiChartPaletteSemanticBadLight2",e.sapUiChartPaletteSemanticBadLight1="sapUiChartPaletteSemanticBadLight1",e.sapUiChartPaletteSemanticBad="sapUiChartPaletteSemanticBad",e.sapUiChartPaletteSemanticBadDark1="sapUiChartPaletteSemanticBadDark1",e.sapUiChartPaletteSemanticBadDark2="sapUiChartPaletteSemanticBadDark2",e.sapUiChartPaletteSemanticCriticalLight3="sapUiChartPaletteSemanticCriticalLight3",e.sapUiChartPaletteSemanticCriticalLight2="sapUiChartPaletteSemanticCriticalLight2",e.sapUiChartPaletteSemanticCriticalLight1="sapUiChartPaletteSemanticCriticalLight1",e.sapUiChartPaletteSemanticCritical="sapUiChartPaletteSemanticCritical",e.sapUiChartPaletteSemanticCriticalDark1="sapUiChartPaletteSemanticCriticalDark1",e.sapUiChartPaletteSemanticCriticalDark2="sapUiChartPaletteSemanticCriticalDark2",e.sapUiChartPaletteSemanticGoodLight3="sapUiChartPaletteSemanticGoodLight3",e.sapUiChartPaletteSemanticGoodLight2="sapUiChartPaletteSemanticGoodLight2",e.sapUiChartPaletteSemanticGoodLight1="sapUiChartPaletteSemanticGoodLight1",e.sapUiChartPaletteSemanticGood="sapUiChartPaletteSemanticGood",e.sapUiChartPaletteSemanticGoodDark1="sapUiChartPaletteSemanticGoodDark1",e.sapUiChartPaletteSemanticGoodDark2="sapUiChartPaletteSemanticGoodDark2",e.sapUiChartPaletteSemanticNeutralLight3="sapUiChartPaletteSemanticNeutralLight3",e.sapUiChartPaletteSemanticNeutralLight2="sapUiChartPaletteSemanticNeutralLight2",e.sapUiChartPaletteSemanticNeutralLight1="sapUiChartPaletteSemanticNeutralLight1",e.sapUiChartPaletteSemanticNeutral="sapUiChartPaletteSemanticNeutral",e.sapUiChartPaletteSemanticNeutralDark1="sapUiChartPaletteSemanticNeutralDark1",e.sapUiChartPaletteSemanticNeutralDark2="sapUiChartPaletteSemanticNeutralDark2",e.sapUiChartPaletteNoSemDiv1Dark2="sapUiChartPaletteNoSemDiv1Dark2",e.sapUiChartPaletteNoSemDiv1Dark1="sapUiChartPaletteNoSemDiv1Dark1",e.sapUiChartPaletteNoSemDiv1="sapUiChartPaletteNoSemDiv1",e.sapUiChartPaletteNoSemDiv1Light1="sapUiChartPaletteNoSemDiv1Light1",e.sapUiChartPaletteNoSemDiv1Light2="sapUiChartPaletteNoSemDiv1Light2",e.sapUiChartPaletteNoSemDiv1Light3="sapUiChartPaletteNoSemDiv1Light3",e.sapUiChartPaletteSequentialHue1Light3="sapUiChartPaletteSequentialHue1Light3",e.sapUiChartPaletteSequentialHue1Light2="sapUiChartPaletteSequentialHue1Light2",e.sapUiChartPaletteSequentialHue1Light1="sapUiChartPaletteSequentialHue1Light1",e.sapUiChartPaletteSequentialHue1="sapUiChartPaletteSequentialHue1",e.sapUiChartPaletteSequentialHue1Dark1="sapUiChartPaletteSequentialHue1Dark1",e.sapUiChartPaletteSequentialHue1Dark2="sapUiChartPaletteSequentialHue1Dark2",e.sapUiChartPaletteSequentialHue2Light3="sapUiChartPaletteSequentialHue2Light3",e.sapUiChartPaletteSequentialHue2Light2="sapUiChartPaletteSequentialHue2Light2",e.sapUiChartPaletteSequentialHue2Light1="sapUiChartPaletteSequentialHue2Light1",e.sapUiChartPaletteSequentialHue2="sapUiChartPaletteSequentialHue2",e.sapUiChartPaletteSequentialHue2Dark1="sapUiChartPaletteSequentialHue2Dark1",e.sapUiChartPaletteSequentialHue2Dark2="sapUiChartPaletteSequentialHue2Dark2",e.sapUiChartPaletteSequentialHue3Light3="sapUiChartPaletteSequentialHue3Light3",e.sapUiChartPaletteSequentialHue3Light2="sapUiChartPaletteSequentialHue3Light2",e.sapUiChartPaletteSequentialHue3Light1="sapUiChartPaletteSequentialHue3Light1",e.sapUiChartPaletteSequentialHue3="sapUiChartPaletteSequentialHue3",e.sapUiChartPaletteSequentialHue3Dark1="sapUiChartPaletteSequentialHue3Dark1",e.sapUiChartPaletteSequentialHue3Dark2="sapUiChartPaletteSequentialHue3Dark2",e.sapUiChartPaletteSequentialHue6Light3="sapUiChartPaletteSequentialHue6Light3",e.sapUiChartPaletteSequentialHue6Light2="sapUiChartPaletteSequentialHue6Light2",e.sapUiChartPaletteSequentialHue6Light1="sapUiChartPaletteSequentialHue6Light1",e.sapUiChartPaletteSequentialHue6="sapUiChartPaletteSequentialHue6",e.sapUiChartPaletteSequentialHue6Dark1="sapUiChartPaletteSequentialHue6Dark1",e.sapUiChartPaletteSequentialHue6Dark2="sapUiChartPaletteSequentialHue6Dark2",e.sapUiChartPaletteSequentialNeutralLight3="sapUiChartPaletteSequentialNeutralLight3",e.sapUiChartPaletteSequentialNeutralLight2="sapUiChartPaletteSequentialNeutralLight2",e.sapUiChartPaletteSequentialNeutralLight1="sapUiChartPaletteSequentialNeutralLight1",e.sapUiChartPaletteSequentialNeutral="sapUiChartPaletteSequentialNeutral",e.sapUiChartPaletteSequentialNeutralDark1="sapUiChartPaletteSequentialNeutralDark1",e.sapUiChartPaletteSequentialNeutralDark2="sapUiChartPaletteSequentialNeutralDark2",e.sapUiChoroplethRegionBG="sapUiChoroplethRegionBG",e.sapUiChartZeroAxisColor="sapUiChartZeroAxisColor",e.sapUiNegativeElement="sapUiNegativeElement",e.sapUiCriticalElement="sapUiCriticalElement",e.sapUiPositiveElement="sapUiPositiveElement",e.sapUiNeutralElement="sapUiNeutralElement"})(cLt||(BW.ChartColor=cLt={}))});var lLt=y(Jd=>{"use strict";var LNn=Jd&&Jd.__createBinding||(Object.create?function(e,t,r,n){n===void 0&&(n=r);var i=Object.getOwnPropertyDescriptor(t,r);(!i||("get"in i?!t.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,i)}:function(e,t,r,n){n===void 0&&(n=r),e[n]=t[r]}),xj=Jd&&Jd.__exportStar||function(e,t){for(var r in e)r!=="default"&&!Object.prototype.hasOwnProperty.call(t,r)&&LNn(t,e,r)};Object.defineProperty(Jd,"__esModule",{value:!0});xj(SRt(),Jd);xj(KRt(),Jd);xj(QRt(),Jd);xj(sLt(),Jd);xj(uLt(),Jd)});var gLt=y(nl=>{"use strict";Object.defineProperty(nl,"__esModule",{value:!0});nl.Features=nl.CustomExtensionType=nl.TemplateType=nl.PropertyMessageType=nl.logSeverityLabel=nl.LogSeverity=void 0;var pLt;(function(e){e.Error="error",e.Warning="warning",e.Info="info"})(pLt||(nl.LogSeverity=pLt={}));nl.logSeverityLabel={error:"Error",warning:"Warning",info:"Information"};var fLt;(function(e){e.Error="error",e.Warning="warning",e.Info="info"})(fLt||(nl.PropertyMessageType=fLt={}));var dLt;(function(e){e.ListReportObjectPageV2="ListReportObjectPageV2",e.ListReportObjectPageV4="ListReportObjectPageV4",e.OverviewPageV2="OverviewPageV2",e.AnalyticalListPageV2="AnalyticalListPageV2",e.AnalyticalListPageV4="AnalyticalListPageV4",e.FreestylePageV4="FreestylePageV4"})(dLt||(nl.TemplateType=dLt={}));var hLt;(function(e){e.ControllerExtension="ControllerExtension",e.CustomAction="CustomAction",e.CustomColumn="CustomColumn",e.CustomFilterField="CustomFilterField",e.CustomHeaderSection="CustomHeaderSection",e.CustomPage="CustomPage",e.CustomSection="CustomSection",e.CustomSubSection="CustomSubSection",e.CustomView="CustomView",e.ListReport="ListReport",e.ObjectPage="ObjectPage",e.CustomField="CustomField"})(hLt||(nl.CustomExtensionType=hLt={}));var mLt;(function(e){e.BuildingBlocks="BuildingBlocks"})(mLt||(nl.Features=mLt={}))});var vLt=y(yLt=>{"use strict";Object.defineProperty(yLt,"__esModule",{value:!0})});var CLt=y(xa=>{"use strict";Object.defineProperty(xa,"__esModule",{value:!0});xa.LinkListFlavorType=xa.SortOrderType=xa.ListTypeType=xa.ListFlavorType=xa.MeasureAggregateValues=xa.CardSettingsType=xa.cardTemplateSettingsMap=xa.cardTemplateTypeMap=xa.CardTemplateType=xa.ChartCardType=void 0;var bLt;(function(e){e.cardBubble="cardBubble",e.cardchartsline="cardchartsline",e.cardchartsdonut="cardchartsdonut"})(bLt||(xa.ChartCardType=bLt={}));var ELt;(function(e){e.analytical="sap.ovp.cards.charts.analytical",e.analyticalv4="sap.ovp.cards.v4.charts.analytical",e.list="sap.ovp.cards.list",e.listv4="sap.ovp.cards.v4.list",e.linklist="sap.ovp.cards.linklist",e.linklistv4="sap.ovp.cards.v4.linklist",e.table="sap.ovp.cards.table",e.tablev4="sap.ovp.cards.v4.table",e.stack="sap.ovp.cards.stack"})(ELt||(xa.CardTemplateType=ELt={}));xa.cardTemplateTypeMap={"sap.ovp.cards.charts.analytical":"AnalyticalCard","sap.ovp.cards.v4.charts.analytical":"AnalyticalCard","sap.ovp.cards.list":"ListCard","sap.ovp.cards.v4.list":"ListCard","sap.ovp.cards.linklist":"LinklistCard","sap.ovp.cards.v4.linklist":"LinklistCard","sap.ovp.cards.table":"TableCard","sap.ovp.cards.v4.table":"TableCard","sap.ovp.cards.stack":"StackCard"};xa.cardTemplateSettingsMap={"sap.ovp.cards.charts.analytical":"AnalyticalCardSettings","sap.ovp.cards.v4.charts.analytical":"AnalyticalCardSettingsv4"};var _Lt;(function(e){e.analyticalCardSettings="analyticalCardSettings",e.analyticalCardSettingsv4="analyticalCardSettingsv4",e.listCardSettings="listCardSettings",e.listCardSettingsv4="listCardSettingsv4",e.stackCardSettings="stackCardSettings",e.linkListCardSettings="linkListCardSettings",e.tableCardSettings="tableCardSettings",e.tableCardSettingsv4="tableCardSettingsv4"})(_Lt||(xa.CardSettingsType=_Lt={}));var xLt;(function(e){e.average="average",e.max="max",e.min="min",e.sum="sum",e.count="$count"})(xLt||(xa.MeasureAggregateValues=xLt={}));var TLt;(function(e){e.standard="standard",e.bar="bar",e.carousel="carousel"})(TLt||(xa.ListFlavorType=TLt={}));var OLt;(function(e){e.extended="extended",e.condensed="condensed"})(OLt||(xa.ListTypeType=OLt={}));var SLt;(function(e){e.ascending="ascending",e.descending="descending"})(SLt||(xa.SortOrderType=SLt={}));var ALt;(function(e){e.standard="standard",e.carousel="carousel"})(ALt||(xa.LinkListFlavorType=ALt={}))});var PLt=y(wLt=>{"use strict";Object.defineProperty(wLt,"__esModule",{value:!0})});var RLt=y(SE=>{"use strict";Object.defineProperty(SE,"__esModule",{value:!0});SE.FilterPathType=SE.DefaultDateRangeValueType=SE.DateRangeType=void 0;var DLt;(function(e){e.DATERANGE="DATERANGE",e.DATE="DATE",e.FROM="FROM",e.TO="TO",e.DAYS="DAYS",e.LASTDAYS="LASTDAYS",e.LASTWEEKS="LASTWEEKS",e.WEEK="WEEK",e.LASTMONTHS="LASTMONTHS",e.MONTH="MONTH",e.QUARTER="QUARTER",e.LASTQUARTERS="LASTQUARTERS",e.LASTYEARS="LASTYEARS",e.LASTYEAR="LASTYEAR",e.YEAR="YEAR",e.NEXTDAYS="NEXTDAYS",e.NEXTWEEKS="NEXTWEEKS",e.NEXTMONTHS="NEXTMONTHS",e.NEXTQUARTERS="NEXTQUARTERS",e.NEXTYEARS="NEXTYEARS",e.NEXT="NEXT",e.SPECIFICMONTH="SPECIFICMONTH",e.YESTERDAY="YESTERDAY",e.YEARTODATE="YEARTODATE",e.TODAY="TODAY",e.TOMORROW="TOMORROW",e.THISWEEK="THISWEEK",e.LASTWEEK="LASTWEEK",e.LAST2WEEKS="LAST2WEEKS",e.LAST3WEEKS="LAST3WEEKS",e.LAST4WEEKS="LAST4WEEKS",e.LAST5WEEKS="LAST5WEEKS",e.NEXTWEEK="NEXTWEEK",e.NEXT2WEEKS="NEXT2WEEKS",e.NEXT3WEEKS="NEXT3WEEKS",e.NEXT4WEEKS="NEXT4WEEKS",e.NEXT5WEEKS="NEXT5WEEKS",e.THISMONTH="THISMONTH",e.LASTMONTH="LASTMONTH",e.NEXTMONTH="NEXTMONTH",e.THISQUARTER="THISQUARTER",e.LASTQUARTER="LASTQUARTER",e.NEXTQUARTER="NEXTQUARTER",e.QUARTER1="QUARTER1",e.QUARTER2="QUARTER2",e.QUARTER3="QUARTER3",e.QUARTER4="QUARTER4",e.TODAYFROMTO="TODAYFROMTO"})(DLt||(SE.DateRangeType=DLt={}));var NLt;(function(e){e.YESTERDAY="YESTERDAY",e.TODAY="TODAY",e.THISWEEK="THISWEEK",e.LASTWEEK="LASTWEEK",e.THISMONTH="THISMONTH",e.TOMORROW="TOMORROW",e.LASTMONTH="LASTMONTH",e.THISQUARTER="THISQUARTER",e.LASTQUARTER="LASTQUARTER",e.THISYEAR="THISYEAR",e.LASTYEAR="LASTYEAR",e.LAST2WEEKS="LAST2WEEKS",e.LAST3WEEKS="LAST3WEEKS",e.LAST4WEEKS="LAST4WEEKS",e.LAST5WEEKS="LAST5WEEKS",e.YEARTODATE="YEARTODATE",e.QUARTER1="QUARTER1",e.QUARTER2="QUARTER2",e.QUARTER3="QUARTER3",e.QUARTER4="QUARTER4",e.DATETOYEAR="DATETOYEAR"})(NLt||(SE.DefaultDateRangeValueType=NLt={}));var ILt;(function(e){e.key="key",e.catgory="category"})(ILt||(SE.FilterPathType=ILt={}))});var kLt=y(LLt=>{"use strict";Object.defineProperty(LLt,"__esModule",{value:!0})});var zLt=y(Qo=>{"use strict";Object.defineProperty(Qo,"__esModule",{value:!0});Qo.LoadDataOnAppLaunchSettings=Qo.DefaultFilterMode=Qo.DefaultContentView=Qo.IgnoredFieldsType=Qo.Strategy=Qo.TableColumnExtensionTypeV2=Qo.TableTypeV2=Qo.customColumnViewTypes=void 0;var $Lt;(function(e){e.XML="XML"})($Lt||(Qo.customColumnViewTypes=$Lt={}));var MLt;(function(e){e.ResponsiveTable="ResponsiveTable",e.GridTable="GridTable",e.AnalyticalTable="AnalyticalTable",e.TreeTable="TreeTable"})(MLt||(Qo.TableTypeV2=MLt={}));var FLt;(function(e){e.ResponsiveTableColumnsExtension="ResponsiveTableColumnsExtension",e.AnalyticalTableColumnsExtension="AnalyticalTableColumnsExtension",e.TreeTableColumnsExtension="TreeTableColumnsExtension",e.GridTableColumnsExtension="GridTableColumnsExtension"})(FLt||(Qo.TableColumnExtensionTypeV2=FLt={}));var jLt;(function(e){e.extension="extension"})(jLt||(Qo.Strategy=jLt={}));var qLt;(function(e){e.GENERICPROPERTY="GENERICPROPERTY"})(qLt||(Qo.IgnoredFieldsType=qLt={}));var VLt;(function(e){e.charttable="charttable",e.chart="chart",e.table="table"})(VLt||(Qo.DefaultContentView=VLt={}));var ULt;(function(e){e.visual="visual",e.compact="compact"})(ULt||(Qo.DefaultFilterMode=ULt={}));var BLt;(function(e){e.always="always",e.never="never",e.ifAnyFilterExist="ifAnyFilterExist"})(BLt||(Qo.LoadDataOnAppLaunchSettings=BLt={}))});var GLt=y(HLt=>{"use strict";Object.defineProperty(HLt,"__esModule",{value:!0})});var YLt=y(KLt=>{"use strict";Object.defineProperty(KLt,"__esModule",{value:!0})});var XLt=y(zW=>{"use strict";Object.defineProperty(zW,"__esModule",{value:!0});zW.ChartType=void 0;var WLt;(function(e){e.bar="bar",e.column="column",e.line="line",e.combination="combination",e.pie="pie",e.donut="donut",e.scatter="scatter",e.bubble="bubble",e.heatmap="heatmap",e.bullet="bullet",e.verticalBullet="vertical_bullet",e.stackedBar="stacked_bar",e.stackedColumn="stacked_column",e.stackedCombination="stacked_combination",e.horizontalStackedCombination="horizontal_stacked_combination",e.dualBar="dual_bar",e.dualColumn="dual_column",e.dualLine="dual_line",e.dualStackedBar="dual_stacked_bar",e.dualStackedColumn="dual_stacked_column",e.dualCombination="dual_combination",e.dualStackedCombination="dual_stacked_combination",e.dualHorizontalCombination="dual_horizontal_combination",e.dualHorizontalStackedCombination="dual_horizontal_stacked_combination",e.hundredStackedBar="100_stacked_bar",e.hundredStackedColumn="100_stacked_column",e.hundredDualStackedBar="100_dual_stacked_bar",e.hundredDualStackedColumn="100_dual_stacked_column",e.waterfall="waterfall",e.horizontalWaterfall="horizontal_waterfall"})(WLt||(zW.ChartType=WLt={}))});var ZLt=y(JLt=>{"use strict";Object.defineProperty(JLt,"__esModule",{value:!0})});var ekt=y(QLt=>{"use strict";Object.defineProperty(QLt,"__esModule",{value:!0})});var rkt=y(tkt=>{"use strict";Object.defineProperty(tkt,"__esModule",{value:!0})});var ikt=y(nkt=>{"use strict";Object.defineProperty(nkt,"__esModule",{value:!0})});var skt=y(lD=>{"use strict";Object.defineProperty(lD,"__esModule",{value:!0});lD.ExtensionFragmentTypes=lD.SectionPosition=void 0;var akt;(function(e){e.AfterFacet="AfterFacet",e.BeforeFacet="BeforeFacet",e.ReplaceFacet="ReplaceFacet"})(akt||(lD.SectionPosition=akt={}));var okt;(function(e){e.XML="XML"})(okt||(lD.ExtensionFragmentTypes=okt={}))});var ukt=y(ckt=>{"use strict";Object.defineProperty(ckt,"__esModule",{value:!0})});var pkt=y(lkt=>{"use strict";Object.defineProperty(lkt,"__esModule",{value:!0})});var dkt=y(HW=>{"use strict";Object.defineProperty(HW,"__esModule",{value:!0});HW.CreateMode=void 0;var fkt;(function(e){e.creationRows="creationRows",e.creationRowsHiddenInEditMode="creationRowsHiddenInEditMode",e.inline="inline"})(fkt||(HW.CreateMode=fkt={}))});var mkt=y(hkt=>{"use strict";Object.defineProperty(hkt,"__esModule",{value:!0})});var gkt=y(Wi=>{"use strict";var kNn=Wi&&Wi.__createBinding||(Object.create?function(e,t,r,n){n===void 0&&(n=r);var i=Object.getOwnPropertyDescriptor(t,r);(!i||("get"in i?!t.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,i)}:function(e,t,r,n){n===void 0&&(n=r),e[n]=t[r]}),es=Wi&&Wi.__exportStar||function(e,t){for(var r in e)r!=="default"&&!Object.prototype.hasOwnProperty.call(t,r)&&kNn(t,e,r)};Object.defineProperty(Wi,"__esModule",{value:!0});es(vLt(),Wi);es(CLt(),Wi);es(PLt(),Wi);es(RLt(),Wi);es(kLt(),Wi);es(zLt(),Wi);es(GLt(),Wi);es(YLt(),Wi);es(XLt(),Wi);es(ZLt(),Wi);es(ekt(),Wi);es(rkt(),Wi);es(ikt(),Wi);es(skt(),Wi);es(ukt(),Wi);es(pkt(),Wi);es(dkt(),Wi);es(mkt(),Wi)});var ykt=y(Fm=>{"use strict";Object.defineProperty(Fm,"__esModule",{value:!0});Fm.FE_TEMPLATE_V2_ALP=Fm.FE_TEMPLATE_V2_LIST_REPORT=Fm.FE_TEMPLATE_V2_OBJECT_PAGE=Fm.FE_TEMPLATE_V2=void 0;Fm.FE_TEMPLATE_V2="sap.suite.ui.generic.template";Fm.FE_TEMPLATE_V2_OBJECT_PAGE="sap.suite.ui.generic.template.ObjectPage";Fm.FE_TEMPLATE_V2_LIST_REPORT="sap.suite.ui.generic.template.ListReport";Fm.FE_TEMPLATE_V2_ALP="sap.suite.ui.generic.template.AnalyticalListPage"});var vkt=y(Df=>{"use strict";Object.defineProperty(Df,"__esModule",{value:!0});Df.SAPUI5_VIEW_EXTENSION_ANALYTICAL_LIST_PAGE=Df.SAPUI5_VIEW_EXTENSION_LIST_REPORT=Df.SAPUI5_VIEW_EXTENSION_OBJECT_PAGE=Df.SAPUI5_CONTROLLER_EXTENSION=Df.SAPUI5_VIEW_EXTENSION=void 0;Df.SAPUI5_VIEW_EXTENSION="sap.ui.viewExtensions";Df.SAPUI5_CONTROLLER_EXTENSION="sap.ui.controllerExtensions";Df.SAPUI5_VIEW_EXTENSION_OBJECT_PAGE="sap.suite.ui.generic.template.ObjectPage.view.Details";Df.SAPUI5_VIEW_EXTENSION_LIST_REPORT="sap.suite.ui.generic.template.ListReport.view.ListReport";Df.SAPUI5_VIEW_EXTENSION_ANALYTICAL_LIST_PAGE="sap.suite.ui.generic.template.AnalyticalListPage.view.AnalyticalListPage"});var Ekt=y(bkt=>{"use strict";Object.defineProperty(bkt,"__esModule",{value:!0})});var _kt=y(pv=>{"use strict";var $Nn=pv&&pv.__createBinding||(Object.create?function(e,t,r,n){n===void 0&&(n=r);var i=Object.getOwnPropertyDescriptor(t,r);(!i||("get"in i?!t.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,i)}:function(e,t,r,n){n===void 0&&(n=r),e[n]=t[r]}),OCe=pv&&pv.__exportStar||function(e,t){for(var r in e)r!=="default"&&!Object.prototype.hasOwnProperty.call(t,r)&&$Nn(t,e,r)};Object.defineProperty(pv,"__esModule",{value:!0});OCe(ykt(),pv);OCe(vkt(),pv);OCe(Ekt(),pv)});var xkt=y(SO=>{"use strict";var MNn=SO&&SO.__createBinding||(Object.create?function(e,t,r,n){n===void 0&&(n=r);var i=Object.getOwnPropertyDescriptor(t,r);(!i||("get"in i?!t.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,i)}:function(e,t,r,n){n===void 0&&(n=r),e[n]=t[r]}),FNn=SO&&SO.__exportStar||function(e,t){for(var r in e)r!=="default"&&!Object.prototype.hasOwnProperty.call(t,r)&&MNn(t,e,r)};Object.defineProperty(SO,"__esModule",{value:!0});FNn(_kt(),SO)});var Okt=y(Tkt=>{"use strict";Object.defineProperty(Tkt,"__esModule",{value:!0})});var Akt=y(Skt=>{"use strict";Object.defineProperty(Skt,"__esModule",{value:!0})});var wkt=y(Ckt=>{"use strict";Object.defineProperty(Ckt,"__esModule",{value:!0})});var Dkt=y(Pkt=>{"use strict";Object.defineProperty(Pkt,"__esModule",{value:!0})});var Ikt=y(Nkt=>{"use strict";Object.defineProperty(Nkt,"__esModule",{value:!0})});var Rkt=y(jm=>{"use strict";var jNn=jm&&jm.__createBinding||(Object.create?function(e,t,r,n){n===void 0&&(n=r);var i=Object.getOwnPropertyDescriptor(t,r);(!i||("get"in i?!t.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,i)}:function(e,t,r,n){n===void 0&&(n=r),e[n]=t[r]}),GW=jm&&jm.__exportStar||function(e,t){for(var r in e)r!=="default"&&!Object.prototype.hasOwnProperty.call(t,r)&&jNn(t,e,r)};Object.defineProperty(jm,"__esModule",{value:!0});GW(Akt(),jm);GW(wkt(),jm);GW(Dkt(),jm);GW(Ikt(),jm)});var $kt=y(KW=>{"use strict";Object.defineProperty(KW,"__esModule",{value:!0});KW.ContainerLayoutType=void 0;var Lkt;(function(e){e.always="always",e.never="never",e.ifAnyFilterExist="ifAnyFilterExist"})(Lkt||(Lkt={}));var kkt;(function(e){e.fixed="fixed",e.resizable="resizable"})(kkt||(KW.ContainerLayoutType=kkt={}))});var Fkt=y(Mkt=>{"use strict";Object.defineProperty(Mkt,"__esModule",{value:!0})});var qkt=y(jkt=>{"use strict";Object.defineProperty(jkt,"__esModule",{value:!0})});var Vkt=y(up=>{"use strict";var qNn=up&&up.__createBinding||(Object.create?function(e,t,r,n){n===void 0&&(n=r);var i=Object.getOwnPropertyDescriptor(t,r);(!i||("get"in i?!t.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,i)}:function(e,t,r,n){n===void 0&&(n=r),e[n]=t[r]}),AO=up&&up.__exportStar||function(e,t){for(var r in e)r!=="default"&&!Object.prototype.hasOwnProperty.call(t,r)&&qNn(t,e,r)};Object.defineProperty(up,"__esModule",{value:!0});AO(gkt(),up);AO(xkt(),up);AO(Okt(),up);AO(Rkt(),up);AO($kt(),up);AO(Fkt(),up);AO(qkt(),up)});var Bkt=y(YW=>{"use strict";Object.defineProperty(YW,"__esModule",{value:!0});YW.ActionPlacement=void 0;var Ukt;(function(e){e.After="After",e.Before="Before"})(Ukt||(YW.ActionPlacement=Ukt={}))});var Hkt=y(WW=>{"use strict";Object.defineProperty(WW,"__esModule",{value:!0});WW.FieldPlacement=void 0;var zkt;(function(e){e.After="After",e.Before="Before"})(zkt||(WW.FieldPlacement=zkt={}))});var Zkt=y(bc=>{"use strict";Object.defineProperty(bc,"__esModule",{value:!0});bc.OperationGroupingMode=bc.EMPTY_OPTION=bc.DefaultPathType=bc.InitialLoadType=bc.TableTypeV4=bc.RowCountMode=bc.SelectionMode=void 0;var Gkt;(function(e){e.Multi="Multi",e.None="None",e.Single="Single",e.Auto="Auto"})(Gkt||(bc.SelectionMode=Gkt={}));var Kkt;(function(e){e.Fixed="Fixed",e.Auto="Auto",e.Interactive="Interactive"})(Kkt||(bc.RowCountMode=Kkt={}));var Ykt;(function(e){e.ResponsiveTable="ResponsiveTable",e.GridTable="GridTable",e.AnalyticalTable="AnalyticalTable",e.TreeTable="TreeTable"})(Ykt||(bc.TableTypeV4=Ykt={}));var Wkt;(function(e){e.Disabled="Disabled",e.Enabled="Enabled",e.Auto="Auto"})(Wkt||(bc.InitialLoadType=Wkt={}));var Xkt;(function(e){e.Primary="primary",e.Secondary="secondary",e.Both="both"})(Xkt||(bc.DefaultPathType=Xkt={}));bc.EMPTY_OPTION="";var Jkt;(function(e){e.ChangeSet="ChangeSet",e.Isolated="Isolated"})(Jkt||(bc.OperationGroupingMode=Jkt={}))});var r$t=y(AE=>{"use strict";Object.defineProperty(AE,"__esModule",{value:!0});AE.FilterFieldPlacement=AE.InitialLayoutType=AE.LayoutType=void 0;var Qkt;(function(e){e.Compact="Compact",e.CompactVisual="CompactVisual"})(Qkt||(AE.LayoutType=Qkt={}));var e$t;(function(e){e.Compact="Compact",e.Visual="Visual"})(e$t||(AE.InitialLayoutType=e$t={}));var t$t;(function(e){e.After="After",e.Before="Before"})(t$t||(AE.FilterFieldPlacement=t$t={}))});var i$t=y(n$t=>{"use strict";Object.defineProperty(n$t,"__esModule",{value:!0})});var o$t=y(XW=>{"use strict";Object.defineProperty(XW,"__esModule",{value:!0});XW.SelectType=void 0;var a$t;(function(e){e.single="single",e.multi="multi"})(a$t||(XW.SelectType=a$t={}))});var c$t=y(s$t=>{"use strict";Object.defineProperty(s$t,"__esModule",{value:!0})});var SCe=y(u$t=>{"use strict";Object.defineProperty(u$t,"__esModule",{value:!0})});var p$t=y(l$t=>{"use strict";Object.defineProperty(l$t,"__esModule",{value:!0})});var d$t=y(f$t=>{"use strict";Object.defineProperty(f$t,"__esModule",{value:!0})});var m$t=y(JW=>{"use strict";Object.defineProperty(JW,"__esModule",{value:!0});JW.SectionLayoutType=void 0;var h$t;(function(e){e.Tabs="Tabs",e.Page="Page"})(h$t||(JW.SectionLayoutType=h$t={}))});var v$t=y(pD=>{"use strict";Object.defineProperty(pD,"__esModule",{value:!0});pD.CustomSectionViewTypesV4=pD.SectionPosition=void 0;var g$t;(function(e){e.After="After",e.Before="Before"})(g$t||(pD.SectionPosition=g$t={}));var y$t;(function(e){e.XML="XML"})(y$t||(pD.CustomSectionViewTypesV4=y$t={}))});var E$t=y(ZW=>{"use strict";Object.defineProperty(ZW,"__esModule",{value:!0});ZW.TableCreationModeType=void 0;var b$t;(function(e){e.NewPage="NewPage",e.InlineCreationRows="InlineCreationRows",e.Inline="Inline",e.CreationDialog="CreationDialog",e.External="External"})(b$t||(ZW.TableCreationModeType=b$t={}))});var x$t=y(_$t=>{"use strict";Object.defineProperty(_$t,"__esModule",{value:!0})});var T$t=y(Ua=>{"use strict";var VNn=Ua&&Ua.__createBinding||(Object.create?function(e,t,r,n){n===void 0&&(n=r);var i=Object.getOwnPropertyDescriptor(t,r);(!i||("get"in i?!t.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,i)}:function(e,t,r,n){n===void 0&&(n=r),e[n]=t[r]}),fu=Ua&&Ua.__exportStar||function(e,t){for(var r in e)r!=="default"&&!Object.prototype.hasOwnProperty.call(t,r)&&VNn(t,e,r)};Object.defineProperty(Ua,"__esModule",{value:!0});fu(Bkt(),Ua);fu(Hkt(),Ua);fu(Zkt(),Ua);fu(r$t(),Ua);fu(i$t(),Ua);fu(o$t(),Ua);fu(c$t(),Ua);fu(SCe(),Ua);fu(p$t(),Ua);fu(d$t(),Ua);fu(m$t(),Ua);fu(v$t(),Ua);fu(E$t(),Ua);fu(x$t(),Ua);fu(SCe(),Ua)});var S$t=y(Ec=>{"use strict";Object.defineProperty(Ec,"__esModule",{value:!0});Ec.SectionPositionV4=Ec.SAPUI5_FRAGMENT_TYPE_V4=Ec.FE_TEMPLATE_V4_ALP=Ec.FE_TEMPLATE_V4_LIST_REPORT=Ec.FE_TEMPLATE_V4_OBJECT_PAGE=Ec.FE_TEMPLATE_V4_CUSTOM_PAGE=Ec.FE_NAMESPACE_V4=void 0;Ec.FE_NAMESPACE_V4="sap.fe";Ec.FE_TEMPLATE_V4_CUSTOM_PAGE="sap.fe.core.fpm";Ec.FE_TEMPLATE_V4_OBJECT_PAGE="sap.fe.templates.ObjectPage";Ec.FE_TEMPLATE_V4_LIST_REPORT="sap.fe.templates.ListReport";Ec.FE_TEMPLATE_V4_ALP="sap.fe.templates.AnalyticalListPage";Ec.SAPUI5_FRAGMENT_TYPE_V4="XMLFragment";var O$t;(function(e){e.AfterFacet="AfterFacet",e.BeforeFacet="BeforeFacet"})(O$t||(Ec.SectionPositionV4=O$t={}))});var A$t=y(Nf=>{"use strict";Object.defineProperty(Nf,"__esModule",{value:!0});Nf.SAPUI5_VIEW_EXTENSION_LIST_REPORT=Nf.SAPUI5_VIEW_EXTENSION_OBJECT_PAGE=Nf.SAPUI5_CONTROLLER_EXTENSION=Nf.SAPUI5_DEPENDENCY_LIB_SAP_F=Nf.FIORI_FCL_ROUTER_CLASS=void 0;Nf.FIORI_FCL_ROUTER_CLASS="sap.f.routing.Router";Nf.SAPUI5_DEPENDENCY_LIB_SAP_F="sap.f";Nf.SAPUI5_CONTROLLER_EXTENSION="sap.ui.controllerExtensions";Nf.SAPUI5_VIEW_EXTENSION_OBJECT_PAGE="sap.fe.templates.ObjectPage.ObjectPageController";Nf.SAPUI5_VIEW_EXTENSION_LIST_REPORT="sap.fe.templates.ListReport.ListReportController"});var D$t=y(CE=>{"use strict";Object.defineProperty(CE,"__esModule",{value:!0});CE.HorizontalAlign=CE.Availability=CE.Placement=void 0;var C$t;(function(e){e.After="After",e.Before="Before"})(C$t||(CE.Placement=C$t={}));var w$t;(function(e){e.Default="Default",e.Adaptation="Adaptation",e.Hidden="Hidden"})(w$t||(CE.Availability=w$t={}));var P$t;(function(e){e.Begin="Begin",e.Center="Center",e.End="End"})(P$t||(CE.HorizontalAlign=P$t={}))});var N$t=y(fv=>{"use strict";var UNn=fv&&fv.__createBinding||(Object.create?function(e,t,r,n){n===void 0&&(n=r);var i=Object.getOwnPropertyDescriptor(t,r);(!i||("get"in i?!t.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,i)}:function(e,t,r,n){n===void 0&&(n=r),e[n]=t[r]}),ACe=fv&&fv.__exportStar||function(e,t){for(var r in e)r!=="default"&&!Object.prototype.hasOwnProperty.call(t,r)&&UNn(t,e,r)};Object.defineProperty(fv,"__esModule",{value:!0});ACe(S$t(),fv);ACe(A$t(),fv);ACe(D$t(),fv)});var I$t=y(CO=>{"use strict";var BNn=CO&&CO.__createBinding||(Object.create?function(e,t,r,n){n===void 0&&(n=r);var i=Object.getOwnPropertyDescriptor(t,r);(!i||("get"in i?!t.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,i)}:function(e,t,r,n){n===void 0&&(n=r),e[n]=t[r]}),zNn=CO&&CO.__exportStar||function(e,t){for(var r in e)r!=="default"&&!Object.prototype.hasOwnProperty.call(t,r)&&BNn(t,e,r)};Object.defineProperty(CO,"__esModule",{value:!0});zNn(N$t(),CO)});var L$t=y(R$t=>{"use strict";Object.defineProperty(R$t,"__esModule",{value:!0})});var $$t=y(QW=>{"use strict";Object.defineProperty(QW,"__esModule",{value:!0});QW.VariantManagementTypeObjectPage=void 0;var k$t;(function(e){e.None="None",e.Control="Control"})(k$t||(QW.VariantManagementTypeObjectPage=k$t={}))});var F$t=y(eX=>{"use strict";Object.defineProperty(eX,"__esModule",{value:!0});eX.VariantManagementTypeListReport=void 0;var M$t;(function(e){e.None="None",e.Control="Control",e.Page="Page"})(M$t||(eX.VariantManagementTypeListReport=M$t={}))});var q$t=y(j$t=>{"use strict";Object.defineProperty(j$t,"__esModule",{value:!0})});var V$t=y(dv=>{"use strict";var HNn=dv&&dv.__createBinding||(Object.create?function(e,t,r,n){n===void 0&&(n=r);var i=Object.getOwnPropertyDescriptor(t,r);(!i||("get"in i?!t.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,i)}:function(e,t,r,n){n===void 0&&(n=r),e[n]=t[r]}),CCe=dv&&dv.__exportStar||function(e,t){for(var r in e)r!=="default"&&!Object.prototype.hasOwnProperty.call(t,r)&&HNn(t,e,r)};Object.defineProperty(dv,"__esModule",{value:!0});CCe($$t(),dv);CCe(F$t(),dv);CCe(q$t(),dv)});var B$t=y(U$t=>{"use strict";Object.defineProperty(U$t,"__esModule",{value:!0})});var H$t=y(z$t=>{"use strict";Object.defineProperty(z$t,"__esModule",{value:!0})});var G$t=y(If=>{"use strict";var GNn=If&&If.__createBinding||(Object.create?function(e,t,r,n){n===void 0&&(n=r);var i=Object.getOwnPropertyDescriptor(t,r);(!i||("get"in i?!t.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,i)}:function(e,t,r,n){n===void 0&&(n=r),e[n]=t[r]}),fD=If&&If.__exportStar||function(e,t){for(var r in e)r!=="default"&&!Object.prototype.hasOwnProperty.call(t,r)&&GNn(t,e,r)};Object.defineProperty(If,"__esModule",{value:!0});fD(T$t(),If);fD(I$t(),If);fD(L$t(),If);fD(V$t(),If);fD(B$t(),If);fD(H$t(),If)});var xc=y(_c=>{"use strict";var K$t=_c&&_c.__createBinding||(Object.create?function(e,t,r,n){n===void 0&&(n=r);var i=Object.getOwnPropertyDescriptor(t,r);(!i||("get"in i?!t.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,i)}:function(e,t,r,n){n===void 0&&(n=r),e[n]=t[r]}),KNn=_c&&_c.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e.default=t}),Y$t=_c&&_c.__exportStar||function(e,t){for(var r in e)r!=="default"&&!Object.prototype.hasOwnProperty.call(t,r)&&K$t(t,e,r)},W$t=_c&&_c.__importStar||function(){var e=function(t){return e=Object.getOwnPropertyNames||function(r){var n=[];for(var i in r)Object.prototype.hasOwnProperty.call(r,i)&&(n[n.length]=i);return n},e(t)};return function(t){if(t&&t.__esModule)return t;var r={};if(t!=null)for(var n=e(t),i=0;i<n.length;i++)n[i]!=="default"&&K$t(r,t,n[i]);return KNn(r,t),r}}();Object.defineProperty(_c,"__esModule",{value:!0});_c.v4=_c.v2=void 0;Y$t(lLt(),_c);Y$t(gLt(),_c);_c.v2=W$t(Vkt());_c.v4=W$t(G$t())});var NX=y(Bm=>{"use strict";Object.defineProperty(Bm,"__esModule",{value:!0});Bm.TermApplicability=Bm.CDS_VOCABULARY_ALIAS=Bm.CDS_VOCABULARY_NAMESPACE=Bm.ENUM_VALUE_KIND=void 0;Bm.ENUM_VALUE_KIND="Member";Bm.CDS_VOCABULARY_NAMESPACE="com.sap.vocabularies.CDS.v1";Bm.CDS_VOCABULARY_ALIAS="CDS";var Q2t;(function(e){e[e.Applicable=0]="Applicable",e[e.TermNotApplicable=1]="TermNotApplicable",e[e.TypeNotApplicable=2]="TypeNotApplicable",e[e.UnknownTerm=3]="UnknownTerm",e[e.UnknownVocabulary=4]="UnknownVocabulary",e[e.UnSupportedVocabulary=5]="UnSupportedVocabulary",e[e.NotInApplicableTermsConstraint=6]="NotInApplicableTermsConstraint"})(Q2t||(Bm.TermApplicability=Q2t={}))});var tMt=y(mn=>{"use strict";Object.defineProperty(mn,"__esModule",{value:!0});mn.GHOST_FILENAME_PREFIX=mn.ANNOTATION_FILE_TYPE=mn.TARGET_TYPE=mn.NAMESPACE_TYPE=mn.REFERENCE_TYPE=mn.EDM_NAMESPACE_ALIAS=mn.EDMX_NAMESPACE_ALIAS=mn.ELEMENT_TYPE=mn.MultilineType=mn.TEXT_TYPE=mn.ATTRIBUTE_TYPE=void 0;mn.createAttributeNode=$In;mn.createTextNode=MIn;mn.createElementNode=FIn;mn.createTarget=jIn;mn.createNamespace=qIn;mn.createReference=VIn;mn.ATTRIBUTE_TYPE="attribute";mn.TEXT_TYPE="text";var eMt;(function(e){e.StripIndentation="StripIndentation",e.KeepIndentation="KeepIndentation"})(eMt||(mn.MultilineType=eMt={}));mn.ELEMENT_TYPE="element";mn.EDMX_NAMESPACE_ALIAS="Edmx";mn.EDM_NAMESPACE_ALIAS="Edm";mn.REFERENCE_TYPE="reference";mn.NAMESPACE_TYPE="namespace";mn.TARGET_TYPE="target";mn.ANNOTATION_FILE_TYPE="annotation-file";function $In(e,t,r,n){let i={type:mn.ATTRIBUTE_TYPE,name:e,value:t};return r&&(i.nameRange=r),n&&(i.valueRange=n),i}function MIn(e,t,r,n){let i={type:mn.TEXT_TYPE,text:e};return t&&(i.range=t),r&&(i.fragmentRanges=r),n&&(i.multilineType=n),i}function FIn({name:e,range:t,nameRange:r,attributes:n,content:i,contentRange:a,namespace:o,namespaceAlias:s}){let c={type:mn.ELEMENT_TYPE,name:e,attributes:n??{},content:i??[]};return t&&(c.range=t),r&&(c.nameRange=r),a&&(c.contentRange=a),o&&(c.namespace=o),s&&(c.namespaceAlias=s),c}mn.GHOST_FILENAME_PREFIX="!";function jIn(e){return{type:"target",name:e,terms:[],range:void 0,nameRange:void 0,termsRange:void 0}}function qIn(e,t,r){let{aliasRange:n,contentRange:i,nameRange:a,range:o}=r??{};return{type:"namespace",name:e,alias:t,range:o,nameRange:a,aliasRange:n,contentRange:i}}function VIn(e,t,r,n){let{aliasRange:i,uriRange:a,nameRange:o,range:s}=n??{};return{type:"reference",name:e,alias:t,uri:r,range:s,nameRange:o,aliasRange:i,uriRange:a}}});var rMt=y($r=>{"use strict";Object.defineProperty($r,"__esModule",{value:!0});$r.cacheKeyAnyTermName=$r.COLLECTION_KIND=$r.ASSOCIATION_SET_KIND=$r.FUNCTION_IMPORT_KIND=$r.ACTION_IMPORT_KIND=$r.SINGLETON_KIND=$r.ENTITY_SET_KIND=$r.NAVIGATION_PROPERTY_KIND=$r.PROPERTY_KIND=$r.ENTITY_CONTAINER_KIND=$r.ASSOCIATION_KIND=$r.FUNCTION_KIND=$r.ACTION_KIND=$r.ENTITY_TYPE_KIND=$r.TERM_KIND=$r.COMPLEX_TYPE_KIND=$r.ENUM_TYPE_KIND=$r.TYPE_DEFINITION_KIND=void 0;$r.TYPE_DEFINITION_KIND="TypeDefinition";$r.ENUM_TYPE_KIND="EnumType";$r.COMPLEX_TYPE_KIND="ComplexType";$r.TERM_KIND="Term";$r.ENTITY_TYPE_KIND="EntityType";$r.ACTION_KIND="Action";$r.FUNCTION_KIND="Function";$r.ASSOCIATION_KIND="Association";$r.ENTITY_CONTAINER_KIND="EntityContainer";$r.PROPERTY_KIND="Property";$r.NAVIGATION_PROPERTY_KIND="NavigationProperty";$r.ENTITY_SET_KIND="EntitySet";$r.SINGLETON_KIND="Singleton";$r.ACTION_IMPORT_KIND="ActionImport";$r.FUNCTION_IMPORT_KIND="FunctionImport";$r.ASSOCIATION_SET_KIND="AssociationSet";$r.COLLECTION_KIND="Collection";$r.cacheKeyAnyTermName="Impl.AnyTerm"});var aMt=y(xD=>{"use strict";Object.defineProperty(xD,"__esModule",{value:!0});xD.EdmType=xD.Edm=void 0;var nMt;(function(e){e.Action="Action",e.ActionImport="ActionImport",e.Add="Add",e.Alias="Alias",e.And="And",e.Annotation="Annotation",e.Annotations="Annotations",e.AnnotationPath="AnnotationPath",e.Association="Association",e.AssociationSet="AssociationSet",e.Apply="Apply",e.Binary="Binary",e.Bool="Bool",e.Cast="Cast",e.Collection="Collection",e.ComplexType="ComplexType",e.Date="Date",e.DateTimeOffset="DateTimeOffset",e.Decimal="Decimal",e.DefaultValue="DefaultValue",e.Div="Div",e.Duration="Duration",e.EntityContainer="EntityContainer",e.EntitySet="EntitySet",e.EntityType="EntityType",e.EnumMember="EnumMember",e.EnumType="EnumType",e.Eq="Eq",e.Float="Float",e.Function="Function",e.FunctionImport="FunctionImport",e.Ge="Ge",e.Gt="Gt",e.Guid="Guid",e.If="If",e.In="In",e.Include="Include",e.Int="Int",e.IsOf="IsOf",e.LabeledElement="LabeledElement",e.Le="Le",e.Lt="Lt",e.MaxLength="MaxLength",e.Member="Member",e.ModelElementPath="ModelElementPath",e.Mul="Mul",e.Name="Name",e.Namespace="Namespace",e.NavigationProperty="NavigationProperty",e.NavigationPropertyPath="NavigationPropertyPath",e.Ne="Ne",e.Neg="Neg",e.Not="Not",e.Null="Null",e.Nullable="Nullable",e.OnDelete="OnDelete",e.Parameter="Parameter",e.Path="Path",e.Precision="Precision",e.Property="Property",e.PropertyPath="PropertyPath",e.PropertyValue="PropertyValue",e.Or="Or",e.Qualifier="Qualifier",e.Record="Record",e.Reference="Reference",e.ReferentialConstraint="ReferentialConstraint",e.ReferencedProperty="ReferencedProperty",e.ReturnType="ReturnType",e.Scale="Scale",e.Schema="Schema",e.Singleton="Singleton",e.SRID="SRID",e.String="String",e.Sub="Sub",e.Target="Target",e.Term="Term",e.TimeOfDay="TimeOfDay",e.Type="Type",e.TypeDefinition="TypeDefinition",e.Unicode="Unicode",e.UrlRef="UrlRef"})(nMt||(xD.Edm=nMt={}));var iMt;(function(e){e.Binary="Edm.Binary",e.Boolean="Edm.Boolean",e.Byte="Edm.Byte",e.Date="Edm.Date",e.DateTimeOffset="Edm.DateTimeOffset",e.Decimal="Edm.Decimal",e.Double="Edm.Double",e.Duration="Edm.Duration",e.Guid="Edm.Guid",e.Int16="Edm.Int16",e.Int32="Edm.Int32",e.Int64="Edm.Int64",e.SByte="Edm.SByte",e.Single="Edm.Single",e.Stream="Edm.Stream",e.String="Edm.String",e.TimeOfDay="Edm.TimeOfDay",e.PrimitiveType="Edm.PrimitiveType",e.ComplexType="Edm.ComplexType",e.EntityType="Edm.EntityType",e.Untyped="Edm.Untyped",e.EntityTypeCollection="Edm.EntityTypeCollection",e.NonEntityTypeCollection="Edm.NonEntityTypeCollection",e.AnnotationPath="Edm.AnnotationPath",e.AnyPropertyPath="Edm.AnyPropertyPath",e.ModelElementPath="Edm.ModelElementPath",e.NavigationPropertyPath="Edm.NavigationPropertyPath",e.PropertyPath="Edm.PropertyPath",e.VirtualProperty="Edm.VirtualProperty",e.PrimitiveCollection="Edm.PrimitiveCollection",e.DataModelEnum="Edm.DataModelEnum"})(iMt||(xD.EdmType=iMt={}))});var uMt=y($f=>{"use strict";Object.defineProperty($f,"__esModule",{value:!0});$f.EDMX_ELEMENT_NAMES=$f.EdmxIncludeElementAttributeName=$f.EdmxReferenceElementAttributeName=$f.EdmxElementName=$f.Edmx=void 0;var oMt;(function(e){e.Alias="Alias",e.DataServices="DataServices",e.Edmx="Edmx",e.Import="Import",e.Include="Include",e.Namespace="Namespace",e.Reference="Reference",e.Uri="Uri",e.Version="Version"})(oMt||($f.Edmx=oMt={}));var $O;(function(e){e.DataServices="DataServices",e.Edmx="Edmx",e.Include="Include",e.IncludeAnnotations="IncludeAnnotations",e.Reference="Reference"})($O||($f.EdmxElementName=$O={}));var sMt;(function(e){e.Uri="Uri"})(sMt||($f.EdmxReferenceElementAttributeName=sMt={}));var cMt;(function(e){e.Alias="Alias",e.Namespace="Namespace"})(cMt||($f.EdmxIncludeElementAttributeName=cMt={}));$f.EDMX_ELEMENT_NAMES=new Set([$O.DataServices,$O.Edmx,$O.Include,$O.IncludeAnnotations,$O.Reference])});var lMt=y(TD=>{"use strict";Object.defineProperty(TD,"__esModule",{value:!0});TD.printOptions=TD.wrapInQuotes=void 0;var UIn=e=>`'${e}'`;TD.wrapInQuotes=UIn;TD.printOptions={printWidth:300,tabWidth:4,useTabs:!1,useSnippetSyntax:!0}});var fMt=y(pMt=>{"use strict";Object.defineProperty(pMt,"__esModule",{value:!0})});var dMt=y(gt=>{"use strict";Object.defineProperty(gt,"__esModule",{value:!0});gt.DEPRECATED_$VALUE_SYNTAX=gt.INVALID_PRIMITIVE_TYPE=gt.ODATA_PATH_SEPARATOR_RULE=gt.COMMON_CASE_ISSUE=gt.INCOMPLETE_PATH_WITH_COMPATIBLE_TYPES=gt.INCOMPLETE_PATH_WITH_TYPE=gt.NO_VALIDATION_FOR_SUBNODES=gt.INVALID_TYPE_TYPE=gt.INVALID_ENUM_MEMBER_TYPE=gt.INVALID_PATH_EXPRESSION=gt.IGNORE_DUPLICATE=gt.ODATA_FUNCTION_WRONG_RETURN_TYPE=gt.RECORD_COLLECTION_PATH_NOT_ALLOWED=gt.NOT_IN_APPLICABLE_TERMS_CONSTRAINT=gt.TERM_NOT_APPLICABLE=gt.MISSING_REQUIRED_VALUE_FOR_ATTRIBUTE=gt.MISSING_REQUIRED_ATTRIBUTE=gt.MISSING_REQUIRED_PROPERTY=gt.ATTRIBUTE_NOT_ALLOWED_HERE=gt.UN_SUPPORTED_VOCABULARY=gt.UNKNOWN_TERM=gt.IGNORE_TARGET_VALIDATION=gt.INCOMPLETE_EXPRESSION_FORWARD_SLASH=gt.INCOMPLETE_EXPRESSION_CC_FORWARD_SLASH=gt.NO_WHITESPACE_IN_PATH_EXPRESSION=gt.VALUE_REQUIRED=gt.MISSING_I18N_KEY=gt.NAME_CASE_ISSUE_PATH_VALUE=gt.NO_UNDEFINED_NAMESPACE_TYPE=gt.NO_UNUSED_NAMESPACE_TYPE=void 0;gt.NO_UNUSED_NAMESPACE_TYPE="no-unused-namespace";gt.NO_UNDEFINED_NAMESPACE_TYPE="no-undefined-namespace";gt.NAME_CASE_ISSUE_PATH_VALUE="name-case-issue-path-value";gt.MISSING_I18N_KEY="missing-i18n-key";gt.VALUE_REQUIRED="value-required";gt.NO_WHITESPACE_IN_PATH_EXPRESSION="no-whitespace-in-path-expression";gt.INCOMPLETE_EXPRESSION_CC_FORWARD_SLASH="incomplete-expression-cc-forward-slash";gt.INCOMPLETE_EXPRESSION_FORWARD_SLASH="incomplete-expression-forward-slash";gt.IGNORE_TARGET_VALIDATION="ignore-target-validation";gt.UNKNOWN_TERM="unknown-term";gt.UN_SUPPORTED_VOCABULARY="un-supported-vocabulary";gt.ATTRIBUTE_NOT_ALLOWED_HERE="attribute-not-allowed-here";gt.MISSING_REQUIRED_PROPERTY="missing-required-property";gt.MISSING_REQUIRED_ATTRIBUTE="missing-required-attribute";gt.MISSING_REQUIRED_VALUE_FOR_ATTRIBUTE="missing-required-value-for-attribute";gt.TERM_NOT_APPLICABLE="term-not-applicable";gt.NOT_IN_APPLICABLE_TERMS_CONSTRAINT="not-in-applicable-terms-constraint";gt.RECORD_COLLECTION_PATH_NOT_ALLOWED="record-collection-path-not-allowed";gt.ODATA_FUNCTION_WRONG_RETURN_TYPE="odata-function-wrong-return-type";gt.IGNORE_DUPLICATE="ignore-duplicate";gt.INVALID_PATH_EXPRESSION="invlid-path-expression";gt.INVALID_ENUM_MEMBER_TYPE="unknown-enum-member";gt.INVALID_TYPE_TYPE="invalid-type";gt.NO_VALIDATION_FOR_SUBNODES="no-validation-subnodes";gt.INCOMPLETE_PATH_WITH_TYPE="incomplete-path-with-type";gt.INCOMPLETE_PATH_WITH_COMPATIBLE_TYPES="incomplete-path-with-compatible-types";gt.COMMON_CASE_ISSUE="common-case-issue";gt.ODATA_PATH_SEPARATOR_RULE="no-odata-path-separator";gt.INVALID_PRIMITIVE_TYPE="invalid-primitive-type";gt.DEPRECATED_$VALUE_SYNTAX="deprecated-$value-syntax"});var mMt=y(hMt=>{"use strict";Object.defineProperty(hMt,"__esModule",{value:!0})});var gMt=y(MO=>{"use strict";var BIn=MO&&MO.__createBinding||(Object.create?function(e,t,r,n){n===void 0&&(n=r);var i=Object.getOwnPropertyDescriptor(t,r);(!i||("get"in i?!t.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,i)}:function(e,t,r,n){n===void 0&&(n=r),e[n]=t[r]}),zIn=MO&&MO.__exportStar||function(e,t){for(var r in e)r!=="default"&&!Object.prototype.hasOwnProperty.call(t,r)&&BIn(t,e,r)};Object.defineProperty(MO,"__esModule",{value:!0});zIn(mMt(),MO)});var yMt=y(ts=>{"use strict";Object.defineProperty(ts,"__esModule",{value:!0});ts.WorkspaceEdit=ts.TextEdit=ts.DiagnosticSeverity=ts.DiagnosticTag=ts.Diagnostic=ts.Position=ts.Range=ts.Location=void 0;var IE=lc();Object.defineProperty(ts,"Location",{enumerable:!0,get:function(){return IE.Location}});Object.defineProperty(ts,"Range",{enumerable:!0,get:function(){return IE.Range}});Object.defineProperty(ts,"Position",{enumerable:!0,get:function(){return IE.Position}});Object.defineProperty(ts,"Diagnostic",{enumerable:!0,get:function(){return IE.Diagnostic}});Object.defineProperty(ts,"DiagnosticTag",{enumerable:!0,get:function(){return IE.DiagnosticTag}});Object.defineProperty(ts,"DiagnosticSeverity",{enumerable:!0,get:function(){return IE.DiagnosticSeverity}});Object.defineProperty(ts,"TextEdit",{enumerable:!0,get:function(){return IE.TextEdit}});Object.defineProperty(ts,"WorkspaceEdit",{enumerable:!0,get:function(){return IE.WorkspaceEdit}})});var Ht=y($n=>{"use strict";var HIn=$n&&$n.__createBinding||(Object.create?function(e,t,r,n){n===void 0&&(n=r);var i=Object.getOwnPropertyDescriptor(t,r);(!i||("get"in i?!t.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,i)}:function(e,t,r,n){n===void 0&&(n=r),e[n]=t[r]}),RE=$n&&$n.__exportStar||function(e,t){for(var r in e)r!=="default"&&!Object.prototype.hasOwnProperty.call(t,r)&&HIn(t,e,r)};Object.defineProperty($n,"__esModule",{value:!0});$n.WorkspaceEdit=$n.TextEdit=$n.DiagnosticTag=$n.DiagnosticSeverity=$n.Diagnostic=$n.Position=$n.Range=$n.Location=void 0;RE(tMt(),$n);RE(rMt(),$n);RE(aMt(),$n);RE(uMt(),$n);RE(lMt(),$n);RE(fMt(),$n);RE(dMt(),$n);RE(gMt(),$n);var LE=yMt();Object.defineProperty($n,"Location",{enumerable:!0,get:function(){return LE.Location}});Object.defineProperty($n,"Range",{enumerable:!0,get:function(){return LE.Range}});Object.defineProperty($n,"Position",{enumerable:!0,get:function(){return LE.Position}});Object.defineProperty($n,"Diagnostic",{enumerable:!0,get:function(){return LE.Diagnostic}});Object.defineProperty($n,"DiagnosticSeverity",{enumerable:!0,get:function(){return LE.DiagnosticSeverity}});Object.defineProperty($n,"DiagnosticTag",{enumerable:!0,get:function(){return LE.DiagnosticTag}});Object.defineProperty($n,"TextEdit",{enumerable:!0,get:function(){return LE.TextEdit}});Object.defineProperty($n,"WorkspaceEdit",{enumerable:!0,get:function(){return LE.WorkspaceEdit}})});var vMt=y(nwe=>{"use strict";Object.defineProperty(nwe,"__esModule",{value:!0});nwe.default={$Version:"4.01",$Reference:{"https://oasis-tcs.github.io/odata-vocabularies/vocabularies/Org.OData.Core.V1.json":{$Include:[{$Namespace:"Org.OData.Core.V1",$Alias:"Core"}]},"https://oasis-tcs.github.io/odata-vocabularies/vocabularies/Org.OData.Validation.V1.json":{$Include:[{$Namespace:"Org.OData.Validation.V1",$Alias:"Validation"}]},"https://oasis-tcs.github.io/odata-vocabularies/vocabularies/Org.OData.Capabilities.V1.json":{$Include:[{$Namespace:"Org.OData.Capabilities.V1",$Alias:"Capabilities"}]}},"Org.OData.Aggregation.V1":{$Alias:"Aggregation","@Org.OData.Core.V1.Description":"Terms to describe which data in a given entity model can be aggregated, and how.","@Org.OData.Core.V1.LongDescription":"Related to the specification document [OData-Data-Agg-v4.0](http://docs.oasis-open.org/odata/odata-data-aggregation-ext/v4.0/odata-data-aggregation-ext-v4.0.html).","@Org.OData.Core.V1.Links":[{rel:"alternate",href:"https://oasis-tcs.github.io/odata-vocabularies/vocabularies/Org.OData.Aggregation.V1.xml"},{rel:"latest-version",href:"https://oasis-tcs.github.io/odata-vocabularies/vocabularies/Org.OData.Aggregation.V1.json"},{rel:"describedby",href:"https://github.com/oasis-tcs/odata-vocabularies/blob/main/vocabularies/Org.OData.Aggregation.V1.md"}],ApplySupported:{$Kind:"Term",$Type:"Org.OData.Aggregation.V1.ApplySupportedType",$AppliesTo:["EntitySet","Collection","EntityType"],"@Org.OData.Core.V1.AppliesViaContainer":!0,"@Org.OData.Core.V1.Description":"This entity set or collection supports the `$apply` system query option"},ApplySupportedDefaults:{$Kind:"Term",$Type:"Org.OData.Aggregation.V1.ApplySupportedBase",$AppliesTo:["EntityContainer"],"@Org.OData.Core.V1.Description":"Default support of the `$apply` system query option for all collection-valued resources in the container","@Org.OData.Core.V1.LongDescription":"Annotating term [`ApplySupported`](#ApplySupported) for a specific collection-valued resource overrides the default support with the specified properties using PATCH semantics:\n- Primitive or collection-valued properties specified in `ApplySupported` replace the corresponding properties specified in `ApplySupportedDefaults`\n- Complex-valued properties specified in `ApplySupported` override the corresponding properties specified in `ApplySupportedDefaults` using PATCH semantics recursively\n- Properties specified neither in `ApplySupported` nor in `ApplySupportedDefaults` have their default value"},ApplySupportedBase:{$Kind:"ComplexType","@Org.OData.Core.V1.LongDescription":"Services that do not fully implement a certain aggregation-related functionality may document\n this by annotating the [`ApplySupported`](#ApplySupported) or [`ApplySupportedDefaults`](#ApplySupportedDefaults)\n annotation with a description.",Transformations:{$Collection:!0,$Type:"Org.OData.Aggregation.V1.Transformation","@Org.OData.Core.V1.Description":"Transformations that can be used in `$apply`"},CustomAggregationMethods:{$Collection:!0,"@Org.OData.Core.V1.Description":"Qualified names of custom aggregation methods that can be used in `aggregate(...with...)`"},Rollup:{$Type:"Org.OData.Aggregation.V1.RollupType",$DefaultValue:"None","@Org.OData.Core.V1.Description":"The service supports rollup hierarchies in a `groupby` transformation"},From:{$Type:"Edm.Boolean",$DefaultValue:!1,"@Org.OData.Core.V1.Description":"The service supports the `from` keyword in an `aggregate` transformation"}},ApplySupportedType:{$Kind:"ComplexType",$BaseType:"Org.OData.Aggregation.V1.ApplySupportedBase",PropertyRestrictions:{$Type:"Edm.Boolean",$DefaultValue:!1,"@Org.OData.Core.V1.Revisions":[{Kind:"Deprecated",Description:"Deprecated since [`Groupable`](#Groupable) and [`Aggregatable`](#Aggregatable) are deprecated"}],"@Org.OData.Core.V1.Description":"Only properties marked as `Groupable` can be used in the `groupby` transformation, and only those marked as `Aggregatable` can be used in the `aggregate` transformation"},GroupableProperties:{$Collection:!0,$Type:"Edm.AnyPropertyPath","@Org.OData.Core.V1.Description":"A non-empty collection indicates that only the listed properties of the annotated target are supported by the `groupby` transformation"},AggregatableProperties:{$Collection:!0,$Type:"Org.OData.Aggregation.V1.AggregatablePropertyType","@Org.OData.Core.V1.Description":"A non-empty collection indicates that only the listed properties of the annotated target can be used in the `aggregate` transformation, optionally restricted to the specified aggregation methods"}},AggregatablePropertyType:{$Kind:"ComplexType",Property:{$Type:"Edm.PropertyPath","@Org.OData.Core.V1.Description":"Aggregatable property"},SupportedAggregationMethods:{$Collection:!0,$Type:"Org.OData.Aggregation.V1.AggregationMethod","@Org.OData.Core.V1.Description":"Standard and custom aggregation methods that can be applied to the property. If omitted, all aggregation methods can be applied"},RecommendedAggregationMethod:{$Type:"Org.OData.Aggregation.V1.AggregationMethod",$Nullable:!0,"@Org.OData.Core.V1.Description":"Recommended method for aggregating values of the property"}},Transformation:{$Kind:"TypeDefinition",$UnderlyingType:"Edm.String","@Org.OData.Core.V1.Description":"A transformation that can be used in `$apply`","@Org.OData.Validation.V1.AllowedValues":[{Value:"aggregate","@Org.OData.Core.V1.Description":"OData-Data-Agg-v4.0, section 3.2.1"},{Value:"groupby","@Org.OData.Core.V1.Description":"OData-Data-Agg-v4.0, section 3.2.3"},{Value:"concat","@Org.OData.Core.V1.Description":"OData-Data-Agg-v4.0, section 3.2.2"},{Value:"identity","@Org.OData.Core.V1.Description":"OData-Data-Agg-v4.0, section 3.4.1"},{Value:"filter","@Org.OData.Core.V1.Description":"OData-Data-Agg-v4.0, section 3.3.2"},{Value:"search","@Org.OData.Core.V1.Description":"OData-Data-Agg-v4.0, section 3.3.4"},{Value:"nest","@Org.OData.Core.V1.Description":"OData-Data-Agg-v4.0, section 3.5.2"},{Value:"addnested","@Org.OData.Core.V1.Description":"OData-Data-Agg-v4.0, section 3.4.3"},{Value:"join","@Org.OData.Core.V1.Description":"OData-Data-Agg-v4.0, section 3.5.1"},{Value:"outerjoin","@Org.OData.Core.V1.Description":"OData-Data-Agg-v4.0, section 3.5.1"},{Value:"compute","@Org.OData.Core.V1.Description":"OData-Data-Agg-v4.0, section 3.4.2"},{Value:"bottomcount","@Org.OData.Core.V1.Description":"OData-Data-Agg-v4.0, section 3.3.1.1"},{Value:"bottomsum","@Org.OData.Core.V1.Description":"OData-Data-Agg-v4.0, section 3.3.1.3"},{Value:"bottompercent","@Org.OData.Core.V1.Description":"OData-Data-Agg-v4.0, section 3.3.1.2"},{Value:"topcount","@Org.OData.Core.V1.Description":"OData-Data-Agg-v4.0, section 3.3.1.1"},{Value:"topsum","@Org.OData.Core.V1.Description":"OData-Data-Agg-v4.0, section 3.3.1.3"},{Value:"toppercent","@Org.OData.Core.V1.Description":"OData-Data-Agg-v4.0, section 3.3.1.2"},{Value:"orderby","@Org.OData.Core.V1.Description":"OData-Data-Agg-v4.0, section 3.3.3"},{Value:"top","@Org.OData.Core.V1.Description":"OData-Data-Agg-v4.0, section 3.3.6"},{Value:"skip","@Org.OData.Core.V1.Description":"OData-Data-Agg-v4.0, section 3.3.5"},{Value:"ancestors","@Org.OData.Core.V1.Description":"OData-Data-Agg-v4.0, section 6.2.1"},{Value:"descendants","@Org.OData.Core.V1.Description":"OData-Data-Agg-v4.0, section 6.2.1"},{Value:"traverse","@Org.OData.Core.V1.Description":"OData-Data-Agg-v4.0, section 6.2.2"}]},AggregationMethod:{$Kind:"TypeDefinition",$UnderlyingType:"Edm.String","@Org.OData.Core.V1.Description":"Standard or custom aggregation method","@Org.OData.Core.V1.LongDescription":"Custom aggregation methods MUST use a namespace-qualified name, that is contain at least one dot. ","@Org.OData.Validation.V1.AllowedValues":[{Value:"sum","@Org.OData.Core.V1.Description":"Can be applied to numeric values to return the sum of the non-null values, or null if there are no non-null values or the input set is empty"},{Value:"min","@Org.OData.Core.V1.Description":"Can be applied to values with a totally ordered domain to return the smallest of the non-null values, or null if there are no non-null values or the input set is empty"},{Value:"max","@Org.OData.Core.V1.Description":"Can be applied to values with a totally ordered domain to return the largest of the non-null values, or null if there are no non-null values or the input set is empty"},{Value:"average","@Org.OData.Core.V1.Description":"Can be applied to numeric values to return the sum of the non-null values divided by the count of the non-null values, or null if there are no non-null values or the input set is empty"},{Value:"countdistinct","@Org.OData.Core.V1.Description":"Counts the distinct values, omitting any null values","@Org.OData.Core.V1.LongDescription":`For navigation properties, it counts the distinct entities in the union of all entities related to entities in the input set.
|
|
428
428
|
For collection-valued primitive properties, it counts the distinct items in the union of all collection values in the input set.`}]},RollupType:{$Kind:"EnumType","@Org.OData.Core.V1.Description":"The number of `rollup` or `rolluprecursive` operators allowed in a `groupby` transformation",None:0,"None@Org.OData.Core.V1.Description":"No support for `rollup` or `rolluprecursive`",SingleHierarchy:1,"SingleHierarchy@Org.OData.Core.V1.Description":"Only one `rollup` or `rolluprecursive` operator per `groupby`",MultipleHierarchies:2,"MultipleHierarchies@Org.OData.Core.V1.Description":"Full support for `rollup` and `rolluprecursive`"},Groupable:{$Kind:"Term",$Type:"Org.OData.Core.V1.Tag",$DefaultValue:!0,$AppliesTo:["Property","NavigationProperty"],"@Org.OData.Core.V1.Revisions":[{Kind:"Deprecated",Description:"Deprecated in favor of [`ApplySupported/GroupableProperties`](#ApplySupported)"}],"@Org.OData.Core.V1.Description":"This property can be used in the `groupby` transformation"},Aggregatable:{$Kind:"Term",$Type:"Org.OData.Core.V1.Tag",$DefaultValue:!0,$AppliesTo:["Property","NavigationProperty"],"@Org.OData.Core.V1.Revisions":[{Kind:"Deprecated",Description:"Deprecated in favor of [`ApplySupported/AggregatableProperties`](#ApplySupported)"}],"@Org.OData.Core.V1.Description":"This property can be used in the `aggregate` transformation"},CustomAggregate:{$Kind:"Term",$AppliesTo:["EntitySet","Collection","EntityContainer","EntityType"],"@Org.OData.Core.V1.AppliesViaContainer":!0,"@Org.OData.Core.V1.Description":"Dynamic property that can be used in the `aggregate` transformation","@Org.OData.Core.V1.LongDescription":"This term MUST be applied with a Qualifier, the Qualifier value is the name of the dynamic property. The value of the annotation MUST be the qualified name of a primitive type. The aggregated value will be of that type."},ContextDefiningProperties:{$Kind:"Term",$Collection:!0,$Type:"Edm.PropertyPath",$AppliesTo:["Property","Annotation"],"@Org.OData.Core.V1.Description":"The annotated property or custom aggregate is only well-defined in the context of these properties","@Org.OData.Core.V1.LongDescription":"The context-defining properties need either be part of the result entities, or be restricted to a single value by a pre-filter operation. Examples are postal codes within a country, or monetary amounts whose context is the unit of currency."},LeveledHierarchy:{$Kind:"Term",$Collection:!0,$Type:"Edm.PropertyPath",$AppliesTo:["EntityType","ComplexType"],"@Org.OData.Core.V1.Description":"Defines a leveled hierarchy (OData-Data-Agg-v4.0, section 5.5.1)"},RecursiveHierarchy:{$Kind:"Term",$Type:"Org.OData.Aggregation.V1.RecursiveHierarchyType",$AppliesTo:["EntityType"],"@Org.OData.Core.V1.Description":"Defines a recursive hierarchy (OData-Data-Agg-v4.0, section 5.5.2)"},RecursiveHierarchyType:{$Kind:"ComplexType",NodeProperty:{$Type:"Edm.PropertyPath","@Org.OData.Core.V1.Description":"Primitive property holding the node identifier"},ParentNavigationProperty:{$Type:"Edm.NavigationPropertyPath","@Org.OData.Core.V1.Description":"Property for navigating to the parent node(s). Its type MUST be the entity type annotated with this term, and it MUST be collection-valued or nullable single-valued."}},HierarchyQualifier:{$Kind:"TypeDefinition",$UnderlyingType:"Edm.String","@Org.OData.Core.V1.Description":"Qualifier of a [`RecursiveHierarchy`](#RecursiveHierarchy) annotation","@Org.OData.Core.V1.LongDescription":"Every recursive hierarchy function defined in this vocabulary has\n- a parameter `HierarchyQualifier` of this type and\n- a parameter `HierarchyNodes` that is a collection of entities of a common type without multiple occurrences of the same entity.\n\n`HierarchyQualifier` is the qualifier of a `RecursiveHierarchy` annotation on the entity type of the collection\ngiven by the `HierarchyNodes` parameter. This specifies a recursive hierarchy that is evaluated by the function."},isnode:[{$Kind:"Function","@Org.OData.Core.V1.Description":"Is the entity a node of the hierarchy specified by the [parameter pair](#HierarchyQualifier) (`HierarchyNodes`, `HierarchyQualifier`)? (See OData-Data-Agg-v4.0, section 5.5.2.1)","@Org.OData.Core.V1.LongDescription":"If a node identifier passed to the function is null, the function returns null.",$Parameter:[{$Name:"HierarchyNodes",$Collection:!0,$Type:"Edm.EntityType","@Org.OData.Core.V1.Description":"A collection, given through a `$root` expression"},{$Name:"HierarchyQualifier",$Type:"Org.OData.Aggregation.V1.HierarchyQualifier"},{$Name:"Node",$Type:"Edm.PrimitiveType",$Nullable:!0,"@Org.OData.Core.V1.Description":"Node identifier of the putative node"}],$ReturnType:{$Type:"Edm.Boolean",$Nullable:!0}}],isroot:[{$Kind:"Function","@Org.OData.Core.V1.Description":"Is the entity a root node of the hierarchy specified by the [parameter pair](#HierarchyQualifier) (`HierarchyNodes`, `HierarchyQualifier`)?","@Org.OData.Core.V1.LongDescription":"If a node identifier passed to the function is null, the function returns null.",$Parameter:[{$Name:"HierarchyNodes",$Collection:!0,$Type:"Edm.EntityType","@Org.OData.Core.V1.Description":"A collection, given through a `$root` expression"},{$Name:"HierarchyQualifier",$Type:"Org.OData.Aggregation.V1.HierarchyQualifier"},{$Name:"Node",$Type:"Edm.PrimitiveType",$Nullable:!0,"@Org.OData.Core.V1.Description":"Node identifier of the putative root"}],$ReturnType:{$Type:"Edm.Boolean",$Nullable:!0}}],isdescendant:[{$Kind:"Function","@Org.OData.Core.V1.Description":"Is the entity a descendant node of the ancestor node in the hierarchy specified by the [parameter pair](#HierarchyQualifier) (`HierarchyNodes`, `HierarchyQualifier`) with at most the specified distance? (See OData-Data-Agg-v4.0, section 5.5.2.1)","@Org.OData.Core.V1.LongDescription":"If a node identifier passed to the function is null, the function returns null.",$Parameter:[{$Name:"HierarchyNodes",$Collection:!0,$Type:"Edm.EntityType","@Org.OData.Core.V1.Description":"A collection, given through a `$root` expression"},{$Name:"HierarchyQualifier",$Type:"Org.OData.Aggregation.V1.HierarchyQualifier"},{$Name:"Node",$Type:"Edm.PrimitiveType",$Nullable:!0,"@Org.OData.Core.V1.Description":"Node identifier of the putative descendant"},{$Name:"Ancestor",$Type:"Edm.PrimitiveType",$Nullable:!0,"@Org.OData.Core.V1.Description":"Node identifier of the ancestor node"},{$Name:"MaxDistance",$Type:"Edm.Int16","@Org.OData.Core.V1.OptionalParameter":{DefaultValue:"32767"},"@Org.OData.Validation.V1.Minimum":1},{$Name:"IncludeSelf",$Type:"Edm.Boolean","@Org.OData.Core.V1.Description":"Whether to include the node itself in the result","@Org.OData.Core.V1.OptionalParameter":{DefaultValue:"false"}}],$ReturnType:{$Type:"Edm.Boolean",$Nullable:!0}}],isancestor:[{$Kind:"Function","@Org.OData.Core.V1.Description":"Is the entity an ancestor node of the descendant node in the hierarchy specified by the [parameter pair](#HierarchyQualifier) (`HierarchyNodes`, `HierarchyQualifier`) with at most the specified distance? (See OData-Data-Agg-v4.0, section 5.5.2.1)","@Org.OData.Core.V1.LongDescription":"If a node identifier passed to the function is null, the function returns null.",$Parameter:[{$Name:"HierarchyNodes",$Collection:!0,$Type:"Edm.EntityType","@Org.OData.Core.V1.Description":"A collection, given through a `$root` expression"},{$Name:"HierarchyQualifier",$Type:"Org.OData.Aggregation.V1.HierarchyQualifier"},{$Name:"Node",$Type:"Edm.PrimitiveType",$Nullable:!0,"@Org.OData.Core.V1.Description":"Node identifier of the putative ancestor"},{$Name:"Descendant",$Type:"Edm.PrimitiveType",$Nullable:!0,"@Org.OData.Core.V1.Description":"Node identifier of the descendant node"},{$Name:"MaxDistance",$Type:"Edm.Int16","@Org.OData.Core.V1.OptionalParameter":{DefaultValue:"32767"},"@Org.OData.Validation.V1.Minimum":1},{$Name:"IncludeSelf",$Type:"Edm.Boolean","@Org.OData.Core.V1.Description":"Whether to include the node itself in the result","@Org.OData.Core.V1.OptionalParameter":{DefaultValue:"false"}}],$ReturnType:{$Type:"Edm.Boolean",$Nullable:!0}}],issibling:[{$Kind:"Function","@Org.OData.Core.V1.Description":"Is the entity a sibling node of the other node in the hierarchy specified by the [parameter pair](#HierarchyQualifier) (`HierarchyNodes`, `HierarchyQualifier`)? (See OData-Data-Agg-v4.0, section 5.5.2.1)","@Org.OData.Core.V1.LongDescription":"A node is not a sibling of itself. If a node identifier passed to the function is null, the function returns null.",$Parameter:[{$Name:"HierarchyNodes",$Collection:!0,$Type:"Edm.EntityType","@Org.OData.Core.V1.Description":"A collection, given through a `$root` expression"},{$Name:"HierarchyQualifier",$Type:"Org.OData.Aggregation.V1.HierarchyQualifier"},{$Name:"Node",$Type:"Edm.PrimitiveType",$Nullable:!0,"@Org.OData.Core.V1.Description":"Node identifier of the putative sibling"},{$Name:"Other",$Type:"Edm.PrimitiveType",$Nullable:!0,"@Org.OData.Core.V1.Description":"Node identifier of the other node"}],$ReturnType:{$Type:"Edm.Boolean",$Nullable:!0}}],isleaf:[{$Kind:"Function","@Org.OData.Core.V1.Description":"Is the entity a leaf node in the hierarchy specified by the [parameter pair](#HierarchyQualifier) (`HierarchyNodes`, `HierarchyQualifier`)? (See OData-Data-Agg-v4.0, section 5.5.2.1)","@Org.OData.Core.V1.LongDescription":"If a node identifier passed to the function is null, the function returns null.",$Parameter:[{$Name:"HierarchyNodes",$Collection:!0,$Type:"Edm.EntityType","@Org.OData.Core.V1.Description":"A collection, given through a `$root` expression"},{$Name:"HierarchyQualifier",$Type:"Org.OData.Aggregation.V1.HierarchyQualifier"},{$Name:"Node",$Type:"Edm.PrimitiveType",$Nullable:!0,"@Org.OData.Core.V1.Description":"Node identifier of the putative leaf"}],$ReturnType:{$Type:"Edm.Boolean",$Nullable:!0}}],rollupnode:[{$Kind:"Function","@Org.OData.Core.V1.Description":"During `rolluprecursive` for a hierarchy node, this function returns the node","@Org.OData.Core.V1.LongDescription":'This function may only occur in the second parameter of a `groupby` transformation whose first parameter\ncontains `rolluprecursive(...)`. It is evaluated as part of the transformation `R(x)` in the "`rolluprecursive` algorithm"\n(OData-Data-Agg-v4.0, section 6.3). Its behavior is undefined outside of this algorithm.\n```\nSales?$apply=groupby((rolluprecursive(...)), filter(SalesOrganization eq Aggregation.rollupnode())/aggregate(...))\n```\nconstructs a rollup that contains aggregates per hierarchy node while excluding descendants from the aggregation.',$Parameter:[{$Name:"Position",$Type:"Edm.Int16","@Org.OData.Core.V1.Description":"Position N among the `rolluprecursive` operators in the first argument of `groupby`","@Org.OData.Core.V1.LongDescription":"Every instance in the output set of a `groupby` transformation with M `rolluprecursive` operators\n has M relationships to M nodes in M recursive hierarchies. This function returns the node x with path r to the root\n in relationship number N.\n If several such `groupby` transformations are nested, this function refers to the innermost one.","@Org.OData.Core.V1.OptionalParameter":{DefaultValue:"1"},"@Org.OData.Validation.V1.Minimum":1}],$ReturnType:{$Type:"Edm.EntityType"}}],UpPath:{$Kind:"Term",$Collection:!0,$AppliesTo:["EntityType"],"@Org.OData.Core.V1.Description":"The string values of the node identifiers in a path from the annotated node to a start node in a traversal of a recursive hierarchy","@Org.OData.Core.V1.LongDescription":"This instance annotation occurs in the result set after a `traverse` transformation (OData-Data-Agg-v4.0, section 6.2.2.2).\n A use case for this is traversal with multiple parents, when this annotation takes\n as value one parent node identifier followed by one grandparent node identifier and so on."},AvailableOnAggregates:{$Kind:"Term",$Type:"Org.OData.Aggregation.V1.AvailableOnAggregatesType",$AppliesTo:["Function"],"@Org.OData.Core.V1.Description":"This function is available on aggregated entities if the `RequiredProperties` are still defined"},AvailableOnAggregatesType:{$Kind:"ComplexType",RequiredProperties:{$Collection:!0,$Type:"Edm.PropertyPath","@Org.OData.Core.V1.Description":"Properties required to apply this function"}},NavigationPropertyAggregationCapabilities:{$Kind:"ComplexType",$BaseType:"Org.OData.Capabilities.V1.NavigationPropertyRestriction","@Org.OData.Core.V1.Revisions":[{Kind:"Deprecated",Description:"[`Capabilities.NavigationRestrictions`](Org.OData.Capabilities.V1.md#NavigationRestrictions) that make use of the additional properties in this subtype are deprecated in favor of [`ApplySupported`](#ApplySupported) and [`CustomAggregate`](#CustomAggregate)"}],"@Org.OData.Core.V1.Description":"Aggregation capabilities on a navigation path",ApplySupported:{$Type:"Org.OData.Aggregation.V1.ApplySupportedType",$Nullable:!0,"@Org.OData.Core.V1.Description":"Support for `$apply`"},CustomAggregates:{$Collection:!0,$Type:"Org.OData.Aggregation.V1.CustomAggregateType","@Org.OData.Core.V1.Description":"Supported custom aggregates"}},CustomAggregateType:{$Kind:"ComplexType","@Org.OData.Core.V1.Revisions":[{Kind:"Deprecated",Description:"Deprecated since [`NavigationPropertyAggregationCapabilities`](#NavigationPropertyAggregationCapabilities) is also deprecated"}],Name:{"@Org.OData.Core.V1.Description":"Name of the dynamic property that can be used in the `aggregate` transformation"},Type:{"@Org.OData.Core.V1.Description":"Qualified name of a primitive type. The aggregated value will be of that type"}}}}});var bMt=y(iwe=>{"use strict";Object.defineProperty(iwe,"__esModule",{value:!0});iwe.default={$Version:"4.0",$Reference:{"https://oasis-tcs.github.io/odata-vocabularies/vocabularies/Org.OData.Core.V1.json":{$Include:[{$Namespace:"Org.OData.Core.V1",$Alias:"Core"}]}},"Org.OData.Authorization.V1":{$Alias:"Authorization","@Org.OData.Core.V1.Description":"The Authorization Vocabulary provides terms for describing authorization requirements of the service","@Org.OData.Core.V1.Links":[{rel:"alternate",href:"https://oasis-tcs.github.io/odata-vocabularies/vocabularies/Org.OData.Authorization.V1.xml"},{rel:"latest-version",href:"https://oasis-tcs.github.io/odata-vocabularies/vocabularies/Org.OData.Authorization.V1.json"},{rel:"describedby",href:"https://github.com/oasis-tcs/odata-vocabularies/blob/main/vocabularies/Org.OData.Authorization.V1.md"}],SecuritySchemes:{$Kind:"Term",$Collection:!0,$Type:"Org.OData.Authorization.V1.SecurityScheme",$AppliesTo:["EntityContainer"],"@Org.OData.Core.V1.Description":"At least one of the specified security schemes are required to make a request against the service"},SecurityScheme:{$Kind:"ComplexType",Authorization:{$Type:"Org.OData.Authorization.V1.SchemeName","@Org.OData.Core.V1.Description":"The name of a required authorization scheme"},RequiredScopes:{$Collection:!0,"@Org.OData.Core.V1.Description":"The names of scopes required from this authorization scheme"}},Authorizations:{$Kind:"Term",$Collection:!0,$Type:"Org.OData.Authorization.V1.Authorization",$AppliesTo:["EntityContainer"],"@Org.OData.Core.V1.Description":"Lists the methods supported by the service to authorize access"},Authorization:{$Kind:"ComplexType",$Abstract:!0,"@Org.OData.Core.V1.Description":"Base type for all Authorization types",Name:{"@Org.OData.Core.V1.Description":"Name that can be used to reference the authorization scheme"},Description:{$Nullable:!0,"@Org.OData.Core.V1.Description":"Description of the authorization scheme"}},OpenIDConnect:{$Kind:"ComplexType",$BaseType:"Org.OData.Authorization.V1.Authorization",IssuerUrl:{"@Org.OData.Core.V1.Description":"Issuer location for the OpenID Provider. Configuration information can be obtained by appending `/.well-known/openid-configuration` to this Url.","@Org.OData.Core.V1.IsURL":!0}},Http:{$Kind:"ComplexType",$BaseType:"Org.OData.Authorization.V1.Authorization",Scheme:{"@Org.OData.Core.V1.Description":"HTTP Authorization scheme to be used in the Authorization header, as per RFC7235"},BearerFormat:{$Nullable:!0,"@Org.OData.Core.V1.Description":"Format of the bearer token"}},OAuthAuthorization:{$Kind:"ComplexType",$Abstract:!0,$BaseType:"Org.OData.Authorization.V1.Authorization",Scopes:{$Collection:!0,$Type:"Org.OData.Authorization.V1.AuthorizationScope","@Org.OData.Core.V1.Description":"Available scopes"},RefreshUrl:{$Nullable:!0,"@Org.OData.Core.V1.Description":"Refresh Url","@Org.OData.Core.V1.IsURL":!0}},OAuth2ClientCredentials:{$Kind:"ComplexType",$BaseType:"Org.OData.Authorization.V1.OAuthAuthorization",TokenUrl:{"@Org.OData.Core.V1.Description":"Token Url","@Org.OData.Core.V1.IsURL":!0}},OAuth2Implicit:{$Kind:"ComplexType",$BaseType:"Org.OData.Authorization.V1.OAuthAuthorization","@Org.OData.Core.V1.Description":"Security note: OAuth2 implicit grant is considered to be not secure and should not be used by clients, see [OAuth 2.0 Security Best Current Practice](https://datatracker.ietf.org/doc/html/draft-ietf-oauth-security-topics.html#name-implicit-grant).",AuthorizationUrl:{"@Org.OData.Core.V1.Description":"Authorization URL","@Org.OData.Core.V1.IsURL":!0}},OAuth2Password:{$Kind:"ComplexType",$BaseType:"Org.OData.Authorization.V1.OAuthAuthorization",TokenUrl:{"@Org.OData.Core.V1.Description":"Token Url","@Org.OData.Core.V1.IsURL":!0}},OAuth2AuthCode:{$Kind:"ComplexType",$BaseType:"Org.OData.Authorization.V1.OAuthAuthorization",AuthorizationUrl:{"@Org.OData.Core.V1.Description":"Authorization URL","@Org.OData.Core.V1.IsURL":!0},TokenUrl:{"@Org.OData.Core.V1.Description":"Token Url","@Org.OData.Core.V1.IsURL":!0}},AuthorizationScope:{$Kind:"ComplexType",Scope:{"@Org.OData.Core.V1.Description":"Scope name"},Grant:{$Nullable:!0,"@Org.OData.Core.V1.Description":"Identity that has access to the scope or can grant access to the scope."},Description:{"@Org.OData.Core.V1.Description":"Description of the scope"}},ApiKey:{$Kind:"ComplexType",$BaseType:"Org.OData.Authorization.V1.Authorization",KeyName:{"@Org.OData.Core.V1.Description":"The name of the header or query parameter"},Location:{$Type:"Org.OData.Authorization.V1.KeyLocation","@Org.OData.Core.V1.Description":"Whether the API Key is passed in the header or as a query option"}},KeyLocation:{$Kind:"EnumType",Header:0,"Header@Org.OData.Core.V1.Description":"API Key is passed in the header",QueryOption:1,"QueryOption@Org.OData.Core.V1.Description":"API Key is passed as a query option",Cookie:2,"Cookie@Org.OData.Core.V1.Description":"API Key is passed as a cookie"},SchemeName:{$Kind:"TypeDefinition",$UnderlyingType:"Edm.String","@Org.OData.Core.V1.Description":"The name of the authorization scheme."}}}});var EMt=y(awe=>{"use strict";Object.defineProperty(awe,"__esModule",{value:!0});awe.default={$Version:"4.0",$Reference:{"https://oasis-tcs.github.io/odata-vocabularies/vocabularies/Org.OData.Authorization.V1.json":{$Include:[{$Namespace:"Org.OData.Authorization.V1",$Alias:"Authorization"}]},"https://oasis-tcs.github.io/odata-vocabularies/vocabularies/Org.OData.Core.V1.json":{$Include:[{$Namespace:"Org.OData.Core.V1",$Alias:"Core"}]},"https://oasis-tcs.github.io/odata-vocabularies/vocabularies/Org.OData.Validation.V1.json":{$Include:[{$Namespace:"Org.OData.Validation.V1",$Alias:"Validation"}]}},"Org.OData.Capabilities.V1":{$Alias:"Capabilities","@Org.OData.Core.V1.Description":"Terms describing capabilities of a service","@Org.OData.Core.V1.Links":[{rel:"alternate",href:"https://oasis-tcs.github.io/odata-vocabularies/vocabularies/Org.OData.Capabilities.V1.xml"},{rel:"latest-version",href:"https://oasis-tcs.github.io/odata-vocabularies/vocabularies/Org.OData.Capabilities.V1.json"},{rel:"describedby",href:"https://github.com/oasis-tcs/odata-vocabularies/blob/main/vocabularies/Org.OData.Capabilities.V1.md"}],"@Org.OData.Core.V1.LongDescription":`
|
|
429
429
|
There are some capabilities which are strongly recommended for services to support even
|
|
430
430
|
though they are optional. Support for $top and $skip is a good example as
|
|
@@ -1151,7 +1151,7 @@ ${s}</${e.name}>`))}else i.push(fr.TextEdit.insert(n,o));return i}function bjn(e
|
|
|
1151
1151
|
`);let f=QDe(u,n,i)+`
|
|
1152
1152
|
`;if(l.requiresNewLine&&p.push(`
|
|
1153
1153
|
`),p.push(f),!l.requiresNewLine){a.push(fr.TextEdit.insert(l.position,p.join("")));continue}let d=(0,a1.indent)(tN.tabWidth,tN.useTabs,n);p.push(d),l.redundantWhitespace&&a.push(fr.TextEdit.del(l.redundantWhitespace)),a.push(fr.TextEdit.insert(l.position,p.join("")))}return a}function Cjn(e){let t=new Map,r=[];for(let n of e){let i=t.get(n.index);i||(i=[],r.push(n.index),t.set(n.index,i)),i.push(n)}return[r,t]}function QDe(e,t,r){return e.map(n=>(0,Br.printCsdlNodeToXmlString)((0,fr.createElementNode)(n.element),tN,{namespaces:r,cursorIndentLevel:t})).join(`
|
|
1154
|
-
`)}function wjn(e,t,r){return(0,Br.printCsdlNodeToXmlString)((0,fr.createElementNode)(e.newElement),tN,{namespaces:r,cursorIndentLevel:t}).trim()}function Pjn(e,t,r){return(0,Br.printCsdlNodeToXmlString)(e.newValue,tN,{namespaces:r,cursorIndentLevel:t}).trim()}function Djn(e,t,r=-1){let n=r!==-1?t.subElements[r]:void 0;if(n){let o=ZUt(n.position),s=Njn(e,o),c=XUt(t,r);if(!c)return{type:"none"};let u=s?s.range.start:o.start,l=u.line===c.end.line,p=l?u:fr.Position.create(u.line,0),f=l?fr.Range.create(c.end,u):void 0;return{type:"child",position:p,requiresNewLine:l,redundantWhitespace:f}}let i=(0,Br.transformRange)(t.syntax.closeBody),a=XUt(t,t.subElements.length);if(i&&a){let o=i.start;return{type:"parent",position:o.line===a.end.line?o:fr.Position.create(o.line,0),requiresNewLine:!1}}return{type:"none"}}function XUt(e,t){let r=e.subElements[t-1];if(t===0)return(0,Br.transformRange)(e.syntax.openBody);if(r)return ZUt(r.position)}function Njn(e,t){let r=t.start.line-1;for(let n of e)if(n.range.end.line===r||n.range.start.line===t.end.line)return n}function ZUt(e){return fr.Range.create(e.startLine-1,e.startColumn-1,e.endLine-1,e.endColumn)}function Ijn(e){if(e?.type==="XMLElement"){let t=(0,Br.transformRange)(e.syntax.openBody);if(t)return(0,a1.getIndentLevel)(t.start.character,tN.tabWidth)+1}return 0}function Rjn(e,t){let r=[],n=t.reduce((i,a)=>{let o=a.split("/"),s=o.slice(0,-2).join("/"),c=Number.parseInt(o.slice(-1)[0],10),u=i.get(s);return u?u.push(c):i.set(s,[c]),i},new Map);for(let[i,a]of n){let o=(0,EZ.getNodeFromPointer)(e,i);if(o?.type==="XMLElement"){a.sort((s,c)=>s-c);for(let s=1,c=a[0],u=a[0];s<=a.length;s++){let l=a[s];l===void 0?r.push({parent:o,start:c,end:u}):u+1===l?u=l:(r.push({parent:o,start:c,end:u}),c=u=l)}}}return r}function Ljn(e,t){let r=(0,Br.transformRange)(e.position);if(!r)return[];let n=t.filter(o=>kjn(r,o,e)),i=[...e.subElements,...n].sort($jn),a=[];for(let o=0;o<i.length;o++){let s=i[o];if(s.type!=="XMLElement"){a.push(s);continue}let c=(0,Br.transformRange)(s.position);if(!c)continue;let u={type:"element",element:s,elementRange:c,range:(0,Tq.copyRange)(c)},l=a[a.length-1],p=u.range.start.line-1;l?.type==="comment"&&(l.range.end.line===p||l.range.end.line===u.range.start.line)&&(u.leadingComment=a.pop(),_Z(u.range.start,l.range.start));let f=i[o+1];f?.type==="comment"&&f.range.start.line===c.end.line&&(u.trailingComment=f,_Z(u.range.end,f.range.end),o++),a.push(u)}return a}function kjn(e,t,r){return(0,a1.rangeContained)(e,t.range)&&!r.subElements.some(n=>{let i=(0,Br.transformRange)(n.position);return i?(0,a1.rangeContained)(i,t.range):!1})}function $jn(e,t){let r=e.range??(0,Br.transformRange)(e.syntax?.closeBody??e.syntax?.openBody),n=t.range??(0,Br.transformRange)(t.syntax?.closeBody??t.syntax?.openBody);return r?!n||(0,a1.isBefore)(r.start,n.start)?-1:(0,a1.isBefore)(n.start,r.start)?1:0:1}function QUt(e,t,r){let n=-1,i=-1,a=-1;for(let o=0,s=0;o<r.length;o++)if(r[o].type==="element"){if(e-1===s&&(n=o),e===s&&(i=o),t===s){a=o;break}s++}return{previousContentIndex:n,startContentIndex:i,endContentIndex:a}}function Mjn(e,t,r,n){let{previousContentIndex:i,startContentIndex:a,endContentIndex:o}=QUt(r,n,e),s=e[o],c=eBt(e,t,i,a)?.start,u=s?.range?.end;if(c&&(c=(0,Tq.copyPosition)(c)),u&&(u=(0,Tq.copyPosition)(u)),!(!c||!s))return fr.Range.create(c,u)}function eBt(e,t,r,n){let i=e[r],a=n===0?(0,Br.transformRange)(t.syntax.openBody)?.end:i?.range?.end,o=e[n];if(a&&(a=(0,Tq.copyPosition)(a)),!a||!o)return;let s=e[n-1];return s?.type==="comment"&&_Z(a,s.range.end),fr.Range.create(a,(0,Tq.copyPosition)(o.range.end))}function _Z(e,t){e.line=t.line,e.character=t.character}function JUt(e,t){if(!t)return;let r=e.filter(n=>n.range.start.line===t.end.line&&n.range.start.character>t.end.character);if(r.length){let n=t.end;for(let i of r)i.range.start.character>n.character&&(n=i.range.end);t.end=n}}function Fjn(e,t,r){if(e===0)return(0,Br.transformRange)(t.syntax.openBody)?.end;if(e===void 0||e>=t.subElements.length){let n=t.subElements[t.subElements.length-1];if(!n)return;let i=(0,Br.transformRange)(n.syntax.closeBody??n.syntax.openBody);return JUt(r,i),i?.end}else if(e>0){let n=t.subElements[e-1],i=(0,Br.transformRange)(n.syntax.closeBody??n.syntax.openBody);return JUt(r,i),i?.end}}function eNe(e){let t={};for(let r of Object.keys(e.namespaces)){if(r===fjn.DEFAULT_NS)continue;let n=e.namespaces[r];n===Br.EDMX_V4_NAMESPACE?t[fr.EDMX_NAMESPACE_ALIAS]=r:n===Br.EDM_V4_NAMESPACE&&(t[fr.EDM_NAMESPACE_ALIAS]=r)}return t}function jjn(e){let t={};for(let r of Object.keys(e.attributes)){if(!r.startsWith("xmlns"))continue;let{name:n,value:i}=e.attributes[r],[,a]=n.split(":");a!==void 0&&(i===Br.EDMX_V4_NAMESPACE?t[fr.EDMX_NAMESPACE_ALIAS]=a:i===Br.EDM_V4_NAMESPACE&&(t[fr.EDM_NAMESPACE_ALIAS]=a))}return t}function qjn(e,t){let r=Ujn(e);return r=Bjn(r),r=Vjn(r,t),r}function Vjn(e,t){let r=[],n=new Set,i=new Map;for(let a=e.length-1;a>=0;a--){let o=e[a];if(o.type!=="insert-element")continue;let s=(0,EZ.getNodeFromPointer)(t,o.pointer);if(s?.type!=="XMLElement")continue;let c=o.index??s.subElements.length-1,u=`${o.pointer}/subElements/${c}`,l=e.findIndex(p=>p.pointer===u&&p.type==="delete-element");l!==-1&&!i.has(l)&&(i.set(l,{type:"replace-element",pointer:u,newElement:o.element}),n.add(a))}for(let a=0;a<e.length;a++){let o=e[a],s=i.get(a);s?r.push(s):n.has(a)||r.push(o)}return r}function Ujn(e){let t=[],r=[];for(let n of e)n.type==="delete-element"?t.indexOf(n.pointer)===-1&&(t.push(n.pointer),r.push(n)):r.push(n);return r}function Bjn(e){let t=[],r=new Set;for(let n of e)if(n.type==="delete-element"){let i=n.pointer.split("/").length;for(let a=0;a<e.length;a++){let o=e[a],s=o.pointer.split("/").length;(o.type==="delete-element"||o.type==="delete-attribute")&&o.pointer.startsWith(n.pointer)&&o.pointer!==n.pointer&&s!==i&&r.add(a)}}for(let n=0;n<e.length;n++){let i=e[n];r.has(n)||t.push(i)}return t}});var nBt=y(tNe=>{"use strict";Object.defineProperty(tNe,"__esModule",{value:!0});tNe.collectUsedNamespaces=OZ;var TZ=Ht(),zjn=Nr();function OZ(e,t){switch(e.type){case TZ.ANNOTATION_FILE_TYPE:{for(let r of e.targets)OZ(r,t);break}case TZ.TARGET_TYPE:{e.name&&rN(e.name,t);for(let r of e.terms)OZ(r,t);break}case TZ.ELEMENT_TYPE:{Hjn(e,t);break}default:break}}var rBt=["Path","PropertyPath","NavigationPropertyPath","AnnotationPath"];function Hjn(e,t){if(e.name==="Annotation"){let r=e.attributes.Term;r?.value&&rN(r.value,t)}if(e.name==="Record"){let r=e.attributes.Type;r?.value&&rN(r.value,t)}if(e.name==="PropertyValue"||e.name==="Annotation"){let r=e.attributes.EnumMember;r?.value&&rN(r.value,t)}Gjn(e,t)}function Gjn(e,t){if(rBt.includes(e.name)){let r=e.content.find(n=>n.type===TZ.TEXT_TYPE);r&&rN(r.text,t)}else{for(let r of rBt){let n=e.attributes[r];n?.value&&rN(n.value,t)}for(let r of e.content)OZ(r,t)}}function rN(e,t){let r=(0,zjn.parsePath)(e);for(let n of r.segments)n.namespaceOrAlias&&t.add(n.namespaceOrAlias)}});var iBt=y(rNe=>{"use strict";Object.defineProperty(rNe,"__esModule",{value:!0});rNe.collectComments=Yjn;var Kjn=Ht();function Yjn(e){let t=[];for(let r of e){if(r.tokenTypeIdx!==3)continue;let n=Wjn(r);n&&t.push({type:"comment",value:r.image,range:n})}return t}function Wjn(e){let t=e.startLine??-1,r=e.startColumn??-1,n=e.endLine??-1,i=e.endColumn??-1;if(!(t===-1||r===-1||n===-1||i===-1))return Kjn.Range.create(t-1,r-1,n-1,i)}});var pBt=y(CZ=>{"use strict";Object.defineProperty(CZ,"__esModule",{value:!0});CZ.XMLAnnotationServiceAdapter=void 0;var uBt=KPe(),lBt=UPe(),nNe=KT(),nN=aDe(),uh=Ht(),SZ=Nr(),aBt=sDe(),wc=XJ(),AZ=nh(),Xjn=tBt(),iNe=WDe(),oBt=nBt(),Jjn=iBt(),sBt=JDe(),aNe=class{service;vocabularyService;project;appName;metadataService=new aBt.MetadataService;splitAnnotationSupport=!1;fileCache;documents=new Map;metadata=[];setFileCache(t){this.fileCache=t}_compiledService;get compiledService(){return this._compiledService||(this._compiledService=this._getCompiledService()),this._compiledService}set compiledService(t){this._compiledService=t}constructor(t,r,n,i){this.service=t,this.vocabularyService=r,this.project=n,this.appName=i,this.fileCache=new Map}sync(t){this.documents.clear(),this._compiledService=void 0,this.setFileCache(t);let{ast:r,comments:n}=cBt(t,this.service.metadataFile);this.documents.set(this.service.metadataFile.uri,{uri:this.service.metadataFile.uri,comments:n,ast:r,annotationFile:(0,nN.convertDocument)(this.service.metadataFile.uri,r),usedNamespaces:new Set});for(let i of this.service.annotationFiles){let{ast:a,comments:o}=cBt(t,i,!1),s=(0,nN.convertDocument)(i.uri,a),c=new Set;(0,oBt.collectUsedNamespaces)(s,c),this.documents.set(i.uri,{uri:i.uri,comments:o,ast:a,annotationFile:s,usedNamespaces:c})}this.addMissingMetadataReferences(),this.metadata=(0,nN.convertMetadataDocument)(this.service.metadataFile.uri,r),this.metadataService=new aBt.MetadataService({ODataVersion:this.service.odataVersion,isCds:!1}),this.metadataService.import(this.metadata,this.service.metadataFile.uri)}getAllFiles(){return[this.service.metadataFile,...this.service.annotationFiles]}getInitialFileContent(t,r){let n=this.appName||Object.keys(this.project.apps)[0],i=`${this.project.apps[n].services[t].uri}$metadata`,a=[...this.metadataService.getNamespaces()][0],o=tqn({references:[{name:a,uri:i,type:"reference",alias:"Metadata"}],targets:[],type:"annotation-file",uri:r,namespace:{name:this.getUniqueNamespace(a),type:"namespace"}},this.metadataService),s=this.vocabularyService.getVocabularies();return(0,nN.getNewAnnotationFile)(o,i,s).fileContent}async getWorkspaceEdit(t){let r={},n=new Map,i={};for(let a of t){let o=n.get(a.uri),s=this.documents.get(a.uri),c=i[a.uri]??=new Map;if(s){if(!o){let u=nNe.TextDocument.create(a.uri,"cds",0,this.fileCache?.get(a.uri)??"");o=new Xjn.XMLWriter(s.ast,s.comments,u),n.set(a.uri,o)}this.processChange(s,o,c,a)}}for(let[a,o]of n.entries()){let s=i[a]??=new Map;for(let[l,p]of s.entries())p.size===0&&o.addChange({type:"delete-element",pointer:l});let c=o.getTextEdits(),u=this.postprocessEdits(a,o,c);u.length&&(c=u),r[a]=c}return Promise.resolve({changes:r})}validateChanges(t){return this.sync(t)}serializeTarget(t){return(0,nN.serializeTarget)(t)}getUniqueNamespace(t){let r=new Set;this.documents.forEach(a=>{let o=a.annotationFile.namespace;o&&r.add(o.name)});let n=`${t}.annotations`,i=0;for(;[...r].includes(n)&&(++i,n=`${n}${i}`,!![...r].includes(n)););return n}_getCompiledService(){let t=[this.service.metadataFile,...this.service.annotationFiles],r=[];for(let n of t){let i=this.documents.get(n.uri);if(i)r.push(i.annotationFile);else throw new AZ.ApiError(`Could not compile service. Missing document ${n.uri}`,AZ.ApiErrorCode.General)}return Object.freeze({odataVersion:this.service.odataVersion,annotationFiles:r,metadata:this.metadata})}processChange(t,r,n,i){switch(i.type){case wc.INSERT_TARGET:{let a=ch(t.ast);Zm(!a,`Could not process change ${i.type} ${i.uri} ${i.target}`);let o=(0,uh.createElementNode)({name:"Annotations",attributes:{Target:(0,uh.createAttributeNode)("Target",i.target.name)},content:i.target.terms});r.addChange({type:wc.INSERT_ELEMENT,pointer:a,element:o});break}case wc.INSERT_ELEMENT:{let a=ch(t.ast);Zm(!a,`Could not process change ${i.type} ${i.uri} ${i.pointer} ${i.element.name}`);let o=a+vp(t.annotationFile,i.pointer),s=(0,sBt.getNodeFromPointer)(t.ast,o);s?.type==="XMLElement"&&s.name==="Annotations"&&this.markElementInsertion(n,o,s),r.addChange({type:wc.INSERT_ELEMENT,pointer:a+vp(t.annotationFile,i.pointer),element:i.element,index:i.index});break}case wc.DELETE_ELEMENT:{let a=ch(t.ast);Zm(!a,`Could not process change ${i.type} ${i.uri} ${i.pointer} `);let o=a+vp(t.annotationFile,i.pointer),s=(0,sBt.getNodeFromPointer)(t.ast,o);s?.type==="XMLElement"&&s.name==="Annotation"&&s.parent?.type==="XMLElement"&&s.parent.name==="Annotations"&&this.markElementDeletion(n,o,s.parent),r.addChange({type:"delete-element",pointer:o});break}case wc.DELETE_ATTRIBUTE:{let a=ch(t.ast);Zm(!a,`Could not process change ${i.type} ${i.uri} ${i.pointer} `),r.addChange({type:"delete-attribute",pointer:a+vp(t.annotationFile,i.pointer)});break}case wc.UPDATE_ATTRIBUTE_VALUE:{let a=ch(t.ast);Zm(!a,`Could not process change ${i.type} ${i.uri} ${i.pointer} `),r.addChange({type:wc.UPDATE_ATTRIBUTE_VALUE,pointer:a+vp(t.annotationFile,i.pointer),newValue:i.newValue});break}case wc.REPLACE_ATTRIBUTE:{let a=ch(t.ast);Zm(!a,`Could not process change ${i.type} ${i.uri} ${i.pointer} `),r.addChange({type:"update-attribute-name",pointer:a+vp(t.annotationFile,i.pointer),newName:i.newAttributeName}),r.addChange({type:wc.UPDATE_ATTRIBUTE_VALUE,pointer:a+vp(t.annotationFile,i.pointer),newValue:i.newAttributeValue});break}case wc.REPLACE_ELEMENT:{let a=ch(t.ast);Zm(!a,`Could not process change ${i.type} ${i.uri} ${i.pointer} `),r.addChange({type:"replace-element",pointer:a+vp(t.annotationFile,i.pointer),newElement:i.newElement});break}case iNe.REPLACE_ELEMENT_CONTENT:{let a=ch(t.ast);Zm(!a,`Could not process change ${i.type} ${i.uri} ${i.pointer} `),r.addChange({type:iNe.REPLACE_ELEMENT_CONTENT,pointer:a+vp(t.annotationFile,i.pointer),newValue:i.newValue});break}case wc.INSERT_ATTRIBUTE:{let a=ch(t.ast);Zm(!a,`Could not process change ${i.type} ${i.uri} ${i.pointer} ${i.name}`),r.addChange({type:"insert-attribute",pointer:a+vp(t.annotationFile,i.pointer),name:i.name,value:i.value});break}case wc.MOVE_ELEMENT:{let a=ch(t.ast);if(a){let o=a+vp(t.annotationFile,i.pointer);r.addChange({type:"move-collection-value",pointer:o,index:i.index,fromPointers:i.fromPointers.map(s=>a+vp(t.annotationFile,s))})}break}case wc.REPLACE_TEXT:{let a=ch(t.ast);if(a){let o=a+vp(t.annotationFile,i.pointer);r.addChange({type:iNe.REPLACE_ELEMENT_CONTENT,pointer:o.split("/").slice(0,-3).join("/"),newValue:[i.text]})}}break;default:break}}getTargetChildReferences(t,r,n){let i=t.get(r);if(i)return i;let a=new Set;for(let o=0;o<n.subElements.length;o++)n.subElements[o].type==="XMLElement"&&a.add(`${r}/subElements/${o}`);return t.set(r,a),a}markElementDeletion(t,r,n){let i=r.split("/").slice(0,-2).join("/");this.getTargetChildReferences(t,i,n).delete(r)}markElementInsertion(t,r,n){this.getTargetChildReferences(t,r,n).add(`${r}/subElements/-1`)}postprocessEdits(t,r,n){let i=this.fileCache.get(t),a=this.documents.get(t);if(!i||!a)return[];let o=nNe.TextDocument.applyEdits(nNe.TextDocument.create(t,"",0,i),n),{cst:s,tokenVector:c}=(0,lBt.parse)(o),u=(0,uBt.buildAst)(s,c);return this.updateReferences(t,r,u)?r.getTextEdits():[]}updateReferences(t,r,n){let i=this.documents.get(t);if(!i)return!1;let a=(0,nN.convertDocument)(t,n),o=new Set;(0,oBt.collectUsedNamespaces)(a,o);let s=(0,SZ.getAllNamespacesAndReferences)(a.namespace,a.references),c=(0,SZ.getAliasInformation)(s,this.metadataService.getNamespaces()),u=Qjn(i.ast);Zm(!u,`No root EDMX element found in ${t}`);let l=this.removeReferences(r,i,c,o,u),p=this.addReferences(r,i,c,o,u);return l||p}removeReferences(t,r,n,i,a){let o=new Set;for(let s of Object.keys(n.aliasMapVocabulary)){let c=n.aliasMapVocabulary[s],u=n.reverseAliasMap[c];!i.has(c)&&u!==void 0&&!i.has(u)&&o.add(c)}for(let s of o)for(let c=0;c<r.ast.rootElement.subElements.length;c++)r.ast.rootElement.subElements[c].subElements.find(p=>p.name==="Include"&&p.attributes.find(f=>f.key==="Namespace")?.value===s)&&t.addChange({type:wc.DELETE_ELEMENT,pointer:`${a}/subElements/${c}`});return o.size>0}addReferences(t,r,n,i,a){let o=new Set;for(let s of i)if(!n.aliasMapVocabulary[s]){let c=this.vocabularyService.getVocabularyNamespace(s);c&&o.add(c)}for(let s of o){let c=this.vocabularyService.getVocabulary(s);if(!c)continue;let u=c.defaultAlias,l=c.defaultUri,p=(0,uh.createReference)(s,u,l);t.addChange({type:wc.INSERT_ELEMENT,pointer:a,element:Zjn(p),index:r.ast.rootElement.subElements.length>0?0:void 0})}return o.size>0}addMissingMetadataReferences(){let t=this.documents.get(this.service.metadataFile.uri);if(!t)return;let r=t.annotationFile.namespace;if(r)for(let n of this.service.annotationFiles){let i=this.documents.get(n.uri);if(!i)continue;let{annotationFile:a}=i,o=a.references.find(s=>s.name===r.name);if(o)o.alias===void 0&&r.alias!==void 0&&(o.alias=r.alias);else{let s=(0,uh.createReference)(r.name,r.alias);a.references.push(s)}}}};CZ.XMLAnnotationServiceAdapter=aNe;function Zm(e,t){if(e)throw new AZ.ApiError(t,AZ.ApiErrorCode.General)}function Zjn(e){let t=(0,uh.createElementNode)({name:"Include",namespaceAlias:"Edmx",attributes:{Namespace:(0,uh.createAttributeNode)("Namespace",e.name)}});return e.alias&&(t.attributes.Alias=(0,uh.createAttributeNode)("Alias",e.alias)),(0,uh.createElementNode)({name:"Reference",namespaceAlias:"Edmx",content:[t],attributes:{Uri:(0,uh.createAttributeNode)("Uri",e.uri??"")}})}function Qjn(e){if(e.rootElement)return"/rootElement"}function ch(e){if(!e.rootElement)return;let t=e.rootElement.subElements.findIndex(n=>n.name==="DataServices");if(t===-1)return;let r=e.rootElement.subElements[t].subElements.findIndex(n=>n.name==="Schema");if(r!==-1)return`/rootElement/subElements/${t}/subElements/${r}`}function cBt(e,t,r=!0){let n=e.get(t.uri);if(typeof n!="string")throw new Error(`File ${t.uri} not found in cache!`);let{cst:i,tokenVector:a}=(0,lBt.parse)(n),o=r?[]:(0,Jjn.collectComments)(a);return{ast:(0,uBt.buildAst)(i,a),comments:o}}function vp(e,t){let r=e;return t.split("/").map((n,i,a)=>{if(n==="content"||n==="targets"||n==="terms")return a[i+2]==="text"?(r=r.textContents,"textContents"):(r&&(r=r[n]),"subElements");if(i!==0&&r){let o=eqn(n,r);return r=o.nextNode,o.mappedSegment}return n}).join("/")}function eqn(e,t){let r=-1,n=Number.parseInt(e,10),i=t[e];if(Number.isSafeInteger(n)&&Array.isArray(t))for(let o=0;o<=n&&o<t.length;o++)t[o].type===uh.ELEMENT_TYPE&&r++;else!Array.isArray(i)&&i?.type===uh.ATTRIBUTE_TYPE&&(r=Object.keys(t).findIndex(o=>o===e));return{mappedSegment:r!==-1?r.toString():e,nextNode:i}}function tqn(e,t){let r=(0,SZ.getAllNamespacesAndReferences)(e.namespace,e.references);return(0,SZ.getAliasInformation)(r,t.getNamespaces())}});var dBt=y(oNe=>{"use strict";Object.defineProperty(oNe,"__esModule",{value:!0});oNe.getLocalEDMXService=rqn;var fBt=require("node:url");function rqn(e,t,r){let i=e.apps[nqn(r,e)]?.services[t];if(!i?.local)throw new Error(`Metadata file for service ${t} in app ${r} is not found!`);let a=i.local??"",s={uri:(0,fBt.pathToFileURL)(a).toString(),isReadOnly:!0},c=i?.annotations??[],u=c.map(d=>(0,fBt.pathToFileURL)(d.local??"").toString()),l=c.findIndex((d,h)=>typeof d.local=="string"&&typeof d.uri=="string"&&!u[h].endsWith(d.uri)),p=u[l]??"",f=u.map(d=>({uri:d,isReadOnly:d===p}));return{type:"local-edmx",odataVersion:i.odataVersion??"2.0",metadataFile:s,annotationFiles:f}}function nqn(e,t){return e&&t.apps[e]?e:t.apps[""]?"":Object.keys(t.apps)[0]||""}});var hBt=y(iN=>{"use strict";Object.defineProperty(iN,"__esModule",{value:!0});iN.getLocalEDMXService=iN.XMLAnnotationServiceAdapter=void 0;var iqn=pBt();Object.defineProperty(iN,"XMLAnnotationServiceAdapter",{enumerable:!0,get:function(){return iqn.XMLAnnotationServiceAdapter}});var aqn=dBt();Object.defineProperty(iN,"getLocalEDMXService",{enumerable:!0,get:function(){return aqn.getLocalEDMXService}})});var aN=y(Ga=>{"use strict";Object.defineProperty(Ga,"__esModule",{value:!0});Ga.getMetadataElementsFromMap=Ga.createMetadataCollector=Ga.ASSOCIATION_NAME_LOCALIZED=Ga.ENTITY_PREFIX_LOCALIZED=Ga.DRAFT_MESSAGES_ELEMENT_NAME=Ga.HAS_ACTIVE_ENTITY_ELEM_NAME=Ga.IS_ACTIVE_ENTITY_ELEM_NAME=Ga.TYPE_NAME_OF_BINDING_PARAMETER=Ga.RETURN_PARAM_NAME=void 0;Ga.getMetadataCollector=mBt;Ga.RETURN_PARAM_NAME="$Return";Ga.TYPE_NAME_OF_BINDING_PARAMETER="$self";Ga.IS_ACTIVE_ENTITY_ELEM_NAME="IsActiveEntity";Ga.HAS_ACTIVE_ENTITY_ELEM_NAME="HasActiveEntity";Ga.DRAFT_MESSAGES_ELEMENT_NAME="DraftMessages";Ga.ENTITY_PREFIX_LOCALIZED="localized.";Ga.ASSOCIATION_NAME_LOCALIZED="localized";var oqn=(e,t)=>{let r=mBt(e);return t&&(r.facade=t),r};Ga.createMetadataCollector=oqn;function mBt(e){return{metadataElementMap:e||new Map,draftNodesPerService:new Map}}var sqn=e=>[...e.keys()].filter(r=>!e?.get(r)?.parentKey).map(r=>e?.get(r)?.node).filter(r=>r!==void 0);Ga.getMetadataElementsFromMap=sqn});var GE=y(sNe=>{"use strict";Object.defineProperty(sNe,"__esModule",{value:!0});sNe.getNameObj=cqn;function cqn(e,t){if(e?.name?.absolute)return e.name;if(e?.name)return t?.getArtifactName(e)}});var Sq=y(Oq=>{"use strict";Object.defineProperty(Oq,"__esModule",{value:!0});Oq.getServiceNameForEntity=void 0;Oq.getAssociation=lqn;var cNe=GE();function uqn(e){let t=!1,r;if(r=e,r.cardinality||(r._origin?.cardinality?r=r._origin:r.type?._artifact?.cardinality&&(r=r?.type?._artifact)),r?.cardinality?.targetMax){let n=r.cardinality.targetMax;t=n.literal==="string"&&n.val==="*"}return t}function lqn(e,t){let r;function n(i,a){return i?.type?._artifact?(0,cNe.getNameObj)(i.type?._artifact,a).absolute==="cds.Composition":!1}if(e){let i=e?._effectiveType,a;i?.kind==="element"&&(a=i?.target?._artifact,a?.name&&["entity","view"].includes(a?.kind)&&(r={target:(0,cNe.getNameObj)(a,t).absolute,isToMany:uqn(i),isComposition:n(e,t)}))}return r}var pqn=(e,t)=>{let r=!1,n=(0,cNe.getNameObj)(e,t?.compiler).absolute.split(".");n.pop();let i="";for(let a=0;a<n.length&&!r;a++)i+=i?"."+n[a]:n[a],r=t?.definitions[i].kind==="service";return r?i:""};Oq.getServiceNameForEntity=pqn});var uNe=y(o1=>{"use strict";Object.defineProperty(o1,"__esModule",{value:!0});o1.getStartLineColFromLocation=o1.getTextForLocationRange=void 0;o1.locationToRange=dqn;var fqn=Ht();function dqn(e){let{line:t,col:r,endLine:n,endCol:i}=e||{};return t=t||1,r=r||1,n=n||t||1,i=i||r||1,fqn.Range.create(t-1,r-1,n-1,i-1)}var hqn=`
|
|
1154
|
+
`)}function wjn(e,t,r){return(0,Br.printCsdlNodeToXmlString)((0,fr.createElementNode)(e.newElement),tN,{namespaces:r,cursorIndentLevel:t}).trim()}function Pjn(e,t,r){return(0,Br.printCsdlNodeToXmlString)(e.newValue,tN,{namespaces:r,cursorIndentLevel:t}).trim()}function Djn(e,t,r=-1){let n=r!==-1?t.subElements[r]:void 0;if(n){let o=ZUt(n.position),s=Njn(e,o),c=XUt(t,r);if(!c)return{type:"none"};let u=s?s.range.start:o.start,l=u.line===c.end.line,p=l?u:fr.Position.create(u.line,0),f=l?fr.Range.create(c.end,u):void 0;return{type:"child",position:p,requiresNewLine:l,redundantWhitespace:f}}let i=(0,Br.transformRange)(t.syntax.closeBody),a=XUt(t,t.subElements.length);if(i&&a){let o=i.start;return{type:"parent",position:o.line===a.end.line?o:fr.Position.create(o.line,0),requiresNewLine:!1}}return{type:"none"}}function XUt(e,t){let r=e.subElements[t-1];if(t===0)return(0,Br.transformRange)(e.syntax.openBody);if(r)return ZUt(r.position)}function Njn(e,t){let r=t.start.line-1;for(let n of e)if(n.range.end.line===r||n.range.start.line===t.end.line)return n}function ZUt(e){return fr.Range.create(e.startLine-1,e.startColumn-1,e.endLine-1,e.endColumn)}function Ijn(e){if(e?.type==="XMLElement"){let t=(0,Br.transformRange)(e.syntax.openBody);if(t)return(0,a1.getIndentLevel)(t.start.character,tN.tabWidth)+1}return 0}function Rjn(e,t){let r=[],n=t.reduce((i,a)=>{let o=a.split("/"),s=o.slice(0,-2).join("/"),c=Number.parseInt(o.slice(-1)[0],10),u=i.get(s);return u?u.push(c):i.set(s,[c]),i},new Map);for(let[i,a]of n){let o=(0,EZ.getNodeFromPointer)(e,i);if(o?.type==="XMLElement"){a.sort((s,c)=>s-c);for(let s=1,c=a[0],u=a[0];s<=a.length;s++){let l=a[s];l===void 0?r.push({parent:o,start:c,end:u}):u+1===l?u=l:(r.push({parent:o,start:c,end:u}),c=u=l)}}}return r}function Ljn(e,t){let r=(0,Br.transformRange)(e.position);if(!r)return[];let n=t.filter(o=>kjn(r,o,e)),i=[...e.subElements,...n].sort($jn),a=[];for(let o=0;o<i.length;o++){let s=i[o];if(s.type!=="XMLElement"){a.push(s);continue}let c=(0,Br.transformRange)(s.position);if(!c)continue;let u={type:"element",element:s,elementRange:c,range:(0,Tq.copyRange)(c)},l=a[a.length-1],p=u.range.start.line-1;l?.type==="comment"&&(l.range.end.line===p||l.range.end.line===u.range.start.line)&&(u.leadingComment=a.pop(),_Z(u.range.start,l.range.start));let f=i[o+1];f?.type==="comment"&&f.range.start.line===c.end.line&&(u.trailingComment=f,_Z(u.range.end,f.range.end),o++),a.push(u)}return a}function kjn(e,t,r){return(0,a1.rangeContained)(e,t.range)&&!r.subElements.some(n=>{let i=(0,Br.transformRange)(n.position);return i?(0,a1.rangeContained)(i,t.range):!1})}function $jn(e,t){let r=e.range??(0,Br.transformRange)(e.syntax?.closeBody??e.syntax?.openBody),n=t.range??(0,Br.transformRange)(t.syntax?.closeBody??t.syntax?.openBody);return r?!n||(0,a1.isBefore)(r.start,n.start)?-1:(0,a1.isBefore)(n.start,r.start)?1:0:1}function QUt(e,t,r){let n=-1,i=-1,a=-1;for(let o=0,s=0;o<r.length;o++)if(r[o].type==="element"){if(e-1===s&&(n=o),e===s&&(i=o),t===s){a=o;break}s++}return{previousContentIndex:n,startContentIndex:i,endContentIndex:a}}function Mjn(e,t,r,n){let{previousContentIndex:i,startContentIndex:a,endContentIndex:o}=QUt(r,n,e),s=e[o],c=eBt(e,t,i,a)?.start,u=s?.range?.end;if(c&&(c=(0,Tq.copyPosition)(c)),u&&(u=(0,Tq.copyPosition)(u)),!(!c||!s))return fr.Range.create(c,u)}function eBt(e,t,r,n){let i=e[r],a=n===0?(0,Br.transformRange)(t.syntax.openBody)?.end:i?.range?.end,o=e[n];if(a&&(a=(0,Tq.copyPosition)(a)),!a||!o)return;let s=e[n-1];return s?.type==="comment"&&_Z(a,s.range.end),fr.Range.create(a,(0,Tq.copyPosition)(o.range.end))}function _Z(e,t){e.line=t.line,e.character=t.character}function JUt(e,t){if(!t)return;let r=e.filter(n=>n.range.start.line===t.end.line&&n.range.start.character>t.end.character);if(r.length){let n=t.end;for(let i of r)i.range.start.character>n.character&&(n=i.range.end);t.end=n}}function Fjn(e,t,r){if(e===0)return(0,Br.transformRange)(t.syntax.openBody)?.end;if(e===void 0||e>=t.subElements.length){let n=t.subElements[t.subElements.length-1];if(!n)return;let i=(0,Br.transformRange)(n.syntax.closeBody??n.syntax.openBody);return JUt(r,i),i?.end}else if(e>0){let n=t.subElements[e-1],i=(0,Br.transformRange)(n.syntax.closeBody??n.syntax.openBody);return JUt(r,i),i?.end}}function eNe(e){let t={};for(let r of Object.keys(e.namespaces)){if(r===fjn.DEFAULT_NS)continue;let n=e.namespaces[r];n===Br.EDMX_V4_NAMESPACE?t[fr.EDMX_NAMESPACE_ALIAS]=r:n===Br.EDM_V4_NAMESPACE&&(t[fr.EDM_NAMESPACE_ALIAS]=r)}return t}function jjn(e){let t={};for(let r of Object.keys(e.attributes)){if(!r.startsWith("xmlns"))continue;let{name:n,value:i}=e.attributes[r],[,a]=n.split(":");a!==void 0&&(i===Br.EDMX_V4_NAMESPACE?t[fr.EDMX_NAMESPACE_ALIAS]=a:i===Br.EDM_V4_NAMESPACE&&(t[fr.EDM_NAMESPACE_ALIAS]=a))}return t}function qjn(e,t){let r=Ujn(e);return r=Bjn(r),r=Vjn(r,t),r}function Vjn(e,t){let r=[],n=new Set,i=new Map;for(let a=e.length-1;a>=0;a--){let o=e[a];if(o.type!=="insert-element")continue;let s=(0,EZ.getNodeFromPointer)(t,o.pointer);if(s?.type!=="XMLElement")continue;let c=o.index??s.subElements.length-1,u=`${o.pointer}/subElements/${c}`,l=e.findIndex(p=>p.pointer===u&&p.type==="delete-element");l!==-1&&!i.has(l)&&(i.set(l,{type:"replace-element",pointer:u,newElement:o.element}),n.add(a))}for(let a=0;a<e.length;a++){let o=e[a],s=i.get(a);s?r.push(s):n.has(a)||r.push(o)}return r}function Ujn(e){let t=[],r=[];for(let n of e)n.type==="delete-element"?t.indexOf(n.pointer)===-1&&(t.push(n.pointer),r.push(n)):r.push(n);return r}function Bjn(e){let t=[],r=new Set;for(let n of e)if(n.type==="delete-element"){let i=n.pointer.split("/").length;for(let a=0;a<e.length;a++){let o=e[a],s=o.pointer.split("/").length;(o.type==="delete-element"||o.type==="delete-attribute")&&o.pointer.startsWith(n.pointer)&&o.pointer!==n.pointer&&s!==i&&r.add(a)}}for(let n=0;n<e.length;n++){let i=e[n];r.has(n)||t.push(i)}return t}});var nBt=y(tNe=>{"use strict";Object.defineProperty(tNe,"__esModule",{value:!0});tNe.collectUsedNamespaces=OZ;var TZ=Ht(),zjn=Nr();function OZ(e,t){switch(e.type){case TZ.ANNOTATION_FILE_TYPE:{for(let r of e.targets)OZ(r,t);break}case TZ.TARGET_TYPE:{e.name&&rN(e.name,t);for(let r of e.terms)OZ(r,t);break}case TZ.ELEMENT_TYPE:{Hjn(e,t);break}default:break}}var rBt=["Path","PropertyPath","NavigationPropertyPath","AnnotationPath"];function Hjn(e,t){if(e.name==="Annotation"){let r=e.attributes.Term;r?.value&&rN(r.value,t)}if(e.name==="Record"){let r=e.attributes.Type;r?.value&&rN(r.value,t)}if(e.name==="PropertyValue"||e.name==="Annotation"){let r=e.attributes.EnumMember;r?.value&&rN(r.value,t)}Gjn(e,t)}function Gjn(e,t){if(rBt.includes(e.name)){let r=e.content.find(n=>n.type===TZ.TEXT_TYPE);r&&rN(r.text,t)}else{for(let r of rBt){let n=e.attributes[r];n?.value&&rN(n.value,t)}for(let r of e.content)OZ(r,t)}}function rN(e,t){let r=(0,zjn.parsePath)(e);for(let n of r.segments)n.namespaceOrAlias&&t.add(n.namespaceOrAlias)}});var iBt=y(rNe=>{"use strict";Object.defineProperty(rNe,"__esModule",{value:!0});rNe.collectComments=Yjn;var Kjn=Ht();function Yjn(e){let t=[];for(let r of e){if(r.tokenTypeIdx!==3)continue;let n=Wjn(r);n&&t.push({type:"comment",value:r.image,range:n})}return t}function Wjn(e){let t=e.startLine??-1,r=e.startColumn??-1,n=e.endLine??-1,i=e.endColumn??-1;if(!(t===-1||r===-1||n===-1||i===-1))return Kjn.Range.create(t-1,r-1,n-1,i)}});var pBt=y(CZ=>{"use strict";Object.defineProperty(CZ,"__esModule",{value:!0});CZ.XMLAnnotationServiceAdapter=void 0;var uBt=KPe(),lBt=UPe(),nNe=KT(),nN=aDe(),uh=Ht(),SZ=Nr(),aBt=sDe(),wc=XJ(),AZ=nh(),Xjn=tBt(),iNe=WDe(),oBt=nBt(),Jjn=iBt(),sBt=JDe(),aNe=class{service;vocabularyService;project;appName;metadataService=new aBt.MetadataService;splitAnnotationSupport=!1;fileCache;documents=new Map;metadata=[];setFileCache(t){this.fileCache=t}_compiledService;get compiledService(){return this._compiledService||(this._compiledService=this._getCompiledService()),this._compiledService}set compiledService(t){this._compiledService=t}constructor(t,r,n,i){this.service=t,this.vocabularyService=r,this.project=n,this.appName=i,this.fileCache=new Map}sync(t){this.documents.clear(),this._compiledService=void 0,this.setFileCache(t);let{ast:r,comments:n}=cBt(t,this.service.metadataFile);this.documents.set(this.service.metadataFile.uri,{uri:this.service.metadataFile.uri,comments:n,ast:r,annotationFile:(0,nN.convertDocument)(this.service.metadataFile.uri,r),usedNamespaces:new Set});for(let i of this.service.annotationFiles){let{ast:a,comments:o}=cBt(t,i,!1),s=(0,nN.convertDocument)(i.uri,a),c=new Set;(0,oBt.collectUsedNamespaces)(s,c),this.documents.set(i.uri,{uri:i.uri,comments:o,ast:a,annotationFile:s,usedNamespaces:c})}this.addMissingMetadataReferences(),this.metadata=(0,nN.convertMetadataDocument)(this.service.metadataFile.uri,r),this.metadataService=new aBt.MetadataService({ODataVersion:this.service.odataVersion,isCds:!1}),this.metadataService.import(this.metadata,this.service.metadataFile.uri)}getAllFiles(){return[this.service.metadataFile,...this.service.annotationFiles]}getInitialFileContent(t,r){let n=this.appName||Object.keys(this.project.apps)[0],i=`${this.project.apps[n].services[t].uri}$metadata`,a=[...this.metadataService.getNamespaces()][0],o=tqn({references:[{name:a,uri:i,type:"reference",alias:"Metadata"}],targets:[],type:"annotation-file",uri:r,namespace:{name:this.getUniqueNamespace(a),type:"namespace"}},this.metadataService),s=this.vocabularyService.getVocabularies();return(0,nN.getNewAnnotationFile)(o,i,s).fileContent}async getWorkspaceEdit(t){let r={},n=new Map,i={};for(let a of t){let o=n.get(a.uri),s=this.documents.get(a.uri),c=i[a.uri]??=new Map;if(s){if(!o){let u=nNe.TextDocument.create(a.uri,"cds",0,this.fileCache?.get(a.uri)??"");o=new Xjn.XMLWriter(s.ast,s.comments,u),n.set(a.uri,o)}this.processChange(s,o,c,a)}}for(let[a,o]of n.entries()){let s=i[a]??=new Map;for(let[l,p]of s.entries())p.size===0&&o.addChange({type:"delete-element",pointer:l});let c=o.getTextEdits(),u=this.postprocessEdits(a,o,c);u.length&&(c=u),r[a]=c}return{changes:r}}validateChanges(t){return this.sync(t)}serializeTarget(t){return(0,nN.serializeTarget)(t)}getUniqueNamespace(t){let r=new Set;this.documents.forEach(a=>{let o=a.annotationFile.namespace;o&&r.add(o.name)});let n=`${t}.annotations`,i=0;for(;[...r].includes(n)&&(++i,n=`${n}${i}`,!![...r].includes(n)););return n}_getCompiledService(){let t=[this.service.metadataFile,...this.service.annotationFiles],r=[];for(let n of t){let i=this.documents.get(n.uri);if(i)r.push(i.annotationFile);else throw new AZ.ApiError(`Could not compile service. Missing document ${n.uri}`,AZ.ApiErrorCode.General)}return Object.freeze({odataVersion:this.service.odataVersion,annotationFiles:r,metadata:this.metadata})}processChange(t,r,n,i){switch(i.type){case wc.INSERT_TARGET:{let a=ch(t.ast);Zm(!a,`Could not process change ${i.type} ${i.uri} ${i.target}`);let o=(0,uh.createElementNode)({name:"Annotations",attributes:{Target:(0,uh.createAttributeNode)("Target",i.target.name)},content:i.target.terms});r.addChange({type:wc.INSERT_ELEMENT,pointer:a,element:o});break}case wc.INSERT_ELEMENT:{let a=ch(t.ast);Zm(!a,`Could not process change ${i.type} ${i.uri} ${i.pointer} ${i.element.name}`);let o=a+vp(t.annotationFile,i.pointer),s=(0,sBt.getNodeFromPointer)(t.ast,o);s?.type==="XMLElement"&&s.name==="Annotations"&&this.markElementInsertion(n,o,s),r.addChange({type:wc.INSERT_ELEMENT,pointer:a+vp(t.annotationFile,i.pointer),element:i.element,index:i.index});break}case wc.DELETE_ELEMENT:{let a=ch(t.ast);Zm(!a,`Could not process change ${i.type} ${i.uri} ${i.pointer} `);let o=a+vp(t.annotationFile,i.pointer),s=(0,sBt.getNodeFromPointer)(t.ast,o);s?.type==="XMLElement"&&s.name==="Annotation"&&s.parent?.type==="XMLElement"&&s.parent.name==="Annotations"&&this.markElementDeletion(n,o,s.parent),r.addChange({type:"delete-element",pointer:o});break}case wc.DELETE_ATTRIBUTE:{let a=ch(t.ast);Zm(!a,`Could not process change ${i.type} ${i.uri} ${i.pointer} `),r.addChange({type:"delete-attribute",pointer:a+vp(t.annotationFile,i.pointer)});break}case wc.UPDATE_ATTRIBUTE_VALUE:{let a=ch(t.ast);Zm(!a,`Could not process change ${i.type} ${i.uri} ${i.pointer} `),r.addChange({type:wc.UPDATE_ATTRIBUTE_VALUE,pointer:a+vp(t.annotationFile,i.pointer),newValue:i.newValue});break}case wc.REPLACE_ATTRIBUTE:{let a=ch(t.ast);Zm(!a,`Could not process change ${i.type} ${i.uri} ${i.pointer} `),r.addChange({type:"update-attribute-name",pointer:a+vp(t.annotationFile,i.pointer),newName:i.newAttributeName}),r.addChange({type:wc.UPDATE_ATTRIBUTE_VALUE,pointer:a+vp(t.annotationFile,i.pointer),newValue:i.newAttributeValue});break}case wc.REPLACE_ELEMENT:{let a=ch(t.ast);Zm(!a,`Could not process change ${i.type} ${i.uri} ${i.pointer} `),r.addChange({type:"replace-element",pointer:a+vp(t.annotationFile,i.pointer),newElement:i.newElement});break}case iNe.REPLACE_ELEMENT_CONTENT:{let a=ch(t.ast);Zm(!a,`Could not process change ${i.type} ${i.uri} ${i.pointer} `),r.addChange({type:iNe.REPLACE_ELEMENT_CONTENT,pointer:a+vp(t.annotationFile,i.pointer),newValue:i.newValue});break}case wc.INSERT_ATTRIBUTE:{let a=ch(t.ast);Zm(!a,`Could not process change ${i.type} ${i.uri} ${i.pointer} ${i.name}`),r.addChange({type:"insert-attribute",pointer:a+vp(t.annotationFile,i.pointer),name:i.name,value:i.value});break}case wc.MOVE_ELEMENT:{let a=ch(t.ast);if(a){let o=a+vp(t.annotationFile,i.pointer);r.addChange({type:"move-collection-value",pointer:o,index:i.index,fromPointers:i.fromPointers.map(s=>a+vp(t.annotationFile,s))})}break}case wc.REPLACE_TEXT:{let a=ch(t.ast);if(a){let o=a+vp(t.annotationFile,i.pointer);r.addChange({type:iNe.REPLACE_ELEMENT_CONTENT,pointer:o.split("/").slice(0,-3).join("/"),newValue:[i.text]})}}break;default:break}}getTargetChildReferences(t,r,n){let i=t.get(r);if(i)return i;let a=new Set;for(let o=0;o<n.subElements.length;o++)n.subElements[o].type==="XMLElement"&&a.add(`${r}/subElements/${o}`);return t.set(r,a),a}markElementDeletion(t,r,n){let i=r.split("/").slice(0,-2).join("/");this.getTargetChildReferences(t,i,n).delete(r)}markElementInsertion(t,r,n){this.getTargetChildReferences(t,r,n).add(`${r}/subElements/-1`)}postprocessEdits(t,r,n){let i=this.fileCache.get(t),a=this.documents.get(t);if(!i||!a)return[];let o=nNe.TextDocument.applyEdits(nNe.TextDocument.create(t,"",0,i),n),{cst:s,tokenVector:c}=(0,lBt.parse)(o),u=(0,uBt.buildAst)(s,c);return this.updateReferences(t,r,u)?r.getTextEdits():[]}updateReferences(t,r,n){let i=this.documents.get(t);if(!i)return!1;let a=(0,nN.convertDocument)(t,n),o=new Set;(0,oBt.collectUsedNamespaces)(a,o);let s=(0,SZ.getAllNamespacesAndReferences)(a.namespace,a.references),c=(0,SZ.getAliasInformation)(s,this.metadataService.getNamespaces()),u=Qjn(i.ast);Zm(!u,`No root EDMX element found in ${t}`);let l=this.removeReferences(r,i,c,o,u),p=this.addReferences(r,i,c,o,u);return l||p}removeReferences(t,r,n,i,a){let o=new Set;for(let s of Object.keys(n.aliasMapVocabulary)){let c=n.aliasMapVocabulary[s],u=n.reverseAliasMap[c];!i.has(c)&&u!==void 0&&!i.has(u)&&o.add(c)}for(let s of o)for(let c=0;c<r.ast.rootElement.subElements.length;c++)r.ast.rootElement.subElements[c].subElements.find(p=>p.name==="Include"&&p.attributes.find(f=>f.key==="Namespace")?.value===s)&&t.addChange({type:wc.DELETE_ELEMENT,pointer:`${a}/subElements/${c}`});return o.size>0}addReferences(t,r,n,i,a){let o=new Set;for(let s of i)if(!n.aliasMapVocabulary[s]){let c=this.vocabularyService.getVocabularyNamespace(s);c&&o.add(c)}for(let s of o){let c=this.vocabularyService.getVocabulary(s);if(!c)continue;let u=c.defaultAlias,l=c.defaultUri,p=(0,uh.createReference)(s,u,l);t.addChange({type:wc.INSERT_ELEMENT,pointer:a,element:Zjn(p),index:r.ast.rootElement.subElements.length>0?0:void 0})}return o.size>0}addMissingMetadataReferences(){let t=this.documents.get(this.service.metadataFile.uri);if(!t)return;let r=t.annotationFile.namespace;if(r)for(let n of this.service.annotationFiles){let i=this.documents.get(n.uri);if(!i)continue;let{annotationFile:a}=i,o=a.references.find(s=>s.name===r.name);if(o)o.alias===void 0&&r.alias!==void 0&&(o.alias=r.alias);else{let s=(0,uh.createReference)(r.name,r.alias);a.references.push(s)}}}};CZ.XMLAnnotationServiceAdapter=aNe;function Zm(e,t){if(e)throw new AZ.ApiError(t,AZ.ApiErrorCode.General)}function Zjn(e){let t=(0,uh.createElementNode)({name:"Include",namespaceAlias:"Edmx",attributes:{Namespace:(0,uh.createAttributeNode)("Namespace",e.name)}});return e.alias&&(t.attributes.Alias=(0,uh.createAttributeNode)("Alias",e.alias)),(0,uh.createElementNode)({name:"Reference",namespaceAlias:"Edmx",content:[t],attributes:{Uri:(0,uh.createAttributeNode)("Uri",e.uri??"")}})}function Qjn(e){if(e.rootElement)return"/rootElement"}function ch(e){if(!e.rootElement)return;let t=e.rootElement.subElements.findIndex(n=>n.name==="DataServices");if(t===-1)return;let r=e.rootElement.subElements[t].subElements.findIndex(n=>n.name==="Schema");if(r!==-1)return`/rootElement/subElements/${t}/subElements/${r}`}function cBt(e,t,r=!0){let n=e.get(t.uri);if(typeof n!="string")throw new Error(`File ${t.uri} not found in cache!`);let{cst:i,tokenVector:a}=(0,lBt.parse)(n),o=r?[]:(0,Jjn.collectComments)(a);return{ast:(0,uBt.buildAst)(i,a),comments:o}}function vp(e,t){let r=e;return t.split("/").map((n,i,a)=>{if(n==="content"||n==="targets"||n==="terms")return a[i+2]==="text"?(r=r.textContents,"textContents"):(r&&(r=r[n]),"subElements");if(i!==0&&r){let o=eqn(n,r);return r=o.nextNode,o.mappedSegment}return n}).join("/")}function eqn(e,t){let r=-1,n=Number.parseInt(e,10),i=t[e];if(Number.isSafeInteger(n)&&Array.isArray(t))for(let o=0;o<=n&&o<t.length;o++)t[o].type===uh.ELEMENT_TYPE&&r++;else!Array.isArray(i)&&i?.type===uh.ATTRIBUTE_TYPE&&(r=Object.keys(t).findIndex(o=>o===e));return{mappedSegment:r!==-1?r.toString():e,nextNode:i}}function tqn(e,t){let r=(0,SZ.getAllNamespacesAndReferences)(e.namespace,e.references);return(0,SZ.getAliasInformation)(r,t.getNamespaces())}});var dBt=y(oNe=>{"use strict";Object.defineProperty(oNe,"__esModule",{value:!0});oNe.getLocalEDMXService=rqn;var fBt=require("node:url");function rqn(e,t,r){let i=e.apps[nqn(r,e)]?.services[t];if(!i?.local)throw new Error(`Metadata file for service ${t} in app ${r} is not found!`);let a=i.local??"",s={uri:(0,fBt.pathToFileURL)(a).toString(),isReadOnly:!0},c=i?.annotations??[],u=c.map(d=>(0,fBt.pathToFileURL)(d.local??"").toString()),l=c.findIndex((d,h)=>typeof d.local=="string"&&typeof d.uri=="string"&&!u[h].endsWith(d.uri)),p=u[l]??"",f=u.map(d=>({uri:d,isReadOnly:d===p}));return{type:"local-edmx",odataVersion:i.odataVersion??"2.0",metadataFile:s,annotationFiles:f}}function nqn(e,t){return e&&t.apps[e]?e:t.apps[""]?"":Object.keys(t.apps)[0]||""}});var hBt=y(iN=>{"use strict";Object.defineProperty(iN,"__esModule",{value:!0});iN.getLocalEDMXService=iN.XMLAnnotationServiceAdapter=void 0;var iqn=pBt();Object.defineProperty(iN,"XMLAnnotationServiceAdapter",{enumerable:!0,get:function(){return iqn.XMLAnnotationServiceAdapter}});var aqn=dBt();Object.defineProperty(iN,"getLocalEDMXService",{enumerable:!0,get:function(){return aqn.getLocalEDMXService}})});var aN=y(Ga=>{"use strict";Object.defineProperty(Ga,"__esModule",{value:!0});Ga.getMetadataElementsFromMap=Ga.createMetadataCollector=Ga.ASSOCIATION_NAME_LOCALIZED=Ga.ENTITY_PREFIX_LOCALIZED=Ga.DRAFT_MESSAGES_ELEMENT_NAME=Ga.HAS_ACTIVE_ENTITY_ELEM_NAME=Ga.IS_ACTIVE_ENTITY_ELEM_NAME=Ga.TYPE_NAME_OF_BINDING_PARAMETER=Ga.RETURN_PARAM_NAME=void 0;Ga.getMetadataCollector=mBt;Ga.RETURN_PARAM_NAME="$Return";Ga.TYPE_NAME_OF_BINDING_PARAMETER="$self";Ga.IS_ACTIVE_ENTITY_ELEM_NAME="IsActiveEntity";Ga.HAS_ACTIVE_ENTITY_ELEM_NAME="HasActiveEntity";Ga.DRAFT_MESSAGES_ELEMENT_NAME="DraftMessages";Ga.ENTITY_PREFIX_LOCALIZED="localized.";Ga.ASSOCIATION_NAME_LOCALIZED="localized";var oqn=(e,t)=>{let r=mBt(e);return t&&(r.facade=t),r};Ga.createMetadataCollector=oqn;function mBt(e){return{metadataElementMap:e||new Map,draftNodesPerService:new Map}}var sqn=e=>[...e.keys()].filter(r=>!e?.get(r)?.parentKey).map(r=>e?.get(r)?.node).filter(r=>r!==void 0);Ga.getMetadataElementsFromMap=sqn});var GE=y(sNe=>{"use strict";Object.defineProperty(sNe,"__esModule",{value:!0});sNe.getNameObj=cqn;function cqn(e,t){if(e?.name?.absolute)return e.name;if(e?.name)return t?.getArtifactName(e)}});var Sq=y(Oq=>{"use strict";Object.defineProperty(Oq,"__esModule",{value:!0});Oq.getServiceNameForEntity=void 0;Oq.getAssociation=lqn;var cNe=GE();function uqn(e){let t=!1,r;if(r=e,r.cardinality||(r._origin?.cardinality?r=r._origin:r.type?._artifact?.cardinality&&(r=r?.type?._artifact)),r?.cardinality?.targetMax){let n=r.cardinality.targetMax;t=n.literal==="string"&&n.val==="*"}return t}function lqn(e,t){let r;function n(i,a){return i?.type?._artifact?(0,cNe.getNameObj)(i.type?._artifact,a).absolute==="cds.Composition":!1}if(e){let i=e?._effectiveType,a;i?.kind==="element"&&(a=i?.target?._artifact,a?.name&&["entity","view"].includes(a?.kind)&&(r={target:(0,cNe.getNameObj)(a,t).absolute,isToMany:uqn(i),isComposition:n(e,t)}))}return r}var pqn=(e,t)=>{let r=!1,n=(0,cNe.getNameObj)(e,t?.compiler).absolute.split(".");n.pop();let i="";for(let a=0;a<n.length&&!r;a++)i+=i?"."+n[a]:n[a],r=t?.definitions[i].kind==="service";return r?i:""};Oq.getServiceNameForEntity=pqn});var uNe=y(o1=>{"use strict";Object.defineProperty(o1,"__esModule",{value:!0});o1.getStartLineColFromLocation=o1.getTextForLocationRange=void 0;o1.locationToRange=dqn;var fqn=Ht();function dqn(e){let{line:t,col:r,endLine:n,endCol:i}=e||{};return t=t||1,r=r||1,n=n||t||1,i=i||r||1,fqn.Range.create(t-1,r-1,n-1,i-1)}var hqn=`
|
|
1155
1155
|
`,mqn=(e,t)=>{if(!e||!e.col||!e.line||!e.endCol||e.line>e.endLine)return"";if(!e.endLine||e.line===e.endLine){let r=t[e.line-1];return r.length<e.endCol?gqn(e,r,t):r.substring(e.col-1,e.endCol-1)}else{let r=t[e.line-1].substring(e.col-1)+`
|
|
1156
1156
|
`;for(let n=e.line+1;n<e.endLine;n++)r+=t[n-1]+`
|
|
1157
1157
|
`;return r+=t[e.endLine-1].substring(0,e.endCol-1),r}};o1.getTextForLocationRange=mqn;function gqn(e,t,r){let n=t.substring(e.col-1,e.endCol-1),i=e.endCol-e.col,a=1;for(;n.length<i;){let o=r[e.line-1+a];if(n+=hqn,o){let s=i-n.length;s<o.length?n+=o.substring(0,s):n+=o.substring(0)}a++}return n}var yqn=e=>{let t=e?.line||0,r=e?.col??-1;return{line:t,col:r}};o1.getStartLineColFromLocation=yqn});var yBt=y(lNe=>{"use strict";Object.defineProperty(lNe,"__esModule",{value:!0});lNe.findUsing=bqn;var gBt=Nr(),vqn=uNe();function bqn(e,t){return(e||[]).find(r=>{if(r.location&&t.location?.line){let n=gBt.Position.create(t.location.line-1,t.location.col);return(0,gBt.positionContained)((0,vqn.locationToRange)(r.location),n)}else return!1})}});var Aq=y(bp=>{"use strict";var Eqn=bp&&bp.__createBinding||(Object.create?function(e,t,r,n){n===void 0&&(n=r);var i=Object.getOwnPropertyDescriptor(t,r);(!i||("get"in i?!t.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,i)}:function(e,t,r,n){n===void 0&&(n=r),e[n]=t[r]}),_qn=bp&&bp.__exportStar||function(e,t){for(var r in e)r!=="default"&&!Object.prototype.hasOwnProperty.call(t,r)&&Eqn(t,e,r)};Object.defineProperty(bp,"__esModule",{value:!0});bp.locationToRange=bp.getTextForLocationRange=bp.getStartLineColFromLocation=void 0;var pNe=uNe();Object.defineProperty(bp,"getStartLineColFromLocation",{enumerable:!0,get:function(){return pNe.getStartLineColFromLocation}});Object.defineProperty(bp,"getTextForLocationRange",{enumerable:!0,get:function(){return pNe.getTextForLocationRange}});Object.defineProperty(bp,"locationToRange",{enumerable:!0,get:function(){return pNe.locationToRange}});_qn(yBt(),bp)});var DZ=y(PZ=>{"use strict";Object.defineProperty(PZ,"__esModule",{value:!0});PZ.Converter=void 0;var xqn=Ht(),Cq=Aq(),vBt=GE(),oN=aN(),Tqn=Sq(),bBt="@odata.Type",EBt="@odata.singleton",Oqn="@Core.MediaType",Sqn="@cds.odata.bindingparameter.name",_Bt="@cds.odata.bindingparameter.collection",wZ="Edm.Binary",sN="Edm.String",fNe="Edm.Decimal",xBt={"cds.Association":"","cds.Composition":"","cds.Binary":wZ,"cds.Boolean":"Edm.Boolean","cds.Date":"Edm.Date","cds.DateTime":"Edm.DateTimeOffset","cds.Decimal":fNe,"cds.DecimalFloat":fNe,"cds.Double":"Edm.Double","cds.Integer":"Edm.Int32","cds.Integer64":"Edm.Int64","cds.Int64":"Edm.Int64","cds.Int32":"Edm.Int32","cds.Int16":"Edm.Int16","cds.UInt8":"Edm.Byte","cds.LargeBinary":wZ,"cds.LargeString":sN,"cds.String":sN,"cds.Time":"Edm.TimeOfDay","cds.Timestamp":"Edm.DateTimeOffset","cds.UUID":"Edm.Guid","cds.hana.BINARY":wZ,"cds.hana.CHAR":sN,"cds.hana.CLOB":sN,"cds.hana.NCHAR":sN,"cds.hana.REAL":"Edm.Single","cds.hana.SMALLDECIMAL":fNe,"cds.hana.SMALLINT":"Edm.Int16","cds.hana.ST_GEOMETRY":"Edm.Geometry","cds.hana.ST_POINT":"Edm.GeometryPoint","cds.hana.TINYINT":"Edm.Byte","cds.hana.VARCHAR":sN,"cds.hana.Object":wZ},Aqn={service:["EntityContainer","Schema"],entitySet:["EntitySet"],entity:["EntityType","EntitySet"],view:["EntityType","EntitySet"],aspect:["ComplexType","EntityType","EntitySet"],element:["Property"],action:["Action","ActionImport"],function:["Function","FunctionImport"],actionImport:["Action"],functionImport:["FunctionImport"],param:["Parameter"],type:["TypeDefinition","Property","Parameter"]},Cqn=new Map(Object.entries(Aqn)),dNe=class{constructor(t,r){this.facade=r,this.convertArtifact=n=>{let i;if(n?.kind==="service"){let a=this.getNameObj(n).absolute+".EntityContainer",o=this.buildNode(n.kind,a,"",this.getOrigin(n));o.content=[],i=o}else if(n?.kind==="entity"||n?.kind==="view"){let a=n,o=this.getElementName(a),s=this.convertNameToEdmx(this.getNameObj(n).absolute)??"",c=this.buildNode("entity",s,"",this.getOrigin(a));c.isEntityType=!0,c.isCollectionValued=!0,c.content=[],o.length&&(o.sort((u,l)=>u.localeCompare(l)),c.keys=o),i=c}else if(n?.kind==="action"||n?.kind==="function"){let a=n,o=this.getNameObj(a).absolute+this.getActionNodeSignature(a),s=this.buildNode(a.kind,o,"",this.getOrigin(a));s.content=[],i=s}else if(n?.kind==="type"||n?.kind==="aspect"){let a=n,o=n?.elements?"aspect":"type",s=this.buildNode(o,this.getNameObj(a).absolute,"",n.builtin?void 0:this.getOrigin(a),this.getPrimitiveType(n));o==="aspect"&&(s.isComplexType=!0),s.content=[],i=s}return i&&(i.targetKinds=this.getEdmTargetKinds(i)),i},this.convertElement=(n,i,a)=>{let o=[];if(a){let s=this.buildNode(a.kind,n,i,this.getOrigin(a),this.getPrimitiveType(a)),c=(0,Tqn.getAssociation)(a,this.compiler);if(c){if(n===oN.ASSOCIATION_NAME_LOCALIZED)return[];s.structuredType=this.convertNameToEdmx(c.target),s.isCollectionValued=c.isToMany,s.isEntityType=!0}let u=a._effectiveType,l=a.items?a._effectiveType?.items?._effectiveType?.elements:a._effectiveType?.elements,p=this.getNameObj(a.items?.type?._artifact||a._effectiveType);a.enum&&(s.enumValues=this.convertEnums(a.enum)),a.items&&(s.isCollectionValued=!0),s.targetKinds=this.getEdmTargetKinds(s),o.push(...this.collectElementsFromStructuredType(u,p,l,s,n,i)),o.push(s),o.push(...this.getAssociationKeyFieldElements(a,n,i))}return o},this.convertBoundAction=(n,i,a)=>{let o=this.getNamespace(n)+"."+i+this.getActionNodeSignature(a,n),s=this.buildNode(a.kind,o,void 0,this.getOrigin(a));return s.targetKinds=this.getEdmTargetKinds(s),s},this.convertParameter=(n,i,a)=>{if(a){let o=this.buildNode(a.kind,n,i,this.getOrigin(a),this.getPrimitiveType(a));return this.setStructuredType(o,a),a.items&&(o.isCollectionValued=!0),a.enum&&(o.enumValues=this.convertEnums(a.enum)),o.targetKinds=this.getEdmTargetKinds(o),o}},this.convertBindingParameter=(n,i,a)=>{let o=(d,h)=>{let m=d?.[h]?.val;return m&&typeof m=="string"?m:void 0},s=Object.keys(n?.params||{}).find(d=>{let h=n?.params?.[d],m=(h?.items||h)?.type?.path;return m?.length===1&&m[0]?.id===oN.TYPE_NAME_OF_BINDING_PARAMETER}),c=s?n?.params?.[s]:void 0,u=c?this.getOrigin(c):void 0;s||(s=o(n,Sqn)),s||(s=o(n,_Bt)),s=s||"in";let l;n&&(l=this.getOrigin(n),l.name+="."+s,l.location&&u?.location&&(l.location.range=u.location.range));let p=this.buildNode("param",s,a,l);p.isAnnotatable=!1,p.isCollectionValued=!!(n?.params?.[s]?.items||n?.[_Bt]?.val),p.isEntityType=!0;let f=this.getNameObj(i);return p.structuredType=this.convertNameToEdmx(f.absolute),p.targetKinds=this.getEdmTargetKinds(p),p},this.convertReturnParameter=(n,i)=>{let a=n?.returns,o;n&&(o=this.getOrigin(n),o.name+="."+oN.RETURN_PARAM_NAME);let s=this.buildNode("param",oN.RETURN_PARAM_NAME,i,o,this.getPrimitiveType(a));return this.setStructuredType(s,a),a?.items&&(s.isCollectionValued=!0),s.targetKinds=this.getEdmTargetKinds(s),s},this.convertDraftPropertyNode=(n,i,a,o)=>{let s=this.getOrigin(n);s.name+="."+i;let c=this.buildNode("element",i,o,s,a);return c.targetKinds=this.getEdmTargetKinds(c),c},this.convertEntitySetNode=(n,i,a)=>{let o=a?this.getOrigin(a):void 0,s=this.buildNode("entitySet",n,i,o),c=a?.[EBt]&&a?.[EBt].val!==!1;s.isEntityType=!0,s.isCollectionValued=!c;let u=this.getNameObj(a);return s.structuredType=this.convertNameToEdmx(u.absolute),s.targetKinds=this.getEdmTargetKinds(s),s},this.convertActionFunctionImportNode=(n,i,a,o)=>{let s=o.kind==="action"?"actionImport":"functionImport",c=this.buildNode(s,n,i,this.getOrigin(o));return c.structuredType=a,c.targetKinds=this.getEdmTargetKinds(c),c},this.compiler=t}convertNamespaceToNamespaces(t){let r=[];return(t.name?.path||t.path||[]).forEach(i=>{r.push(i.id)}),{type:"namespace",name:r.join(".")}}convertUsingsToNamespaces(t,r){let n=[];return(r||[]).forEach(i=>{let a=(0,Cq.findUsing)(t,i);if(a){let o=a.fileDep?.realname||a.fileDep?.val,s=a.fileDep?.location?(0,Cq.locationToRange)(a.fileDep?.location):void 0;a.usings?(a.usings||[]).forEach(c=>n.push(this.convertUsingToNamespace(c,o,s))):n.push(this.convertUsingToNamespace(a,o,s))}else i.realname&&n.push(this.convertDependencyToNamespace(i))}),n}getNameObj(t){return(0,vBt.getNameObj)(t,this.compiler)}convertEnums(t){let r=[];for(let[n,i]of Object.entries(t)){let a=this.convertLiteral(i.value)??n;r.push({name:n,value:a})}return r}convertLiteral(t){if(!(!t||!t.literal)){if(t.literal==="string")return t.val?t.val.toString():"";if(t.literal==="number")return t.val?Number(t.val):0}}convertNameToEdmx(t){return t&&this.facade?this.facade.convertNameToEdmx(t):t}convertNameFromEdmx(t){return t&&this.facade?this.facade.convertNameFromEdmx(t):t}collectElementsFromStructuredType(t,r,n,i,a,o){let s=[];if(r&&t&&n){let{absolute:c,element:u}=r;if(i.structuredType=c,i.isComplexType=!0,t.kind==="element"&&u){let l=u.replace(".","_");i.isAnnotatable=i.path!==`${i.structuredType}/${l}`,i.structuredType+="."+l}if(t.items)return i.isAnnotatable=!0,i.isCollectionValued=!0,[];for(let[l,p]of Object.entries(n))s.push(...this.convertElement(a+"_"+l,o,p))}return s}getPrimitiveType(t){function r(a){return t?.[Oqn]?"Edm.Stream":typeof t?.[bBt]?.val=="string"?t[bBt].val:a}let n=t?._effectiveType?.items?._effectiveType||t?._effectiveType;if(n?.kind==="type"&&n.builtin&&n.name)return r(xBt[this.getNameObj(n).absolute]);let i=n?.type?._artifact||n?._origin?.type?._artifact;return!i&&t?.items&&(i=t.items._effectiveType?.type?._artifact),!i?.builtin&&i?._effectiveType?.type?._artifact&&(i=i?._effectiveType?.type?._artifact),i?.kind==="type"&&i.builtin&&i.name?r(xBt[this.getNameObj(i).absolute]):""}setStructuredType(t,r){if(t.edmPrimitiveType)return;let n=(r?.items||r)?.type?.path||[],i=r?.type?._artifact||r?._effectiveType?.type?._artifact;if(!i&&r?.items&&(i=r.items.type?._artifact||r.items?._effectiveType?.type?._artifact),n?.length===1&&n[0]?.id===oN.TYPE_NAME_OF_BINDING_PARAMETER)t.structuredType=oN.TYPE_NAME_OF_BINDING_PARAMETER,t.isEntityType=!0;else if(i?.name){t.structuredType=this.convertNameToEdmx(this.getNameObj(i).absolute);let a=i.kind;["entity","view"].includes(a)?t.isEntityType=!0:["type"].includes(a)&&(t.isComplexType=!0)}}getEdmTargetKinds(t){if(!t)return[];let r=[];return r.push(...Cqn.get(t.kind)??[]),t.kind==="element"&&t.structuredType&&t.isEntityType&&r.unshift("NavigationProperty"),(r.includes("EntitySet")||t.isCollectionValued)&&r.push("Collection"),r}buildNode(t,r,n,i,a){let o={name:r,path:n?`${n}/${r}`:r,content:[],kind:t,isEntityType:!1,isCollectionValued:!1,isComplexType:!1,isAnnotatable:!0,targetKinds:[]};return i&&(o.originalName=i.name,o.location=i.location,o.importUri=i.importUri),a&&(o.edmPrimitiveType=a),o}getNamespace(t){let r=t.split(".");return r.pop(),r.join(".")}getOrigin(t){let r=this.getRecursiveOrigin(t),n=t._origin&&t.kind!=="entity"?t._origin:t,i;if(n){let a=this.getNameObj(n);i={importUri:n.location.file,name:a.absolute+(a.element?"."+a.element:"")+(a.action?"."+a.action:"")+(a.param?"."+a.param:"")};let o=this.getNameObj(r)?.location||r.location,s=(0,Cq.locationToRange)(o);o&&s&&(i.location=xqn.Location.create(this.adaptFilePath(o),s))}return i}getRecursiveOrigin(t){return t._origin&&t.kind!=="entity"?this.getRecursiveOrigin(t._origin):t}adaptFilePath(t){let r=t.file,n=r.indexOf("node_modules");return n>-1&&(r=r.substring(n)),r}getStructuredType(t){let r=t?.type?._artifact||t?._effectiveType?.type?._artifact;!r&&t?.items&&(r=t.items.type?._artifact||t.items._effectiveType?.type?._artifact);let n;return r&&(n=this.getNameObj(r)),r?.name&&n?this.convertNameToEdmx(n.absolute)??"":""}getActionNodeSignature(t,r){if(t.kind==="action")return r?"("+r+")":"()";{let n=this.getActionOrFunctionParams(t);return r?"("+[r,...n].join(",")+")":"("+n.join(",")+")"}}getKeyNamesAndTypes(t){let r=[];if(t){let n=Object.keys(t);for(let i of n){let a=t[i];if(a.kind!=="key")continue;let o=a.targetElement?._artifact?.foreignKeys;if(o){let s=this.getKeyNamesAndTypes(o);for(let{name:c,type:u}of s)r.push({name:`${i}_${c}`,type:u})}else r.push({name:i,type:this.getPrimitiveType(a.targetElement?._artifact||a)})}}return r}getElementName(t){let r=[];return Object.keys(t.elements||{}).forEach(n=>{let i=t?.elements?.[n];i?.kind==="element"&&i.key&&i.key.val&&i.key.val===!0&&r.push(n)}),r}getActionOrFunctionParams(t){let r=[];return wqn(t.params).forEach(i=>{let a=t?.params?.[i],o=this.getPrimitiveType(a)||this.getStructuredType(a);a?.items&&(o=`Collection(${o})`),o&&r.push(o)}),r}getAssociationKeyFieldElements(t,r,n){let i=[],a=this.getKeyNamesAndTypes(t.foreignKeys);for(let{name:o,type:s}of a){let c=this.buildNode(t.kind,[r,o].join("_"),n,this.getOrigin(t),s);c.targetKinds=this.getEdmTargetKinds(c),i.push(c)}return i}convertUsingToNamespace(t,r,n){return{type:"reference",alias:t.name.id,aliasRange:(0,Cq.locationToRange)(t.name.location),name:(0,vBt.getNameObj)(t,this.compiler).absolute,uri:r,uriRange:n}}convertDependencyToNamespace(t){let r={type:"reference",alias:"",name:"",uri:t.realname};return t.location&&(r.uriRange=(0,Cq.locationToRange)(t.location)),r}};PZ.Converter=dNe;function wqn(e){if(!e||typeof e!="object")return[];let t=Object.keys(e||{});return t.some(r=>!e[r]?.$effectiveSeqNo)?t:t.sort((r,n)=>(e[r]?.$effectiveSeqNo||0)-(e[n]?.$effectiveSeqNo||0))}});var mNe=y(hNe=>{"use strict";Object.defineProperty(hNe,"__esModule",{value:!0});hNe.getDraftNodesForService=Iqn;var TBt=GE(),Pqn=Sq(),Dqn=aN(),NZ="@odata.draft.enabled";function OBt(e,t,r,n,i){if(["view","entity"].includes(e.kind)){let a=(0,TBt.getNameObj)(e,t?.compiler),o=n.convertNameToEdmx(a.absolute)??"";Nqn(e,o,!!i)&&(r.add(o),Object.keys(e?.elements||{}).forEach(c=>{let u=e?.elements?.[c],l=(0,Pqn.getAssociation)(u,t?.compiler);l&&l.isComposition&&t?.definitions[l.target]&&OBt(t.definitions[l.target],t,r,n)}))}}function Nqn(e,t,r){let n=!1;return r?n=e[NZ]&&e[NZ].val!==!1:t.endsWith("_texts")?n=Object.keys(e.elements||{}).findIndex(i=>i==="ID_texts"&&e?.elements?.[i].key?.val)>=0:n=!e[NZ]||e[NZ].val!==!1,n}function Iqn(e,t,r){let n=new Set;return Object.keys(r.definitions||{}).filter(i=>{let a=r.definitions[i]._service;return(a?(0,TBt.getNameObj)(a,r.compiler):void 0)?.absolute===e&&!i.startsWith(Dqn.ENTITY_PREFIX_LOCALIZED)}).forEach(i=>{let a=r.definitions[i];a&&OBt(a,r,n,t,!0)}),n}});var CBt=y(RZ=>{"use strict";Object.defineProperty(RZ,"__esModule",{value:!0});RZ.collectMetadataForAbsolutePath=kqn;RZ.collectMetadataForRelativePath=$qn;var gNe=GE(),Pc=aN(),Rqn=Sq(),SBt=DZ(),Lqn=mNe(),IZ="<ServiceName>";function kqn(e,t,r,n){let i="",a={compileModel:n,metadataCollector:r,converter:new SBt.Converter(n.compiler,r.facade)},o=e.split(".");o.length>1&&["action","function"].includes(t)?o[o.length-1]+="()":o.length>2&&t==="param"&&(o[o.length-2]+="()");let{collectorEntry:s,key:c}=Ep(a,o);if(s){i=s.node.name;let u=s.parentKey;for(;u;){let l=r.metadataElementMap.get(u),p=l?.node.isComplexType&&!l?.node.isAnnotatable?"_":"/";i=l?.node.name+p+i,u=l?.parentKey}}return!i&&t==="element"&&(i=o.slice(0,o.length-1).join(".")+"/"+o[o.length-1]),{edmxPath:i||e,collectorKey:c}}function $qn(e,t,r,n,i){let a={compileModel:i,metadataCollector:n,converter:new SBt.Converter(i.compiler,n.facade)};if(e.startsWith("/"))if(e.slice(1).indexOf("/")>0&&e.includes("EntityContainer")){let[o,s]=e.slice(1).split("/"),c=[o.split(".").filter(u=>u!=="EntityContainer").join("."),s];Ep(a,c,1)}else tVn(a,e,t,r);else if(e.includes(IZ)){let o;if(r){let s=e.replace(IZ,r).split("/");({collectorEntry:o}=Ep(a,s,1))}o||eVn(a,t,e)}else{let o=t.split(/[./]+/),s=[...o,...e.split("/")];Ep(a,s,o.length)}}function Ep(e,t,r){let{facade:n,metadataElementMap:i}=e.metadataCollector,a,o="";for(let s=(r||t.length)-1;s>=0&&!a;s--){let c=t.slice(0,s+1),u=t.slice(s+1);o=c.join(".")+(u.length?"/"+u.join("/"):""),a=i.get(o)}if(a||!n)return{collectorEntry:a,key:o};o="";for(let s=(r||t.length)-1;s>=0&&!a;s--){let c=t.slice(0,s+1),u=t.slice(s+1),{topLevelMdElementName:l,topLevelArtifact:p}=Mqn(e,c);p&&({mdElementName:o,mdEntry:a}=Fqn(e,u,l,p))}return{collectorEntry:a,key:o}}function Mqn(e,t){let{metadataCollector:r,compileModel:n,converter:i}=e,{metadataElementMap:a}=r,s=t.join(".").split("()").join("");s=e.converter.convertNameFromEdmx(s)??s;let c=Iv(n?.definitions,s),u=(c||"").split(".").map((p,f)=>t[f]?.endsWith("()")?p+"()":p).join("."),l=c?n?.definitions[c]:void 0;if(u=e.converter.convertNameToEdmx(u),l&&!a.has(u)){let p=i.convertArtifact(l);p&&a.set(u,{node:p})}return{topLevelMdElementName:u,topLevelArtifact:l}}function Fqn(e,t,r,n){let{metadataCollector:i,compileModel:a}=e,{metadataElementMap:o}=i,s=o.get(r)?.node,c=r,u=n,l=r;for(let p of t){if(!s)continue;if(Qqn(e,s)){let{collectorEntry:h}=Ep(e,s?.structuredType?.split(".")||[]);if(c=s.structuredType||c,s=h?.node,u=a?.definitions?.[c],!h||!s||!u){s=void 0;continue}}s.content=s.content||[];let d=jqn(e,{parentXsnNode:u,parentNode:s,parentKey:c,topLevelArtifact:n},p,t);l=d.mdElementName,u=d.xsnObject,s=o.get(l)?.node,c=l}return{mdElementName:l,mdEntry:s?o.get(l):void 0}}function jqn(e,t,r,n){let{parentNode:i,parentKey:a,parentXsnNode:o}=t,s=a+"/"+r,c;if(i.kind==="service"){let u=Wqn(e,t,r);u&&({mdElementName:s,xsnObject:c}=u)}else if(r.endsWith("()")&&o?.actions){let u=Yqn(e,t,r);u&&({mdElementName:s,xsnObject:c}=u)}else if(a?.endsWith("()")){let u=zqn(e,t,r,n);u&&({mdElementName:s,xsnObject:c}=u)}else if(Xqn(e,r,o))s=qqn(e,t,r);else if(o?.elements){let u=Vqn(e,t,r,n);u&&({mdElementName:s,xsnObject:c}=u)}return{xsnObject:c,mdElementName:s}}function qqn(e,t,r){let{metadataCollector:n,converter:i}=e,{metadataElementMap:a}=n,{parentKey:o,parentNode:s,parentXsnNode:c}=t;switch(r.toUpperCase()){case Pc.IS_ACTIVE_ENTITY_ELEM_NAME.toUpperCase():{let u=Pc.IS_ACTIVE_ENTITY_ELEM_NAME,l=o+"/"+u;if(c){let p=i.convertDraftPropertyNode(c,u,"Edm.Boolean",t.parentKey);s.content.push(p),a.set(o+"/"+u,{node:p,parentKey:o})}return l}case Pc.DRAFT_MESSAGES_ELEMENT_NAME.toUpperCase():{if(t.parentXsnNode?.kind!=="entity"&&t.parentXsnNode?.kind!=="view")break;let u=i.getNameObj(t.parentXsnNode._service)?.id;if(!e.compileModel.options.beta?.draftMessages||!u)break;let l=Pc.DRAFT_MESSAGES_ELEMENT_NAME,p=o+"/"+l;if(c){let f=i.convertDraftPropertyNode(c,l,`Collection(${u}.DRAFT_DraftAdministrativeData_DraftMessage)`,t.parentKey);s.content.push(f),a.set(o+"/"+l,{node:f,parentKey:o})}return p}case Pc.HAS_ACTIVE_ENTITY_ELEM_NAME.toUpperCase():{let u=Pc.HAS_ACTIVE_ENTITY_ELEM_NAME,l=o+"/"+u;if(c){let p=i.convertDraftPropertyNode(c,u,"Edm.Boolean",t.parentKey);s.content.push(p),a.set(o+"/"+u,{node:p,parentKey:o})}return l}}return o+"/"+Pc.HAS_ACTIVE_ENTITY_ELEM_NAME}function Vqn(e,t,r,n){let{metadataElementMap:i}=e.metadataCollector,a,o="",s=t.parentXsnNode;if(Iv(s.elements,r)||ABt(n,r))({mdElementName:o,xsnObject:a}=Uqn(e,t,r));else if(r.lastIndexOf("_")>0&&!o&&!i.has(o+"/"+r)){let c=Bqn(e,t,r);c&&({mdElementName:o,xsnObject:a}=c)}return o?{xsnObject:a,mdElementName:o}:null}function Uqn(e,t,r){let{metadataCollector:n,converter:i}=e,{metadataElementMap:a}=n,{parentKey:o,parentNode:s,parentXsnNode:c}=t,u=c,l=r==="*"&&u?.elements?Object.keys(u?.elements)[0]:Iv(u.elements,r),p=s.isComplexType&&!s.isAnnotatable?"_":"/",f=o+p+l;if(!a.has(f)){let d;l&&o&&(d=i.convertElement(l,o,u?.elements?.[l]));for(let h of d||[])s.content.push(h),a.set(o+"/"+h.name,{node:h,parentKey:o}),wq(e,h)}return{mdElementName:f,xsnObject:l?u?.elements?.[l]:void 0}}function Bqn(e,t,r){let n=(h,m)=>{let v=m.split("_");for(let _=v.length-1;_>0;_--){let T=Iv(h,v.slice(0,_).join("_"));if(T)return T}return""},{metadataCollector:i,converter:a}=e,{metadataElementMap:o}=i,{parentKey:s,parentNode:c,parentXsnNode:u}=t,l=u,p=n(l?.elements,r);if(!p)return;let f=[];s&&(f=a.convertElement(p,s,l?.elements?.[p]));let d;return(f||[]).forEach(h=>{o.has(s+"/"+h.name)||(c.content.push(h),o.set(s+"/"+h.name,{node:h,parentKey:s}),wq(e,h)),h.name.toUpperCase()===r.toUpperCase()&&(d=s+"/"+h.name)}),d?{mdElementName:d}:void 0}function zqn(e,t,r,n){let i=t?.parentXsnNode?.params,a=r.toUpperCase(),o,s="";if(i&&(Iv(i,r)||ABt(n,r)))({mdElementName:s,xsnObject:o}=Gqn(e,t,r));else if(t?.parentXsnNode?.returns&&a===Pc.RETURN_PARAM_NAME.toUpperCase())({mdElementName:s,xsnObject:o}=Hqn(e,t));else{let c=Kqn(e,t,r);c&&({mdElementName:s,xsnObject:o}=c)}return s?{xsnObject:o,mdElementName:s}:null}function Hqn(e,t){let{metadataCollector:r,converter:n}=e,{metadataElementMap:i}=r,{parentKey:a,parentNode:o,parentXsnNode:s}=t,c=a+"/"+Pc.RETURN_PARAM_NAME;if(!i.has(c)){let u=n.convertReturnParameter(s,o.path);u&&(o.content.push(u),i.set(c,{node:u,parentKey:a}),wq(e,u))}return{mdElementName:c,xsnObject:s?.returns}}function Gqn(e,t,r){let{metadataCollector:n,compileModel:i,converter:a}=e,{metadataElementMap:o}=n,{parentKey:s,parentNode:c,parentXsnNode:u,topLevelArtifact:l}=t,p=r==="*"&&u?.params?.length?Object.keys(u.params)[0]:Iv(u?.params,r),f=s+"/"+p;if(!o.has(f)&&p){let d=a.convertParameter(p,c.path,u?.params?.[p]);if(d?.structuredType===Pc.TYPE_NAME_OF_BINDING_PARAMETER){d.isAnnotatable=!1,d.isEntityType=!0,d.isCollectionValued=!!u?.params?.[p].items;let h=(0,gNe.getNameObj)(l,i.compiler);d.structuredType=e.converter.convertNameToEdmx(h.absolute)}d&&(c.content.push(d),o.set(f,{node:d,parentKey:s}),wq(e,d))}return{mdElementName:f,xsnObject:p?u?.params?.[p]:void 0}}function Kqn(e,t,r){let{metadataCollector:n,converter:i}=e,{metadataElementMap:a}=n,{parentKey:o,parentNode:s,parentXsnNode:c,topLevelArtifact:u}=t;if(Object.keys(c?.params||{}).find(d=>{let h=c?.params?.[d],m=(h?.items||h)?.type?.path||[];return m?.length===1&&m[0]?.id===Pc.TYPE_NAME_OF_BINDING_PARAMETER}))return null;let p=c?.["@cds.odata.bindingparameter.name"]?.val||c?.["@cds.odata.bindingparameter.collection"]?.val||"in";if(r.toUpperCase()!==p.toUpperCase())return null;let f=o+"/"+p;if(!a.has(f)){let d=i.convertBindingParameter(c,u,s.path);s.content.push(d),a.set(f,{node:d,parentKey:o}),wq(e,d)}return{mdElementName:f,xsnObject:u}}function Yqn(e,t,r){let{metadataCollector:n,converter:i}=e,{metadataElementMap:a}=n,{parentKey:o,parentXsnNode:s}=t,c=s,u=Iv(c.actions,r.slice(0,-2));if(!u)return null;let l=o+"/"+u+"()";if(!a.has(l)&&o&&c?.actions?.[u]){let p=i.convertBoundAction(o,u,c?.actions?.[u]);a.set(l,{node:p})}return{mdElementName:l,xsnObject:c?.actions?.[u]}}function Wqn(e,t,r){let{metadataCollector:n,compileModel:i}=e,{metadataElementMap:a}=n,{parentKey:o,parentNode:s}=t,c=r;if((!i?.definitions||!Iv(i.definitions,o+"."+r))&&(o&&r.lastIndexOf("_")>0?c=nVn(i.definitions,o,r):c=""),!c)return null;let u=Iv(i.definitions,o+"."+c),l=u?i.definitions[u]:void 0,p=l?._service,f=p?(0,gNe.getNameObj)(p,i.compiler):void 0;if(u?.startsWith(Pc.ENTITY_PREFIX_LOCALIZED)||f.absolute!==o||l?.kind==="event"||l?.kind==="namespace")return null;u&&(u=e.converter.convertNameToEdmx(u));let d=o?.length?u?.slice(o.length+1):"",h=o+"/"+d;if(!a.has(h)){let m=s.content.find(v=>v.name===d);m||(m=Zqn(e,l,d,s.path,u),s.content.push(m)),m&&a.set(h,{node:m,parentKey:o})}return{mdElementName:h,xsnObject:l}}function Xqn(e,t,r){let n=t.toUpperCase();return(Pc.IS_ACTIVE_ENTITY_ELEM_NAME.toUpperCase()===n||Pc.HAS_ACTIVE_ENTITY_ELEM_NAME.toUpperCase()===n||Pc.DRAFT_MESSAGES_ELEMENT_NAME.toUpperCase()===n)&&!!r&&["entity","view"].includes(r.kind)&&Jqn(e,r)}function Jqn(e,t){let{metadataCollector:r,compileModel:n}=e,i=r.draftNodesPerService,a=(0,Rqn.getServiceNameForEntity)(t,n);a&&!i.has(a)&&i.set(a,(0,Lqn.getDraftNodesForService)(a,e.converter,n));let o=(0,gNe.getNameObj)(t,n?.compiler),s=e.converter.convertNameToEdmx(o.absolute)??"";return!!a&&!!i?.get(a)?.has(s)}function wq(e,t){let{metadataCollector:r,compileModel:n}=e;if(t.structuredType&&!r.metadataElementMap.has(t.structuredType)&&n?.definitions[e.converter.convertNameFromEdmx(t.structuredType)||t.structuredType]){let i=t.structuredType.split("."),a=Ep(e,i);a?.collectorEntry?.node?.keys&&a?.collectorEntry?.node?.keys.length&&Ep(e,[...i,a?.collectorEntry?.node?.keys[0]])}}function Iv(e,t){return e?.[t]?t:Object.keys(e||{}).find(r=>r.toUpperCase()===t.toUpperCase())}function Zqn(e,t,r,n,i){let{compileModel:a,converter:o}=e,s;r&&(t?.kind&&["action","function"].includes(t.kind)?s=o.convertActionFunctionImportNode(r,n,i,t):s=o.convertEntitySetNode(r,n,t));let c=s?.structuredType;return c&&a.definitions[o.convertNameFromEdmx(c)||c]&&Ep(e,c.split(".")),s}function Qqn(e,t){let r=e.converter.convertNameFromEdmx(t.structuredType)||t.structuredType||"";return["element","entitySet","param"].includes(t.kind)&&t.structuredType&&!!e.compileModel?.definitions[r]}function ABt(e,t){return t==="*"&&e.indexOf(t)===e.length-1}function eVn(e,t,r){let{compileModel:n}=e,i=t.split("."),a=i.slice(0,i.length-1).join("."),s=r.replace(`${IZ}/`,`${a}.`).split("/");if(!Ep(e,s,1).collectorEntry&&n?.definitions&&r.includes("/")){let u=r.split("/")[1],l=n?.definitions,p=Object.keys(l).find(h=>(h===u||h.endsWith(`.${u}`))&&l[h].kind==="entity"),d=r.replace(`${IZ}/${u}`,p||"").split("/");Ep(e,d,1)}}function tVn(e,t,r,n){let{compileModel:i}=e,a=t.split(".").pop();if(a&&i?.definitions[r]?.actions?.[a]){let o=r.split(".");Ep(e,[...o,a+"()"],o.length)}else if(i?.definitions[t.slice(1)]){let o=(t.slice(1)+"()").split(".");Ep(e,o)}else rVn(e,t,n)}function rVn(e,t,r){let n=t.split(".").pop(),i=e.compileModel?.definitions[r]?.artifacts,a=Object.keys(i||{}).filter(o=>i?.[o].kind==="entity");for(let o of a){let s=r+"."+o;if(n&&e.compileModel?.definitions[s]?.actions?.[n]){let c=s.split(".");Ep(e,[...c,n+"()"],c.length);break}}}function nVn(e,t,r){let n=`${t}.${r}`.replaceAll("_","."),i=Object.keys(e??{}).find(a=>a.startsWith(`${t}.`)&&a.replaceAll("_",".")===n);return i?i.substring(`${t}.`.length):""}});var PBt=y(LZ=>{"use strict";Object.defineProperty(LZ,"__esModule",{value:!0});LZ.generateMetadata=void 0;var zf=aN(),iVn=Sq(),wBt=mNe(),aVn=DZ(),oVn=(e,t,r)=>{let n=new aVn.Converter(e.compiler,t),i=new Map,a={};r?(e.definitions[r]&&(a[r]=e.definitions[r],Object.keys(e.definitions).filter(s=>{let c=e.definitions[s]._service;return(c?n.getNameObj(c):void 0)?.absolute===r&&!s.startsWith(zf.ENTITY_PREFIX_LOCALIZED)}).forEach(s=>a[s]=e.definitions[s])),i.set(r,(0,wBt.getDraftNodesForService)(r,n,e))):(a=e.definitions,Object.keys(a).filter(s=>a[s].kind==="service").forEach(s=>{i.set(s,(0,wBt.getDraftNodesForService)(s,n,e))}));let o={metadataElementMap:new Map,converter:n};return Object.keys(a).filter(s=>!s.startsWith(zf.ENTITY_PREFIX_LOCALIZED)).filter(s=>["service","entity","view","action","function","aspect","type"].includes(a[s]?.kind)&&!(a[s].kind==="type"&&a[s].builtin)).forEach(s=>sVn(o,s,a,i,e)),o.metadataElementMap};LZ.generateMetadata=oVn;function sVn(e,t,r,n,i){let{metadataElementMap:a,converter:o}=e,s=r[t],c=o.convertArtifact(s),u=s.kind==="service"?t:c.name;if(s.kind==="service"&&Object.keys(r||{}).filter(l=>{let p=r[l]._service,f=p?o.getNameObj(p):void 0;return!l.startsWith(zf.ENTITY_PREFIX_LOCALIZED)&&f?.absolute===u&&["entity","view","action","function"].includes(r[l].kind)}).forEach(l=>{cVn(e,r[l],c,u)}),lVn(e,s),uVn(e,s,u,c),["entity","view"].includes(s.kind)&&n.get((0,iVn.getServiceNameForEntity)(s,i))?.has(u)){let l=o.convertDraftPropertyNode(s,zf.IS_ACTIVE_ENTITY_ELEM_NAME,"Edm.Boolean",u);l&&(c.content.push(l),a.set(u+"/"+zf.IS_ACTIVE_ENTITY_ELEM_NAME,{parentKey:u,node:l}));let p=o.convertDraftPropertyNode(s,zf.HAS_ACTIVE_ENTITY_ELEM_NAME,"Edm.Boolean",u);p&&(c.content.push(p),a.set(u+"/"+zf.HAS_ACTIVE_ENTITY_ELEM_NAME,{parentKey:u,node:p}));let f=o.getNameObj(s._service)?.id;if(f&&i.options.beta?.draftMessages){let d=o.convertDraftPropertyNode(s,zf.DRAFT_MESSAGES_ELEMENT_NAME,`Collection(${f}.DRAFT_DraftAdministrativeData_DraftMessage)`,u);d&&(d.isCollectionValued=!0,c.content.push(d),a.set(u+"/"+zf.DRAFT_MESSAGES_ELEMENT_NAME,{parentKey:u,node:d}))}}dVn(e,s,u,c),a.set(u,{node:c})}function cVn(e,t,r,n){let{metadataElementMap:i,converter:a}=e,o=e.converter.convertNameToEdmx(a.getNameObj(t).absolute)??"",s=o.slice(n.length+1),c;["entity","view"].includes(t.kind)?c=a.convertEntitySetNode(s,r.name,t):c=a.convertActionFunctionImportNode(s,r.name,o,t),r.content.push(c),i.set(r.name+"/"+s,{parentKey:r.name,node:c})}function uVn(e,t,r,n){let{metadataElementMap:i,converter:a}=e;Object.keys(t.elements||{}).forEach(o=>{let s=t?.elements?.[o],c=a.convertElement(o,r,s);n.content.push(...c);for(let u of c)i.set(r+"/"+u.name,{parentKey:r,node:u})})}function lVn(e,t){let{metadataElementMap:r,converter:n}=e;Object.keys(t.actions||{}).sort((i,a)=>i.localeCompare(a)).forEach(i=>{let a=t?.actions?.[i];if(a&&["action","function"].includes(a.kind)){let o=n.convertBoundAction(n.getNameObj(t).absolute,i,a),s=o.name;o.content=[];let c=n.convertBindingParameter(a,t,s);c&&(o.content.push(c),r.set(s+"/"+c.name,{parentKey:s,node:c})),pVn(e,a,s),fVn(e,a,s,o),r.set(s,{node:o})}})}function pVn(e,t,r){let{metadataElementMap:n,converter:i}=e;Object.keys(t.params||{}).forEach(a=>{let o=t?.params?.[a];if(o&&["param"].includes(o.kind)){let s=i.convertParameter(a,r,o);s&&s.structuredType!==zf.TYPE_NAME_OF_BINDING_PARAMETER&&n.set(r+"/"+a,{parentKey:r,node:s})}})}function fVn(e,t,r,n){if(t.returns){let{metadataElementMap:i,converter:a}=e,o=a.convertReturnParameter(t,r);o&&(n.content.push(o),i.set(r+"/"+zf.RETURN_PARAM_NAME,{parentKey:r,node:o}))}}function dVn(e,t,r,n){let{metadataElementMap:i,converter:a}=e;if(Object.keys(t.params||{}).sort((o,s)=>o.localeCompare(s)).forEach(o=>{let s=t?.params?.[o],c=a.convertParameter(o,r,s);c&&(n.content.push(c),i.set(r+"/"+o,{parentKey:r,node:c}))}),t.returns){let o=a.convertReturnParameter(t,r);o&&(n.content.push(o),i.set(r+"/"+zf.RETURN_PARAM_NAME,{parentKey:r,node:o}))}}});var vNe=y(Pq=>{"use strict";Object.defineProperty(Pq,"__esModule",{value:!0});Pq.EdmxNameConverter=void 0;Pq.convertNameToEdmxInternal=DBt;var hVn=["namespace","service","context"];function mVn(e){return hVn.includes(e.kind)}function DBt(e,t){let r=e,n=e.split("/"),i=n.shift(),a=t.definitions[i],o=[];for(;a&&!mVn(a);){let s=i.split("."),c=s.pop();if(o.unshift(c),i=s.join("."),a=t.definitions[i],i==="")return r}return a&&(r=i+(o.length?"."+o.join("_"):""),r=[r,...n].join("/")),r}var yNe=class{constructor(t){this.compileModel=t,this.edmxNamesMap=new Map,this.reverseNamesMap=new Map}convertNameToEdmx(t){let r=this.edmxNamesMap.get(t);if(r!==void 0)return r;let n=DBt(t,this.compileModel);return this.edmxNamesMap.set(t,n),this.reverseNamesMap.set(n.toUpperCase(),t),n}convertNameFromEdmx(t){return this.reverseNamesMap.get(t.toUpperCase())}};Pq.EdmxNameConverter=yNe});var kZ=y(ho=>{"use strict";Object.defineProperty(ho,"__esModule",{value:!0});ho.convertNameToEdmxInternal=ho.EdmxNameConverter=ho.Converter=ho.generateMetadata=ho.collectMetadataForRelativePath=ho.collectMetadataForAbsolutePath=ho.getMetadataElementsFromMap=ho.createMetadataCollector=ho.getMetadataCollector=void 0;var bNe=aN();Object.defineProperty(ho,"getMetadataCollector",{enumerable:!0,get:function(){return bNe.getMetadataCollector}});Object.defineProperty(ho,"createMetadataCollector",{enumerable:!0,get:function(){return bNe.createMetadataCollector}});Object.defineProperty(ho,"getMetadataElementsFromMap",{enumerable:!0,get:function(){return bNe.getMetadataElementsFromMap}});var NBt=CBt();Object.defineProperty(ho,"collectMetadataForAbsolutePath",{enumerable:!0,get:function(){return NBt.collectMetadataForAbsolutePath}});Object.defineProperty(ho,"collectMetadataForRelativePath",{enumerable:!0,get:function(){return NBt.collectMetadataForRelativePath}});var gVn=PBt();Object.defineProperty(ho,"generateMetadata",{enumerable:!0,get:function(){return gVn.generateMetadata}});var yVn=DZ();Object.defineProperty(ho,"Converter",{enumerable:!0,get:function(){return yVn.Converter}});var IBt=vNe();Object.defineProperty(ho,"EdmxNameConverter",{enumerable:!0,get:function(){return IBt.EdmxNameConverter}});Object.defineProperty(ho,"convertNameToEdmxInternal",{enumerable:!0,get:function(){return IBt.convertNameToEdmxInternal}})});var _Ne=y($Z=>{"use strict";Object.defineProperty($Z,"__esModule",{value:!0});$Z.GenericTokenImpl=void 0;var RBt=Ht(),ENe=class{constructor(t,r,n,i,a,o){this.uri=t,this.tokenIndex=r,this.text=n,this.line=i,this.character=a,this.annotationValue=o}toString(){return`${this.text}@${this.line}:${this.character}`}get range(){return RBt.Range.create(this.line,this.character,this.line,this.character+this.text.length)}get location(){return RBt.Location.create(this.uri,this.range)}compare(t){let r=this.line-t.line;return r===0?(r=t.character-this.character,r<0?1:r<=this.text.length?0:-1):Math.sign(r)}};$Z.GenericTokenImpl=ENe});var LBt=y(s1=>{"use strict";Object.defineProperty(s1,"__esModule",{value:!0});s1.AnnotationAssignmentTokenImpl=s1.NEWLINE_REGEX=void 0;var vVn=Ht(),bVn=_Ne();s1.NEWLINE_REGEX=/\r?\n/g;var xNe=class extends bVn.GenericTokenImpl{constructor(t,r,n,i,a,o,s,c,u){super(t,r,n,i,a,u),this.uri=t,this.tokenIndex=r,this.text=n,this.line=i,this.character=a,this.carrierName=o,this.carrier=s,this.carrierNameRange=c,this.annotationValue=u}get range(){if(!this._range){let t=this.text.split(s1.NEWLINE_REGEX);this._range=vVn.Range.create(this.line,this.character,this.line+t.length-1,t.length===1?this.character+this.text.length:t.slice(-1)[0].length)}return this._range}};s1.AnnotationAssignmentTokenImpl=xNe});var kBt=y(MZ=>{"use strict";Object.defineProperty(MZ,"__esModule",{value:!0});MZ.GenericDefinitionImpl=void 0;var TNe=class{constructor(t,r,n=t){this.symbolName=t,this.kind=r,this.absoluteName=n}get fullyQualifiedName(){return this.symbolName}};MZ.GenericDefinitionImpl=TNe});var $Bt=y(FZ=>{"use strict";Object.defineProperty(FZ,"__esModule",{value:!0});FZ.IdentifierTokenImpl=void 0;var EVn=_Ne(),ONe=class extends EVn.GenericTokenImpl{constructor(t,r,n,i,a,o,s){super(t,r,n,i,a,s),this.uri=t,this.tokenIndex=r,this.text=n,this.line=i,this.character=a,this.definitions=o,this.annotationValue=s}};FZ.IdentifierTokenImpl=ONe});var MBt=y(Dq=>{"use strict";Object.defineProperty(Dq,"__esModule",{value:!0});Dq.findTokenByPosition=_Vn;Dq.getTokenLocation=xVn;Dq.isOldToken=SNe;function _Vn(e,t,r){let n=0,i=e.length-1;for(;n<=i;){let a=Math.floor((n+i)/2),o=e[a];if(SNe(o))if(o.line<t||o.line===t&&o.column<r-1)n=a+1;else if(o.line>t||o.line===t&&o.column>r-1)i=a-1;else return o;else if(o.location.line<t||o.location.line===t&&o.location.col<r)n=a+1;else if(o.location.line>t||o.location.line===t&&o.location.col>r)i=a-1;else return o}}function xVn(e,t=e.text){return SNe(e)?{line:e.line,column:e.column+1,endLine:e.line+t.split(/\r?\n/).length-1,endColumn:e.text.indexOf(`
|
|
@@ -1228,7 +1228,7 @@ Hint: If possible, try to maintain the Type property for each Record.
|
|
|
1228
1228
|
<Annotation Term="${t}">
|
|
1229
1229
|
<Record>...</Record>
|
|
1230
1230
|
</Annotation>
|
|
1231
|
-
</Annotations>`),i}function szn(e){return e.hasOwnProperty("Action")&&(e.$Type==="com.sap.vocabularies.UI.v1.DataFieldForAction"||e.$Type==="com.sap.vocabularies.UI.v1.DataFieldWithAction")}function czn(e,t,r,n,i){let a;return!i.type&&t?a=Q8t(e,t,r.fullyQualifiedName,n):a=e.unalias(i.type),a}function mRe(e,t,r,n,i,a,o){let s={$Type:czn(e,t,r,n,a),fullyQualifiedName:o,[hh]:r,__source:i};for(let c of a.propertyValues)(0,rt.lazy)(s,c.name,()=>Z8t(e,r,t,c.name,i,c.value,`${o}/${c.name}`));return(0,rt.lazy)(s,"annotations",r6t(e,a,s)),szn(s)&&(0,rt.lazy)(s,"ActionTarget",()=>{var c,u;let l=e.unalias((c=s.Action)===null||c===void 0?void 0:c.toString()),p=r.actions[l];return p||(p=(u=e.getConvertedActionImport(l))===null||u===void 0?void 0:u.action),p||(p=e.getConvertedAction(l),p?.isBound||(p=void 0)),p||e.logError(`${s.fullyQualifiedName}: Unable to resolve '${s.Action}' ('${l}')`),p}),s}function uzn(e){let t=e.type;if(t===void 0&&e.length>0){let r=e[0];r.hasOwnProperty("PropertyPath")?t="PropertyPath":r.hasOwnProperty("Path")?t="Path":r.hasOwnProperty("AnnotationPath")?t="AnnotationPath":r.hasOwnProperty("NavigationPropertyPath")?t="NavigationPropertyPath":typeof r=="object"&&(r.hasOwnProperty("type")||r.hasOwnProperty("propertyValues"))?t="Record":typeof r=="string"&&(t="String")}else t===void 0&&(t="EmptyCollection");return t}function e6t(e,t,r,n,i,a,o){switch(uzn(a)){case"PropertyPath":return a.map((c,u)=>W8t(e,c,`${o}/${u}`,t,r));case"Path":return a.map(c=>xp(e,t,c.Path,r).target);case"AnnotationPath":return a.map((c,u)=>X8t(e,c,`${o}/${u}`,t,r));case"NavigationPropertyPath":return a.map((c,u)=>J8t(e,c,`${o}/${u}`,t,r));case"Record":return a.map((c,u)=>mRe(e,r,t,n,i,c,`${o}/${u}`));case"Apply":case"Null":case"If":case"Eq":case"Ne":case"Lt":case"Gt":case"Le":case"Ge":case"Not":case"And":case"Or":return a.map(c=>c);case"String":return a.map(c=>typeof c=="string"||c===void 0?c:c.String);default:if(a.length===0)return[];throw new Error("Unsupported case")}}function lzn(e){return!!e.targetTypeName}function pzn(e,t,r){var n;let i;if(r.record)i=mRe(e,r.term,t,"",r.__source,r.record,r.fullyQualifiedName);else if(r.collection===void 0)i=Z8t(e,t,r.term,"",r.__source,(n=r.value)!==null&&n!==void 0?n:{type:"Bool",Bool:!0},r.fullyQualifiedName);else if(r.collection)i=e6t(e,t,r.term,"",r.__source,r.collection,r.fullyQualifiedName);else throw new Error("Unsupported case");switch(typeof i){case"string":i=new String(i);break;case"boolean":i=new Boolean(i);break;case"number":i=new Number(i);break;default:break}i.fullyQualifiedName=r.fullyQualifiedName,i[hh]=t;let[a,o]=e.splitTerm(r.term);i.term=e.unalias(`${a}.${o}`,tee.VocabularyReferences),i.qualifier=r.qualifier,i.__source=r.__source;try{(0,rt.lazy)(i,"annotations",r6t(e,r,i))}catch{}return i}var dRe=class{getAnnotations(t){var r;if(this.annotationsByTarget===void 0){let n=Object.keys(this.rawSchema.annotations).map(i=>({name:i,annotationList:this.rawSchema.annotations[i]}));this.annotationsByTarget=(0,rt.mergeAnnotations)(this.rawMetadata.references,...n)}return(r=this.annotationsByTarget[t])!==null&&r!==void 0?r:[]}getConvertedEntityContainer(){return this.getConvertedElement(this.rawMetadata.schema.entityContainer.fullyQualifiedName,this.rawMetadata.schema.entityContainer,n6t)}getConvertedEntitySet(t){return this.convertedOutput.entitySets.by_fullyQualifiedName(t)}getConvertedSingleton(t){return this.convertedOutput.singletons.by_fullyQualifiedName(t)}getConvertedEntityType(t){return this.convertedOutput.entityTypes.by_fullyQualifiedName(t)}getConvertedComplexType(t){return this.convertedOutput.complexTypes.by_fullyQualifiedName(t)}getConvertedTypeDefinition(t){return this.convertedOutput.typeDefinitions.by_fullyQualifiedName(t)}getConvertedActionImport(t){let r=this.convertedOutput.actionImports.by_fullyQualifiedName(t);return r||(r=this.convertedOutput.actionImports.by_name(t)),r}getConvertedAction(t){return this.convertedOutput.actions.by_fullyQualifiedName(t)}convert(t,r){return Array.isArray(t)?()=>{let n=t.reduce((i,a)=>{let o=this.getConvertedElement(a.fullyQualifiedName,a,r);return o&&i.push(o),i},[]);return(0,rt.addGetByValue)(n,"name"),(0,rt.addGetByValue)(n,"fullyQualifiedName"),n}:()=>this.getConvertedElement(t.fullyQualifiedName,t,r)}constructor(t,r){this.convertedElements=new Map,this.rawMetadata=t,this.rawSchema=t.schema,this.convertedOutput=r}getConvertedElement(t,r,n){let i=this.convertedElements.get(t);if(i===void 0){let a=typeof r=="function"?r.apply(void 0,[t]):r;a!==void 0&&(i=n.apply(void 0,[this,a]),this.convertedElements.set(t,i))}return i}logError(t){this.convertedOutput.diagnostics.push({message:t})}splitTerm(t){let r=(0,rt.alias)(tee.VocabularyReferences,t);return(0,rt.splitAtLast)(r,".")}unalias(t,r=this.rawMetadata.references){var n;return(n=(0,rt.unalias)(r,t,this.rawSchema.namespace))!==null&&n!==void 0?n:""}};function nV(e,t){return()=>{let r=e.getConvertedEntityType(t);return r||(e.logError(`EntityType '${t}' not found`),r={}),r}}function t6t(e,t){return()=>Object.keys(t).reduce((r,n)=>{let i=t[n];return(0,rt.lazy)(r,n,()=>{var a;return(a=e.getConvertedEntitySet(i))!==null&&a!==void 0?a:e.getConvertedSingleton(i)}),r},{})}function Uv(e,t){let r=t.annotations;return()=>ree(e,t,r??e.getAnnotations(t.fullyQualifiedName))}function r6t(e,t,r){return()=>{let n=r.fullyQualifiedName,i;return t.annotations&&t.annotations.length>0?i=t.annotations:i=e.getAnnotations(n),i?.forEach(a=>{a.target=n,a.__source=r.__source,a[hh]=r[hh],a.fullyQualifiedName=`${n}@${a.term}`}),ree(e,r,i??[])}}function ree(e,t,r){return r.reduce((n,i)=>{let[a,o]=e.splitTerm(i.term),s=`${o}${i.qualifier?"#"+i.qualifier:""}`;return n[a]===void 0&&(n[a]={_keys:[]}),n[a].hasOwnProperty(s)||(n[a]._keys.push(s),(0,rt.lazy)(n[a],s,()=>e.getConvertedElement(i.fullyQualifiedName,i,(c,u)=>pzn(c,t,u)))),n},{})}function n6t(e,t){let r=t;return(0,rt.lazy)(r,"annotations",Uv(e,t)),(0,rt.lazy)(r,"entitySets",e.convert(e.rawSchema.entitySets,a6t)),(0,rt.lazy)(r,"singletons",e.convert(e.rawSchema.singletons,i6t)),(0,rt.lazy)(r,"actionImports",e.convert(e.rawSchema.actionImports,s6t)),r}function i6t(e,t){let r=t;(0,rt.lazy)(r,"entityType",nV(e,t.entityTypeName)),(0,rt.lazy)(r,"annotations",Uv(e,r));let n=t.navigationPropertyBinding;return(0,rt.lazy)(r,"navigationPropertyBinding",t6t(e,n)),r}function a6t(e,t){let r=t;(0,rt.lazy)(r,"entityType",nV(e,t.entityTypeName)),(0,rt.lazy)(r,"annotations",Uv(e,r));let n=t.navigationPropertyBinding;return(0,rt.lazy)(r,"navigationPropertyBinding",t6t(e,n)),r}function fzn(e,t){let r=t;return t.keys.forEach(n=>{n.isKey=!0}),(0,rt.lazy)(r,"annotations",Uv(e,t)),(0,rt.lazy)(r,"keys",e.convert(t.keys,hRe)),(0,rt.lazy)(r,"entityProperties",e.convert(t.entityProperties,hRe)),(0,rt.lazy)(r,"navigationProperties",e.convert(t.navigationProperties,o6t)),(0,rt.lazy)(r,"actions",()=>e.rawSchema.actions.filter(n=>n.isBound&&(n.sourceType===t.fullyQualifiedName||n.sourceType===`Collection(${t.fullyQualifiedName})`)).reduce((n,i)=>{let a=`${e.rawSchema.namespace}.${i.name}`;return n[a]=e.getConvertedAction(i.fullyQualifiedName),n},{})),r.resolvePath=(n,i)=>{let a=xp(e,t,n);return i?{target:a.target,visitedObjects:a.objectPath,messages:a.messages}:a.target},r}function hRe(e,t){let r=t;return(0,rt.lazy)(r,"annotations",Uv(e,t)),(0,rt.lazy)(r,"targetType",()=>{var n;let i=t.type,a=i.startsWith("Collection")?i.substring(11,i.length-1):i;return(n=e.getConvertedComplexType(a))!==null&&n!==void 0?n:e.getConvertedTypeDefinition(a)}),r}function o6t(e,t){var r,n,i,a,o;let s=t;if(s.referentialConstraint=(r=s.referentialConstraint)!==null&&r!==void 0?r:[],s.referentialConstraint.length===0){let u=e.getAnnotations(t.fullyQualifiedName).find(l=>l.term==="com.sap.vocabularies.Common.v1.ReferentialConstraint");u&&(s.referentialConstraint=(i=(n=u.collection)===null||n===void 0?void 0:n.map(l=>{var p,f;let d=(p=l.propertyValues.find(m=>m.name==="ReferencedProperty"))===null||p===void 0?void 0:p.value,h="";if(d.PropertyPath){let m=d.PropertyPath.split("/");m.shift(),h=m.join("/")}return{sourceProperty:((f=l.propertyValues.find(m=>m.name==="Property"))===null||f===void 0?void 0:f.value).PropertyPath,targetTypeName:s.targetTypeName,targetProperty:h}}))!==null&&i!==void 0?i:[])}if(!lzn(t)){let c=(a=e.rawSchema.associations.find(u=>u.fullyQualifiedName===t.relationship))===null||a===void 0?void 0:a.associationEnd.find(u=>u.role===t.toRole);s.isCollection=c?.multiplicity==="*",s.targetTypeName=(o=c?.type)!==null&&o!==void 0?o:""}return(0,rt.lazy)(s,"targetType",nV(e,t.targetTypeName)),(0,rt.lazy)(s,"annotations",Uv(e,t)),s}function s6t(e,t){let r=t;return(0,rt.lazy)(r,"annotations",Uv(e,t)),(0,rt.lazy)(r,"action",()=>{let n=e.rawSchema.actions.filter(i=>!i.isBound&&i.fullyQualifiedName.startsWith(t.actionName+"("));return n.length>1&&e.logError(`Ambiguous reference in action import: ${t.fullyQualifiedName}`),e.getConvertedAction(n[0].fullyQualifiedName)}),r}function dzn(e,t){let r=t;return r.sourceType&&(0,rt.lazy)(r,"sourceEntityType",nV(e,t.sourceType)),r.returnType&&((0,rt.lazy)(r,"returnEntityType",nV(e,t.returnType)),(0,rt.lazy)(r,"returnTypeReference",()=>{var n,i;let a=r.returnType.startsWith("Collection")?r.returnType.substring(11,r.returnType.length-1):r.returnType;return(i=(n=e.getConvertedEntityType(a))!==null&&n!==void 0?n:e.getConvertedComplexType(a))!==null&&i!==void 0?i:e.getConvertedTypeDefinition(a)})),(0,rt.lazy)(r,"parameters",e.convert(t.parameters,hzn)),(0,rt.lazy)(r,"annotations",()=>{let n=(0,rt.substringBeforeFirst)(t.fullyQualifiedName,"("),i=t.fullyQualifiedName,a=e.getAnnotations(i),o=e.getAnnotations(n);for(let s of o)a.some(c=>c.term===s.term&&c.qualifier===s.qualifier)||a.push(s);return ree(e,t,a)}),r}function hzn(e,t){let r=t;return(0,rt.lazy)(r,"typeReference",()=>{var n,i;let a=t.type;return a.startsWith("Collection(")&&(a=a.substring(11,a.length-1)),(i=(n=e.getConvertedEntityType(a))!==null&&n!==void 0?n:e.getConvertedComplexType(a))!==null&&i!==void 0?i:e.getConvertedTypeDefinition(a)}),(0,rt.lazy)(r,"annotations",()=>{let n=t.fullyQualifiedName.substring(0,t.fullyQualifiedName.indexOf("("))+t.fullyQualifiedName.substring(t.fullyQualifiedName.lastIndexOf(")")+1),i=t.fullyQualifiedName,a=e.getAnnotations(i),o=e.getAnnotations(n);for(let s of o)a.some(c=>c.term===s.term&&c.qualifier===s.qualifier)||a.push(s);return ree(e,t,a)}),r}function mzn(e,t){let r=t;return(0,rt.lazy)(r,"properties",e.convert(t.properties,hRe)),(0,rt.lazy)(r,"navigationProperties",e.convert(t.navigationProperties,o6t)),(0,rt.lazy)(r,"annotations",Uv(e,t)),r}function gzn(e,t){let r=t;return(0,rt.lazy)(r,"annotations",Uv(e,t)),r}function yzn(e){let t={version:e.version,namespace:e.schema.namespace,annotations:e.schema.annotations,references:tee.VocabularyReferences,diagnostics:[]},r=new dRe(e,t);return(0,rt.lazy)(t,"entityContainer",r.convert(r.rawSchema.entityContainer,n6t)),(0,rt.lazy)(t,"entitySets",r.convert(r.rawSchema.entitySets,a6t)),(0,rt.lazy)(t,"singletons",r.convert(r.rawSchema.singletons,i6t)),(0,rt.lazy)(t,"entityTypes",r.convert(r.rawSchema.entityTypes,fzn)),(0,rt.lazy)(t,"actions",r.convert(r.rawSchema.actions,dzn)),(0,rt.lazy)(t,"complexTypes",r.convert(r.rawSchema.complexTypes,mzn)),(0,rt.lazy)(t,"actionImports",r.convert(r.rawSchema.actionImports,s6t)),(0,rt.lazy)(t,"typeDefinitions",r.convert(r.rawSchema.typeDefinitions,gzn)),t.resolvePath=function(i,a){let o=xp(r,a,i);return o.target&&Vv(o.objectPath,o.target),o},t}nee.convert=yzn});var f6t=y(aee=>{"use strict";Object.defineProperty(aee,"__esModule",{value:!0});aee.revertTermToGenericType=void 0;var gRe=eee();function vzn(e,t){var r,n,i,a,o,s,c;let u;if(Array.isArray(t)){let l=t[0],p=!1;if(l&&typeof l=="string"){let f=l.valueOf().split(".");f.length>1&&e.find(d=>d.alias===f[0])&&(p=gRe.EnumIsFlag[(0,gRe.substringBeforeFirst)(l,"/")])}p?u={type:"EnumMember",EnumMember:t.map(f=>f.valueOf()).join(" ")}:u={type:"Collection",Collection:t.map(f=>iee(e,f))}}else if(!((r=t.isDecimal)===null||r===void 0)&&r.call(t))u={type:"Decimal",Decimal:t.valueOf()};else if(!((n=t.isDouble)===null||n===void 0)&&n.call(t))u={type:"Double",Double:t.valueOf()};else if(!((i=t.isString)===null||i===void 0)&&i.call(t)){let l=t.valueOf().split(".");l.length>1&&e.find(p=>p.alias===l[0])?u={type:"EnumMember",EnumMember:t.valueOf()}:u={type:"String",String:t.valueOf()}}else!((a=t.isInt)===null||a===void 0)&&a.call(t)?u={type:"Int",Int:t.valueOf()}:!((o=t.isFloat)===null||o===void 0)&&o.call(t)?u={type:"Float",Float:t.valueOf()}:!((s=t.isDate)===null||s===void 0)&&s.call(t)?u={type:"Date",Date:t.valueOf()}:!((c=t.isBoolean)===null||c===void 0)&&c.call(t)?u={type:"Bool",Bool:t.valueOf()}:t.type==="Path"?u={type:"Path",Path:t.path}:t.type==="AnnotationPath"?u={type:"AnnotationPath",AnnotationPath:t.value}:t.type==="Apply"?u={type:"Apply",$Apply:t.$Apply,$Function:t.$Function}:t.type==="Null"?u={type:"Null"}:t.type==="PropertyPath"?u={type:"PropertyPath",PropertyPath:t.value}:t.type==="NavigationPropertyPath"?u={type:"NavigationPropertyPath",NavigationPropertyPath:t.value}:Object.prototype.hasOwnProperty.call(t,"$Type")&&(u={type:"Record",Record:iee(e,t)});return u}function u6t(e,t){let r;switch(t.type==="Constant"&&(t=t.value),t?.constructor.name){case"String":case"string":let i=t.toString().split(".");i.length>1&&e.find(a=>a.alias===i[0])?r={type:"EnumMember",EnumMember:t.toString()}:r={type:"String",String:t.toString()};break;case"Boolean":case"boolean":r={type:"Bool",Bool:t.valueOf()};break;case"Number":case"number":t.toString()===t.toFixed()?r={type:"Int",Int:t.valueOf()}:r={type:"Decimal",Decimal:t.valueOf()};break;case"object":default:r=vzn(e,t);break}return r}var bzn=["$Type","term","__source","qualifier","ActionTarget","fullyQualifiedName","annotations"];function l6t(e,t,r){Object.keys(t).filter(n=>n!=="_annotations").forEach(n=>{Object.keys(t[n]).filter(i=>i!=="_keys").forEach(i=>{let a=p6t(e,t[n][i]);if(!a.term){let o=(0,gRe.unalias)(e,`${n}.${i}`);if(o){let s=o.split("#");a.term=s[0],s.length>1&&(a.qualifier=s[1])}}r.push(a)})})}function iee(e,t){if(typeof t=="string")return{type:"String",String:t};if(typeof t=="object")if(t.hasOwnProperty("$Type")){let r={type:t.$Type,propertyValues:[]};return Object.keys(t).forEach(n=>{if(bzn.indexOf(n)===-1){let i=t[n];r.propertyValues.push({name:n,value:u6t(e,i)})}else n==="annotations"&&Object.keys(t[n]).length>0&&(r.annotations=[],l6t(e,t[n],r.annotations))}),r}else{if(t.type==="PropertyPath")return{type:"PropertyPath",PropertyPath:t.value};if(t.type==="AnnotationPath")return{type:"AnnotationPath",AnnotationPath:t.value};if(t.type==="NavigationPropertyPath")return{type:"NavigationPropertyPath",NavigationPropertyPath:t.value};if(t.type==="Constant")return t.value}}function p6t(e,t){let r={term:t.term,qualifier:t.qualifier};return Array.isArray(t)?(t.hasOwnProperty("annotations")&&Object.keys(t.annotations).length>0&&(r.annotations=[],l6t(e,t.annotations,r.annotations)),{...r,collection:t.map(n=>iee(e,n))}):t.hasOwnProperty("$Type")?{...r,record:iee(e,t)}:{...r,value:u6t(e,t)}}aee.revertTermToGenericType=p6t});var d6t=y(Bv=>{"use strict";var Ezn=Bv&&Bv.__createBinding||(Object.create?function(e,t,r,n){n===void 0&&(n=r);var i=Object.getOwnPropertyDescriptor(t,r);(!i||("get"in i?!t.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,i)}:function(e,t,r,n){n===void 0&&(n=r),e[n]=t[r]}),yRe=Bv&&Bv.__exportStar||function(e,t){for(var r in e)r!=="default"&&!Object.prototype.hasOwnProperty.call(t,r)&&Ezn(t,e,r)};Object.defineProperty(Bv,"__esModule",{value:!0});yRe(c6t(),Bv);yRe(eee(),Bv);yRe(f6t(),Bv)});var DN=y(sV=>{"use strict";Object.defineProperty(sV,"__esModule",{value:!0});sV.ODataRequestError=void 0;sV.isAxiosError=$zn;function $zn(e){return typeof e=="object"&&e!==null&&"isAxiosError"in e}var wRe=class extends Error{static containsError(t){return!!t?.error}constructor(t){let r=t.error;super(`${r.message} (${r.code})`),this.name=this.constructor.name}};sV.ODataRequestError=wRe});var a_=y(NN=>{"use strict";Object.defineProperty(NN,"__esModule",{value:!0});NN.ODataService=NN.ODataVersion=void 0;var Mzn=uu(),I6t;(function(e){e.v2="2",e.v4="4"})(I6t||(NN.ODataVersion=I6t={}));function Fzn(e=!1){let t=this.data?JSON.parse(this.data):{};return t.d?t.d.results?t.d.results:t.d:!e&&t["@odata.context"]&&t.value?t.value:t}var PRe=class extends Mzn.Axios{log;doc;metadataDoc;async document(){if(!this.doc){let r=(await this.get("/")).odata();r.EntitySets?this.doc=r:this.doc={EntitySets:r.map(n=>n.name)}}return this.doc}async metadata(){if(!this.metadataDoc){let t=await this.get("/$metadata",{headers:{Accept:"application/xml"}});this.metadataDoc=t.data}return this.metadataDoc}async get(t,r={},n=!1){r.params instanceof URLSearchParams&&!r.params.has("$format")&&!r.headers?.Accept?(r.params.set("$format","json"),r.headers=r.headers??{},r.headers.Accept="application/json"):r.params?.$format===void 0&&!r.headers?.Accept&&(r.params=r.params??{},r.params.$format="json",r.headers=r.headers??{},r.headers.Accept="application/json");let i=await super.get(t,r),a=i.headers["content-type"]??i.headers["Content-Type"];return i.data&&(a?.includes("application/json")||r.params?.$format==="json")&&(i.odata=Fzn.bind(i,n)),i}};NN.ODataService=PRe});var NRe=y((vQi,L6t)=>{"use strict";var R6t=require("fs"),DRe;function jzn(){try{return R6t.statSync("/.dockerenv"),!0}catch{return!1}}function qzn(){try{return R6t.readFileSync("/proc/self/cgroup","utf8").includes("docker")}catch{return!1}}L6t.exports=()=>(DRe===void 0&&(DRe=jzn()||qzn()),DRe)});var M6t=y((bQi,IRe)=>{"use strict";var Vzn=require("os"),Uzn=require("fs"),k6t=NRe(),$6t=()=>{if(process.platform!=="linux")return!1;if(Vzn.release().toLowerCase().includes("microsoft"))return!k6t();try{return Uzn.readFileSync("/proc/version","utf8").toLowerCase().includes("microsoft")?!k6t():!1}catch{return!1}};process.env.__IS_WSL_TEST__?IRe.exports=$6t:IRe.exports=$6t()});var RRe=y((EQi,U6t)=>{"use strict";var{promisify:j6t}=require("util"),Bzn=require("path"),q6t=require("child_process"),V6t=require("fs"),cV=M6t(),zzn=NRe(),Hzn=j6t(V6t.access),Gzn=j6t(q6t.execFile),F6t=Bzn.join(__dirname,"xdg-open"),Kzn=async e=>{let{stdout:t}=await Gzn("wslpath",["-w",e]);return t.trim()};U6t.exports=async(e,t)=>{if(typeof e!="string")throw new TypeError("Expected a `target`");t={wait:!1,background:!1,url:!1,...t};let r,n=[],i=[],a={};if(Array.isArray(t.app)&&(n=t.app.slice(1),t.app=t.app[0]),t.url&&(e=encodeURI(e),cV&&(e=e.replace(/&/g,"^&"))),process.platform==="darwin")r="open",t.wait&&i.push("--wait-apps"),t.background&&i.push("--background"),t.app&&i.push("-a",t.app);else if(process.platform==="win32"||cV&&!zzn()){if(r="cmd"+(cV?".exe":""),i.push("/s","/c","start",'""',"/b"),cV||(e=`"${e}"`,a.windowsVerbatimArguments=!0,t.app&&(t.app=`"${t.app}"`)),t.wait&&i.push("/wait"),t.app){if(cV&&t.app.startsWith("/mnt/")){let s=await Kzn(t.app);t.app=s}i.push(t.app)}n.length>0&&i.push(...n)}else{if(t.app)r=t.app;else{let s=!__dirname||__dirname==="/",c=!1;try{await Hzn(F6t,V6t.constants.X_OK),c=!0}catch{}r=process.versions.electron||process.platform==="android"||s||!c?"xdg-open":F6t}n.length>0&&i.push(...n),t.wait||(a.stdio="ignore",a.detached=!0)}i.push(e),process.platform==="darwin"&&n.length>0&&i.push("--args",...n);let o=q6t.spawn(r,i,a);return t.wait?new Promise((s,c)=>{o.once("error",c),o.once("close",u=>{if(u>0){c(new Error(`Exited with code ${u}`));return}s(o)})}):(o.unref(),o)}});var z6t=y((bee,B6t)=>{"use strict";Object.defineProperty(bee,"__esModule",{value:!0});bee.default=Yzn;function Yzn(e){let t=e.slice(0,512),r=0;for(;r<t.length&&Wzn(t[r]);)r++;for(let n of Zzn){let i=n.match(t,r);if(i!="")return i}return"application/octet-stream"}function Wzn(e){switch(e){case 9:case 10:case 44:case 13:case 32:return!0}return!1}var ml=class{constructor(t,r){Object.assign(this,{sig:t,ct:r})}match(t){return Buffer.compare(this.sig,t.slice(0,this.sig.length))==0?this.ct:""}},gl=class{constructor(t,r,n,i){Object.assign(this,{mask:t,pat:r,skipWS:n,ct:i})}match(t,r){if(this.skipWS&&(t=t.slice(r)),this.pat.length!=this.mask.length||t.length<this.mask.length)return"";for(let n=0;n<this.mask.length;n++)if((t[n]&this.mask[n])!=this.pat[n])return"";return this.ct}},$o=class{constructor(t){this.h=Buffer.from(t)}match(t,r){if(t=t.slice(r),t.length<this.h.length+1)return"";for(let i=0;i<this.h.length;i++){let a=this.h[i],o=t[i];if(65<=a&&a<=90&&(o&=223),a!=o)return""}let n=String.fromCharCode(t[this.h.length]);return n!=" "&&n!=">"?"":"text/html; charset=utf-8"}},Xzn=Buffer.from("ftyp"),Jzn=Buffer.from("mp4"),LRe=class{match(t){if(t.length<12)return"";let r=t.readUInt32BE(0);if(r%4!=0||t.length<r||Buffer.compare(t.slice(4,8),Xzn)!=0)return"";for(let n=8;n<r;n+=4)if(n!=12&&Buffer.compare(t.slice(n,n+3),Jzn)==0)return"video/mp4";return""}},kRe=class{match(t,r){for(let n of t.slice(r))if(n<=8||n==11||14<=n&&n<=26||28<=n&&n<=31)return"";return"text/plain; charset=utf-8"}},Zzn=[new $o("<!DOCTYPE HTML"),new $o("<HTML"),new $o("<HEAD"),new $o("<SCRIPT"),new $o("<IFRAME"),new $o("<H1"),new $o("<DIV"),new $o("<FONT"),new $o("<TABLE"),new $o("<A"),new $o("<STYLE"),new $o("<TITLE"),new $o("<B"),new $o("<BODY"),new $o("<BR"),new $o("<P"),new $o("<!--"),new gl(Buffer.from([255,255,255,255,255]),Buffer.from("<?xml"),!0,"text/xml; charset=utf-8"),new ml(Buffer.from("%PDF-"),"application/pdf"),new ml(Buffer.from("%!PS-Adobe-"),"application/postscript"),new gl(Buffer.from([255,255,0,0]),Buffer.from([254,255,0,0]),!1,"text/plain; charset=utf-16be"),new gl(Buffer.from([255,255,0,0]),Buffer.from([255,254,0,0]),!1,"text/plain; charset=utf-16le"),new gl(Buffer.from([255,255,255,0]),Buffer.from([239,187,191,0]),!1,"text/plain; charset=utf-8"),new ml(Buffer.from("GIF87a"),"image/gif"),new ml(Buffer.from("GIF89a"),"image/gif"),new ml(Buffer.from([137,80,78,71,13,10,26,10]),"image/png"),new ml(Buffer.from([255,216,255]),"image/jpeg"),new ml(Buffer.from("BM"),"image/bmp"),new gl(Buffer.from([255,255,255,255,0,0,0,0,255,255,255,255,255,255]),Buffer.from("RIFF\0\0\0\0WEBPVP"),!1,"image/webp"),new ml(Buffer.from([0,0,1,0]),"image/vnd.microsoft.icon"),new gl(Buffer.from([255,255,255,255,0,0,0,0,255,255,255,255]),Buffer.from("RIFF\0\0\0\0WAVE"),!1,"audio/wave"),new gl(Buffer.from([255,255,255,255,0,0,0,0,255,255,255,255]),Buffer.from("FORM\0\0\0\0AIFF"),!1,"audio/aiff"),new gl(Buffer.from([255,255,255,255]),Buffer.from(".snd"),!1,"audio/basic"),new gl(Buffer.from([255,255,255,255,255]),Buffer.from("OggS\0"),!1,"application/ogg"),new gl(Buffer.from([255,255,255,255,255,255,255,255]),Buffer.concat([Buffer.from("MThd"),Buffer.from([0,0,0,6])]),!1,"audio/midi"),new gl(Buffer.from([255,255,255]),Buffer.from("ID3"),!1,"audio/mpeg"),new gl(Buffer.from([255,255,255,255,0,0,0,0,255,255,255,255]),Buffer.from("RIFF\0\0\0\0AVI "),!1,"video/avi"),new ml(Buffer.from([26,69,223,163]),"video/webm"),new ml(Buffer.from([82,97,114,32,26,7,0]),"application/x-rar-compressed"),new ml(Buffer.from([80,75,3,4]),"application/zip"),new ml(Buffer.from([31,139,8]),"application/x-gzip"),new LRe,new kRe];B6t.exports=bee.default});var Eee=y(mh=>{"use strict";var Qzn=mh&&mh.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(mh,"__esModule",{value:!0});mh.Cookies=mh.defaultTimeout=mh.CSRF=void 0;mh.attachConnectionHandler=a9n;var H6t=uu(),e9n=Qzn(z6t()),pg;(function(e){e.RequestHeaderName="X-Csrf-Token",e.RequestHeaderValue="Fetch",e.ResponseHeaderName="x-csrf-token"})(pg||(mh.CSRF=pg={}));mh.defaultTimeout=60*1e3;var $Re=class{cookies={};setCookies(t){return t.headers?.["set-cookie"]&&t.headers["set-cookie"].forEach(r=>this.addCookie(r)),this}addCookie(t){let r=t.split(";"),[n,...i]=r[0]?.split("=")||[],a=i?.join("=");return n&&t.indexOf("Max-Age=0")>=0?delete this.cookies[n]:n&&a&&(this.cookies[n]=a),this}toString(){let t=[];return Object.keys(this.cookies).forEach(r=>{t.push(`${r}=${this.cookies[r]}`)}),t.join("; ")}};mh.Cookies=$Re;function t9n(e){return e?.status===200&&G6t(e)&&typeof e.data=="string"&&!!e.data.match(/saml/i)}function r9n(e){if(e?.status===200&&(e.headers["sap-err-id"]==="ICFLOGONREQUIRED"||n9n(e))){let t=new Error;throw t.response={status:401},t.isAxiosError=!0,t.toJSON=()=>({status:401}),t}}function G6t(e){return i9n(e.headers["content-type"],e.data).startsWith("text/html")}function n9n(e){return G6t(e)&&typeof e.data=="string"&&!!e.data.match(/log[io]n/i)}function i9n(e,t){return e?e.toLowerCase():typeof t=="string"?(0,e9n.default)(Buffer.from(t))?.toLowerCase()??"":""}function a9n(e){let t=e.interceptors.request.use(n=>(n.headers=n.headers??new H6t.AxiosHeaders,n.headers[pg.RequestHeaderName]=pg.RequestHeaderValue,n)),r=e.interceptors.response.use(n=>t9n(n)&&e.defaults.params?.saml2!=="disabled"?(e.defaults.params=e.defaults.params??{},e.defaults.params.saml2="disabled",e.request(n.config)):(r9n(n),n.headers?.[pg.ResponseHeaderName]&&(e.defaults.headers.common[pg.RequestHeaderName]=n.headers[pg.ResponseHeaderName],e.interceptors.request.eject(t)),e.interceptors.response.eject(r),n),n=>{throw n.response&&(n.response.headers?.[pg.ResponseHeaderName]&&(e.defaults.headers.common[pg.RequestHeaderName]=n.response.headers[pg.ResponseHeaderName],e.interceptors.request.eject(t)),e.cookies.setCookies(n.response)),n});e.interceptors.request.use(n=>(n.headers=n.headers??new H6t.AxiosHeaders,n.headers.cookie=e.cookies.toString(),n)),e.interceptors.response.use(n=>(e.cookies.setCookies(n),n))}});var K6t=y(IN=>{"use strict";var o9n=IN&&IN.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(IN,"__esModule",{value:!0});IN.ABAPVirtualHostProvider=void 0;var s9n=w0(),c9n=o9n(uu()),MRe=class{apiURL;uiURL;systemURL;relatedUrls;logger=new s9n.ToolsLogger;constructor(t,r){this.systemURL=new URL(t),r&&(this.logger=r)}async getVirtualHosts(){if(!this.relatedUrls){this.logger.debug(`Requesting virtual hosts from: ${this.systemURL}`);let t=new URL("/sap/public/bc/icf/virtualhost",this.systemURL.origin),r=await c9n.default.get(t.href,{headers:{Accept:"application/json"}});if(r.status!==200)throw this.logger.debug(`Failed to fetch virtual hosts: from: ${t}. Error: ${r.statusText}`),new Error(`Failed to fetch virtual hosts: ${r.statusText}`);this.relatedUrls=r.data}return this.relatedUrls}async uiHostname(){return this.uiURL||(this.uiURL=new URL((await this.getVirtualHosts()).relatedUrls.UI)),this.uiURL.origin}async apiHostname(){return this.apiURL||(this.apiURL=new URL((await this.getVirtualHosts()).relatedUrls.API)),this.apiURL.origin}async logoffUrl(){return await this.uiHostname()+"/sap/public/bc/icf/logoff"}};IN.ABAPVirtualHostProvider=MRe});var xee=y(fg=>{"use strict";Object.defineProperty(fg,"__esModule",{value:!0});fg.UAATimeoutError=fg.TimeoutError=fg.ConnectionError=fg.BaseError=void 0;var uV=class extends Error{cause;constructor(t,r){super(t),this.cause=r,this.name=this.constructor.name}};fg.BaseError=uV;var FRe=class extends uV{};fg.ConnectionError=FRe;var _ee=class extends uV{};fg.TimeoutError=_ee;var jRe=class extends _ee{};fg.UAATimeoutError=jRe});var T1=y(o_=>{"use strict";Object.defineProperty(o_,"__esModule",{value:!0});o_.prettyPrintTimeInMs=void 0;o_.prettyPrintMessage=l9n;o_.prettyPrintError=J6t;o_.logError=f9n;o_.getErrorMessageFromString=Z6t;var Y6t=require("node:url"),u9n=uu();function W6t(e,t,r,n=!1){e?(e=e.toLowerCase(),e==="success"?r.info(t):(e==="warning"&&(e="warn"),r[e](t))):n?r.error(t):r.info(t)}function l9n({msg:e,log:t,host:r,isDest:n=!1}){try{let i=JSON.parse(e);t.info(i.message),X6t({host:r,path:i.longtext_url,log:t,isDest:n}),i.details&&i.details.forEach(a=>{W6t(a.severity,a.message,t)})}catch{t.debug(e)}}function X6t({host:e,path:t,log:r,isDest:n=!1}){if(e&&t){let i=new Y6t.URL(e).origin;r.info("Please copy/paste this URL in a browser for more details:"),n&&r.info("(Note: You will need to replace the host in the URL with the internal host, if your destination is configured using an On-Premise SAP Cloud Connector)"),r.info(new Y6t.URL(t,i).href)}}function J6t({error:e,log:t,host:r,isDest:n},i=!0){if(e&&(i&&t.error(e.message?.value||"An unknown error occurred."),(e.innererror?.errordetails||[]).forEach(a=>{a.message.startsWith("<![CDATA")||W6t(a.severity,a.message,t,!0),X6t({host:r,path:a.longtext_url,log:t,isDest:n})}),i&&e.innererror?.Error_Resolution))for(let a in e.innererror.Error_Resolution)t.error(`${a}: ${e.innererror.Error_Resolution[a]}`)}var p9n=e=>{let t=e/60/1e3|0;return t>1?`${t} minutes`:t===1?"1 minute":`${e/1e3} seconds`};o_.prettyPrintTimeInMs=p9n;function f9n({error:e,host:t,log:r,isDest:n}){if(r.error(e.message),(0,u9n.isAxiosError)(e)&&e.response?.data){let i=Z6t(e.response?.data);i?J6t({error:i,log:r,host:t,isDest:n}):r.error(e.response.data.toString())}}function Z6t(e){let t;if(typeof e=="string")try{let r=JSON.parse(e);r.error&&(t=r.error)}catch{}return t}});var qRe=y(RN=>{"use strict";Object.defineProperty(RN,"__esModule",{value:!0});RN.redirectErrorHtml=RN.redirectSuccessHtml=void 0;var d9n=(e,t)=>{let r=`${t?t+": ":""}Authentication Successful`,n=e?'<a class="centerLink" href="'+e+'">(Click here to log off the current user)</a>':"";return Q6t({title:r,content:n})};RN.redirectSuccessHtml=d9n;var h9n=e=>{let t=`${e?e+": ":""}Authentication Successful`;return Q6t({title:t,content:"Login failed, please check the logs in the console"})};RN.redirectErrorHtml=h9n;function Q6t({title:e,content:t}){return`
|
|
1231
|
+
</Annotations>`),i}function szn(e){return e.hasOwnProperty("Action")&&(e.$Type==="com.sap.vocabularies.UI.v1.DataFieldForAction"||e.$Type==="com.sap.vocabularies.UI.v1.DataFieldWithAction")}function czn(e,t,r,n,i){let a;return!i.type&&t?a=Q8t(e,t,r.fullyQualifiedName,n):a=e.unalias(i.type),a}function mRe(e,t,r,n,i,a,o){let s={$Type:czn(e,t,r,n,a),fullyQualifiedName:o,[hh]:r,__source:i};for(let c of a.propertyValues)(0,rt.lazy)(s,c.name,()=>Z8t(e,r,t,c.name,i,c.value,`${o}/${c.name}`));return(0,rt.lazy)(s,"annotations",r6t(e,a,s)),szn(s)&&(0,rt.lazy)(s,"ActionTarget",()=>{var c,u;let l=e.unalias((c=s.Action)===null||c===void 0?void 0:c.toString()),p=r.actions[l];return p||(p=(u=e.getConvertedActionImport(l))===null||u===void 0?void 0:u.action),p||(p=e.getConvertedAction(l),p?.isBound||(p=void 0)),p||e.logError(`${s.fullyQualifiedName}: Unable to resolve '${s.Action}' ('${l}')`),p}),s}function uzn(e){let t=e.type;if(t===void 0&&e.length>0){let r=e[0];r.hasOwnProperty("PropertyPath")?t="PropertyPath":r.hasOwnProperty("Path")?t="Path":r.hasOwnProperty("AnnotationPath")?t="AnnotationPath":r.hasOwnProperty("NavigationPropertyPath")?t="NavigationPropertyPath":typeof r=="object"&&(r.hasOwnProperty("type")||r.hasOwnProperty("propertyValues"))?t="Record":typeof r=="string"&&(t="String")}else t===void 0&&(t="EmptyCollection");return t}function e6t(e,t,r,n,i,a,o){switch(uzn(a)){case"PropertyPath":return a.map((c,u)=>W8t(e,c,`${o}/${u}`,t,r));case"Path":return a.map(c=>xp(e,t,c.Path,r).target);case"AnnotationPath":return a.map((c,u)=>X8t(e,c,`${o}/${u}`,t,r));case"NavigationPropertyPath":return a.map((c,u)=>J8t(e,c,`${o}/${u}`,t,r));case"Record":return a.map((c,u)=>mRe(e,r,t,n,i,c,`${o}/${u}`));case"Apply":case"Null":case"If":case"Eq":case"Ne":case"Lt":case"Gt":case"Le":case"Ge":case"Not":case"And":case"Or":return a.map(c=>c);case"String":return a.map(c=>typeof c=="string"||c===void 0?c:c.String);default:if(a.length===0)return[];throw new Error("Unsupported case")}}function lzn(e){return!!e.targetTypeName}function pzn(e,t,r){var n;let i;if(r.record)i=mRe(e,r.term,t,"",r.__source,r.record,r.fullyQualifiedName);else if(r.collection===void 0)i=Z8t(e,t,r.term,"",r.__source,(n=r.value)!==null&&n!==void 0?n:{type:"Bool",Bool:!0},r.fullyQualifiedName);else if(r.collection)i=e6t(e,t,r.term,"",r.__source,r.collection,r.fullyQualifiedName);else throw new Error("Unsupported case");switch(typeof i){case"string":i=new String(i);break;case"boolean":i=new Boolean(i);break;case"number":i=new Number(i);break;default:break}i.fullyQualifiedName=r.fullyQualifiedName,i[hh]=t;let[a,o]=e.splitTerm(r.term);i.term=e.unalias(`${a}.${o}`,tee.VocabularyReferences),i.qualifier=r.qualifier,i.__source=r.__source;try{(0,rt.lazy)(i,"annotations",r6t(e,r,i))}catch{}return i}var dRe=class{getAnnotations(t){var r;if(this.annotationsByTarget===void 0){let n=Object.keys(this.rawSchema.annotations).map(i=>({name:i,annotationList:this.rawSchema.annotations[i]}));this.annotationsByTarget=(0,rt.mergeAnnotations)(this.rawMetadata.references,...n)}return(r=this.annotationsByTarget[t])!==null&&r!==void 0?r:[]}getConvertedEntityContainer(){return this.getConvertedElement(this.rawMetadata.schema.entityContainer.fullyQualifiedName,this.rawMetadata.schema.entityContainer,n6t)}getConvertedEntitySet(t){return this.convertedOutput.entitySets.by_fullyQualifiedName(t)}getConvertedSingleton(t){return this.convertedOutput.singletons.by_fullyQualifiedName(t)}getConvertedEntityType(t){return this.convertedOutput.entityTypes.by_fullyQualifiedName(t)}getConvertedComplexType(t){return this.convertedOutput.complexTypes.by_fullyQualifiedName(t)}getConvertedTypeDefinition(t){return this.convertedOutput.typeDefinitions.by_fullyQualifiedName(t)}getConvertedActionImport(t){let r=this.convertedOutput.actionImports.by_fullyQualifiedName(t);return r||(r=this.convertedOutput.actionImports.by_name(t)),r}getConvertedAction(t){return this.convertedOutput.actions.by_fullyQualifiedName(t)}convert(t,r){return Array.isArray(t)?()=>{let n=t.reduce((i,a)=>{let o=this.getConvertedElement(a.fullyQualifiedName,a,r);return o&&i.push(o),i},[]);return(0,rt.addGetByValue)(n,"name"),(0,rt.addGetByValue)(n,"fullyQualifiedName"),n}:()=>this.getConvertedElement(t.fullyQualifiedName,t,r)}constructor(t,r){this.convertedElements=new Map,this.rawMetadata=t,this.rawSchema=t.schema,this.convertedOutput=r}getConvertedElement(t,r,n){let i=this.convertedElements.get(t);if(i===void 0){let a=typeof r=="function"?r.apply(void 0,[t]):r;a!==void 0&&(i=n.apply(void 0,[this,a]),this.convertedElements.set(t,i))}return i}logError(t){this.convertedOutput.diagnostics.push({message:t})}splitTerm(t){let r=(0,rt.alias)(tee.VocabularyReferences,t);return(0,rt.splitAtLast)(r,".")}unalias(t,r=this.rawMetadata.references){var n;return(n=(0,rt.unalias)(r,t,this.rawSchema.namespace))!==null&&n!==void 0?n:""}};function nV(e,t){return()=>{let r=e.getConvertedEntityType(t);return r||(e.logError(`EntityType '${t}' not found`),r={}),r}}function t6t(e,t){return()=>Object.keys(t).reduce((r,n)=>{let i=t[n];return(0,rt.lazy)(r,n,()=>{var a;return(a=e.getConvertedEntitySet(i))!==null&&a!==void 0?a:e.getConvertedSingleton(i)}),r},{})}function Uv(e,t){let r=t.annotations;return()=>ree(e,t,r??e.getAnnotations(t.fullyQualifiedName))}function r6t(e,t,r){return()=>{let n=r.fullyQualifiedName,i;return t.annotations&&t.annotations.length>0?i=t.annotations:i=e.getAnnotations(n),i?.forEach(a=>{a.target=n,a.__source=r.__source,a[hh]=r[hh],a.fullyQualifiedName=`${n}@${a.term}`}),ree(e,r,i??[])}}function ree(e,t,r){return r.reduce((n,i)=>{let[a,o]=e.splitTerm(i.term),s=`${o}${i.qualifier?"#"+i.qualifier:""}`;return n[a]===void 0&&(n[a]={_keys:[]}),n[a].hasOwnProperty(s)||(n[a]._keys.push(s),(0,rt.lazy)(n[a],s,()=>e.getConvertedElement(i.fullyQualifiedName,i,(c,u)=>pzn(c,t,u)))),n},{})}function n6t(e,t){let r=t;return(0,rt.lazy)(r,"annotations",Uv(e,t)),(0,rt.lazy)(r,"entitySets",e.convert(e.rawSchema.entitySets,a6t)),(0,rt.lazy)(r,"singletons",e.convert(e.rawSchema.singletons,i6t)),(0,rt.lazy)(r,"actionImports",e.convert(e.rawSchema.actionImports,s6t)),r}function i6t(e,t){let r=t;(0,rt.lazy)(r,"entityType",nV(e,t.entityTypeName)),(0,rt.lazy)(r,"annotations",Uv(e,r));let n=t.navigationPropertyBinding;return(0,rt.lazy)(r,"navigationPropertyBinding",t6t(e,n)),r}function a6t(e,t){let r=t;(0,rt.lazy)(r,"entityType",nV(e,t.entityTypeName)),(0,rt.lazy)(r,"annotations",Uv(e,r));let n=t.navigationPropertyBinding;return(0,rt.lazy)(r,"navigationPropertyBinding",t6t(e,n)),r}function fzn(e,t){let r=t;return t.keys.forEach(n=>{n.isKey=!0}),(0,rt.lazy)(r,"annotations",Uv(e,t)),(0,rt.lazy)(r,"keys",e.convert(t.keys,hRe)),(0,rt.lazy)(r,"entityProperties",e.convert(t.entityProperties,hRe)),(0,rt.lazy)(r,"navigationProperties",e.convert(t.navigationProperties,o6t)),(0,rt.lazy)(r,"actions",()=>e.rawSchema.actions.filter(n=>n.isBound&&(n.sourceType===t.fullyQualifiedName||n.sourceType===`Collection(${t.fullyQualifiedName})`)).reduce((n,i)=>{let a=`${e.rawSchema.namespace}.${i.name}`;return n[a]=e.getConvertedAction(i.fullyQualifiedName),n},{})),r.resolvePath=(n,i)=>{let a=xp(e,t,n);return i?{target:a.target,visitedObjects:a.objectPath,messages:a.messages}:a.target},r}function hRe(e,t){let r=t;return(0,rt.lazy)(r,"annotations",Uv(e,t)),(0,rt.lazy)(r,"targetType",()=>{var n;let i=t.type,a=i.startsWith("Collection")?i.substring(11,i.length-1):i;return(n=e.getConvertedComplexType(a))!==null&&n!==void 0?n:e.getConvertedTypeDefinition(a)}),r}function o6t(e,t){var r,n,i,a,o;let s=t;if(s.referentialConstraint=(r=s.referentialConstraint)!==null&&r!==void 0?r:[],s.referentialConstraint.length===0){let u=e.getAnnotations(t.fullyQualifiedName).find(l=>l.term==="com.sap.vocabularies.Common.v1.ReferentialConstraint");u&&(s.referentialConstraint=(i=(n=u.collection)===null||n===void 0?void 0:n.map(l=>{var p,f;let d=(p=l.propertyValues.find(m=>m.name==="ReferencedProperty"))===null||p===void 0?void 0:p.value,h="";if(d.PropertyPath){let m=d.PropertyPath.split("/");m.shift(),h=m.join("/")}return{sourceProperty:((f=l.propertyValues.find(m=>m.name==="Property"))===null||f===void 0?void 0:f.value).PropertyPath,targetTypeName:s.targetTypeName,targetProperty:h}}))!==null&&i!==void 0?i:[])}if(!lzn(t)){let c=(a=e.rawSchema.associations.find(u=>u.fullyQualifiedName===t.relationship))===null||a===void 0?void 0:a.associationEnd.find(u=>u.role===t.toRole);s.isCollection=c?.multiplicity==="*",s.targetTypeName=(o=c?.type)!==null&&o!==void 0?o:""}return(0,rt.lazy)(s,"targetType",nV(e,t.targetTypeName)),(0,rt.lazy)(s,"annotations",Uv(e,t)),s}function s6t(e,t){let r=t;return(0,rt.lazy)(r,"annotations",Uv(e,t)),(0,rt.lazy)(r,"action",()=>{let n=e.rawSchema.actions.filter(i=>!i.isBound&&i.fullyQualifiedName.startsWith(t.actionName+"("));return n.length>1&&e.logError(`Ambiguous reference in action import: ${t.fullyQualifiedName}`),e.getConvertedAction(n[0].fullyQualifiedName)}),r}function dzn(e,t){let r=t;return r.sourceType&&(0,rt.lazy)(r,"sourceEntityType",nV(e,t.sourceType)),r.returnType&&((0,rt.lazy)(r,"returnEntityType",nV(e,t.returnType)),(0,rt.lazy)(r,"returnTypeReference",()=>{var n,i;let a=r.returnType.startsWith("Collection")?r.returnType.substring(11,r.returnType.length-1):r.returnType;return(i=(n=e.getConvertedEntityType(a))!==null&&n!==void 0?n:e.getConvertedComplexType(a))!==null&&i!==void 0?i:e.getConvertedTypeDefinition(a)})),(0,rt.lazy)(r,"parameters",e.convert(t.parameters,hzn)),(0,rt.lazy)(r,"annotations",()=>{let n=(0,rt.substringBeforeFirst)(t.fullyQualifiedName,"("),i=t.fullyQualifiedName,a=e.getAnnotations(i),o=e.getAnnotations(n);for(let s of o)a.some(c=>c.term===s.term&&c.qualifier===s.qualifier)||a.push(s);return ree(e,t,a)}),r}function hzn(e,t){let r=t;return(0,rt.lazy)(r,"typeReference",()=>{var n,i;let a=t.type;return a.startsWith("Collection(")&&(a=a.substring(11,a.length-1)),(i=(n=e.getConvertedEntityType(a))!==null&&n!==void 0?n:e.getConvertedComplexType(a))!==null&&i!==void 0?i:e.getConvertedTypeDefinition(a)}),(0,rt.lazy)(r,"annotations",()=>{let n=t.fullyQualifiedName.substring(0,t.fullyQualifiedName.indexOf("("))+t.fullyQualifiedName.substring(t.fullyQualifiedName.lastIndexOf(")")+1),i=t.fullyQualifiedName,a=e.getAnnotations(i),o=e.getAnnotations(n);for(let s of o)a.some(c=>c.term===s.term&&c.qualifier===s.qualifier)||a.push(s);return ree(e,t,a)}),r}function mzn(e,t){let r=t;return(0,rt.lazy)(r,"properties",e.convert(t.properties,hRe)),(0,rt.lazy)(r,"navigationProperties",e.convert(t.navigationProperties,o6t)),(0,rt.lazy)(r,"annotations",Uv(e,t)),r}function gzn(e,t){let r=t;return(0,rt.lazy)(r,"annotations",Uv(e,t)),r}function yzn(e){let t={version:e.version,namespace:e.schema.namespace,annotations:e.schema.annotations,references:tee.VocabularyReferences,diagnostics:[]},r=new dRe(e,t);return(0,rt.lazy)(t,"entityContainer",r.convert(r.rawSchema.entityContainer,n6t)),(0,rt.lazy)(t,"entitySets",r.convert(r.rawSchema.entitySets,a6t)),(0,rt.lazy)(t,"singletons",r.convert(r.rawSchema.singletons,i6t)),(0,rt.lazy)(t,"entityTypes",r.convert(r.rawSchema.entityTypes,fzn)),(0,rt.lazy)(t,"actions",r.convert(r.rawSchema.actions,dzn)),(0,rt.lazy)(t,"complexTypes",r.convert(r.rawSchema.complexTypes,mzn)),(0,rt.lazy)(t,"actionImports",r.convert(r.rawSchema.actionImports,s6t)),(0,rt.lazy)(t,"typeDefinitions",r.convert(r.rawSchema.typeDefinitions,gzn)),t.resolvePath=function(i,a){let o=xp(r,a,i);return o.target&&Vv(o.objectPath,o.target),o},t}nee.convert=yzn});var f6t=y(aee=>{"use strict";Object.defineProperty(aee,"__esModule",{value:!0});aee.revertTermToGenericType=void 0;var gRe=eee();function vzn(e,t){var r,n,i,a,o,s,c;let u;if(Array.isArray(t)){let l=t[0],p=!1;if(l&&typeof l=="string"){let f=l.valueOf().split(".");f.length>1&&e.find(d=>d.alias===f[0])&&(p=gRe.EnumIsFlag[(0,gRe.substringBeforeFirst)(l,"/")])}p?u={type:"EnumMember",EnumMember:t.map(f=>f.valueOf()).join(" ")}:u={type:"Collection",Collection:t.map(f=>iee(e,f))}}else if(!((r=t.isDecimal)===null||r===void 0)&&r.call(t))u={type:"Decimal",Decimal:t.valueOf()};else if(!((n=t.isDouble)===null||n===void 0)&&n.call(t))u={type:"Double",Double:t.valueOf()};else if(!((i=t.isString)===null||i===void 0)&&i.call(t)){let l=t.valueOf().split(".");l.length>1&&e.find(p=>p.alias===l[0])?u={type:"EnumMember",EnumMember:t.valueOf()}:u={type:"String",String:t.valueOf()}}else!((a=t.isInt)===null||a===void 0)&&a.call(t)?u={type:"Int",Int:t.valueOf()}:!((o=t.isFloat)===null||o===void 0)&&o.call(t)?u={type:"Float",Float:t.valueOf()}:!((s=t.isDate)===null||s===void 0)&&s.call(t)?u={type:"Date",Date:t.valueOf()}:!((c=t.isBoolean)===null||c===void 0)&&c.call(t)?u={type:"Bool",Bool:t.valueOf()}:t.type==="Path"?u={type:"Path",Path:t.path}:t.type==="AnnotationPath"?u={type:"AnnotationPath",AnnotationPath:t.value}:t.type==="Apply"?u={type:"Apply",$Apply:t.$Apply,$Function:t.$Function}:t.type==="Null"?u={type:"Null"}:t.type==="PropertyPath"?u={type:"PropertyPath",PropertyPath:t.value}:t.type==="NavigationPropertyPath"?u={type:"NavigationPropertyPath",NavigationPropertyPath:t.value}:Object.prototype.hasOwnProperty.call(t,"$Type")&&(u={type:"Record",Record:iee(e,t)});return u}function u6t(e,t){let r;switch(t.type==="Constant"&&(t=t.value),t?.constructor.name){case"String":case"string":let i=t.toString().split(".");i.length>1&&e.find(a=>a.alias===i[0])?r={type:"EnumMember",EnumMember:t.toString()}:r={type:"String",String:t.toString()};break;case"Boolean":case"boolean":r={type:"Bool",Bool:t.valueOf()};break;case"Number":case"number":t.toString()===t.toFixed()?r={type:"Int",Int:t.valueOf()}:r={type:"Decimal",Decimal:t.valueOf()};break;case"object":default:r=vzn(e,t);break}return r}var bzn=["$Type","term","__source","qualifier","ActionTarget","fullyQualifiedName","annotations"];function l6t(e,t,r){Object.keys(t).filter(n=>n!=="_annotations").forEach(n=>{Object.keys(t[n]).filter(i=>i!=="_keys").forEach(i=>{let a=p6t(e,t[n][i]);if(!a.term){let o=(0,gRe.unalias)(e,`${n}.${i}`);if(o){let s=o.split("#");a.term=s[0],s.length>1&&(a.qualifier=s[1])}}r.push(a)})})}function iee(e,t){if(typeof t=="string")return{type:"String",String:t};if(typeof t=="object")if(t.hasOwnProperty("$Type")){let r={type:t.$Type,propertyValues:[]};return Object.keys(t).forEach(n=>{if(bzn.indexOf(n)===-1){let i=t[n];r.propertyValues.push({name:n,value:u6t(e,i)})}else n==="annotations"&&Object.keys(t[n]).length>0&&(r.annotations=[],l6t(e,t[n],r.annotations))}),r}else{if(t.type==="PropertyPath")return{type:"PropertyPath",PropertyPath:t.value};if(t.type==="AnnotationPath")return{type:"AnnotationPath",AnnotationPath:t.value};if(t.type==="NavigationPropertyPath")return{type:"NavigationPropertyPath",NavigationPropertyPath:t.value};if(t.type==="Constant")return t.value}}function p6t(e,t){let r={term:t.term,qualifier:t.qualifier};return Array.isArray(t)?(t.hasOwnProperty("annotations")&&Object.keys(t.annotations).length>0&&(r.annotations=[],l6t(e,t.annotations,r.annotations)),{...r,collection:t.map(n=>iee(e,n))}):t.hasOwnProperty("$Type")?{...r,record:iee(e,t)}:{...r,value:u6t(e,t)}}aee.revertTermToGenericType=p6t});var d6t=y(Bv=>{"use strict";var Ezn=Bv&&Bv.__createBinding||(Object.create?function(e,t,r,n){n===void 0&&(n=r);var i=Object.getOwnPropertyDescriptor(t,r);(!i||("get"in i?!t.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,i)}:function(e,t,r,n){n===void 0&&(n=r),e[n]=t[r]}),yRe=Bv&&Bv.__exportStar||function(e,t){for(var r in e)r!=="default"&&!Object.prototype.hasOwnProperty.call(t,r)&&Ezn(t,e,r)};Object.defineProperty(Bv,"__esModule",{value:!0});yRe(c6t(),Bv);yRe(eee(),Bv);yRe(f6t(),Bv)});var DN=y(sV=>{"use strict";Object.defineProperty(sV,"__esModule",{value:!0});sV.ODataRequestError=void 0;sV.isAxiosError=$zn;function $zn(e){return typeof e=="object"&&e!==null&&"isAxiosError"in e}var wRe=class extends Error{static containsError(t){return!!t?.error}constructor(t){let r=t.error;super(`${r.message} (${r.code})`),this.name=this.constructor.name}};sV.ODataRequestError=wRe});var a_=y(NN=>{"use strict";Object.defineProperty(NN,"__esModule",{value:!0});NN.ODataService=NN.ODataVersion=void 0;var Mzn=uu(),I6t;(function(e){e.v2="2",e.v4="4"})(I6t||(NN.ODataVersion=I6t={}));function Fzn(e=!1){let t=this.data?JSON.parse(this.data):{};return t.d?t.d.results?t.d.results:t.d:!e&&t["@odata.context"]&&t.value?t.value:t}var PRe=class extends Mzn.Axios{log;doc;metadataDoc;async document(){if(!this.doc){let r=(await this.get("/")).odata();r.EntitySets?this.doc=r:this.doc={EntitySets:r.map(n=>n.name)}}return this.doc}async metadata(){if(!this.metadataDoc){let t=await this.get("/$metadata",{headers:{Accept:"application/xml"}});this.metadataDoc=t.data}return this.metadataDoc}async get(t,r={},n=!1){r.params instanceof URLSearchParams&&!r.params.has("$format")&&!r.headers?.Accept?(r.params.set("$format","json"),r.headers=r.headers??{},r.headers.Accept="application/json"):r.params?.$format===void 0&&!r.headers?.Accept&&(r.params=r.params??{},r.params.$format="json",r.headers=r.headers??{},r.headers.Accept="application/json");let i=await super.get(t,r),a=i.headers["content-type"]??i.headers["Content-Type"];return i.data&&(a?.includes("application/json")||r.params?.$format==="json")&&(i.odata=Fzn.bind(i,n)),i}};NN.ODataService=PRe});var NRe=y((vQi,L6t)=>{"use strict";var R6t=require("fs"),DRe;function jzn(){try{return R6t.statSync("/.dockerenv"),!0}catch{return!1}}function qzn(){try{return R6t.readFileSync("/proc/self/cgroup","utf8").includes("docker")}catch{return!1}}L6t.exports=()=>(DRe===void 0&&(DRe=jzn()||qzn()),DRe)});var M6t=y((bQi,IRe)=>{"use strict";var Vzn=require("os"),Uzn=require("fs"),k6t=NRe(),$6t=()=>{if(process.platform!=="linux")return!1;if(Vzn.release().toLowerCase().includes("microsoft"))return!k6t();try{return Uzn.readFileSync("/proc/version","utf8").toLowerCase().includes("microsoft")?!k6t():!1}catch{return!1}};process.env.__IS_WSL_TEST__?IRe.exports=$6t:IRe.exports=$6t()});var RRe=y((EQi,U6t)=>{"use strict";var{promisify:j6t}=require("util"),Bzn=require("path"),q6t=require("child_process"),V6t=require("fs"),cV=M6t(),zzn=NRe(),Hzn=j6t(V6t.access),Gzn=j6t(q6t.execFile),F6t=Bzn.join(__dirname,"xdg-open"),Kzn=async e=>{let{stdout:t}=await Gzn("wslpath",["-w",e]);return t.trim()};U6t.exports=async(e,t)=>{if(typeof e!="string")throw new TypeError("Expected a `target`");t={wait:!1,background:!1,url:!1,...t};let r,n=[],i=[],a={};if(Array.isArray(t.app)&&(n=t.app.slice(1),t.app=t.app[0]),t.url&&(e=encodeURI(e),cV&&(e=e.replace(/&/g,"^&"))),process.platform==="darwin")r="open",t.wait&&i.push("--wait-apps"),t.background&&i.push("--background"),t.app&&i.push("-a",t.app);else if(process.platform==="win32"||cV&&!zzn()){if(r="cmd"+(cV?".exe":""),i.push("/s","/c","start",'""',"/b"),cV||(e=`"${e}"`,a.windowsVerbatimArguments=!0,t.app&&(t.app=`"${t.app}"`)),t.wait&&i.push("/wait"),t.app){if(cV&&t.app.startsWith("/mnt/")){let s=await Kzn(t.app);t.app=s}i.push(t.app)}n.length>0&&i.push(...n)}else{if(t.app)r=t.app;else{let s=!__dirname||__dirname==="/",c=!1;try{await Hzn(F6t,V6t.constants.X_OK),c=!0}catch{}r=process.versions.electron||process.platform==="android"||s||!c?"xdg-open":F6t}n.length>0&&i.push(...n),t.wait||(a.stdio="ignore",a.detached=!0)}i.push(e),process.platform==="darwin"&&n.length>0&&i.push("--args",...n);let o=q6t.spawn(r,i,a);return t.wait?new Promise((s,c)=>{o.once("error",c),o.once("close",u=>{if(u>0){c(new Error(`Exited with code ${u}`));return}s(o)})}):(o.unref(),o)}});var z6t=y((bee,B6t)=>{"use strict";Object.defineProperty(bee,"__esModule",{value:!0});bee.default=Yzn;function Yzn(e){let t=e.slice(0,512),r=0;for(;r<t.length&&Wzn(t[r]);)r++;for(let n of Zzn){let i=n.match(t,r);if(i!="")return i}return"application/octet-stream"}function Wzn(e){switch(e){case 9:case 10:case 44:case 13:case 32:return!0}return!1}var ml=class{constructor(t,r){Object.assign(this,{sig:t,ct:r})}match(t){return Buffer.compare(this.sig,t.slice(0,this.sig.length))==0?this.ct:""}},gl=class{constructor(t,r,n,i){Object.assign(this,{mask:t,pat:r,skipWS:n,ct:i})}match(t,r){if(this.skipWS&&(t=t.slice(r)),this.pat.length!=this.mask.length||t.length<this.mask.length)return"";for(let n=0;n<this.mask.length;n++)if((t[n]&this.mask[n])!=this.pat[n])return"";return this.ct}},$o=class{constructor(t){this.h=Buffer.from(t)}match(t,r){if(t=t.slice(r),t.length<this.h.length+1)return"";for(let i=0;i<this.h.length;i++){let a=this.h[i],o=t[i];if(65<=a&&a<=90&&(o&=223),a!=o)return""}let n=String.fromCharCode(t[this.h.length]);return n!=" "&&n!=">"?"":"text/html; charset=utf-8"}},Xzn=Buffer.from("ftyp"),Jzn=Buffer.from("mp4"),LRe=class{match(t){if(t.length<12)return"";let r=t.readUInt32BE(0);if(r%4!=0||t.length<r||Buffer.compare(t.slice(4,8),Xzn)!=0)return"";for(let n=8;n<r;n+=4)if(n!=12&&Buffer.compare(t.slice(n,n+3),Jzn)==0)return"video/mp4";return""}},kRe=class{match(t,r){for(let n of t.slice(r))if(n<=8||n==11||14<=n&&n<=26||28<=n&&n<=31)return"";return"text/plain; charset=utf-8"}},Zzn=[new $o("<!DOCTYPE HTML"),new $o("<HTML"),new $o("<HEAD"),new $o("<SCRIPT"),new $o("<IFRAME"),new $o("<H1"),new $o("<DIV"),new $o("<FONT"),new $o("<TABLE"),new $o("<A"),new $o("<STYLE"),new $o("<TITLE"),new $o("<B"),new $o("<BODY"),new $o("<BR"),new $o("<P"),new $o("<!--"),new gl(Buffer.from([255,255,255,255,255]),Buffer.from("<?xml"),!0,"text/xml; charset=utf-8"),new ml(Buffer.from("%PDF-"),"application/pdf"),new ml(Buffer.from("%!PS-Adobe-"),"application/postscript"),new gl(Buffer.from([255,255,0,0]),Buffer.from([254,255,0,0]),!1,"text/plain; charset=utf-16be"),new gl(Buffer.from([255,255,0,0]),Buffer.from([255,254,0,0]),!1,"text/plain; charset=utf-16le"),new gl(Buffer.from([255,255,255,0]),Buffer.from([239,187,191,0]),!1,"text/plain; charset=utf-8"),new ml(Buffer.from("GIF87a"),"image/gif"),new ml(Buffer.from("GIF89a"),"image/gif"),new ml(Buffer.from([137,80,78,71,13,10,26,10]),"image/png"),new ml(Buffer.from([255,216,255]),"image/jpeg"),new ml(Buffer.from("BM"),"image/bmp"),new gl(Buffer.from([255,255,255,255,0,0,0,0,255,255,255,255,255,255]),Buffer.from("RIFF\0\0\0\0WEBPVP"),!1,"image/webp"),new ml(Buffer.from([0,0,1,0]),"image/vnd.microsoft.icon"),new gl(Buffer.from([255,255,255,255,0,0,0,0,255,255,255,255]),Buffer.from("RIFF\0\0\0\0WAVE"),!1,"audio/wave"),new gl(Buffer.from([255,255,255,255,0,0,0,0,255,255,255,255]),Buffer.from("FORM\0\0\0\0AIFF"),!1,"audio/aiff"),new gl(Buffer.from([255,255,255,255]),Buffer.from(".snd"),!1,"audio/basic"),new gl(Buffer.from([255,255,255,255,255]),Buffer.from("OggS\0"),!1,"application/ogg"),new gl(Buffer.from([255,255,255,255,255,255,255,255]),Buffer.concat([Buffer.from("MThd"),Buffer.from([0,0,0,6])]),!1,"audio/midi"),new gl(Buffer.from([255,255,255]),Buffer.from("ID3"),!1,"audio/mpeg"),new gl(Buffer.from([255,255,255,255,0,0,0,0,255,255,255,255]),Buffer.from("RIFF\0\0\0\0AVI "),!1,"video/avi"),new ml(Buffer.from([26,69,223,163]),"video/webm"),new ml(Buffer.from([82,97,114,32,26,7,0]),"application/x-rar-compressed"),new ml(Buffer.from([80,75,3,4]),"application/zip"),new ml(Buffer.from([31,139,8]),"application/x-gzip"),new LRe,new kRe];B6t.exports=bee.default});var Eee=y(mh=>{"use strict";var Qzn=mh&&mh.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(mh,"__esModule",{value:!0});mh.Cookies=mh.defaultTimeout=mh.CSRF=void 0;mh.attachConnectionHandler=a9n;var H6t=uu(),e9n=Qzn(z6t()),pg;(function(e){e.RequestHeaderName="X-Csrf-Token",e.RequestHeaderValue="Fetch",e.ResponseHeaderName="x-csrf-token"})(pg||(mh.CSRF=pg={}));mh.defaultTimeout=60*1e3;var $Re=class{cookies={};setCookies(t){return t.headers?.["set-cookie"]&&t.headers["set-cookie"].forEach(r=>this.addCookie(r)),this}addCookie(t){let r=t.split(";"),[n,...i]=r[0]?.split("=")||[],a=i?.join("=");return n&&t.indexOf("Max-Age=0")>=0?delete this.cookies[n]:n&&a&&(this.cookies[n]=a),this}toString(){let t=[];return Object.keys(this.cookies).forEach(r=>{t.push(`${r}=${this.cookies[r]}`)}),t.join("; ")}};mh.Cookies=$Re;function t9n(e){return e?.status===200&&G6t(e)&&typeof e.data=="string"&&!!e.data.match(/saml/i)}function r9n(e){if(e?.status===200&&(e.headers["sap-err-id"]==="ICFLOGONREQUIRED"||n9n(e))){let t=new Error;throw t.response={status:401},t.isAxiosError=!0,t.toJSON=()=>({status:401}),t}}function G6t(e){return i9n(e.headers["content-type"],e.data).startsWith("text/html")}function n9n(e){return G6t(e)&&typeof e.data=="string"&&!!e.data.match(/log[io]n/i)}function i9n(e,t){return e?e.toLowerCase():typeof t=="string"?(0,e9n.default)(Buffer.from(t))?.toLowerCase()??"":""}function a9n(e){let t=e.interceptors.request.use(n=>(n.headers=n.headers??new H6t.AxiosHeaders,n.headers[pg.RequestHeaderName]=pg.RequestHeaderValue,n)),r=e.interceptors.response.use(n=>t9n(n)&&e.defaults.params?.saml2!=="disabled"?(e.defaults.params=e.defaults.params??{},e.defaults.params.saml2="disabled",e.request(n.config)):(r9n(n),n.headers?.[pg.ResponseHeaderName]&&(e.defaults.headers.common[pg.RequestHeaderName]=n.headers[pg.ResponseHeaderName],e.interceptors.request.eject(t)),e.interceptors.response.eject(r),n),n=>{throw n.response&&(n.response.headers?.[pg.ResponseHeaderName]&&(e.defaults.headers.common[pg.RequestHeaderName]=n.response.headers[pg.ResponseHeaderName],e.interceptors.request.eject(t)),e.cookies.setCookies(n.response)),n});e.interceptors.request.use(n=>(n.headers=n.headers??new H6t.AxiosHeaders,n.headers.cookie=e.cookies.toString(),n)),e.interceptors.response.use(n=>(e.cookies.setCookies(n),n))}});var K6t=y(IN=>{"use strict";var o9n=IN&&IN.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(IN,"__esModule",{value:!0});IN.ABAPVirtualHostProvider=void 0;var s9n=w0(),c9n=o9n(uu()),MRe=class{apiURL;uiURL;systemURL;relatedUrls;logger=new s9n.ToolsLogger;constructor(t,r){this.systemURL=new URL(t),r&&(this.logger=r)}async getVirtualHosts(){if(!this.relatedUrls){this.logger.debug(`Requesting virtual hosts from: ${this.systemURL}`);let t=new URL("/sap/public/bc/icf/virtualhost",this.systemURL.origin),r=await c9n.default.get(t.href,{headers:{Accept:"application/json"}});if(r.status!==200)throw this.logger.debug(`Failed to fetch virtual hosts: from: ${t}. Error: ${r.statusText}`),new Error(`Failed to fetch virtual hosts: ${r.statusText}`);this.relatedUrls=r.data}return this.relatedUrls}async uiHostname(){return this.uiURL||(this.uiURL=new URL((await this.getVirtualHosts()).relatedUrls.UI)),this.uiURL.origin}async apiHostname(){return this.apiURL||(this.apiURL=new URL((await this.getVirtualHosts()).relatedUrls.API)),this.apiURL.origin}async logoffUrl(){return await this.uiHostname()+"/sap/public/bc/icf/logoff"}};IN.ABAPVirtualHostProvider=MRe});var xee=y(fg=>{"use strict";Object.defineProperty(fg,"__esModule",{value:!0});fg.UAATimeoutError=fg.TimeoutError=fg.ConnectionError=fg.BaseError=void 0;var uV=class extends Error{cause;constructor(t,r){super(t),this.cause=r,this.name=this.constructor.name}};fg.BaseError=uV;var FRe=class extends uV{};fg.ConnectionError=FRe;var _ee=class extends uV{};fg.TimeoutError=_ee;var jRe=class extends _ee{};fg.UAATimeoutError=jRe});var T1=y(o_=>{"use strict";Object.defineProperty(o_,"__esModule",{value:!0});o_.prettyPrintTimeInMs=void 0;o_.prettyPrintMessage=l9n;o_.prettyPrintError=J6t;o_.logError=f9n;o_.getErrorMessageFromString=Z6t;var Y6t=require("node:url"),u9n=uu();function W6t(e,t,r,n=!1){e?(e=e.toLowerCase(),e==="success"?r.info(t):(e==="warning"&&(e="warn"),r[e](t))):n?r.error(t):r.info(t)}function l9n({msg:e,log:t,host:r,isDest:n=!1}){try{let i=JSON.parse(e);t.info(i.message),X6t({host:r,path:i.longtext_url,log:t,isDest:n}),i.details&&i.details.forEach(a=>{W6t(a.severity,a.message,t)})}catch{t.debug(e)}}function X6t({host:e,path:t,log:r,isDest:n=!1}){if(e&&t){let i=new Y6t.URL(e).origin;r.info("Please copy/paste this URL in a browser for more details:"),n&&r.info("(Note: You will need to replace the host in the URL with the internal host, if your destination is configured using an On-Premise SAP Cloud Connector)"),r.info(new Y6t.URL(t,i).href)}}function J6t({error:e,log:t,host:r,isDest:n},i=!0){if(e&&(i&&t.error(e.message?.value||"An unknown error occurred."),(e.innererror?.errordetails||[]).forEach(a=>{a.message.startsWith("<![CDATA")||W6t(a.severity,a.message,t,!0),X6t({host:r,path:a.longtext_url,log:t,isDest:n})}),i&&e.innererror?.Error_Resolution))for(let a in e.innererror.Error_Resolution)t.error(`${a}: ${e.innererror.Error_Resolution[a]}`)}var p9n=e=>{let t=Math.trunc(e/60/1e3);return t>1?`${t} minutes`:t===1?"1 minute":`${e/1e3} seconds`};o_.prettyPrintTimeInMs=p9n;function f9n({error:e,host:t,log:r,isDest:n}){if(r.error(e.message),(0,u9n.isAxiosError)(e)&&e.response?.data){let i=Z6t(e.response?.data);i?J6t({error:i,log:r,host:t,isDest:n}):r.error(e.response.data.toString())}}function Z6t(e){let t;if(typeof e=="string")try{let r=JSON.parse(e);r.error&&(t=r.error)}catch{}return t}});var qRe=y(RN=>{"use strict";Object.defineProperty(RN,"__esModule",{value:!0});RN.redirectErrorHtml=RN.redirectSuccessHtml=void 0;var d9n=(e,t)=>{let r=`${t?t+": ":""}Authentication Successful`,n=e?'<a class="centerLink" href="'+e+'">(Click here to log off the current user)</a>':"";return Q6t({title:r,content:n})};RN.redirectSuccessHtml=d9n;var h9n=e=>{let t=`${e?e+": ":""}Authentication Successful`;return Q6t({title:t,content:"Login failed, please check the logs in the console"})};RN.redirectErrorHtml=h9n;function Q6t({title:e,content:t}){return`
|
|
1232
1232
|
<html>
|
|
1233
1233
|
|
|
1234
1234
|
<head>
|
|
@@ -1474,7 +1474,7 @@ cfg: { // Application Insights Configuration\r
|
|
|
1474
1474
|
${bui.sanitize(Object.assign(Object.assign({},this),{request:this.request,response:this.response}))}`}};VU.RestError=tR;tR.REQUEST_SEND_ERROR="REQUEST_SEND_ERROR";tR.PARSE_ERROR="PARSE_ERROR";function Eui(e){return e instanceof tR?!0:(0,gui.isError)(e)&&e.name==="RestError"}});var _je=y(rR=>{"use strict";Object.defineProperty(rR,"__esModule",{value:!0});rR.tracingPolicyName=void 0;rR.tracingPolicy=Aui;var _ui=Tnr(),xui=M_(),Tui=tje(),oie=gS(),UU=Rg(),Oui=aie(),Sui=Une();rR.tracingPolicyName="tracingPolicy";function Aui(e={}){let t=(0,Tui.getUserAgentValue)(e.userAgentPrefix),r=new Sui.Sanitizer({additionalAllowedQueryParameters:e.additionalAllowedQueryParameters}),n=Cui();return{name:rR.tracingPolicyName,async sendRequest(i,a){var o,s;if(!n||!(!((o=i.tracingOptions)===null||o===void 0)&&o.tracingContext))return a(i);let c=await t,u={"http.url":r.sanitizeUrl(i.url),"http.method":i.method,"http.user_agent":c,requestId:i.requestId};c&&(u["http.user_agent"]=c);let{span:l,tracingContext:p}=(s=wui(n,i,u))!==null&&s!==void 0?s:{};if(!l||!p)return a(i);try{let f=await n.withContext(p,a,i);return Dui(l,f),f}catch(f){throw Pui(l,f),f}}}}function Cui(){try{return(0,_ui.createTracingClient)({namespace:"",packageName:"@azure/core-rest-pipeline",packageVersion:xui.SDK_VERSION})}catch(e){oie.logger.warning(`Error when creating the TracingClient: ${(0,UU.getErrorMessage)(e)}`);return}}function wui(e,t,r){try{let{span:n,updatedOptions:i}=e.startSpan(`HTTP ${t.method}`,{tracingOptions:t.tracingOptions},{spanKind:"client",spanAttributes:r});if(!n.isRecording()){n.end();return}let a=e.createRequestHeaders(i.tracingOptions.tracingContext);for(let[o,s]of Object.entries(a))t.headers.set(o,s);return{span:n,tracingContext:i.tracingOptions.tracingContext}}catch(n){oie.logger.warning(`Skipping creating a tracing span due to an error: ${(0,UU.getErrorMessage)(n)}`);return}}function Pui(e,t){try{e.setStatus({status:"error",error:(0,UU.isError)(t)?t:void 0}),(0,Oui.isRestError)(t)&&t.statusCode&&e.setAttribute("http.status_code",t.statusCode),e.end()}catch(r){oie.logger.warning(`Skipping tracing span processing due to an error: ${(0,UU.getErrorMessage)(r)}`)}}function Dui(e,t){try{e.setAttribute("http.status_code",t.status);let r=t.headers.get("x-ms-request-id");r&&e.setAttribute("serviceRequestId",r),e.setStatus({status:"success"}),e.end()}catch(r){oie.logger.warning(`Skipping tracing span processing due to an error: ${(0,UU.getErrorMessage)(r)}`)}}});var Cnr=y(xje=>{"use strict";Object.defineProperty(xje,"__esModule",{value:!0});xje.createPipelineFromOptions=Uui;var Nui=JFe(),Iui=xFe(),Rui=ZFe(),Lui=rje(),Snr=oje(),kui=sje(),$ui=lje(),Mui=dje(),Anr=Rg(),Fui=hje(),jui=mje(),qui=gje(),Vui=_je();function Uui(e){var t;let r=(0,Iui.createEmptyPipeline)();return Anr.isNodeLike&&(e.tlsOptions&&r.addPolicy((0,qui.tlsPolicy)(e.tlsOptions)),r.addPolicy((0,Fui.proxyPolicy)(e.proxyOptions)),r.addPolicy((0,kui.decompressResponsePolicy)())),r.addPolicy((0,Mui.formDataPolicy)(),{beforePolicies:[Snr.multipartPolicyName]}),r.addPolicy((0,Lui.userAgentPolicy)(e.userAgentOptions)),r.addPolicy((0,jui.setClientRequestIdPolicy)((t=e.telemetryOptions)===null||t===void 0?void 0:t.clientRequestIdHeaderName)),r.addPolicy((0,Snr.multipartPolicy)(),{afterPhase:"Deserialize"}),r.addPolicy((0,$ui.defaultRetryPolicy)(e.retryOptions),{phase:"Retry"}),r.addPolicy((0,Vui.tracingPolicy)(Object.assign(Object.assign({},e.userAgentOptions),e.loggingOptions)),{afterPhase:"Retry"}),Anr.isNodeLike&&r.addPolicy((0,Rui.redirectPolicy)(e.redirectOptions),{afterPhase:"Retry"}),r.addPolicy((0,Nui.logPolicy)(e.loggingOptions),{afterPhase:"Sign"}),r}});var Rnr=y(cie=>{"use strict";Object.defineProperty(cie,"__esModule",{value:!0});cie.getBodyLength=Inr;cie.createNodeHttpClient=Wui;var Aje=(hS(),nn(dS)),Tje=Aje.__importStar(require("node:http")),Oje=Aje.__importStar(require("node:https")),wnr=Aje.__importStar(require("node:zlib")),Bui=require("node:stream"),Pnr=$U(),zui=qU(),HU=aie(),BU=gS(),Hui={};function zU(e){return e&&typeof e.pipe=="function"}function Dnr(e){return new Promise(t=>{e.on("close",t),e.on("end",t),e.on("error",t)})}function Nnr(e){return e&&typeof e.byteLength=="number"}var sie=class extends Bui.Transform{_transform(t,r,n){this.push(t),this.loadedBytes+=t.length;try{this.progressCallback({loadedBytes:this.loadedBytes}),n()}catch(i){n(i)}}constructor(t){super(),this.loadedBytes=0,this.progressCallback=t}},Sje=class{constructor(){this.cachedHttpsAgents=new WeakMap}async sendRequest(t){var r,n,i;let a=new AbortController,o;if(t.abortSignal){if(t.abortSignal.aborted)throw new Pnr.AbortError("The operation was aborted.");o=p=>{p.type==="abort"&&a.abort()},t.abortSignal.addEventListener("abort",o)}t.timeout>0&&setTimeout(()=>{a.abort()},t.timeout);let s=t.headers.get("Accept-Encoding"),c=s?.includes("gzip")||s?.includes("deflate"),u=typeof t.body=="function"?t.body():t.body;if(u&&!t.headers.has("Content-Length")){let p=Inr(u);p!==null&&t.headers.set("Content-Length",p)}let l;try{if(u&&t.onUploadProgress){let v=t.onUploadProgress,_=new sie(v);_.on("error",T=>{BU.logger.error("Error in upload progress",T)}),zU(u)?u.pipe(_):_.end(u),u=_}let p=await this.makeRequest(t,a,u),f=Gui(p),h={status:(r=p.statusCode)!==null&&r!==void 0?r:0,headers:f,request:t};if(t.method==="HEAD")return p.resume(),h;l=c?Kui(p,f):p;let m=t.onDownloadProgress;if(m){let v=new sie(m);v.on("error",_=>{BU.logger.error("Error in download progress",_)}),l.pipe(v),l=v}return!((n=t.streamResponseStatusCodes)===null||n===void 0)&&n.has(Number.POSITIVE_INFINITY)||!((i=t.streamResponseStatusCodes)===null||i===void 0)&&i.has(h.status)?h.readableStreamBody=l:h.bodyAsText=await Yui(l),h}finally{if(t.abortSignal&&o){let p=Promise.resolve();zU(u)&&(p=Dnr(u));let f=Promise.resolve();zU(l)&&(f=Dnr(l)),Promise.all([p,f]).then(()=>{var d;o&&((d=t.abortSignal)===null||d===void 0||d.removeEventListener("abort",o))}).catch(d=>{BU.logger.warning("Error when cleaning up abortListener on httpRequest",d)})}}}makeRequest(t,r,n){var i;let a=new URL(t.url),o=a.protocol!=="https:";if(o&&!t.allowInsecureConnection)throw new Error(`Cannot connect to ${t.url} while allowInsecureConnection is false.`);let c={agent:(i=t.agent)!==null&&i!==void 0?i:this.getOrCreateAgent(t,o),hostname:a.hostname,path:`${a.pathname}${a.search}`,port:a.port,method:t.method,headers:t.headers.toJSON({preserveCase:!0})};return new Promise((u,l)=>{let p=o?Tje.request(c,u):Oje.request(c,u);p.once("error",f=>{var d;l(new HU.RestError(f.message,{code:(d=f.code)!==null&&d!==void 0?d:HU.RestError.REQUEST_SEND_ERROR,request:t}))}),r.signal.addEventListener("abort",()=>{let f=new Pnr.AbortError("The operation was aborted.");p.destroy(f),l(f)}),n&&zU(n)?n.pipe(p):n?typeof n=="string"||Buffer.isBuffer(n)?p.end(n):Nnr(n)?p.end(ArrayBuffer.isView(n)?Buffer.from(n.buffer):Buffer.from(n)):(BU.logger.error("Unrecognized body type",n),l(new HU.RestError("Unrecognized body type"))):p.end()})}getOrCreateAgent(t,r){var n;let i=t.disableKeepAlive;if(r)return i?Tje.globalAgent:(this.cachedHttpAgent||(this.cachedHttpAgent=new Tje.Agent({keepAlive:!0})),this.cachedHttpAgent);{if(i&&!t.tlsSettings)return Oje.globalAgent;let a=(n=t.tlsSettings)!==null&&n!==void 0?n:Hui,o=this.cachedHttpsAgents.get(a);return o&&o.options.keepAlive===!i||(BU.logger.info("No cached TLS Agent exist, creating a new Agent"),o=new Oje.Agent(Object.assign({keepAlive:!i},a)),this.cachedHttpsAgents.set(a,o)),o}}};function Gui(e){let t=(0,zui.createHttpHeaders)();for(let r of Object.keys(e.headers)){let n=e.headers[r];Array.isArray(n)?n.length>0&&t.set(r,n[0]):n&&t.set(r,n)}return t}function Kui(e,t){let r=t.get("Content-Encoding");if(r==="gzip"){let n=wnr.createGunzip();return e.pipe(n),n}else if(r==="deflate"){let n=wnr.createInflate();return e.pipe(n),n}return e}function Yui(e){return new Promise((t,r)=>{let n=[];e.on("data",i=>{Buffer.isBuffer(i)?n.push(i):n.push(Buffer.from(i))}),e.on("end",()=>{t(Buffer.concat(n).toString("utf8"))}),e.on("error",i=>{i&&i?.name==="AbortError"?r(i):r(new HU.RestError(`Error reading response as text: ${i.message}`,{code:HU.RestError.PARSE_ERROR}))})})}function Inr(e){return e?Buffer.isBuffer(e)?e.length:zU(e)?null:Nnr(e)?e.byteLength:typeof e=="string"?Buffer.from(e).length:null:0}function Wui(){return new Sje}});var Lnr=y(Cje=>{"use strict";Object.defineProperty(Cje,"__esModule",{value:!0});Cje.createDefaultHttpClient=Jui;var Xui=Rnr();function Jui(){return(0,Xui.createNodeHttpClient)()}});var knr=y(Pje=>{"use strict";Object.defineProperty(Pje,"__esModule",{value:!0});Pje.createPipelineRequest=eli;var Zui=qU(),Qui=Rg(),wje=class{constructor(t){var r,n,i,a,o,s,c;this.url=t.url,this.body=t.body,this.headers=(r=t.headers)!==null&&r!==void 0?r:(0,Zui.createHttpHeaders)(),this.method=(n=t.method)!==null&&n!==void 0?n:"GET",this.timeout=(i=t.timeout)!==null&&i!==void 0?i:0,this.multipartBody=t.multipartBody,this.formData=t.formData,this.disableKeepAlive=(a=t.disableKeepAlive)!==null&&a!==void 0?a:!1,this.proxySettings=t.proxySettings,this.streamResponseStatusCodes=t.streamResponseStatusCodes,this.withCredentials=(o=t.withCredentials)!==null&&o!==void 0?o:!1,this.abortSignal=t.abortSignal,this.tracingOptions=t.tracingOptions,this.onUploadProgress=t.onUploadProgress,this.onDownloadProgress=t.onDownloadProgress,this.requestId=t.requestId||(0,Qui.randomUUID)(),this.allowInsecureConnection=(s=t.allowInsecureConnection)!==null&&s!==void 0?s:!1,this.enableBrowserStreams=(c=t.enableBrowserStreams)!==null&&c!==void 0?c:!1}};function eli(e){return new wje(e)}});var $nr=y(GU=>{"use strict";Object.defineProperty(GU,"__esModule",{value:!0});GU.exponentialRetryPolicyName=void 0;GU.exponentialRetryPolicy=ili;var tli=Jne(),rli=YI(),nli=M_();GU.exponentialRetryPolicyName="exponentialRetryPolicy";function ili(e={}){var t;return(0,rli.retryPolicy)([(0,tli.exponentialRetryStrategy)(Object.assign(Object.assign({},e),{ignoreSystemErrors:!0}))],{maxRetries:(t=e.maxRetries)!==null&&t!==void 0?t:nli.DEFAULT_RETRY_POLICY_COUNT})}});var Mnr=y(nR=>{"use strict";Object.defineProperty(nR,"__esModule",{value:!0});nR.systemErrorRetryPolicyName=void 0;nR.systemErrorRetryPolicy=cli;var ali=Jne(),oli=YI(),sli=M_();nR.systemErrorRetryPolicyName="systemErrorRetryPolicy";function cli(e={}){var t;return{name:nR.systemErrorRetryPolicyName,sendRequest:(0,oli.retryPolicy)([(0,ali.exponentialRetryStrategy)(Object.assign(Object.assign({},e),{ignoreHttpStatusCodes:!0}))],{maxRetries:(t=e.maxRetries)!==null&&t!==void 0?t:sli.DEFAULT_RETRY_POLICY_COUNT}).sendRequest}}});var Fnr=y(iR=>{"use strict";Object.defineProperty(iR,"__esModule",{value:!0});iR.throttlingRetryPolicyName=void 0;iR.throttlingRetryPolicy=fli;var uli=Xne(),lli=YI(),pli=M_();iR.throttlingRetryPolicyName="throttlingRetryPolicy";function fli(e={}){var t;return{name:iR.throttlingRetryPolicyName,sendRequest:(0,lli.retryPolicy)([(0,uli.throttlingRetryStrategy)()],{maxRetries:(t=e.maxRetries)!==null&&t!==void 0?t:pli.DEFAULT_RETRY_POLICY_COUNT}).sendRequest}}});var Dje=y(aR=>{"use strict";Object.defineProperty(aR,"__esModule",{value:!0});aR.DEFAULT_CYCLER_OPTIONS=void 0;aR.createTokenCycler=mli;var dli=Yne();aR.DEFAULT_CYCLER_OPTIONS={forcedRefreshWindowInMs:1e3,retryIntervalInMs:3e3,refreshWindowInMs:1e3*60*2};async function hli(e,t,r){async function n(){if(Date.now()<r)try{return await e()}catch{return null}else{let a=await e();if(a===null)throw new Error("Failed to refresh access token.");return a}}let i=await n();for(;i===null;)await(0,dli.delay)(t),i=await n();return i}function mli(e,t){let r=null,n=null,i,a=Object.assign(Object.assign({},aR.DEFAULT_CYCLER_OPTIONS),t),o={get isRefreshing(){return r!==null},get shouldRefresh(){var c;return!o.isRefreshing&&((c=n?.expiresOnTimestamp)!==null&&c!==void 0?c:0)-a.refreshWindowInMs<Date.now()},get mustRefresh(){return n===null||n.expiresOnTimestamp-a.forcedRefreshWindowInMs<Date.now()}};function s(c,u){var l;return o.isRefreshing||(r=hli(()=>e.getToken(c,u),a.retryIntervalInMs,(l=n?.expiresOnTimestamp)!==null&&l!==void 0?l:Date.now()).then(f=>(r=null,n=f,i=u.tenantId,n)).catch(f=>{throw r=null,n=null,i=void 0,f})),r}return async(c,u)=>{let l=!!u.claims,p=i!==u.tenantId;return l&&(n=null),p||l||o.mustRefresh?s(c,u):(o.shouldRefresh&&s(c,u),n)}}});var jnr=y(oR=>{"use strict";Object.defineProperty(oR,"__esModule",{value:!0});oR.bearerTokenAuthenticationPolicyName=void 0;oR.bearerTokenAuthenticationPolicy=Eli;var gli=Dje(),yli=gS();oR.bearerTokenAuthenticationPolicyName="bearerTokenAuthenticationPolicy";async function vli(e){let{scopes:t,getAccessToken:r,request:n}=e,i={abortSignal:n.abortSignal,tracingOptions:n.tracingOptions},a=await r(t,i);a&&e.request.headers.set("Authorization",`Bearer ${a.token}`)}function bli(e){let t=e.headers.get("WWW-Authenticate");if(e.status===401&&t)return t}function Eli(e){var t;let{credential:r,scopes:n,challengeCallbacks:i}=e,a=e.logger||yli.logger,o=Object.assign({authorizeRequest:(t=i?.authorizeRequest)!==null&&t!==void 0?t:vli,authorizeRequestOnChallenge:i?.authorizeRequestOnChallenge},i),s=r?(0,gli.createTokenCycler)(r):()=>Promise.resolve(null);return{name:oR.bearerTokenAuthenticationPolicyName,async sendRequest(c,u){if(!c.url.toLowerCase().startsWith("https://"))throw new Error("Bearer token authentication is not permitted for non-TLS protected (non-https) URLs.");await o.authorizeRequest({scopes:Array.isArray(n)?n:[n],request:c,getAccessToken:s,logger:a});let l,p;try{l=await u(c)}catch(f){p=f,l=f.response}if(o.authorizeRequestOnChallenge&&l?.status===401&&bli(l)&&await o.authorizeRequestOnChallenge({scopes:Array.isArray(n)?n:[n],request:c,response:l,getAccessToken:s,logger:a}))return u(c);if(p)throw p;return l}}}});var qnr=y(sR=>{"use strict";Object.defineProperty(sR,"__esModule",{value:!0});sR.ndJsonPolicyName=void 0;sR.ndJsonPolicy=_li;sR.ndJsonPolicyName="ndJsonPolicy";function _li(){return{name:sR.ndJsonPolicyName,async sendRequest(e,t){if(typeof e.body=="string"&&e.body.startsWith("[")){let r=JSON.parse(e.body);Array.isArray(r)&&(e.body=r.map(n=>JSON.stringify(n)+`
|
|
1475
1475
|
`).join(""))}return t(e)}}}});var Unr=y(bS=>{"use strict";Object.defineProperty(bS,"__esModule",{value:!0});bS.auxiliaryAuthenticationHeaderPolicyName=void 0;bS.auxiliaryAuthenticationHeaderPolicy=Sli;var xli=Dje(),Tli=gS();bS.auxiliaryAuthenticationHeaderPolicyName="auxiliaryAuthenticationHeaderPolicy";var Vnr="x-ms-authorization-auxiliary";async function Oli(e){var t,r;let{scopes:n,getAccessToken:i,request:a}=e,o={abortSignal:a.abortSignal,tracingOptions:a.tracingOptions};return(r=(t=await i(n,o))===null||t===void 0?void 0:t.token)!==null&&r!==void 0?r:""}function Sli(e){let{credentials:t,scopes:r}=e,n=e.logger||Tli.logger,i=new WeakMap;return{name:bS.auxiliaryAuthenticationHeaderPolicyName,async sendRequest(a,o){if(!a.url.toLowerCase().startsWith("https://"))throw new Error("Bearer token authentication for auxiliary header is not permitted for non-TLS protected (non-https) URLs.");if(!t||t.length===0)return n.info(`${bS.auxiliaryAuthenticationHeaderPolicyName} header will not be set due to empty credentials.`),o(a);let s=[];for(let u of t){let l=i.get(u);l||(l=(0,xli.createTokenCycler)(u),i.set(u,l)),s.push(Oli({scopes:Array.isArray(r)?r:[r],request:a,getAccessToken:l,logger:n}))}let c=(await Promise.all(s)).filter(u=>!!u);return c.length===0?(n.warning(`None of the auxiliary tokens are valid. ${Vnr} header will not be set.`),o(a)):(a.headers.set(Vnr,c.map(u=>`Bearer ${u}`).join(", ")),o(a))}}}});var oir=y(Re=>{"use strict";Object.defineProperty(Re,"__esModule",{value:!0});Re.createFileFromStream=Re.createFile=Re.auxiliaryAuthenticationHeaderPolicyName=Re.auxiliaryAuthenticationHeaderPolicy=Re.ndJsonPolicyName=Re.ndJsonPolicy=Re.bearerTokenAuthenticationPolicyName=Re.bearerTokenAuthenticationPolicy=Re.formDataPolicyName=Re.formDataPolicy=Re.tlsPolicyName=Re.tlsPolicy=Re.userAgentPolicyName=Re.userAgentPolicy=Re.defaultRetryPolicy=Re.tracingPolicyName=Re.tracingPolicy=Re.retryPolicy=Re.throttlingRetryPolicyName=Re.throttlingRetryPolicy=Re.systemErrorRetryPolicyName=Re.systemErrorRetryPolicy=Re.redirectPolicyName=Re.redirectPolicy=Re.getDefaultProxySettings=Re.proxyPolicyName=Re.proxyPolicy=Re.multipartPolicyName=Re.multipartPolicy=Re.logPolicyName=Re.logPolicy=Re.setClientRequestIdPolicyName=Re.setClientRequestIdPolicy=Re.exponentialRetryPolicyName=Re.exponentialRetryPolicy=Re.decompressResponsePolicyName=Re.decompressResponsePolicy=Re.isRestError=Re.RestError=Re.createPipelineRequest=Re.createHttpHeaders=Re.createDefaultHttpClient=Re.createPipelineFromOptions=Re.createEmptyPipeline=void 0;var Ali=xFe();Object.defineProperty(Re,"createEmptyPipeline",{enumerable:!0,get:function(){return Ali.createEmptyPipeline}});var Cli=Cnr();Object.defineProperty(Re,"createPipelineFromOptions",{enumerable:!0,get:function(){return Cli.createPipelineFromOptions}});var wli=Lnr();Object.defineProperty(Re,"createDefaultHttpClient",{enumerable:!0,get:function(){return wli.createDefaultHttpClient}});var Pli=qU();Object.defineProperty(Re,"createHttpHeaders",{enumerable:!0,get:function(){return Pli.createHttpHeaders}});var Dli=knr();Object.defineProperty(Re,"createPipelineRequest",{enumerable:!0,get:function(){return Dli.createPipelineRequest}});var Bnr=aie();Object.defineProperty(Re,"RestError",{enumerable:!0,get:function(){return Bnr.RestError}});Object.defineProperty(Re,"isRestError",{enumerable:!0,get:function(){return Bnr.isRestError}});var znr=sje();Object.defineProperty(Re,"decompressResponsePolicy",{enumerable:!0,get:function(){return znr.decompressResponsePolicy}});Object.defineProperty(Re,"decompressResponsePolicyName",{enumerable:!0,get:function(){return znr.decompressResponsePolicyName}});var Hnr=$nr();Object.defineProperty(Re,"exponentialRetryPolicy",{enumerable:!0,get:function(){return Hnr.exponentialRetryPolicy}});Object.defineProperty(Re,"exponentialRetryPolicyName",{enumerable:!0,get:function(){return Hnr.exponentialRetryPolicyName}});var Gnr=mje();Object.defineProperty(Re,"setClientRequestIdPolicy",{enumerable:!0,get:function(){return Gnr.setClientRequestIdPolicy}});Object.defineProperty(Re,"setClientRequestIdPolicyName",{enumerable:!0,get:function(){return Gnr.setClientRequestIdPolicyName}});var Knr=JFe();Object.defineProperty(Re,"logPolicy",{enumerable:!0,get:function(){return Knr.logPolicy}});Object.defineProperty(Re,"logPolicyName",{enumerable:!0,get:function(){return Knr.logPolicyName}});var Ynr=oje();Object.defineProperty(Re,"multipartPolicy",{enumerable:!0,get:function(){return Ynr.multipartPolicy}});Object.defineProperty(Re,"multipartPolicyName",{enumerable:!0,get:function(){return Ynr.multipartPolicyName}});var Nje=hje();Object.defineProperty(Re,"proxyPolicy",{enumerable:!0,get:function(){return Nje.proxyPolicy}});Object.defineProperty(Re,"proxyPolicyName",{enumerable:!0,get:function(){return Nje.proxyPolicyName}});Object.defineProperty(Re,"getDefaultProxySettings",{enumerable:!0,get:function(){return Nje.getDefaultProxySettings}});var Wnr=ZFe();Object.defineProperty(Re,"redirectPolicy",{enumerable:!0,get:function(){return Wnr.redirectPolicy}});Object.defineProperty(Re,"redirectPolicyName",{enumerable:!0,get:function(){return Wnr.redirectPolicyName}});var Xnr=Mnr();Object.defineProperty(Re,"systemErrorRetryPolicy",{enumerable:!0,get:function(){return Xnr.systemErrorRetryPolicy}});Object.defineProperty(Re,"systemErrorRetryPolicyName",{enumerable:!0,get:function(){return Xnr.systemErrorRetryPolicyName}});var Jnr=Fnr();Object.defineProperty(Re,"throttlingRetryPolicy",{enumerable:!0,get:function(){return Jnr.throttlingRetryPolicy}});Object.defineProperty(Re,"throttlingRetryPolicyName",{enumerable:!0,get:function(){return Jnr.throttlingRetryPolicyName}});var Nli=YI();Object.defineProperty(Re,"retryPolicy",{enumerable:!0,get:function(){return Nli.retryPolicy}});var Znr=_je();Object.defineProperty(Re,"tracingPolicy",{enumerable:!0,get:function(){return Znr.tracingPolicy}});Object.defineProperty(Re,"tracingPolicyName",{enumerable:!0,get:function(){return Znr.tracingPolicyName}});var Ili=lje();Object.defineProperty(Re,"defaultRetryPolicy",{enumerable:!0,get:function(){return Ili.defaultRetryPolicy}});var Qnr=rje();Object.defineProperty(Re,"userAgentPolicy",{enumerable:!0,get:function(){return Qnr.userAgentPolicy}});Object.defineProperty(Re,"userAgentPolicyName",{enumerable:!0,get:function(){return Qnr.userAgentPolicyName}});var eir=gje();Object.defineProperty(Re,"tlsPolicy",{enumerable:!0,get:function(){return eir.tlsPolicy}});Object.defineProperty(Re,"tlsPolicyName",{enumerable:!0,get:function(){return eir.tlsPolicyName}});var tir=dje();Object.defineProperty(Re,"formDataPolicy",{enumerable:!0,get:function(){return tir.formDataPolicy}});Object.defineProperty(Re,"formDataPolicyName",{enumerable:!0,get:function(){return tir.formDataPolicyName}});var rir=jnr();Object.defineProperty(Re,"bearerTokenAuthenticationPolicy",{enumerable:!0,get:function(){return rir.bearerTokenAuthenticationPolicy}});Object.defineProperty(Re,"bearerTokenAuthenticationPolicyName",{enumerable:!0,get:function(){return rir.bearerTokenAuthenticationPolicyName}});var nir=qnr();Object.defineProperty(Re,"ndJsonPolicy",{enumerable:!0,get:function(){return nir.ndJsonPolicy}});Object.defineProperty(Re,"ndJsonPolicyName",{enumerable:!0,get:function(){return nir.ndJsonPolicyName}});var iir=Unr();Object.defineProperty(Re,"auxiliaryAuthenticationHeaderPolicy",{enumerable:!0,get:function(){return iir.auxiliaryAuthenticationHeaderPolicy}});Object.defineProperty(Re,"auxiliaryAuthenticationHeaderPolicyName",{enumerable:!0,get:function(){return iir.auxiliaryAuthenticationHeaderPolicyName}});var air=nje();Object.defineProperty(Re,"createFile",{enumerable:!0,get:function(){return air.createFile}});Object.defineProperty(Re,"createFileFromStream",{enumerable:!0,get:function(){return air.createFileFromStream}})});var cir=y((YU,sir)=>{"use strict";var Rli=YU&&YU.__awaiter||function(e,t,r,n){function i(a){return a instanceof r?a:new r(function(o){o(a)})}return new(r||(r=Promise))(function(a,o){function s(l){try{u(n.next(l))}catch(p){o(p)}}function c(l){try{u(n.throw(l))}catch(p){o(p)}}function u(l){l.done?a(l.value):i(l.value).then(s,c)}u((n=n.apply(e,t||[])).next())})},Lli=YU&&YU.__generator||function(e,t){var r={label:0,sent:function(){if(a[0]&1)throw a[1];return a[1]},trys:[],ops:[]},n,i,a,o;return o={next:s(0),throw:s(1),return:s(2)},typeof Symbol=="function"&&(o[Symbol.iterator]=function(){return this}),o;function s(u){return function(l){return c([u,l])}}function c(u){if(n)throw new TypeError("Generator is already executing.");for(;o&&(o=0,u[0]&&(r=0)),r;)try{if(n=1,i&&(a=u[0]&2?i.return:u[0]?i.throw||((a=i.return)&&a.call(i),0):i.next)&&!(a=a.call(i,u[1])).done)return a;switch(i=0,a&&(u=[u[0]&2,a.value]),u[0]){case 0:case 1:a=u;break;case 4:return r.label++,{value:u[1],done:!1};case 5:r.label++,i=u[1],u=[0];continue;case 7:u=r.ops.pop(),r.trys.pop();continue;default:if(a=r.trys,!(a=a.length>0&&a[a.length-1])&&(u[0]===6||u[0]===2)){r=0;continue}if(u[0]===3&&(!a||u[1]>a[0]&&u[1]<a[3])){r.label=u[1];break}if(u[0]===6&&r.label<a[1]){r.label=a[1],a=u;break}if(a&&r.label<a[2]){r.label=a[2],r.ops.push(u);break}a[2]&&r.ops.pop(),r.trys.pop();continue}u=t.call(e,r)}catch(l){u=[6,l],i=0}finally{n=a=0}if(u[0]&5)throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}},kli=li(),$li="https://monitor.azure.com//.default",KU;try{KU=oir()}catch{kli.warn("Cannot load @azure/core-auth package. This package is required for AAD token authentication. It's likely that your node.js version is not supported by the JS Azure SDK.")}function Mli(e){return null}var Fli=function(){function e(t,r){if(KU){var n=r?[r]:[$li];this._azureTokenPolicy=KU.bearerTokenAuthenticationPolicy({credential:t,scopes:n})}}return e.prototype.addAuthorizationHeader=function(t){return Rli(this,void 0,void 0,function(){var r,n;return Lli(this,function(i){switch(i.label){case 0:return KU?(r="authorization",n=KU.createPipelineRequest({url:"https://"}),[4,this._azureTokenPolicy.sendRequest(n,Mli)]):[3,2];case 1:i.sent(),t.headers[r]=n.headers.get(r),i.label=2;case 2:return[2]}})})},e}();sir.exports=Fli});var lir=y((Tha,uir)=>{"use strict";var jli=li(),qli=qs(),Vli=function(){function e(t,r,n,i){this._buffer=[],this._lastSend=0,this._isDisabled=t,this._getBatchSize=r,this._getBatchIntervalMs=n,this._sender=i}return e.prototype.setUseDiskRetryCaching=function(t,r,n){this._sender.setDiskRetryMode(t,r,n)},e.prototype.send=function(t){var r=this;if(!this._isDisabled()){if(!t){jli.warn("Cannot send null/undefined telemetry");return}if(this._buffer.push(t),this._buffer.length>=this._getBatchSize()){this.triggerSend(!1);return}!this._timeoutHandle&&this._buffer.length>0&&(this._timeoutHandle=setTimeout(function(){r._timeoutHandle=null,r.triggerSend(!1)},this._getBatchIntervalMs()))}},e.prototype.triggerSend=function(t,r){var n=this._buffer.length<1;n||(t||qli.isNodeExit?(this._sender.saveOnCrash(this._buffer),typeof r=="function"&&r("data saved on crash")):this._sender.send(this._buffer,r)),this._lastSend=+new Date,this._buffer=[],clearTimeout(this._timeoutHandle),this._timeoutHandle=null,n&&typeof r=="function"&&r("no data to send")},e}();uir.exports=Vli});var pir=y(Ije=>{"use strict";Object.defineProperty(Ije,"__esModule",{value:!0});Ije.azureRoleEnvironmentTelemetryProcessor=Uli;function Uli(e,t){}});var hir=y(uie=>{"use strict";Object.defineProperty(uie,"__esModule",{value:!0});uie.samplingTelemetryProcessor=Bli;uie.getSamplingHashCode=dir;var fir=Mc();function Bli(e,t){var r=e.sampleRate,n=!1;return r==null||r>=100||e.data&&fir.TelemetryType.Metric===fir.baseTypeToTelemetryType(e.data.baseType)?!0:(t.correlationContext&&t.correlationContext.operation?n=dir(t.correlationContext.operation.id)<r:n=Math.random()*100<r,n)}function dir(e){var t=-2147483648,r=2147483647,n=5381;if(!e)return 0;for(;e.length<8;)e=e+e;for(var i=0;i<e.length;i++)n=((n<<5)+n|0)+e.charCodeAt(i)|0;return n=n<=t?r:Math.abs(n),n/r*100}});var mir=y(vb=>{"use strict";var zli=vb&&vb.__createBinding||(Object.create?function(e,t,r,n){n===void 0&&(n=r);var i=Object.getOwnPropertyDescriptor(t,r);(!i||("get"in i?!t.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,i)}:function(e,t,r,n){n===void 0&&(n=r),e[n]=t[r]}),Hli=vb&&vb.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e.default=t}),Gli=vb&&vb.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var r in e)r!=="default"&&Object.prototype.hasOwnProperty.call(e,r)&&zli(t,e,r);return Hli(t,e),t};Object.defineProperty(vb,"__esModule",{value:!0});vb.performanceMetricsTelemetryProcessor=Kli;var Rje=dne(),Lje=Gli(Mc());function Kli(e,t){switch(t&&t.addDocument(e),e.data.baseType){case Lje.TelemetryTypeString.Exception:Rje.countException();break;case Lje.TelemetryTypeString.Request:var r=e.data.baseData;Rje.countRequest(r.duration,r.success);break;case Lje.TelemetryTypeString.Dependency:var n=e.data.baseData;Rje.countDependency(n.duration,n.success);break}return!0}});var gir=y(Oh=>{"use strict";var Lg=Oh&&Oh.__assign||function(){return Lg=Object.assign||function(e){for(var t,r=1,n=arguments.length;r<n;r++){t=arguments[r];for(var i in t)Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i])}return e},Lg.apply(this,arguments)},Yli=Oh&&Oh.__createBinding||(Object.create?function(e,t,r,n){n===void 0&&(n=r);var i=Object.getOwnPropertyDescriptor(t,r);(!i||("get"in i?!t.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,i)}:function(e,t,r,n){n===void 0&&(n=r),e[n]=t[r]}),Wli=Oh&&Oh.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e.default=t}),Xli=Oh&&Oh.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var r in e)r!=="default"&&Object.prototype.hasOwnProperty.call(e,r)&&Yli(t,e,r);return Wli(t,e),t};Object.defineProperty(Oh,"__esModule",{value:!0});Oh.preAggregatedMetricsTelemetryProcessor=Zli;var Jli=Mc(),WU=ZMe(),lie=Xli(Mc());function Zli(e,t){if(WU.isEnabled())switch(e.data.baseType){case lie.TelemetryTypeString.Exception:var r=e.data.baseData;r.properties=Lg(Lg({},r.properties),{"_MS.ProcessedByMetricExtractors":"(Name:'Exceptions', Ver:'1.1')"});var n={cloudRoleInstance:e.tags[t.keys.cloudRoleInstance],cloudRoleName:e.tags[t.keys.cloudRole]};WU.countException(n);break;case lie.TelemetryTypeString.Trace:var i=e.data.baseData;i.properties=Lg(Lg({},i.properties),{"_MS.ProcessedByMetricExtractors":"(Name:'Traces', Ver:'1.1')"});var a={cloudRoleInstance:e.tags[t.keys.cloudRoleInstance],cloudRoleName:e.tags[t.keys.cloudRole],traceSeverityLevel:Jli.SeverityLevel[i.severity]};WU.countTrace(a);break;case lie.TelemetryTypeString.Request:var o=e.data.baseData;o.properties=Lg(Lg({},o.properties),{"_MS.ProcessedByMetricExtractors":"(Name:'Requests', Ver:'1.1')"});var s={cloudRoleInstance:e.tags[t.keys.cloudRoleInstance],cloudRoleName:e.tags[t.keys.cloudRole],operationSynthetic:e.tags[t.keys.operationSyntheticSource],requestSuccess:o.success,requestResultCode:o.responseCode};WU.countRequest(o.duration,s);break;case lie.TelemetryTypeString.Dependency:var c=e.data.baseData;c.properties=Lg(Lg({},c.properties),{"_MS.ProcessedByMetricExtractors":"(Name:'Dependencies', Ver:'1.1')"});var u={cloudRoleInstance:e.tags[t.keys.cloudRoleInstance],cloudRoleName:e.tags[t.keys.cloudRole],operationSynthetic:e.tags[t.keys.operationSyntheticSource],dependencySuccess:c.success,dependencyType:c.type,dependencyTarget:c.target,dependencyResultCode:c.resultCode};WU.countDependency(c.duration,u);break}return!0}});var yir=y(kg=>{"use strict";var Qli=kg&&kg.__createBinding||(Object.create?function(e,t,r,n){n===void 0&&(n=r);var i=Object.getOwnPropertyDescriptor(t,r);(!i||("get"in i?!t.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,i)}:function(e,t,r,n){n===void 0&&(n=r),e[n]=t[r]}),pie=kg&&kg.__exportStar||function(e,t){for(var r in e)r!=="default"&&!Object.prototype.hasOwnProperty.call(t,r)&&Qli(t,e,r)};Object.defineProperty(kg,"__esModule",{value:!0});pie(pir(),kg);pie(hir(),kg);pie(mir(),kg);pie(gir(),kg)});var kje=y((Pha,Eir)=>{"use strict";var Kt=Mc(),Pl=qs(),vir=w_(),epi=li(),tpi=function(){function e(){}return e.createEnvelope=function(t,r,n,i,a){var o=null;switch(r){case Kt.TelemetryType.Trace:o=e.createTraceData(t);break;case Kt.TelemetryType.Dependency:o=e.createDependencyData(t);break;case Kt.TelemetryType.Event:o=e.createEventData(t);break;case Kt.TelemetryType.Exception:o=e.createExceptionData(t);break;case Kt.TelemetryType.Request:o=e.createRequestData(t);break;case Kt.TelemetryType.Metric:o=e.createMetricData(t);break;case Kt.TelemetryType.Availability:o=e.createAvailabilityData(t);break;case Kt.TelemetryType.PageView:o=e.createPageViewData(t);break}if(o&&o.baseData&&Kt.domainSupportsProperties(o.baseData)){if(n)if(!o.baseData.properties)o.baseData.properties=n;else for(var s in n)o.baseData.properties[s]||(o.baseData.properties[s]=n[s]);e.addAzureFunctionsCorrelationProperties(o.baseData.properties),o.baseData.properties&&(o.baseData.properties=Pl.validateStringMap(o.baseData.properties))}var c=a&&a.instrumentationKey||"",u=new Kt.Envelope;return u.data=o,u.iKey=c,u.name="Microsoft.ApplicationInsights."+c.replace(/-/g,"")+"."+o.baseType.substr(0,o.baseType.length-4),u.tags=this.getTags(i,t.tagOverrides),u.time=new Date().toISOString(),u.ver=1,u.sampleRate=a?a.samplingPercentage:100,r===Kt.TelemetryType.Metric&&(u.sampleRate=100),u},e.addAzureFunctionsCorrelationProperties=function(t){var r=vir.CorrelationContextManager.getCurrentContext();if(r&&r.customProperties&&r.customProperties.getProperty instanceof Function){t=t||{};var n=r.customProperties.getProperty("InvocationId");n&&(t.InvocationId=n),n=r.customProperties.getProperty("ProcessId"),n&&(t.ProcessId=n),n=r.customProperties.getProperty("LogLevel"),n&&(t.LogLevel=n),n=r.customProperties.getProperty("Category"),n&&(t.Category=n),n=r.customProperties.getProperty("HostInstanceId"),n&&(t.HostInstanceId=n),n=r.customProperties.getProperty("AzFuncLiveLogsSessionId"),n&&(t.AzFuncLiveLogsSessionId=n)}},e.truncateProperties=function(t){if(t.properties)try{for(var r={},n=Object.keys(t.properties),i=Object.values(t.properties),a=0;a<n.length;a++)n[a].length<=150&&(Pl.isDate(i[a])||(i[a]==null&&(i[a]=""),typeof i[a]=="object"&&(i[a]=Pl.stringify(i[a])),r[n[a]]=String(i[a]).substring(0,8192)),r[n[a]]=i[a]);return r}catch(o){epi.warn("Failed to properly truncate telemetry properties: ",o)}},e.createTraceData=function(t){var r,n=new Kt.MessageData;n.message=(r=t.message)===null||r===void 0?void 0:r.substring(0,32768),n.properties=this.truncateProperties(t),isNaN(t.severity)?n.severityLevel=Kt.SeverityLevel.Information:n.severityLevel=t.severity;var i=new Kt.Data;return i.baseType=Kt.telemetryTypeToBaseType(Kt.TelemetryType.Trace),i.baseData=n,i},e.createDependencyData=function(t){var r,n,i,a=new Kt.RemoteDependencyData;a.name=(r=t.name)===null||r===void 0?void 0:r.substring(0,1024),a.data=(n=t.data)===null||n===void 0?void 0:n.substring(0,8192),a.target=(i=t.target)===null||i===void 0?void 0:i.substring(0,1024),a.duration=Pl.msToTimeSpan(t.duration),a.success=t.success,a.type=t.dependencyTypeName,a.properties=this.truncateProperties(t),a.resultCode=t.resultCode?t.resultCode.toString():"0",t.id?a.id=t.id:a.id=Pl.w3cTraceId();var o=new Kt.Data;return o.baseType=Kt.telemetryTypeToBaseType(Kt.TelemetryType.Dependency),o.baseData=a,o},e.createEventData=function(t){var r,n=new Kt.EventData;n.name=(r=t.name)===null||r===void 0?void 0:r.substring(0,512),n.properties=this.truncateProperties(t),n.measurements=t.measurements;var i=new Kt.Data;return i.baseType=Kt.telemetryTypeToBaseType(Kt.TelemetryType.Event),i.baseData=n,i},e.createExceptionData=function(t){var r,n,i=new Kt.ExceptionData;i.properties=this.truncateProperties(t),isNaN(t.severity)?i.severityLevel=Kt.SeverityLevel.Error:i.severityLevel=t.severity,i.measurements=t.measurements,i.exceptions=[];var a=t.exception.stack,o=new Kt.ExceptionDetails;o.message=(r=t.exception.message)===null||r===void 0?void 0:r.substring(0,32768),o.typeName=(n=t.exception.name)===null||n===void 0?void 0:n.substring(0,1024),o.parsedStack=this.parseStack(a),o.hasFullStack=Pl.isArray(o.parsedStack)&&o.parsedStack.length>0,i.exceptions.push(o);var s=new Kt.Data;return s.baseType=Kt.telemetryTypeToBaseType(Kt.TelemetryType.Exception),s.baseData=i,s},e.createRequestData=function(t){var r,n,i,a,o=new Kt.RequestData;t.id?o.id=t.id:o.id=Pl.w3cTraceId(),o.name=(r=t.name)===null||r===void 0?void 0:r.substring(0,1024),o.url=(n=t.url)===null||n===void 0?void 0:n.substring(0,2048),o.source=(i=t.source)===null||i===void 0?void 0:i.substring(0,1024),o.duration=Pl.msToTimeSpan(t.duration),o.responseCode=(a=t.resultCode?t.resultCode.toString():"0")===null||a===void 0?void 0:a.substring(0,1024),o.success=t.success,o.properties=this.truncateProperties(t),o.measurements=t.measurements;var s=new Kt.Data;return s.baseType=Kt.telemetryTypeToBaseType(Kt.TelemetryType.Request),s.baseData=o,s},e.createMetricData=function(t){var r,n=new Kt.MetricData;n.metrics=[];var i=new Kt.DataPoint;i.count=isNaN(t.count)?1:t.count,i.kind=Kt.DataPointType.Aggregation,i.max=isNaN(t.max)?t.value:t.max,i.min=isNaN(t.min)?t.value:t.min,i.name=(r=t.name)===null||r===void 0?void 0:r.substring(0,1024),i.stdDev=isNaN(t.stdDev)?0:t.stdDev,i.value=t.value,i.ns=t.namespace,n.metrics.push(i),n.properties=this.truncateProperties(t);var a=new Kt.Data;return a.baseType=Kt.telemetryTypeToBaseType(Kt.TelemetryType.Metric),a.baseData=n,a},e.createAvailabilityData=function(t){var r,n,i=new Kt.AvailabilityData;t.id?i.id=t.id:i.id=Pl.w3cTraceId(),i.name=(r=t.name)===null||r===void 0?void 0:r.substring(0,1024),i.duration=Pl.msToTimeSpan(t.duration),i.success=t.success,i.runLocation=t.runLocation,i.message=(n=t.message)===null||n===void 0?void 0:n.substring(0,8192),i.measurements=t.measurements,i.properties=this.truncateProperties(t);var a=new Kt.Data;return a.baseType=Kt.telemetryTypeToBaseType(Kt.TelemetryType.Availability),a.baseData=i,a},e.createPageViewData=function(t){var r,n,i=new Kt.PageViewData;i.name=(r=t.name)===null||r===void 0?void 0:r.substring(0,1024),i.duration=Pl.msToTimeSpan(t.duration),i.url=(n=t.url)===null||n===void 0?void 0:n.substring(0,2048),i.measurements=t.measurements,i.properties=this.truncateProperties(t);var a=new Kt.Data;return a.baseType=Kt.telemetryTypeToBaseType(Kt.TelemetryType.PageView),a.baseData=i,a},e.getTags=function(t,r){var n=vir.CorrelationContextManager.getCurrentContext(),i={};if(t&&t.tags)for(var a in t.tags)i[a]=t.tags[a];if(r)for(var a in r)i[a]=r[a];return n&&(i[t.keys.operationId]=i[t.keys.operationId]||n.operation.id,i[t.keys.operationName]=i[t.keys.operationName]||n.operation.name,i[t.keys.operationParentId]=i[t.keys.operationParentId]||n.operation.parentId),i},e.parseStack=function(t){var r=void 0;if(typeof t=="string"){var n=t.split(`
|
|
1476
1476
|
`);r=[];for(var i=0,a=0,o=0;o<=n.length;o++){var s=n[o];if(bir.regex.test(s)){var c=new bir(n[o],i++);a+=c.sizeInBytes,r.push(c)}}var u=32*1024;if(a>u)for(var l=0,p=r.length-1,f=0,d=l,h=p;l<p;){var m=r[l].sizeInBytes,v=r[p].sizeInBytes;if(f+=m+v,f>u){var _=h-d+1;r.splice(d,_);break}d=l,h=p,l++,p--}}return r},e}(),bir=function(){function e(t,r){this.sizeInBytes=0,this.level=r,this.method="<no_method>",this.assembly=Pl.trim(t);var n=t.match(e.regex);n&&n.length>=5&&(this.method=Pl.trim(n[2])||this.method,this.fileName=Pl.trim(n[4])||"<no_filename>",this.line=parseInt(n[5])||0),this.sizeInBytes+=this.method.length,this.sizeInBytes+=this.fileName.length,this.sizeInBytes+=this.assembly.length,this.sizeInBytes+=e.baseSize,this.sizeInBytes+=this.level.toString().length,this.sizeInBytes+=this.line.toString().length}return e.regex=/^(\s+at)?(.*?)(\@|\s\(|\s)([^\(\n]+):(\d+):(\d+)(\)?)$/,e.baseSize=58,e}();Eir.exports=tpi});var _ir=y(F_=>{"use strict";var rpi=F_&&F_.__awaiter||function(e,t,r,n){function i(a){return a instanceof r?a:new r(function(o){o(a)})}return new(r||(r=Promise))(function(a,o){function s(l){try{u(n.next(l))}catch(p){o(p)}}function c(l){try{u(n.throw(l))}catch(p){o(p)}}function u(l){l.done?a(l.value):i(l.value).then(s,c)}u((n=n.apply(e,t||[])).next())})},npi=F_&&F_.__generator||function(e,t){var r={label:0,sent:function(){if(a[0]&1)throw a[1];return a[1]},trys:[],ops:[]},n,i,a,o;return o={next:s(0),throw:s(1),return:s(2)},typeof Symbol=="function"&&(o[Symbol.iterator]=function(){return this}),o;function s(u){return function(l){return c([u,l])}}function c(u){if(n)throw new TypeError("Generator is already executing.");for(;o&&(o=0,u[0]&&(r=0)),r;)try{if(n=1,i&&(a=u[0]&2?i.return:u[0]?i.throw||((a=i.return)&&a.call(i),0):i.next)&&!(a=a.call(i,u[1])).done)return a;switch(i=0,a&&(u=[u[0]&2,a.value]),u[0]){case 0:case 1:a=u;break;case 4:return r.label++,{value:u[1],done:!1};case 5:r.label++,i=u[1],u=[0];continue;case 7:u=r.ops.pop(),r.trys.pop();continue;default:if(a=r.trys,!(a=a.length>0&&a[a.length-1])&&(u[0]===6||u[0]===2)){r=0;continue}if(u[0]===3&&(!a||u[1]>a[0]&&u[1]<a[3])){r.label=u[1];break}if(u[0]===6&&r.label<a[1]){r.label=a[1],a=u;break}if(a&&r.label<a[2]){r.label=a[2],r.ops.push(u);break}a[2]&&r.ops.pop(),r.trys.pop();continue}u=t.call(e,r)}catch(l){u=[6,l],i=0}finally{n=a=0}if(u[0]&5)throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}};Object.defineProperty(F_,"__esModule",{value:!0});F_.FileAccessControl=void 0;var ipi=require("fs"),api=require("os"),cR=require("child_process"),opi=li(),spi=function(){function e(){}return e.checkFileProtection=function(){if(!e.OS_PROVIDES_FILE_PROTECTION&&!e.OS_FILE_PROTECTION_CHECKED)if(e.OS_FILE_PROTECTION_CHECKED=!0,e.USE_ICACLS){try{e.OS_PROVIDES_FILE_PROTECTION=ipi.existsSync(e.ICACLS_PATH)}catch{}e.OS_PROVIDES_FILE_PROTECTION||opi.warn(e.TAG,"Could not find ICACLS in expected location! This is necessary to use disk retry mode on Windows.")}else e.OS_PROVIDES_FILE_PROTECTION=!0},e.applyACLRules=function(t){return rpi(this,void 0,void 0,function(){var r,n;return npi(this,function(i){switch(i.label){case 0:if(!e.USE_ICACLS)return[3,7];if(e.ACLED_DIRECTORIES[t]!==void 0)return[3,6];e.ACLED_DIRECTORIES[t]=!1,i.label=1;case 1:return i.trys.push([1,4,,5]),[4,this._getACLIdentity()];case 2:return r=i.sent(),[4,this._runICACLS(this._getACLArguments(t,r))];case 3:return i.sent(),e.ACLED_DIRECTORIES[t]=!0,[3,5];case 4:throw n=i.sent(),e.ACLED_DIRECTORIES[t]=!1,n;case 5:return[3,7];case 6:if(!e.ACLED_DIRECTORIES[t])throw new Error("Setting ACL restrictions did not succeed (cached result)");i.label=7;case 7:return[2]}})})},e.applyACLRulesSync=function(t){if(e.USE_ICACLS){if(e.ACLED_DIRECTORIES[t]===void 0){this._runICACLSSync(this._getACLArguments(t,this._getACLIdentitySync())),e.ACLED_DIRECTORIES[t]=!0;return}else if(!e.ACLED_DIRECTORIES[t])throw new Error("Setting ACL restrictions did not succeed (cached result)")}},e._runICACLS=function(t){return new Promise(function(r,n){var i=cR.spawn(e.ICACLS_PATH,t,{windowsHide:!0});i.on("error",function(a){return n(a)}),i.on("close",function(a,o){a===0?r():n(new Error("Setting ACL restrictions did not succeed (ICACLS returned code ".concat(a,")")))})})},e._runICACLSSync=function(t){if(cR.spawnSync){var r=cR.spawnSync(e.ICACLS_PATH,t,{windowsHide:!0});if(r.error)throw r.error;if(r.status!==0)throw new Error("Setting ACL restrictions did not succeed (ICACLS returned code ".concat(r.status,")"))}else throw new Error("Could not synchronously call ICACLS under current version of Node.js")},e._getACLIdentity=function(){return new Promise(function(t,r){e.ACL_IDENTITY&&t(e.ACL_IDENTITY);var n=cR.spawn(e.POWERSHELL_PATH,["-Command","[System.Security.Principal.WindowsIdentity]::GetCurrent().Name"],{windowsHide:!0,stdio:["ignore","pipe","pipe"]}),i="";n.stdout.on("data",function(a){return i+=a}),n.on("error",function(a){return r(a)}),n.on("close",function(a,o){e.ACL_IDENTITY=i&&i.trim(),a===0?t(e.ACL_IDENTITY):r(new Error("Getting ACL identity did not succeed (PS returned code ".concat(a,")")))})})},e._getACLIdentitySync=function(){if(e.ACL_IDENTITY)return e.ACL_IDENTITY;if(cR.spawnSync){var t=cR.spawnSync(e.POWERSHELL_PATH,["-Command","[System.Security.Principal.WindowsIdentity]::GetCurrent().Name"],{windowsHide:!0,stdio:["ignore","pipe","pipe"]});if(t.error)throw t.error;if(t.status!==0)throw new Error("Getting ACL identity did not succeed (PS returned code ".concat(t.status,")"));return e.ACL_IDENTITY=t.stdout&&t.stdout.toString().trim(),e.ACL_IDENTITY}else throw new Error("Could not synchronously get ACL identity under current version of Node.js")},e._getACLArguments=function(t,r){return[t,"/grant","*S-1-5-32-544:(OI)(CI)F","/grant","".concat(r,":(OI)(CI)F"),"/inheritance:r"]},e.TAG="FileAccessControl",e.ICACLS_PATH="".concat(process.env.systemdrive,"/windows/system32/icacls.exe"),e.POWERSHELL_PATH="".concat(process.env.systemdrive,"/windows/system32/windowspowershell/v1.0/powershell.exe"),e.ACLED_DIRECTORIES={},e.ACL_IDENTITY=null,e.OS_FILE_PROTECTION_CHECKED=!1,e.OS_PROVIDES_FILE_PROTECTION=!1,e.USE_ICACLS=api.type()==="Windows_NT",e}();F_.FileAccessControl=spi});var Fje=y((JU,xir)=>{"use strict";var fie=JU&&JU.__awaiter||function(e,t,r,n){function i(a){return a instanceof r?a:new r(function(o){o(a)})}return new(r||(r=Promise))(function(a,o){function s(l){try{u(n.next(l))}catch(p){o(p)}}function c(l){try{u(n.throw(l))}catch(p){o(p)}}function u(l){l.done?a(l.value):i(l.value).then(s,c)}u((n=n.apply(e,t||[])).next())})},die=JU&&JU.__generator||function(e,t){var r={label:0,sent:function(){if(a[0]&1)throw a[1];return a[1]},trys:[],ops:[]},n,i,a,o;return o={next:s(0),throw:s(1),return:s(2)},typeof Symbol=="function"&&(o[Symbol.iterator]=function(){return this}),o;function s(u){return function(l){return c([u,l])}}function c(u){if(n)throw new TypeError("Generator is already executing.");for(;o&&(o=0,u[0]&&(r=0)),r;)try{if(n=1,i&&(a=u[0]&2?i.return:u[0]?i.throw||((a=i.return)&&a.call(i),0):i.next)&&!(a=a.call(i,u[1])).done)return a;switch(i=0,a&&(u=[u[0]&2,a.value]),u[0]){case 0:case 1:a=u;break;case 4:return r.label++,{value:u[1],done:!1};case 5:r.label++,i=u[1],u=[0];continue;case 7:u=r.ops.pop(),r.trys.pop();continue;default:if(a=r.trys,!(a=a.length>0&&a[a.length-1])&&(u[0]===6||u[0]===2)){r=0;continue}if(u[0]===3&&(!a||u[1]>a[0]&&u[1]<a[3])){r.label=u[1];break}if(u[0]===6&&r.label<a[1]){r.label=a[1],a=u;break}if(a&&r.label<a[2]){r.label=a[2],r.ops.push(u);break}a[2]&&r.ops.pop(),r.trys.pop();continue}u=t.call(e,r)}catch(l){u=[6,l],i=0}finally{n=a=0}if(u[0]&5)throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}},$je=require("fs"),cpi=require("os"),ES=require("path"),upi=require("zlib"),j_=Ui(),lpi=FI(),bb=_ke(),Dl=qs(),ppi=require("url"),Mje=li(),XU=_ir(),fpi=439,dpi=402,hpi=[200,206,402,408,429,439,500],mpi="Invalid instrumentation key",gpi=function(){function e(t,r,n,i,a,o,s){this._redirectedHost=null,this._config=t,this._onSuccess=n,this._onError=i,this._statsbeat=a,this._enableDiskRetryMode=!1,this._resendInterval=e.WAIT_BETWEEN_RESEND,this._maxBytesOnDisk=e.MAX_BYTES_ON_DISK,this._numConsecutiveFailures=0,this._numConsecutiveRedirects=0,this._resendTimer=null,this._getAuthorizationHandler=r,this._fileCleanupTimer=null,this._tempDir=ES.join(cpi.tmpdir(),e.TEMPDIR_PREFIX+this._config.instrumentationKey),this._isStatsbeatSender=o||!1,this._shutdownStatsbeat=s,this._failedToIngestCounter=0,this._statsbeatHasReachedIngestionAtLeastOnce=!1}return e.prototype.setDiskRetryMode=function(t,r,n){var i=this;t&&XU.FileAccessControl.checkFileProtection(),this._enableDiskRetryMode=XU.FileAccessControl.OS_PROVIDES_FILE_PROTECTION&&t,typeof r=="number"&&r>=0&&(this._resendInterval=Math.floor(r)),typeof n=="number"&&n>=0&&(this._maxBytesOnDisk=Math.floor(n)),t&&!XU.FileAccessControl.OS_PROVIDES_FILE_PROTECTION&&(this._enableDiskRetryMode=!1,this._logWarn("Ignoring request to enable disk retry mode. Sufficient file protection capabilities were not detected.")),this._enableDiskRetryMode?(this._statsbeat&&this._statsbeat.addFeature(j_.StatsbeatFeature.DISK_RETRY),this._fileCleanupTimer||(this._fileCleanupTimer=setTimeout(function(){i._fileCleanupTask()},e.CLEANUP_TIMEOUT),this._fileCleanupTimer.unref())):(this._statsbeat&&this._statsbeat.removeFeature(j_.StatsbeatFeature.DISK_RETRY),this._fileCleanupTimer&&clearTimeout(this._fileCleanupTimer))},e.prototype.send=function(t,r){return fie(this,void 0,void 0,function(){var n,i,a,o,s,c,u,l,p=this;return die(this,function(f){switch(f.label){case 0:if(!(t&&t.length>0))return[3,5];if(n=this._redirectedHost||this._config.endpointUrl,i=new ppi.URL(n).hostname,a={method:"POST",withCredentials:!1,headers:{"Content-Type":"application/x-json-stream"}},o=this._getAuthorizationHandler?this._getAuthorizationHandler(this._config):null,!o)return[3,4];this._statsbeat&&this._statsbeat.addFeature(j_.StatsbeatFeature.AAD_HANDLING),f.label=1;case 1:return f.trys.push([1,3,,4]),[4,o.addAuthorizationHeader(a)];case 2:return f.sent(),[3,4];case 3:return s=f.sent(),c="Failed to get AAD bearer token for the Application.",this._enableDiskRetryMode&&(c+="This batch of telemetry items will be retried. ",this._storeToDisk(t)),c+="Error:"+s.toString(),this._logWarn(c),typeof r=="function"&&r(c),[2];case 4:if(u="",t.forEach(function(d){var h=Dl.stringify(d);typeof h=="string"&&(u+=h+`
|
|
1477
|
-
`)}),u.length>0&&(u=u.substring(0,u.length-1)),u.length===0)return typeof r=="function"&&r("Empty batch of telemetry items. Nothing to send."),[2];l=Buffer.from?Buffer.from(u):new Buffer(u),upi.gzip(l,function(d,h){var m=h;d?(p._logWarn(Dl.dumpObj(d)),m=l,a.headers["Content-Length"]=l.length.toString()):(a.headers["Content-Encoding"]="gzip",a.headers["Content-Length"]=h.length.toString()),p._logInfo(Dl.dumpObj(a)),a[lpi.disableCollectionRequestOption]=!0;var v=+new Date,_=function(O){O.setEncoding("utf-8");var S="";O.on("data",function(A){S+=A}),O.on("end",function(){var A,P=+new Date,I=P-v;if(p._numConsecutiveFailures=0,S.includes(mpi)&&O.statusCode===400&&(Mje.warn("Instrumentation key was invalid, please check the iKey"),(A=p._shutdownStatsbeat)===null||A===void 0||A.call(p)),p._isStatsbeatSender&&!p._statsbeatHasReachedIngestionAtLeastOnce&&(hpi.includes(O.statusCode)?p._statsbeatHasReachedIngestionAtLeastOnce=!0:p._statsbeatFailedToIngest()),p._statsbeat&&(O.statusCode==dpi||O.statusCode==fpi?p._statsbeat.countThrottle(j_.StatsbeatNetworkCategory.Breeze,i,O.statusCode):p._statsbeat.countRequest(j_.StatsbeatNetworkCategory.Breeze,i,I,O.statusCode===200,O.statusCode)),p._enableDiskRetryMode){if(O.statusCode===200)p._resendTimer||(p._resendTimer=setTimeout(function(){p._resendTimer=null,p._sendFirstFileOnDisk()},p._resendInterval),p._resendTimer.unref());else if(p._isRetriable(O.statusCode))try{p._statsbeat&&p._statsbeat.countRetry(j_.StatsbeatNetworkCategory.Breeze,i,O.statusCode);var j=JSON.parse(S),k=[];j.errors&&(j.errors.forEach(function(B){(B.statusCode==429||B.statusCode==500||B.statusCode==503)&&k.push(t[B.index])}),k.length>0&&p._storeToDisk(k))}catch{p._storeToDisk(t)}}if(O.statusCode===307||O.statusCode===308)if(p._numConsecutiveRedirects++,p._numConsecutiveRedirects<10){var z=O.headers.location?O.headers.location.toString():null;z&&(p._redirectedHost=z,p.send(t,r))}else{var L={name:"Circular Redirect",message:"Error sending telemetry because of circular redirects."};p._statsbeat&&p._statsbeat.countException(j_.StatsbeatNetworkCategory.Breeze,i,L),typeof r=="function"&&r("Error sending telemetry because of circular redirects.")}else p._numConsecutiveRedirects=0,typeof r=="function"&&r(S),p._logInfo(S),typeof p._onSuccess=="function"&&p._onSuccess(S)})},T=Dl.makeRequest(p._config,n,a,_);T.setTimeout(e.HTTP_TIMEOUT,function(){p._requestTimedOut=!0,T.abort()}),T.on("error",function(O){if(p._isStatsbeatSender&&!p._statsbeatHasReachedIngestionAtLeastOnce&&p._statsbeatFailedToIngest(),p._numConsecutiveFailures++,p._statsbeat&&p._statsbeat.countException(j_.StatsbeatNetworkCategory.Breeze,i,O),!p._enableDiskRetryMode||p._numConsecutiveFailures>0&&p._numConsecutiveFailures%e.MAX_CONNECTION_FAILURES_BEFORE_WARN===0){var S="Ingestion endpoint could not be reached. This batch of telemetry items has been lost. Use Disk Retry Caching to enable resending of failed telemetry. Error:";p._enableDiskRetryMode&&(S="Ingestion endpoint could not be reached ".concat(p._numConsecutiveFailures," consecutive times. There may be resulting telemetry loss. Most recent error:")),p._logWarn(S,Dl.dumpObj(O))}else{var S="Transient failure to reach ingestion endpoint. This batch of telemetry items will be retried. Error:";p._logInfo(S,Dl.dumpObj(O))}p._onErrorHelper(O),typeof r=="function"&&(O?(p._requestTimedOut&&(O.name="telemetry timeout",O.message="telemetry request timed out"),r(Dl.dumpObj(O))):r("Error sending telemetry")),p._enableDiskRetryMode&&p._storeToDisk(t)}),T.write(m),T.end()}),f.label=5;case 5:return[2]}})})},e.prototype.saveOnCrash=function(t){this._enableDiskRetryMode&&this._storeToDiskSync(Dl.stringify(t))},e.prototype._isRetriable=function(t){return t===206||t===401||t===403||t===408||t===429||t===500||t===502||t===503||t===504},e.prototype._logInfo=function(t){for(var r=[],n=1;n<arguments.length;n++)r[n-1]=arguments[n];this._isStatsbeatSender||Mje.info(e.TAG,t,r)},e.prototype._logWarn=function(t){for(var r=[],n=1;n<arguments.length;n++)r[n-1]=arguments[n];this._isStatsbeatSender||Mje.warn(e.TAG,t,r)},e.prototype._statsbeatFailedToIngest=function(){this._shutdownStatsbeat&&(this._failedToIngestCounter++,this._failedToIngestCounter>=3&&this._shutdownStatsbeat())},e.prototype._storeToDisk=function(t){return fie(this,void 0,void 0,function(){var r,n,i,a,o,s,c;return die(this,function(u){switch(u.label){case 0:return u.trys.push([0,2,,3]),this._logInfo("Checking existence of data storage directory: "+this._tempDir),[4,bb.confirmDirExists(this._tempDir)];case 1:return u.sent(),[3,3];case 2:return r=u.sent(),this._logWarn("Failed to create folder to put telemetry: "+Dl.dumpObj(r)),this._onErrorHelper(r),[2];case 3:return u.trys.push([3,5,,6]),[4,XU.FileAccessControl.applyACLRules(this._tempDir)];case 4:return u.sent(),[3,6];case 5:return n=u.sent(),this._logWarn("Failed to apply file access control to folder: "+Dl.dumpObj(n)),this._onErrorHelper(n),[2];case 6:return u.trys.push([6,8,,9]),[4,bb.getShallowDirectorySize(this._tempDir)];case 7:return i=u.sent(),i>this._maxBytesOnDisk?(this._logWarn("Not saving data due to max size limit being met. Directory size in bytes is: "+i),[2]):[3,9];case 8:return a=u.sent(),this._logWarn("Failed to read directory for retriable telemetry: "+Dl.dumpObj(a)),this._onErrorHelper(a),[2];case 9:return u.trys.push([9,11,,12]),o="".concat(new Date().getTime(),".ai.json"),s=ES.join(this._tempDir,o),this._logInfo("saving data to disk at: "+s),[4,bb.writeFileAsync(s,Dl.stringify(t),{mode:384})];case 10:return u.sent(),[3,12];case 11:return c=u.sent(),this._logWarn("Failed to persist telemetry to disk: "+Dl.dumpObj(c)),this._onErrorHelper(c),[2];case 12:return[2]}})})},e.prototype._storeToDiskSync=function(t){try{this._logInfo("Checking existence of data storage directory: "+this._tempDir),$je.existsSync(this._tempDir)||$je.mkdirSync(this._tempDir),XU.FileAccessControl.applyACLRulesSync(this._tempDir);var r=bb.getShallowDirectorySizeSync(this._tempDir);if(r>this._maxBytesOnDisk){this._logInfo("Not saving data due to max size limit being met. Directory size in bytes is: "+r);return}var n="".concat(new Date().getTime(),".ai.json"),i=ES.join(this._tempDir,n);this._logInfo("saving data before crash to disk at: "+i),$je.writeFileSync(i,t,{mode:384})}catch(a){this._logWarn("Error while saving data to disk: "+Dl.dumpObj(a)),this._onErrorHelper(a)}},e.prototype._sendFirstFileOnDisk=function(){return fie(this,void 0,void 0,function(){var t,r,n,i,a,o;return die(this,function(s){switch(s.label){case 0:return s.trys.push([0,6,,7]),[4,bb.readdirAsync(this._tempDir)];case 1:return t=s.sent(),t=t.filter(function(c){return ES.basename(c).indexOf(".ai.json")>-1}),t.length>0?(r=t[0],n=ES.join(this._tempDir,r),[4,bb.readFileAsync(n)]):[3,5];case 2:return i=s.sent(),[4,bb.unlinkAsync(n)];case 3:return s.sent(),a=JSON.parse(i.toString()),[4,this.send(a)];case 4:s.sent(),s.label=5;case 5:return[3,7];case 6:return o=s.sent(),this._onErrorHelper(o),[3,7];case 7:return[2]}})})},e.prototype._onErrorHelper=function(t){typeof this._onError=="function"&&this._onError(t)},e.prototype._fileCleanupTask=function(){return fie(this,void 0,void 0,function(){var t,r,n,i,a,o,s=this;return die(this,function(c){switch(c.label){case 0:return c.trys.push([0,6,,7]),[4,bb.readdirAsync(this._tempDir)];case 1:if(t=c.sent(),t=t.filter(function(u){return ES.basename(u).indexOf(".ai.json")>-1}),!(t.length>0))return[3,5];r=0,c.label=2;case 2:return r<t.length?(n=new Date(parseInt(t[r].split(".ai.json")[0])),i=new Date(+new Date-e.FILE_RETEMPTION_PERIOD)>n,i?(a=ES.join(this._tempDir,t[r]),[4,bb.unlinkAsync(a).catch(function(u){s._onErrorHelper(u)})]):[3,4]):[3,5];case 3:c.sent(),c.label=4;case 4:return r++,[3,2];case 5:return[3,7];case 6:return o=c.sent(),o.code!="ENOENT"&&this._onErrorHelper(o),[3,7];case 7:return[2]}})})},e.TAG="Sender",e.WAIT_BETWEEN_RESEND=60*1e3,e.MAX_BYTES_ON_DISK=50*1024*1024,e.MAX_CONNECTION_FAILURES_BEFORE_WARN=5,e.CLEANUP_TIMEOUT=60*60*1e3,e.FILE_RETEMPTION_PERIOD=7*24*60*60*1e3,e.TEMPDIR_PREFIX="appInsights-node",e.HTTP_TIMEOUT=2e4,e}();xir.exports=gpi});var Oir=y(hie=>{"use strict";Object.defineProperty(hie,"__esModule",{value:!0});hie.AzureVirtualMachine=void 0;var Tir=li(),ypi=qs(),vpi=FI(),bpi="http://169.254.169.254/metadata/instance/compute",Epi="api-version=2017-12-01",_pi="format=json",xpi="UNREACH",Tpi=function(){function e(){}return e.getAzureComputeMetadata=function(t,r){var n,i=this,a={},o="".concat(bpi,"?").concat(Epi,"&").concat(_pi),s=(n={method:"GET"},n[vpi.disableCollectionRequestOption]=!0,n.headers={Metadata:"True"},n),c=ypi.makeRequest(t,o,s,function(u){if(u.statusCode===200){a.isVM=!0;var l="";u.on("data",function(p){l+=p}),u.on("end",function(){try{var p=JSON.parse(l);a.id=p.vmId||"",a.subscriptionId=p.subscriptionId||"",a.osType=p.osType||""}catch(f){Tir.info(e.TAG,f)}r(a)})}else r(a)},!1,!1);c&&(setTimeout(function(){i._requestTimedOut=!0,c.abort()},e.HTTP_TIMEOUT),c.on("error",function(u){i._requestTimedOut&&u&&(u.name="telemetry timeout",u.message="telemetry request timed out"),u&&u.message&&u.message.indexOf(xpi)>-1?a.isVM=!1:Tir.info(e.TAG,u),r(a)}),c.end())},e.HTTP_TIMEOUT=2500,e.TAG="AzureVirtualMachine",e}();hie.AzureVirtualMachine=Tpi});var Sir=y(mie=>{"use strict";Object.defineProperty(mie,"__esModule",{value:!0});mie.NetworkStatsbeat=void 0;var Opi=function(){function e(t,r){this.endpoint=t,this.host=r,this.totalRequestCount=0,this.totalSuccesfulRequestCount=0,this.totalFailedRequestCount=[],this.retryCount=[],this.exceptionCount=[],this.throttleCount=[],this.intervalRequestExecutionTime=0,this.lastIntervalRequestExecutionTime=0,this.lastTime=+new Date,this.lastRequestCount=0}return e}();mie.NetworkStatsbeat=Opi});var Dir=y((_S,Pir)=>{"use strict";var $g=_S&&_S.__assign||function(){return $g=Object.assign||function(e){for(var t,r=1,n=arguments.length;r<n;r++){t=arguments[r];for(var i in t)Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i])}return e},$g.apply(this,arguments)},jje=_S&&_S.__awaiter||function(e,t,r,n){function i(a){return a instanceof r?a:new r(function(o){o(a)})}return new(r||(r=Promise))(function(a,o){function s(l){try{u(n.next(l))}catch(p){o(p)}}function c(l){try{u(n.throw(l))}catch(p){o(p)}}function u(l){l.done?a(l.value):i(l.value).then(s,c)}u((n=n.apply(e,t||[])).next())})},qje=_S&&_S.__generator||function(e,t){var r={label:0,sent:function(){if(a[0]&1)throw a[1];return a[1]},trys:[],ops:[]},n,i,a,o;return o={next:s(0),throw:s(1),return:s(2)},typeof Symbol=="function"&&(o[Symbol.iterator]=function(){return this}),o;function s(u){return function(l){return c([u,l])}}function c(u){if(n)throw new TypeError("Generator is already executing.");for(;o&&(o=0,u[0]&&(r=0)),r;)try{if(n=1,i&&(a=u[0]&2?i.return:u[0]?i.throw||((a=i.return)&&a.call(i),0):i.next)&&!(a=a.call(i,u[1])).done)return a;switch(i=0,a&&(u=[u[0]&2,a.value]),u[0]){case 0:case 1:a=u;break;case 4:return r.label++,{value:u[1],done:!1};case 5:r.label++,i=u[1],u=[0];continue;case 7:u=r.ops.pop(),r.trys.pop();continue;default:if(a=r.trys,!(a=a.length>0&&a[a.length-1])&&(u[0]===6||u[0]===2)){r=0;continue}if(u[0]===3&&(!a||u[1]>a[0]&&u[1]<a[3])){r.label=u[1];break}if(u[0]===6&&r.label<a[1]){r.label=a[1],a=u;break}if(a&&r.label<a[2]){r.label=a[2],r.ops.push(u);break}a[2]&&r.ops.pop(),r.trys.pop();continue}u=t.call(e,r)}catch(l){u=[6,l],i=0}finally{n=a=0}if(u[0]&5)throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}},Spi=require("os"),Api=kje(),Air=li(),Cpi=Fje(),zi=Ui(),wpi=Mc(),Ppi=Oir(),Dpi=bFe(),Cir=NI(),Npi=Sir(),wir=qs(),Ipi="node",Rpi=function(){function e(t,r){this._attach=zi.StatsbeatAttach.sdk,this._feature=zi.StatsbeatFeature.NONE,this._instrumentation=zi.StatsbeatInstrumentation.NONE,this._isInitialized=!1,this._statbeatMetrics=[],this._networkStatsbeatCollection=[],this._config=t,this._context=r||new Cir,this._longHandleTimeout=null;var n=this._getConnectionString(t);this._statsbeatConfig=new Dpi(n),this._statsbeatConfig.samplingPercentage=100,this._sender=new Cpi(this._statsbeatConfig,null,null,null,null,!0,this._shutdownStatsbeat.bind(this))}return e.prototype.enable=function(t){var r=this;this._isEnabled=t,this._isEnabled&&!this._isInitialized&&(this._getCustomProperties(),this._isInitialized=!0),t?(this._handle||(this._handle=setInterval(function(){r.trackShortIntervalStatsbeats()},e.STATS_COLLECTION_SHORT_INTERVAL),this._handle.unref()),this._longHandle||(this._longHandleTimeout=setTimeout(function(){r.isEnabled()&&r.trackLongIntervalStatsbeats()},e.STATS_COLLECTION_INITIAL_DELAY),this._longHandleTimeout.unref(),this._longHandle=setInterval(function(){r.trackLongIntervalStatsbeats()},e.STATS_COLLECTION_LONG_INTERVAL),this._longHandle.unref())):(this._handle&&(clearInterval(this._handle),this._handle=null),this._longHandle&&(clearInterval(this._longHandle),this._longHandle=null),this._longHandleTimeout&&(clearTimeout(this._longHandleTimeout),this._longHandleTimeout=null))},e.prototype.isInitialized=function(){return this._isInitialized},e.prototype.isEnabled=function(){return this._isEnabled},e.prototype.setCodelessAttach=function(){this._attach=zi.StatsbeatAttach.codeless},e.prototype.addFeature=function(t){this._feature|=t},e.prototype.removeFeature=function(t){this._feature&=~t},e.prototype.addInstrumentation=function(t){this._instrumentation|=t},e.prototype.removeInstrumentation=function(t){this._instrumentation&=~t},e.prototype.countRequest=function(t,r,n,i,a){if(this.isEnabled()){var o=this._getNetworkStatsbeatCounter(t,r);if(o.totalRequestCount++,o.intervalRequestExecutionTime+=n,i===!1){if(!a)return;var s=o.totalFailedRequestCount.find(function(c){return a===c.statusCode});s?s.count++:o.totalFailedRequestCount.push({statusCode:a,count:1})}else o.totalSuccesfulRequestCount++}},e.prototype.countException=function(t,r,n){if(this.isEnabled()){var i=this._getNetworkStatsbeatCounter(t,r),a=i.exceptionCount.find(function(o){return n.name===o.exceptionType});a?a.count++:i.exceptionCount.push({exceptionType:n.name,count:1})}},e.prototype.countThrottle=function(t,r,n){if(this.isEnabled()){var i=this._getNetworkStatsbeatCounter(t,r),a=i.throttleCount.find(function(o){return n===o.statusCode});a?a.count++:i.throttleCount.push({statusCode:n,count:1})}},e.prototype.countRetry=function(t,r,n){if(this.isEnabled()){var i=this._getNetworkStatsbeatCounter(t,r),a=i.retryCount.find(function(o){return n===o.statusCode});a?a.count++:i.retryCount.push({statusCode:n,count:1})}},e.prototype.trackShortIntervalStatsbeats=function(){return jje(this,void 0,void 0,function(){var t,r;return qje(this,function(n){switch(n.label){case 0:return n.trys.push([0,3,,4]),[4,this._getResourceProvider()];case 1:return n.sent(),t={os:this._os,rp:this._resourceProvider,cikey:this._cikey,runtimeVersion:this._runtimeVersion,language:this._language,version:this._sdkVersion,attach:this._attach},this._trackRequestDuration(t),this._trackRequestsCount(t),[4,this._sendStatsbeats()];case 2:return n.sent(),[3,4];case 3:return r=n.sent(),Air.info(e.TAG,"Failed to send Statsbeat metrics: "+wir.dumpObj(r)),[3,4];case 4:return[2]}})})},e.prototype.trackLongIntervalStatsbeats=function(){return jje(this,void 0,void 0,function(){var t,r,n,i,a;return qje(this,function(o){switch(o.label){case 0:return o.trys.push([0,3,,4]),[4,this._getResourceProvider()];case 1:return o.sent(),t={os:this._os,rp:this._resourceProvider,cikey:this._cikey,runtimeVersion:this._runtimeVersion,language:this._language,version:this._sdkVersion,attach:this._attach},r=Object.assign({rpId:this._resourceIdentifier},t),this._statbeatMetrics.push({name:zi.StatsbeatCounter.ATTACH,value:1,properties:r}),this._instrumentation!=zi.StatsbeatInstrumentation.NONE&&(n=Object.assign({feature:this._instrumentation,type:zi.StatsbeatFeatureType.Instrumentation},t),this._statbeatMetrics.push({name:zi.StatsbeatCounter.FEATURE,value:1,properties:n})),this._feature!=zi.StatsbeatFeature.NONE&&(i=Object.assign({feature:this._feature,type:zi.StatsbeatFeatureType.Feature},t),this._statbeatMetrics.push({name:zi.StatsbeatCounter.FEATURE,value:1,properties:i})),[4,this._sendStatsbeats()];case 2:return o.sent(),[3,4];case 3:return a=o.sent(),Air.info(e.TAG,"Failed to send Statsbeat metrics: "+wir.dumpObj(a)),[3,4];case 4:return[2]}})})},e.prototype._getNetworkStatsbeatCounter=function(t,r){for(var n=this._getShortHost(r),i=0;i<this._networkStatsbeatCollection.length;i++)if(t===this._networkStatsbeatCollection[i].endpoint&&n===this._networkStatsbeatCollection[i].host)return this._networkStatsbeatCollection[i];var a=new Npi.NetworkStatsbeat(t,n);return this._networkStatsbeatCollection.push(a),a},e.prototype._trackRequestDuration=function(t){for(var r=0;r<this._networkStatsbeatCollection.length;r++){var n=this._networkStatsbeatCollection[r];n.time=+new Date;var i=n.totalRequestCount-n.lastRequestCount||0,a=n.intervalRequestExecutionTime-n.lastIntervalRequestExecutionTime,o=a>0&&a/i||0;if(n.lastIntervalRequestExecutionTime=n.intervalRequestExecutionTime,i>0){var s=Object.assign({endpoint:this._networkStatsbeatCollection[r].endpoint,host:this._networkStatsbeatCollection[r].host},t);this._statbeatMetrics.push({name:zi.StatsbeatCounter.REQUEST_DURATION,value:o,properties:s})}n.lastRequestCount=n.totalRequestCount,n.lastTime=n.time}},e.prototype._getShortHost=function(t){var r=t;try{var n=new RegExp(/^https?:\/\/(?:www\.)?([^\/.-]+)/),i=n.exec(t);i!=null&&i.length>1&&(r=i[1]),r=r.replace(".in.applicationinsights.azure.com","")}catch{}return r},e.prototype._trackRequestsCount=function(t){for(var r=this,n=function(s){a=i._networkStatsbeatCollection[s];var c=Object.assign({endpoint:a.endpoint,host:a.host},t);a.totalSuccesfulRequestCount>0&&(i._statbeatMetrics.push({name:zi.StatsbeatCounter.REQUEST_SUCCESS,value:a.totalSuccesfulRequestCount,properties:c}),a.totalSuccesfulRequestCount=0),a.totalFailedRequestCount.length>0&&(a.totalFailedRequestCount.forEach(function(u){c=Object.assign($g($g({},c),{statusCode:u.statusCode})),r._statbeatMetrics.push({name:zi.StatsbeatCounter.REQUEST_FAILURE,value:u.count,properties:c})}),a.totalFailedRequestCount=[]),a.retryCount.length>0&&(a.retryCount.forEach(function(u){c=Object.assign($g($g({},c),{statusCode:u.statusCode})),r._statbeatMetrics.push({name:zi.StatsbeatCounter.RETRY_COUNT,value:u.count,properties:c})}),a.retryCount=[]),a.throttleCount.length>0&&(a.throttleCount.forEach(function(u){c=Object.assign($g($g({},c),{statusCode:u.statusCode})),r._statbeatMetrics.push({name:zi.StatsbeatCounter.THROTTLE_COUNT,value:u.count,properties:c})}),a.throttleCount=[]),a.exceptionCount.length>0&&(a.exceptionCount.forEach(function(u){c=Object.assign($g($g({},c),{exceptionType:u.exceptionType})),r._statbeatMetrics.push({name:zi.StatsbeatCounter.EXCEPTION_COUNT,value:u.count,properties:c})}),a.exceptionCount=[])},i=this,a,o=0;o<this._networkStatsbeatCollection.length;o++)n(o)},e.prototype._sendStatsbeats=function(){return jje(this,void 0,void 0,function(){var t,r,n,i;return qje(this,function(a){switch(a.label){case 0:if(!(this._statbeatMetrics.length>0))return[3,2];for(t=[],r=0;r<this._statbeatMetrics.length;r++)n={name:this._statbeatMetrics[r].name,value:this._statbeatMetrics[r].value,properties:this._statbeatMetrics[r].properties},i=Api.createEnvelope(n,wpi.TelemetryType.Metric,null,this._context,this._statsbeatConfig),i.name=zi.StatsbeatTelemetryName,t.push(i);return this._statbeatMetrics=[],[4,this._sender.send(t)];case 1:a.sent(),a.label=2;case 2:return[2]}})})},e.prototype._getCustomProperties=function(){this._language=Ipi,this._cikey=this._config.instrumentationKey,this._sdkVersion=Cir.sdkVersion,this._os=Spi.type(),this._runtimeVersion=process.version},e.prototype._getResourceProvider=function(){var t=this;return new Promise(function(r,n){var i=!1;t._resourceProvider=zi.StatsbeatResourceProvider.unknown,t._resourceIdentifier=zi.StatsbeatResourceProvider.unknown,process.env.AKS_ARM_NAMESPACE_ID?(t._resourceProvider=zi.StatsbeatResourceProvider.aks,t._resourceIdentifier=process.env.AKS_ARM_NAMESPACE_ID):process.env.WEBSITE_SITE_NAME?(t._resourceProvider=zi.StatsbeatResourceProvider.appsvc,t._resourceIdentifier=process.env.WEBSITE_SITE_NAME,process.env.WEBSITE_HOME_STAMPNAME&&(t._resourceIdentifier+="/"+process.env.WEBSITE_HOME_STAMPNAME)):process.env.FUNCTIONS_WORKER_RUNTIME?(t._resourceProvider=zi.StatsbeatResourceProvider.functions,process.env.WEBSITE_HOSTNAME&&(t._resourceIdentifier=process.env.WEBSITE_HOSTNAME)):t._config&&(t._isVM===void 0||t._isVM==!0?(i=!0,Ppi.AzureVirtualMachine.getAzureComputeMetadata(t._config,function(a){t._isVM=a.isVM,t._isVM&&(t._resourceProvider=zi.StatsbeatResourceProvider.vm,t._resourceIdentifier=a.id+"/"+a.subscriptionId,a.osType&&(t._os=a.osType)),r()})):t._resourceProvider=zi.StatsbeatResourceProvider.unknown),i||r()})},e.prototype._shutdownStatsbeat=function(){this.enable(!1)},e.prototype._getConnectionString=function(t){for(var r=t.endpointUrl,n=["westeurope","northeurope","francecentral","francesouth","germanywestcentral","norwayeast","norwaywest","swedencentral","switzerlandnorth","switzerlandwest","uksouth","ukwest"],i=0;i<n.length;i++)if(r.indexOf(n[i])>-1)return e.EU_CONNECTION_STRING;return e.NON_EU_CONNECTION_STRING},e.NON_EU_CONNECTION_STRING="InstrumentationKey=c4a29126-a7cb-47e5-b348-11414998b11e;IngestionEndpoint=https://westus-0.in.applicationinsights.azure.com",e.EU_CONNECTION_STRING="InstrumentationKey=7dc56bab-3c0c-4e9f-9ebb-d1acadee8d0f;IngestionEndpoint=https://westeurope-5.in.applicationinsights.azure.com",e.STATS_COLLECTION_SHORT_INTERVAL=9e5,e.STATS_COLLECTION_LONG_INTERVAL=864e5,e.STATS_COLLECTION_INITIAL_DELAY=15e3,e.TAG="Statsbeat",e}();Pir.exports=Rpi});var Rir=y((Rha,Iir)=>{"use strict";var Lpi=require("url"),kpi=bFe(),$pi=cir(),Mpi=NI(),Eb=Mc(),Fpi=lir(),Vje=yir(),Nir=w_(),jpi=Dir(),qpi=Fje(),Uje=qs(),gie=li(),Vpi=kje(),Upi=function(){function e(t){this._telemetryProcessors=[];var r=new kpi(t);if(this.config=r,!this.config.instrumentationKey||this.config.instrumentationKey=="")throw new Error("Instrumentation key not found, please provide a connection string before starting Application Insights SDK.");this.context=new Mpi,this.commonProperties={},this.authorizationHandler=null,this.config.disableStatsbeat||(this._statsbeat=new jpi(this.config,this.context),this._statsbeat.enable(!0));var n=new qpi(this.config,this.getAuthorizationHandler,null,null,this._statsbeat);this.channel=new Fpi(function(){return r.disableAppInsights},function(){return r.maxBatchSize},function(){return r.maxBatchIntervalMs},n)}return e.prototype.trackAvailability=function(t){this.track(t,Eb.TelemetryType.Availability)},e.prototype.trackPageView=function(t){this.track(t,Eb.TelemetryType.PageView)},e.prototype.trackTrace=function(t){this.track(t,Eb.TelemetryType.Trace)},e.prototype.trackMetric=function(t){this.track(t,Eb.TelemetryType.Metric)},e.prototype.trackException=function(t){t&&t.exception&&!Uje.isError(t.exception)&&(t.exception=new Error(t.exception.toString())),this.track(t,Eb.TelemetryType.Exception)},e.prototype.trackEvent=function(t){this.track(t,Eb.TelemetryType.Event)},e.prototype.trackRequest=function(t){this.track(t,Eb.TelemetryType.Request)},e.prototype.trackDependency=function(t){if(t&&!t.target&&t.data)try{t.target=new Lpi.URL(t.data).host}catch(r){t.target=null,gie.warn(e.TAG,"The URL object is failed to create.",r)}this.track(t,Eb.TelemetryType.Dependency)},e.prototype.flush=function(t){this.channel.triggerSend(t?!!t.isAppCrashing:!1,t?t.callback:void 0)},e.prototype.track=function(t,r){if(t&&Eb.telemetryTypeToBaseType(r)){var n=Vpi.createEnvelope(t,r,this.commonProperties,this.context,this.config);t.time&&(n.time=t.time.toISOString());var i=this.runTelemetryProcessors(n,t.contextObjects);i=i&&Vje.samplingTelemetryProcessor(n,{correlationContext:Nir.CorrelationContextManager.getCurrentContext()}),Vje.preAggregatedMetricsTelemetryProcessor(n,this.context),i&&(Vje.performanceMetricsTelemetryProcessor(n,this.quickPulseClient),this.channel.send(n))}else gie.warn(e.TAG,"track() requires telemetry object and telemetryType to be specified.")},e.prototype.setAutoPopulateAzureProperties=function(t){},e.prototype.getAuthorizationHandler=function(t){return t&&t.aadTokenCredential?(this.authorizationHandler||(gie.info(e.TAG,"Adding authorization handler"),this.authorizationHandler=new $pi(t.aadTokenCredential,t.aadAudience)),this.authorizationHandler):null},e.prototype.addTelemetryProcessor=function(t){this._telemetryProcessors.push(t)},e.prototype.clearTelemetryProcessors=function(){this._telemetryProcessors=[]},e.prototype.runTelemetryProcessors=function(t,r){var n=!0,i=this._telemetryProcessors.length;if(i===0)return n;r=r||{},r.correlationContext=Nir.CorrelationContextManager.getCurrentContext();for(var a=0;a<i;++a)try{var o=this._telemetryProcessors[a];if(o&&o.apply(null,[t,r])===!1){n=!1;break}}catch(s){n=!0,gie.warn(e.TAG,"One of telemetry processors failed, telemetry item will be sent.",s,t)}return n&&(t&&t.tags&&(t.tags=Uje.validateStringMap(t.tags)),t&&t.data&&t.data.baseData&&t.data.baseData.properties&&(t.data.baseData.properties=Uje.validateStringMap(t.data.baseData.properties))),n},e.prototype.getStatsbeat=function(){return this._statsbeat},e.TAG="TelemetryClient",e}();Iir.exports=Upi});var $ir=y((Bje,kir)=>{"use strict";var Bpi=Bje&&Bje.__extends||function(){var e=function(t,r){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,i){n.__proto__=i}||function(n,i){for(var a in i)Object.prototype.hasOwnProperty.call(i,a)&&(n[a]=i[a])},e(t,r)};return function(t,r){if(typeof r!="function"&&r!==null)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");e(t,r);function n(){this.constructor=t}t.prototype=r===null?Object.create(r):(n.prototype=r.prototype,new n)}}(),zpi=Rir(),Lir=fFe(),Hpi=FI(),yie=li(),Gpi=function(e){Bpi(t,e);function t(){return e!==null&&e.apply(this,arguments)||this}return t.prototype.trackNodeHttpRequestSync=function(r){r&&r.request&&r.response&&r.duration?Lir.trackRequestSync(this,r):yie.warn("trackNodeHttpRequestSync requires NodeHttpRequestTelemetry object with request, response and duration specified.")},t.prototype.trackNodeHttpRequest=function(r){(r.duration||r.error)&&yie.warn("trackNodeHttpRequest will ignore supplied duration and error parameters. These values are collected from the request and response objects."),r&&r.request&&r.response?Lir.trackRequest(this,r):yie.warn("trackNodeHttpRequest requires NodeHttpRequestTelemetry object with request and response specified.")},t.prototype.trackNodeHttpDependency=function(r){r&&r.request?Hpi.trackRequest(this,r):yie.warn("trackNodeHttpDependency requires NodeHttpDependencyTelemetry object with request specified.")},t}(zpi);kir.exports=Gpi});var Fir=y(Mir=>{"use strict";Object.defineProperty(Mir,"__esModule",{value:!0})});var Wje=y(oe=>{"use strict";Object.defineProperty(oe,"__esModule",{value:!0});oe.Configuration=oe.liveMetricsClient=oe.defaultClient=oe.DistributedTracingModes=void 0;oe.setup=tfi;oe.start=Vir;oe.getCorrelationContext=nfi;oe.startOperation=ifi;oe.wrapWithCorrelationContext=afi;oe.dispose=ofi;var Hje=w_(),Kpi=Ier(),Ypi=Ler(),Gje=dne(),Wpi=ZMe(),Xpi=zer(),Jpi=ttr(),Zpi=FI(),Qpi=fFe(),jir=X1(),ZU=li(),qir=ktr(),Kje=Mtr(),efi=qtr();oe.TelemetryClient=$ir();oe.Contracts=Mc();oe.azureFunctionsTypes=Fir();var zje;(function(e){e[e.AI=0]="AI",e[e.AI_AND_W3C=1]="AI_AND_W3C"})(zje||(oe.DistributedTracingModes=zje={}));var QU,eB,tB,rB,nB,uR,lR,xS,iB,aB,Ip=!1,vie;function tfi(e){return oe.defaultClient?ZU.info("The default client is already setup"):(oe.defaultClient=new oe.TelemetryClient(e),QU=new Kpi(oe.defaultClient),eB=new Ypi(oe.defaultClient),tB=new Gje(oe.defaultClient),rB=new Wpi(oe.defaultClient),nB=new Xpi(oe.defaultClient),uR=new Jpi(oe.defaultClient),xS=new Qpi(oe.defaultClient),iB=new Zpi(oe.defaultClient),lR||(lR=new Kje.AutoCollectNativePerformance(oe.defaultClient)),aB=new efi.AzureFunctionsHook(oe.defaultClient)),Yje}function rfi(){oe.defaultClient&&(oe.defaultClient.config.enableAutoCollectExternalLoggers==null&&(oe.defaultClient.config.enableAutoCollectExternalLoggers=!0),oe.defaultClient.config.enableAutoCollectConsole==null&&(oe.defaultClient.config.enableAutoCollectConsole=!1),oe.defaultClient.config.enableAutoCollectExceptions==null&&(oe.defaultClient.config.enableAutoCollectExceptions=!0),oe.defaultClient.config.enableAutoCollectPerformance==null&&(oe.defaultClient.config.enableAutoCollectPerformance=!0),oe.defaultClient.config.enableAutoCollectPreAggregatedMetrics==null&&(oe.defaultClient.config.enableAutoCollectPreAggregatedMetrics=!0),oe.defaultClient.config.enableAutoCollectHeartbeat==null&&(oe.defaultClient.config.enableAutoCollectHeartbeat=!0),oe.defaultClient.config.enableAutoCollectRequests==null&&(oe.defaultClient.config.enableAutoCollectRequests=!0),oe.defaultClient.config.enableAutoCollectDependencies==null&&(oe.defaultClient.config.enableAutoCollectDependencies=!0),oe.defaultClient.config.enableUseDiskRetryCaching==null&&(oe.defaultClient.config.enableUseDiskRetryCaching=!0),oe.defaultClient.config.enableAutoDependencyCorrelation==null&&(oe.defaultClient.config.enableAutoDependencyCorrelation=!0),oe.defaultClient.config.enableSendLiveMetrics==null&&(oe.defaultClient.config.enableSendLiveMetrics=!1),oe.defaultClient.config.enableAutoCollectExtendedMetrics==null&&(oe.defaultClient.config.enableAutoCollectExtendedMetrics=!0),oe.defaultClient.config.enableWebInstrumentation==null&&(oe.defaultClient.config.enableWebInstrumentation=!1),oe.defaultClient.config.enableAutoCollectIncomingRequestAzureFunctions==null&&(oe.defaultClient.config.enableAutoCollectIncomingRequestAzureFunctions=!1))}function Vir(){if(oe.defaultClient){Ip=!0,rfi(),QU.enable(oe.defaultClient.config.enableAutoCollectExternalLoggers,oe.defaultClient.config.enableAutoCollectConsole),eB.enable(oe.defaultClient.config.enableAutoCollectExceptions),tB.enable(oe.defaultClient.config.enableAutoCollectPerformance),rB.enable(oe.defaultClient.config.enableAutoCollectPreAggregatedMetrics),nB.enable(oe.defaultClient.config.enableAutoCollectHeartbeat),xS.useAutoCorrelation(oe.defaultClient.config.enableAutoDependencyCorrelation,oe.defaultClient.config.enableUseAsyncHooks),xS.enable(oe.defaultClient.config.enableAutoCollectRequests),iB.enable(oe.defaultClient.config.enableAutoCollectDependencies),uR.enable(oe.defaultClient.config.enableWebInstrumentation,oe.defaultClient.config.webInstrumentationConnectionString),oe.defaultClient.config.enableSendLiveMetrics&&(oe.liveMetricsClient||(oe.liveMetricsClient=new qir(oe.defaultClient.config,oe.defaultClient.context,oe.defaultClient.getAuthorizationHandler,oe.defaultClient),vie=new Gje(oe.liveMetricsClient,1e3,!0),oe.liveMetricsClient.addCollector(vie),oe.defaultClient.quickPulseClient=oe.liveMetricsClient),oe.liveMetricsClient.enable(oe.defaultClient.config.enableSendLiveMetrics)),aB.enable(oe.defaultClient.config.enableAutoCollectIncomingRequestAzureFunctions);var e=Kje.AutoCollectNativePerformance.parseEnabled(oe.defaultClient.config.enableAutoCollectExtendedMetrics,oe.defaultClient.config);lR.enable(oe.defaultClient.config.enableAutoCollectExtendedMetrics,e.disabledMetrics),oe.defaultClient&&oe.defaultClient.channel&&oe.defaultClient.channel.setUseDiskRetryCaching(oe.defaultClient.config.enableUseDiskRetryCaching,oe.defaultClient.config.enableResendInterval,oe.defaultClient.config.enableMaxBytesOnDisk)}else ZU.warn("Start cannot be called before setup");return Yje}function nfi(){return Hje.CorrelationContextManager.getCurrentContext()}function ifi(e,t){return Hje.CorrelationContextManager.startOperation(e,t)}function afi(e,t){return Hje.CorrelationContextManager.wrapCallback(e,t)}var Yje=function(){function e(){}return e.setDistributedTracingMode=function(t){return jir.w3cEnabled=t===zje.AI_AND_W3C,e},e.setAutoCollectConsole=function(t,r){return r===void 0&&(r=!1),oe.defaultClient&&(oe.defaultClient.config.enableAutoCollectExternalLoggers=t,oe.defaultClient.config.enableAutoCollectConsole=r,Ip&&QU.enable(t,r)),e},e.setAutoCollectExceptions=function(t){return oe.defaultClient&&(oe.defaultClient.config.enableAutoCollectExceptions=t,Ip&&eB.enable(t)),e},e.setAutoCollectPerformance=function(t,r){if(r===void 0&&(r=!0),oe.defaultClient){oe.defaultClient.config.enableAutoCollectPerformance=t;var n=Kje.AutoCollectNativePerformance.parseEnabled(r,oe.defaultClient.config);oe.defaultClient.config.enableAutoCollectExtendedMetrics=n.isEnabled,Ip&&(tB.enable(t),lR.enable(oe.defaultClient.config.enableAutoCollectExtendedMetrics,n.disabledMetrics))}return e},e.setAutoCollectPreAggregatedMetrics=function(t){return oe.defaultClient&&(oe.defaultClient.config.enableAutoCollectPreAggregatedMetrics=t,Ip&&rB.enable(t)),e},e.setAutoCollectHeartbeat=function(t){return oe.defaultClient&&(oe.defaultClient.config.enableAutoCollectHeartbeat=t,Ip&&nB.enable(t)),e},e.enableAutoWebSnippetInjection=function(t,r){return oe.defaultClient&&(oe.defaultClient.config.enableWebInstrumentation=t,oe.defaultClient.config.webInstrumentationConnectionString=r,Ip&&uR.enable(oe.defaultClient.config.enableAutoWebSnippetInjection,oe.defaultClient.config.webSnippetConnectionString)),e},e.enableWebInstrumentation=function(t,r){return oe.defaultClient&&(oe.defaultClient.config.enableWebInstrumentation=t,oe.defaultClient.config.webInstrumentationConnectionString=r,Ip&&uR.enable(oe.defaultClient.config.enableWebInstrumentation,oe.defaultClient.config.webInstrumentationConnectionString)),e},e.setAutoCollectRequests=function(t){return oe.defaultClient&&(oe.defaultClient.config.enableAutoCollectRequests=t,Ip&&xS.enable(t)),e},e.setAutoCollectDependencies=function(t){return oe.defaultClient&&(oe.defaultClient.config.enableAutoCollectDependencies=t,Ip&&iB.enable(t)),e},e.setAutoDependencyCorrelation=function(t,r){return oe.defaultClient&&(oe.defaultClient.config.enableAutoDependencyCorrelation=t,oe.defaultClient.config.enableUseAsyncHooks=r,Ip&&xS.useAutoCorrelation(t,r)),e},e.setUseDiskRetryCaching=function(t,r,n){return oe.defaultClient&&(oe.defaultClient.config.enableUseDiskRetryCaching=t,oe.defaultClient.config.enableResendInterval=r,oe.defaultClient.config.enableMaxBytesOnDisk=n,oe.defaultClient.channel&&oe.defaultClient.channel.setUseDiskRetryCaching(oe.defaultClient.config.enableUseDiskRetryCaching,oe.defaultClient.config.enableResendInterval,oe.defaultClient.config.enableMaxBytesOnDisk)),e},e.setInternalLogging=function(t,r){return t===void 0&&(t=!1),r===void 0&&(r=!0),ZU.enableDebug=t,ZU.disableWarnings=!r,e},e.setAutoCollectIncomingRequestAzureFunctions=function(t){return oe.defaultClient&&(oe.defaultClient.config.enableAutoCollectIncomingRequestAzureFunctions=t,Ip&&aB.enable(t)),e},e.setSendLiveMetrics=function(t){return t===void 0&&(t=!1),oe.defaultClient?(!oe.liveMetricsClient&&t?(oe.liveMetricsClient=new qir(oe.defaultClient.config,oe.defaultClient.context,oe.defaultClient.getAuthorizationHandler,oe.defaultClient),vie=new Gje(oe.liveMetricsClient,1e3,!0),oe.liveMetricsClient.addCollector(vie),oe.defaultClient.quickPulseClient=oe.liveMetricsClient):oe.liveMetricsClient&&oe.liveMetricsClient.enable(t),oe.defaultClient.config.enableSendLiveMetrics=t,e):(ZU.warn("Live metrics client cannot be setup without the default client"),e)},e.start=Vir,e}();oe.Configuration=Yje;function ofi(){jir.w3cEnabled=!0,oe.defaultClient=null,Ip=!1,QU&&QU.dispose(),eB&&eB.dispose(),tB&&tB.dispose(),rB&&rB.dispose(),nB&&nB.dispose(),uR&&uR.dispose(),lR&&lR.dispose(),xS&&xS.dispose(),iB&&iB.dispose(),oe.liveMetricsClient&&(oe.liveMetricsClient.enable(!1),oe.liveMetricsClient=void 0),aB&&aB.dispose()}});var Eie=y(bie=>{"use strict";Object.defineProperty(bie,"__esModule",{value:!0});bie.EventHeader=void 0;var Xje=class{extensionName;eventName;constructor(t,r){this.extensionName=t,this.eventName=r}getExtensionName(){return this.extensionName}getEventName(){return this.eventName}toString(){return`${this.extensionName}/${this.eventName}`}};bie.EventHeader=Xje});var xie=y(_ie=>{"use strict";Object.defineProperty(_ie,"__esModule",{value:!0});_ie.SampleRate=void 0;var Uir;(function(e){e[e.OnePercent=0]="OnePercent",e[e.TenPercent=1]="TenPercent",e[e.NoSampling=2]="NoSampling"})(Uir||(_ie.SampleRate=Uir={}))});var Zje=y(Jje=>{"use strict";Object.defineProperty(Jje,"__esModule",{value:!0});Jje.configAzureTelemetryClient=sfi;function sfi(e){e.channel.setUseDiskRetryCaching(!0),e.addTelemetryProcessor(t=>(t.tags["ai.location.ip"]="0.0.0.0",t.tags["ai.cloud.roleInstance"]="masked",t.tags["ai.cloud.role"]="masked",t.tags["ai.device.type"]="masked",!0))}});var Bir=y((jha,cfi)=>{cfi.exports={name:"@sap-ux/telemetry",version:"0.6.42",description:"Library for sending usage telemetry data",repository:{type:"git",url:"https://github.com/SAP/open-ux-tools.git",directory:"packages/telemetry"},bugs:{url:"https://github.com/SAP/open-ux-tools/issues?q=is%3Aopen+is%3Aissue+label%3Abug+label%3Atelemetry"},license:"Apache-2.0",private:!1,main:"dist/index.js",scripts:{build:"tsc --build",watch:"tsc --watch",clean:"rimraf --glob dist coverage *.tsbuildinfo",format:"prettier --write '**/*.{js,json,ts,yaml,yml}' --ignore-path ../../.prettierignore",lint:"eslint . --ext .ts","lint:fix":"eslint . --ext .ts --fix",test:"jest --ci --forceExit --detectOpenHandles --colors","test-u":"jest --ci --forceExit --detectOpenHandles --colors -u",link:"pnpm link --global",unlink:"pnpm unlink --global",example:"ts-node example/index.ts"},dependencies:{"@sap-ux/store":"workspace:*","@sap-ux/project-access":"workspace:*","@sap-ux/btp-utils":"workspace:*","@sap-ux/ui5-config":"workspace:*","@sap-ux/logger":"workspace:*","@sap-ux/nodejs-utils":"workspace:*",applicationinsights:"2.9.8",axios:"1.12.2","performance-now":"2.1.0",yaml:"2.3.3"},devDependencies:{"jest-extended":"6.0.0",memfs:"3.4.13",unionfs:"4.4.0",dotenv:"16.3.1"},files:["dist","LICENSE","!dist/*.map","!dist/**/*.map"],engines:{node:">=20.x"}}});var oB=y(pR=>{"use strict";var ufi=pR&&pR.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(pR,"__esModule",{value:!0});pR.TelemetrySettings=void 0;var zir=ufi(Bir());pR.TelemetrySettings={azureInstrumentationKey:"",telemetryEnabled:!0,telemetryLibName:zir.default.name,telemetryLibVersion:zir.default.version,consumerModuleName:"",consumerModuleVersion:""}});var eqe=y(Fg=>{"use strict";var lfi=Fg&&Fg.__createBinding||(Object.create?function(e,t,r,n){n===void 0&&(n=r);var i=Object.getOwnPropertyDescriptor(t,r);(!i||("get"in i?!t.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,i)}:function(e,t,r,n){n===void 0&&(n=r),e[n]=t[r]}),pfi=Fg&&Fg.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e.default=t}),ffi=Fg&&Fg.__importStar||function(){var e=function(t){return e=Object.getOwnPropertyNames||function(r){var n=[];for(var i in r)Object.prototype.hasOwnProperty.call(r,i)&&(n[n.length]=i);return n},e(t)};return function(t){if(t&&t.__esModule)return t;var r={};if(t!=null)for(var n=e(t),i=0;i<n.length;i++)n[i]!=="default"&&lfi(r,t,n[i]);return pfi(r,t),r}}();Object.defineProperty(Fg,"__esModule",{value:!0});Fg.ApplicationInsightClient=void 0;var dfi=yke(),hfi=ffi(Wje()),mfi=Eie(),Mg=xie(),gfi=Zje(),Hir=oB(),Qje=class extends dfi.Client{clients;constructor(t,r,n){super(),this.clients=new Map,this.applicationKey=t,this.extensionVersion=n,this.extensionName=r;let i=this.createTelemetryClient(Mg.SampleRate.OnePercent),a=this.createTelemetryClient(Mg.SampleRate.TenPercent),o=this.createTelemetryClient(Mg.SampleRate.NoSampling);this.clients.set(Mg.SampleRate.OnePercent,i),this.clients.set(Mg.SampleRate.TenPercent,a),this.clients.set(Mg.SampleRate.NoSampling,o)}reportBlocking(t,r,n,i,a=!1){if(!a||Hir.TelemetrySettings.telemetryEnabled){let{client:o,event:s}=this.prepareClientAndEvent(t,r,n,i);return this.trackEventBlocking(o,s)}return Promise.resolve()}async report(t,r,n,i,a,o){if(o!==void 0&&!o||!Hir.TelemetrySettings.telemetryEnabled)return;let{client:s,event:c}=this.prepareClientAndEvent(t,r,n,i);this.trackEvent(s,c)}prepareClientAndEvent(t,r,n,i=Mg.SampleRate.NoSampling){let a=this.clients.get(i),s={name:new mfi.EventHeader(this.extensionName,t).toString(),properties:r,measurements:n};return{client:a,event:s}}async trackEventBlocking(t,r){return process.env.SAP_UX_FIORI_TOOLS_DISABLE_TELEMETRY==="true"?Promise.resolve():new Promise((n,i)=>{try{t.trackEvent(r),t.flush({callback:()=>n()})}catch(a){i(a)}})}trackEvent(t,r){return process.env.SAP_UX_FIORI_TOOLS_DISABLE_TELEMETRY!=="true"?(t.trackEvent(r),!0):!1}createTelemetryClient(t){let r;switch(t){case Mg.SampleRate.OnePercent:r=1;break;case Mg.SampleRate.TenPercent:r=10;break;case Mg.SampleRate.NoSampling:default:r=100;break}let n=new hfi.TelemetryClient(this.applicationKey);return n.config.samplingPercentage=r,(0,gfi.configAzureTelemetryClient)(n),n}};Fg.ApplicationInsightClient=Qje});var Gir=y(Tie=>{"use strict";Object.defineProperty(Tie,"__esModule",{value:!0});Tie.localDatetimeToUTC=void 0;var yfi=()=>{let e=new Date().getTime();return new Date(e).toISOString()};Tie.localDatetimeToUTC=yfi});var Wir=y(Oie=>{"use strict";Object.defineProperty(Oie,"__esModule",{value:!0});Oie.ToolsSuiteTelemetryClient=void 0;var vfi=eqe(),Kir=Sie(),Yir=Gir(),tqe=class extends vfi.ApplicationInsightClient{constructor(t,r,n){super(t,r,n)}async report(t,r,n,i,a,o){let s=await(0,Kir.processToolsSuiteTelemetry)(a),c={v:this.extensionVersion,datetime:(0,Yir.localDatetimeToUTC)()},u={...r,...s,...c};await super.report(t,u,n,i,a,o)}async reportEvent(t,r,n,i){let{finalProperties:a,finalMeasurements:o}=await this.collectToolsSuiteTelemetry(t,n);return super.report(t.eventName,a,o,r,n,i)}async reportEventBlocking(t,r,n,i){let{finalProperties:a,finalMeasurements:o}=await this.collectToolsSuiteTelemetry(t,n);return super.reportBlocking(t.eventName,a,o,r,i)}async collectToolsSuiteTelemetry(t,r){let n=await(0,Kir.processToolsSuiteTelemetry)(r),i={v:this.extensionVersion,datetime:(0,Yir.localDatetimeToUTC)()},a={...t.properties,...n,...i},o={...t.measurements};return{finalProperties:a,finalMeasurements:o}}};Oie.ToolsSuiteTelemetryClient=tqe});var Cn=y(Hs=>{"use strict";var rqe=Symbol.for("yaml.alias"),Xir=Symbol.for("yaml.document"),Aie=Symbol.for("yaml.map"),Jir=Symbol.for("yaml.pair"),nqe=Symbol.for("yaml.scalar"),Cie=Symbol.for("yaml.seq"),_b=Symbol.for("yaml.node.type"),bfi=e=>!!e&&typeof e=="object"&&e[_b]===rqe,Efi=e=>!!e&&typeof e=="object"&&e[_b]===Xir,_fi=e=>!!e&&typeof e=="object"&&e[_b]===Aie,xfi=e=>!!e&&typeof e=="object"&&e[_b]===Jir,Zir=e=>!!e&&typeof e=="object"&&e[_b]===nqe,Tfi=e=>!!e&&typeof e=="object"&&e[_b]===Cie;function Qir(e){if(e&&typeof e=="object")switch(e[_b]){case Aie:case Cie:return!0}return!1}function Ofi(e){if(e&&typeof e=="object")switch(e[_b]){case rqe:case Aie:case nqe:case Cie:return!0}return!1}var Sfi=e=>(Zir(e)||Qir(e))&&!!e.anchor;Hs.ALIAS=rqe;Hs.DOC=Xir;Hs.MAP=Aie;Hs.NODE_TYPE=_b;Hs.PAIR=Jir;Hs.SCALAR=nqe;Hs.SEQ=Cie;Hs.hasAnchor=Sfi;Hs.isAlias=bfi;Hs.isCollection=Qir;Hs.isDocument=Efi;Hs.isMap=_fi;Hs.isNode=Ofi;Hs.isPair=xfi;Hs.isScalar=Zir;Hs.isSeq=Tfi});var sB=y(iqe=>{"use strict";var qo=Cn(),Nl=Symbol("break visit"),ear=Symbol("skip children"),jg=Symbol("remove node");function wie(e,t){let r=tar(t);qo.isDocument(e)?fR(null,e.contents,r,Object.freeze([e]))===jg&&(e.contents=null):fR(null,e,r,Object.freeze([]))}wie.BREAK=Nl;wie.SKIP=ear;wie.REMOVE=jg;function fR(e,t,r,n){let i=rar(e,t,r,n);if(qo.isNode(i)||qo.isPair(i))return nar(e,n,i),fR(e,i,r,n);if(typeof i!="symbol"){if(qo.isCollection(t)){n=Object.freeze(n.concat(t));for(let a=0;a<t.items.length;++a){let o=fR(a,t.items[a],r,n);if(typeof o=="number")a=o-1;else{if(o===Nl)return Nl;o===jg&&(t.items.splice(a,1),a-=1)}}}else if(qo.isPair(t)){n=Object.freeze(n.concat(t));let a=fR("key",t.key,r,n);if(a===Nl)return Nl;a===jg&&(t.key=null);let o=fR("value",t.value,r,n);if(o===Nl)return Nl;o===jg&&(t.value=null)}}return i}async function Pie(e,t){let r=tar(t);qo.isDocument(e)?await dR(null,e.contents,r,Object.freeze([e]))===jg&&(e.contents=null):await dR(null,e,r,Object.freeze([]))}Pie.BREAK=Nl;Pie.SKIP=ear;Pie.REMOVE=jg;async function dR(e,t,r,n){let i=await rar(e,t,r,n);if(qo.isNode(i)||qo.isPair(i))return nar(e,n,i),dR(e,i,r,n);if(typeof i!="symbol"){if(qo.isCollection(t)){n=Object.freeze(n.concat(t));for(let a=0;a<t.items.length;++a){let o=await dR(a,t.items[a],r,n);if(typeof o=="number")a=o-1;else{if(o===Nl)return Nl;o===jg&&(t.items.splice(a,1),a-=1)}}}else if(qo.isPair(t)){n=Object.freeze(n.concat(t));let a=await dR("key",t.key,r,n);if(a===Nl)return Nl;a===jg&&(t.key=null);let o=await dR("value",t.value,r,n);if(o===Nl)return Nl;o===jg&&(t.value=null)}}return i}function tar(e){return typeof e=="object"&&(e.Collection||e.Node||e.Value)?Object.assign({Alias:e.Node,Map:e.Node,Scalar:e.Node,Seq:e.Node},e.Value&&{Map:e.Value,Scalar:e.Value,Seq:e.Value},e.Collection&&{Map:e.Collection,Seq:e.Collection},e):e}function rar(e,t,r,n){if(typeof r=="function")return r(e,t,n);if(qo.isMap(t))return r.Map?.(e,t,n);if(qo.isSeq(t))return r.Seq?.(e,t,n);if(qo.isPair(t))return r.Pair?.(e,t,n);if(qo.isScalar(t))return r.Scalar?.(e,t,n);if(qo.isAlias(t))return r.Alias?.(e,t,n)}function nar(e,t,r){let n=t[t.length-1];if(qo.isCollection(n))n.items[e]=r;else if(qo.isPair(n))e==="key"?n.key=r:n.value=r;else if(qo.isDocument(n))n.contents=r;else{let i=qo.isAlias(n)?"alias":"scalar";throw new Error(`Cannot replace node with ${i} parent`)}}iqe.visit=wie;iqe.visitAsync=Pie});var aqe=y(aar=>{"use strict";var iar=Cn(),Afi=sB(),Cfi={"!":"%21",",":"%2C","[":"%5B","]":"%5D","{":"%7B","}":"%7D"},wfi=e=>e.replace(/[!,[\]{}]/g,t=>Cfi[t]),cB=class e{constructor(t,r){this.docStart=null,this.docEnd=!1,this.yaml=Object.assign({},e.defaultYaml,t),this.tags=Object.assign({},e.defaultTags,r)}clone(){let t=new e(this.yaml,this.tags);return t.docStart=this.docStart,t}atDocument(){let t=new e(this.yaml,this.tags);switch(this.yaml.version){case"1.1":this.atNextDocument=!0;break;case"1.2":this.atNextDocument=!1,this.yaml={explicit:e.defaultYaml.explicit,version:"1.2"},this.tags=Object.assign({},e.defaultTags);break}return t}add(t,r){this.atNextDocument&&(this.yaml={explicit:e.defaultYaml.explicit,version:"1.1"},this.tags=Object.assign({},e.defaultTags),this.atNextDocument=!1);let n=t.trim().split(/[ \t]+/),i=n.shift();switch(i){case"%TAG":{if(n.length!==2&&(r(0,"%TAG directive should contain exactly two parts"),n.length<2))return!1;let[a,o]=n;return this.tags[a]=o,!0}case"%YAML":{if(this.yaml.explicit=!0,n.length!==1)return r(0,"%YAML directive should contain exactly one part"),!1;let[a]=n;if(a==="1.1"||a==="1.2")return this.yaml.version=a,!0;{let o=/^\d+\.\d+$/.test(a);return r(6,`Unsupported YAML version ${a}`,o),!1}}default:return r(0,`Unknown directive ${i}`,!0),!1}}tagName(t,r){if(t==="!")return"!";if(t[0]!=="!")return r(`Not a valid tag: ${t}`),null;if(t[1]==="<"){let o=t.slice(2,-1);return o==="!"||o==="!!"?(r(`Verbatim tags aren't resolved, so ${t} is invalid.`),null):(t[t.length-1]!==">"&&r("Verbatim tags must end with a >"),o)}let[,n,i]=t.match(/^(.*!)([^!]*)$/);i||r(`The ${t} tag has no suffix`);let a=this.tags[n];if(a)try{return a+decodeURIComponent(i)}catch(o){return r(String(o)),null}return n==="!"?t:(r(`Could not resolve tag: ${t}`),null)}tagString(t){for(let[r,n]of Object.entries(this.tags))if(t.startsWith(n))return r+wfi(t.substring(n.length));return t[0]==="!"?t:`!<${t}>`}toString(t){let r=this.yaml.explicit?[`%YAML ${this.yaml.version||"1.2"}`]:[],n=Object.entries(this.tags),i;if(t&&n.length>0&&iar.isNode(t.contents)){let a={};Afi.visit(t.contents,(o,s)=>{iar.isNode(s)&&s.tag&&(a[s.tag]=!0)}),i=Object.keys(a)}else i=[];for(let[a,o]of n)a==="!!"&&o==="tag:yaml.org,2002:"||(!t||i.some(s=>s.startsWith(o)))&&r.push(`%TAG ${a} ${o}`);return r.join(`
|
|
1477
|
+
`)}),u.length>0&&(u=u.substring(0,u.length-1)),u.length===0)return typeof r=="function"&&r("Empty batch of telemetry items. Nothing to send."),[2];l=Buffer.from?Buffer.from(u):new Buffer(u),upi.gzip(l,function(d,h){var m=h;d?(p._logWarn(Dl.dumpObj(d)),m=l,a.headers["Content-Length"]=l.length.toString()):(a.headers["Content-Encoding"]="gzip",a.headers["Content-Length"]=h.length.toString()),p._logInfo(Dl.dumpObj(a)),a[lpi.disableCollectionRequestOption]=!0;var v=+new Date,_=function(O){O.setEncoding("utf-8");var S="";O.on("data",function(A){S+=A}),O.on("end",function(){var A,P=+new Date,I=P-v;if(p._numConsecutiveFailures=0,S.includes(mpi)&&O.statusCode===400&&(Mje.warn("Instrumentation key was invalid, please check the iKey"),(A=p._shutdownStatsbeat)===null||A===void 0||A.call(p)),p._isStatsbeatSender&&!p._statsbeatHasReachedIngestionAtLeastOnce&&(hpi.includes(O.statusCode)?p._statsbeatHasReachedIngestionAtLeastOnce=!0:p._statsbeatFailedToIngest()),p._statsbeat&&(O.statusCode==dpi||O.statusCode==fpi?p._statsbeat.countThrottle(j_.StatsbeatNetworkCategory.Breeze,i,O.statusCode):p._statsbeat.countRequest(j_.StatsbeatNetworkCategory.Breeze,i,I,O.statusCode===200,O.statusCode)),p._enableDiskRetryMode){if(O.statusCode===200)p._resendTimer||(p._resendTimer=setTimeout(function(){p._resendTimer=null,p._sendFirstFileOnDisk()},p._resendInterval),p._resendTimer.unref());else if(p._isRetriable(O.statusCode))try{p._statsbeat&&p._statsbeat.countRetry(j_.StatsbeatNetworkCategory.Breeze,i,O.statusCode);var j=JSON.parse(S),k=[];j.errors&&(j.errors.forEach(function(B){(B.statusCode==429||B.statusCode==500||B.statusCode==503)&&k.push(t[B.index])}),k.length>0&&p._storeToDisk(k))}catch{p._storeToDisk(t)}}if(O.statusCode===307||O.statusCode===308)if(p._numConsecutiveRedirects++,p._numConsecutiveRedirects<10){var z=O.headers.location?O.headers.location.toString():null;z&&(p._redirectedHost=z,p.send(t,r))}else{var L={name:"Circular Redirect",message:"Error sending telemetry because of circular redirects."};p._statsbeat&&p._statsbeat.countException(j_.StatsbeatNetworkCategory.Breeze,i,L),typeof r=="function"&&r("Error sending telemetry because of circular redirects.")}else p._numConsecutiveRedirects=0,typeof r=="function"&&r(S),p._logInfo(S),typeof p._onSuccess=="function"&&p._onSuccess(S)})},T=Dl.makeRequest(p._config,n,a,_);T.setTimeout(e.HTTP_TIMEOUT,function(){p._requestTimedOut=!0,T.abort()}),T.on("error",function(O){if(p._isStatsbeatSender&&!p._statsbeatHasReachedIngestionAtLeastOnce&&p._statsbeatFailedToIngest(),p._numConsecutiveFailures++,p._statsbeat&&p._statsbeat.countException(j_.StatsbeatNetworkCategory.Breeze,i,O),!p._enableDiskRetryMode||p._numConsecutiveFailures>0&&p._numConsecutiveFailures%e.MAX_CONNECTION_FAILURES_BEFORE_WARN===0){var S="Ingestion endpoint could not be reached. This batch of telemetry items has been lost. Use Disk Retry Caching to enable resending of failed telemetry. Error:";p._enableDiskRetryMode&&(S="Ingestion endpoint could not be reached ".concat(p._numConsecutiveFailures," consecutive times. There may be resulting telemetry loss. Most recent error:")),p._logWarn(S,Dl.dumpObj(O))}else{var S="Transient failure to reach ingestion endpoint. This batch of telemetry items will be retried. Error:";p._logInfo(S,Dl.dumpObj(O))}p._onErrorHelper(O),typeof r=="function"&&(O?(p._requestTimedOut&&(O.name="telemetry timeout",O.message="telemetry request timed out"),r(Dl.dumpObj(O))):r("Error sending telemetry")),p._enableDiskRetryMode&&p._storeToDisk(t)}),T.write(m),T.end()}),f.label=5;case 5:return[2]}})})},e.prototype.saveOnCrash=function(t){this._enableDiskRetryMode&&this._storeToDiskSync(Dl.stringify(t))},e.prototype._isRetriable=function(t){return t===206||t===401||t===403||t===408||t===429||t===500||t===502||t===503||t===504},e.prototype._logInfo=function(t){for(var r=[],n=1;n<arguments.length;n++)r[n-1]=arguments[n];this._isStatsbeatSender||Mje.info(e.TAG,t,r)},e.prototype._logWarn=function(t){for(var r=[],n=1;n<arguments.length;n++)r[n-1]=arguments[n];this._isStatsbeatSender||Mje.warn(e.TAG,t,r)},e.prototype._statsbeatFailedToIngest=function(){this._shutdownStatsbeat&&(this._failedToIngestCounter++,this._failedToIngestCounter>=3&&this._shutdownStatsbeat())},e.prototype._storeToDisk=function(t){return fie(this,void 0,void 0,function(){var r,n,i,a,o,s,c;return die(this,function(u){switch(u.label){case 0:return u.trys.push([0,2,,3]),this._logInfo("Checking existence of data storage directory: "+this._tempDir),[4,bb.confirmDirExists(this._tempDir)];case 1:return u.sent(),[3,3];case 2:return r=u.sent(),this._logWarn("Failed to create folder to put telemetry: "+Dl.dumpObj(r)),this._onErrorHelper(r),[2];case 3:return u.trys.push([3,5,,6]),[4,XU.FileAccessControl.applyACLRules(this._tempDir)];case 4:return u.sent(),[3,6];case 5:return n=u.sent(),this._logWarn("Failed to apply file access control to folder: "+Dl.dumpObj(n)),this._onErrorHelper(n),[2];case 6:return u.trys.push([6,8,,9]),[4,bb.getShallowDirectorySize(this._tempDir)];case 7:return i=u.sent(),i>this._maxBytesOnDisk?(this._logWarn("Not saving data due to max size limit being met. Directory size in bytes is: "+i),[2]):[3,9];case 8:return a=u.sent(),this._logWarn("Failed to read directory for retriable telemetry: "+Dl.dumpObj(a)),this._onErrorHelper(a),[2];case 9:return u.trys.push([9,11,,12]),o="".concat(new Date().getTime(),".ai.json"),s=ES.join(this._tempDir,o),this._logInfo("saving data to disk at: "+s),[4,bb.writeFileAsync(s,Dl.stringify(t),{mode:384})];case 10:return u.sent(),[3,12];case 11:return c=u.sent(),this._logWarn("Failed to persist telemetry to disk: "+Dl.dumpObj(c)),this._onErrorHelper(c),[2];case 12:return[2]}})})},e.prototype._storeToDiskSync=function(t){try{this._logInfo("Checking existence of data storage directory: "+this._tempDir),$je.existsSync(this._tempDir)||$je.mkdirSync(this._tempDir),XU.FileAccessControl.applyACLRulesSync(this._tempDir);var r=bb.getShallowDirectorySizeSync(this._tempDir);if(r>this._maxBytesOnDisk){this._logInfo("Not saving data due to max size limit being met. Directory size in bytes is: "+r);return}var n="".concat(new Date().getTime(),".ai.json"),i=ES.join(this._tempDir,n);this._logInfo("saving data before crash to disk at: "+i),$je.writeFileSync(i,t,{mode:384})}catch(a){this._logWarn("Error while saving data to disk: "+Dl.dumpObj(a)),this._onErrorHelper(a)}},e.prototype._sendFirstFileOnDisk=function(){return fie(this,void 0,void 0,function(){var t,r,n,i,a,o;return die(this,function(s){switch(s.label){case 0:return s.trys.push([0,6,,7]),[4,bb.readdirAsync(this._tempDir)];case 1:return t=s.sent(),t=t.filter(function(c){return ES.basename(c).indexOf(".ai.json")>-1}),t.length>0?(r=t[0],n=ES.join(this._tempDir,r),[4,bb.readFileAsync(n)]):[3,5];case 2:return i=s.sent(),[4,bb.unlinkAsync(n)];case 3:return s.sent(),a=JSON.parse(i.toString()),[4,this.send(a)];case 4:s.sent(),s.label=5;case 5:return[3,7];case 6:return o=s.sent(),this._onErrorHelper(o),[3,7];case 7:return[2]}})})},e.prototype._onErrorHelper=function(t){typeof this._onError=="function"&&this._onError(t)},e.prototype._fileCleanupTask=function(){return fie(this,void 0,void 0,function(){var t,r,n,i,a,o,s=this;return die(this,function(c){switch(c.label){case 0:return c.trys.push([0,6,,7]),[4,bb.readdirAsync(this._tempDir)];case 1:if(t=c.sent(),t=t.filter(function(u){return ES.basename(u).indexOf(".ai.json")>-1}),!(t.length>0))return[3,5];r=0,c.label=2;case 2:return r<t.length?(n=new Date(parseInt(t[r].split(".ai.json")[0])),i=new Date(+new Date-e.FILE_RETEMPTION_PERIOD)>n,i?(a=ES.join(this._tempDir,t[r]),[4,bb.unlinkAsync(a).catch(function(u){s._onErrorHelper(u)})]):[3,4]):[3,5];case 3:c.sent(),c.label=4;case 4:return r++,[3,2];case 5:return[3,7];case 6:return o=c.sent(),o.code!="ENOENT"&&this._onErrorHelper(o),[3,7];case 7:return[2]}})})},e.TAG="Sender",e.WAIT_BETWEEN_RESEND=60*1e3,e.MAX_BYTES_ON_DISK=50*1024*1024,e.MAX_CONNECTION_FAILURES_BEFORE_WARN=5,e.CLEANUP_TIMEOUT=60*60*1e3,e.FILE_RETEMPTION_PERIOD=7*24*60*60*1e3,e.TEMPDIR_PREFIX="appInsights-node",e.HTTP_TIMEOUT=2e4,e}();xir.exports=gpi});var Oir=y(hie=>{"use strict";Object.defineProperty(hie,"__esModule",{value:!0});hie.AzureVirtualMachine=void 0;var Tir=li(),ypi=qs(),vpi=FI(),bpi="http://169.254.169.254/metadata/instance/compute",Epi="api-version=2017-12-01",_pi="format=json",xpi="UNREACH",Tpi=function(){function e(){}return e.getAzureComputeMetadata=function(t,r){var n,i=this,a={},o="".concat(bpi,"?").concat(Epi,"&").concat(_pi),s=(n={method:"GET"},n[vpi.disableCollectionRequestOption]=!0,n.headers={Metadata:"True"},n),c=ypi.makeRequest(t,o,s,function(u){if(u.statusCode===200){a.isVM=!0;var l="";u.on("data",function(p){l+=p}),u.on("end",function(){try{var p=JSON.parse(l);a.id=p.vmId||"",a.subscriptionId=p.subscriptionId||"",a.osType=p.osType||""}catch(f){Tir.info(e.TAG,f)}r(a)})}else r(a)},!1,!1);c&&(setTimeout(function(){i._requestTimedOut=!0,c.abort()},e.HTTP_TIMEOUT),c.on("error",function(u){i._requestTimedOut&&u&&(u.name="telemetry timeout",u.message="telemetry request timed out"),u&&u.message&&u.message.indexOf(xpi)>-1?a.isVM=!1:Tir.info(e.TAG,u),r(a)}),c.end())},e.HTTP_TIMEOUT=2500,e.TAG="AzureVirtualMachine",e}();hie.AzureVirtualMachine=Tpi});var Sir=y(mie=>{"use strict";Object.defineProperty(mie,"__esModule",{value:!0});mie.NetworkStatsbeat=void 0;var Opi=function(){function e(t,r){this.endpoint=t,this.host=r,this.totalRequestCount=0,this.totalSuccesfulRequestCount=0,this.totalFailedRequestCount=[],this.retryCount=[],this.exceptionCount=[],this.throttleCount=[],this.intervalRequestExecutionTime=0,this.lastIntervalRequestExecutionTime=0,this.lastTime=+new Date,this.lastRequestCount=0}return e}();mie.NetworkStatsbeat=Opi});var Dir=y((_S,Pir)=>{"use strict";var $g=_S&&_S.__assign||function(){return $g=Object.assign||function(e){for(var t,r=1,n=arguments.length;r<n;r++){t=arguments[r];for(var i in t)Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i])}return e},$g.apply(this,arguments)},jje=_S&&_S.__awaiter||function(e,t,r,n){function i(a){return a instanceof r?a:new r(function(o){o(a)})}return new(r||(r=Promise))(function(a,o){function s(l){try{u(n.next(l))}catch(p){o(p)}}function c(l){try{u(n.throw(l))}catch(p){o(p)}}function u(l){l.done?a(l.value):i(l.value).then(s,c)}u((n=n.apply(e,t||[])).next())})},qje=_S&&_S.__generator||function(e,t){var r={label:0,sent:function(){if(a[0]&1)throw a[1];return a[1]},trys:[],ops:[]},n,i,a,o;return o={next:s(0),throw:s(1),return:s(2)},typeof Symbol=="function"&&(o[Symbol.iterator]=function(){return this}),o;function s(u){return function(l){return c([u,l])}}function c(u){if(n)throw new TypeError("Generator is already executing.");for(;o&&(o=0,u[0]&&(r=0)),r;)try{if(n=1,i&&(a=u[0]&2?i.return:u[0]?i.throw||((a=i.return)&&a.call(i),0):i.next)&&!(a=a.call(i,u[1])).done)return a;switch(i=0,a&&(u=[u[0]&2,a.value]),u[0]){case 0:case 1:a=u;break;case 4:return r.label++,{value:u[1],done:!1};case 5:r.label++,i=u[1],u=[0];continue;case 7:u=r.ops.pop(),r.trys.pop();continue;default:if(a=r.trys,!(a=a.length>0&&a[a.length-1])&&(u[0]===6||u[0]===2)){r=0;continue}if(u[0]===3&&(!a||u[1]>a[0]&&u[1]<a[3])){r.label=u[1];break}if(u[0]===6&&r.label<a[1]){r.label=a[1],a=u;break}if(a&&r.label<a[2]){r.label=a[2],r.ops.push(u);break}a[2]&&r.ops.pop(),r.trys.pop();continue}u=t.call(e,r)}catch(l){u=[6,l],i=0}finally{n=a=0}if(u[0]&5)throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}},Spi=require("os"),Api=kje(),Air=li(),Cpi=Fje(),zi=Ui(),wpi=Mc(),Ppi=Oir(),Dpi=bFe(),Cir=NI(),Npi=Sir(),wir=qs(),Ipi="node",Rpi=function(){function e(t,r){this._attach=zi.StatsbeatAttach.sdk,this._feature=zi.StatsbeatFeature.NONE,this._instrumentation=zi.StatsbeatInstrumentation.NONE,this._isInitialized=!1,this._statbeatMetrics=[],this._networkStatsbeatCollection=[],this._config=t,this._context=r||new Cir,this._longHandleTimeout=null;var n=this._getConnectionString(t);this._statsbeatConfig=new Dpi(n),this._statsbeatConfig.samplingPercentage=100,this._sender=new Cpi(this._statsbeatConfig,null,null,null,null,!0,this._shutdownStatsbeat.bind(this))}return e.prototype.enable=function(t){var r=this;this._isEnabled=t,this._isEnabled&&!this._isInitialized&&(this._getCustomProperties(),this._isInitialized=!0),t?(this._handle||(this._handle=setInterval(function(){r.trackShortIntervalStatsbeats()},e.STATS_COLLECTION_SHORT_INTERVAL),this._handle.unref()),this._longHandle||(this._longHandleTimeout=setTimeout(function(){r.isEnabled()&&r.trackLongIntervalStatsbeats()},e.STATS_COLLECTION_INITIAL_DELAY),this._longHandleTimeout.unref(),this._longHandle=setInterval(function(){r.trackLongIntervalStatsbeats()},e.STATS_COLLECTION_LONG_INTERVAL),this._longHandle.unref())):(this._handle&&(clearInterval(this._handle),this._handle=null),this._longHandle&&(clearInterval(this._longHandle),this._longHandle=null),this._longHandleTimeout&&(clearTimeout(this._longHandleTimeout),this._longHandleTimeout=null))},e.prototype.isInitialized=function(){return this._isInitialized},e.prototype.isEnabled=function(){return this._isEnabled},e.prototype.setCodelessAttach=function(){this._attach=zi.StatsbeatAttach.codeless},e.prototype.addFeature=function(t){this._feature|=t},e.prototype.removeFeature=function(t){this._feature&=~t},e.prototype.addInstrumentation=function(t){this._instrumentation|=t},e.prototype.removeInstrumentation=function(t){this._instrumentation&=~t},e.prototype.countRequest=function(t,r,n,i,a){if(this.isEnabled()){var o=this._getNetworkStatsbeatCounter(t,r);if(o.totalRequestCount++,o.intervalRequestExecutionTime+=n,i===!1){if(!a)return;var s=o.totalFailedRequestCount.find(function(c){return a===c.statusCode});s?s.count++:o.totalFailedRequestCount.push({statusCode:a,count:1})}else o.totalSuccesfulRequestCount++}},e.prototype.countException=function(t,r,n){if(this.isEnabled()){var i=this._getNetworkStatsbeatCounter(t,r),a=i.exceptionCount.find(function(o){return n.name===o.exceptionType});a?a.count++:i.exceptionCount.push({exceptionType:n.name,count:1})}},e.prototype.countThrottle=function(t,r,n){if(this.isEnabled()){var i=this._getNetworkStatsbeatCounter(t,r),a=i.throttleCount.find(function(o){return n===o.statusCode});a?a.count++:i.throttleCount.push({statusCode:n,count:1})}},e.prototype.countRetry=function(t,r,n){if(this.isEnabled()){var i=this._getNetworkStatsbeatCounter(t,r),a=i.retryCount.find(function(o){return n===o.statusCode});a?a.count++:i.retryCount.push({statusCode:n,count:1})}},e.prototype.trackShortIntervalStatsbeats=function(){return jje(this,void 0,void 0,function(){var t,r;return qje(this,function(n){switch(n.label){case 0:return n.trys.push([0,3,,4]),[4,this._getResourceProvider()];case 1:return n.sent(),t={os:this._os,rp:this._resourceProvider,cikey:this._cikey,runtimeVersion:this._runtimeVersion,language:this._language,version:this._sdkVersion,attach:this._attach},this._trackRequestDuration(t),this._trackRequestsCount(t),[4,this._sendStatsbeats()];case 2:return n.sent(),[3,4];case 3:return r=n.sent(),Air.info(e.TAG,"Failed to send Statsbeat metrics: "+wir.dumpObj(r)),[3,4];case 4:return[2]}})})},e.prototype.trackLongIntervalStatsbeats=function(){return jje(this,void 0,void 0,function(){var t,r,n,i,a;return qje(this,function(o){switch(o.label){case 0:return o.trys.push([0,3,,4]),[4,this._getResourceProvider()];case 1:return o.sent(),t={os:this._os,rp:this._resourceProvider,cikey:this._cikey,runtimeVersion:this._runtimeVersion,language:this._language,version:this._sdkVersion,attach:this._attach},r=Object.assign({rpId:this._resourceIdentifier},t),this._statbeatMetrics.push({name:zi.StatsbeatCounter.ATTACH,value:1,properties:r}),this._instrumentation!=zi.StatsbeatInstrumentation.NONE&&(n=Object.assign({feature:this._instrumentation,type:zi.StatsbeatFeatureType.Instrumentation},t),this._statbeatMetrics.push({name:zi.StatsbeatCounter.FEATURE,value:1,properties:n})),this._feature!=zi.StatsbeatFeature.NONE&&(i=Object.assign({feature:this._feature,type:zi.StatsbeatFeatureType.Feature},t),this._statbeatMetrics.push({name:zi.StatsbeatCounter.FEATURE,value:1,properties:i})),[4,this._sendStatsbeats()];case 2:return o.sent(),[3,4];case 3:return a=o.sent(),Air.info(e.TAG,"Failed to send Statsbeat metrics: "+wir.dumpObj(a)),[3,4];case 4:return[2]}})})},e.prototype._getNetworkStatsbeatCounter=function(t,r){for(var n=this._getShortHost(r),i=0;i<this._networkStatsbeatCollection.length;i++)if(t===this._networkStatsbeatCollection[i].endpoint&&n===this._networkStatsbeatCollection[i].host)return this._networkStatsbeatCollection[i];var a=new Npi.NetworkStatsbeat(t,n);return this._networkStatsbeatCollection.push(a),a},e.prototype._trackRequestDuration=function(t){for(var r=0;r<this._networkStatsbeatCollection.length;r++){var n=this._networkStatsbeatCollection[r];n.time=+new Date;var i=n.totalRequestCount-n.lastRequestCount||0,a=n.intervalRequestExecutionTime-n.lastIntervalRequestExecutionTime,o=a>0&&a/i||0;if(n.lastIntervalRequestExecutionTime=n.intervalRequestExecutionTime,i>0){var s=Object.assign({endpoint:this._networkStatsbeatCollection[r].endpoint,host:this._networkStatsbeatCollection[r].host},t);this._statbeatMetrics.push({name:zi.StatsbeatCounter.REQUEST_DURATION,value:o,properties:s})}n.lastRequestCount=n.totalRequestCount,n.lastTime=n.time}},e.prototype._getShortHost=function(t){var r=t;try{var n=new RegExp(/^https?:\/\/(?:www\.)?([^\/.-]+)/),i=n.exec(t);i!=null&&i.length>1&&(r=i[1]),r=r.replace(".in.applicationinsights.azure.com","")}catch{}return r},e.prototype._trackRequestsCount=function(t){for(var r=this,n=function(s){a=i._networkStatsbeatCollection[s];var c=Object.assign({endpoint:a.endpoint,host:a.host},t);a.totalSuccesfulRequestCount>0&&(i._statbeatMetrics.push({name:zi.StatsbeatCounter.REQUEST_SUCCESS,value:a.totalSuccesfulRequestCount,properties:c}),a.totalSuccesfulRequestCount=0),a.totalFailedRequestCount.length>0&&(a.totalFailedRequestCount.forEach(function(u){c=Object.assign($g($g({},c),{statusCode:u.statusCode})),r._statbeatMetrics.push({name:zi.StatsbeatCounter.REQUEST_FAILURE,value:u.count,properties:c})}),a.totalFailedRequestCount=[]),a.retryCount.length>0&&(a.retryCount.forEach(function(u){c=Object.assign($g($g({},c),{statusCode:u.statusCode})),r._statbeatMetrics.push({name:zi.StatsbeatCounter.RETRY_COUNT,value:u.count,properties:c})}),a.retryCount=[]),a.throttleCount.length>0&&(a.throttleCount.forEach(function(u){c=Object.assign($g($g({},c),{statusCode:u.statusCode})),r._statbeatMetrics.push({name:zi.StatsbeatCounter.THROTTLE_COUNT,value:u.count,properties:c})}),a.throttleCount=[]),a.exceptionCount.length>0&&(a.exceptionCount.forEach(function(u){c=Object.assign($g($g({},c),{exceptionType:u.exceptionType})),r._statbeatMetrics.push({name:zi.StatsbeatCounter.EXCEPTION_COUNT,value:u.count,properties:c})}),a.exceptionCount=[])},i=this,a,o=0;o<this._networkStatsbeatCollection.length;o++)n(o)},e.prototype._sendStatsbeats=function(){return jje(this,void 0,void 0,function(){var t,r,n,i;return qje(this,function(a){switch(a.label){case 0:if(!(this._statbeatMetrics.length>0))return[3,2];for(t=[],r=0;r<this._statbeatMetrics.length;r++)n={name:this._statbeatMetrics[r].name,value:this._statbeatMetrics[r].value,properties:this._statbeatMetrics[r].properties},i=Api.createEnvelope(n,wpi.TelemetryType.Metric,null,this._context,this._statsbeatConfig),i.name=zi.StatsbeatTelemetryName,t.push(i);return this._statbeatMetrics=[],[4,this._sender.send(t)];case 1:a.sent(),a.label=2;case 2:return[2]}})})},e.prototype._getCustomProperties=function(){this._language=Ipi,this._cikey=this._config.instrumentationKey,this._sdkVersion=Cir.sdkVersion,this._os=Spi.type(),this._runtimeVersion=process.version},e.prototype._getResourceProvider=function(){var t=this;return new Promise(function(r,n){var i=!1;t._resourceProvider=zi.StatsbeatResourceProvider.unknown,t._resourceIdentifier=zi.StatsbeatResourceProvider.unknown,process.env.AKS_ARM_NAMESPACE_ID?(t._resourceProvider=zi.StatsbeatResourceProvider.aks,t._resourceIdentifier=process.env.AKS_ARM_NAMESPACE_ID):process.env.WEBSITE_SITE_NAME?(t._resourceProvider=zi.StatsbeatResourceProvider.appsvc,t._resourceIdentifier=process.env.WEBSITE_SITE_NAME,process.env.WEBSITE_HOME_STAMPNAME&&(t._resourceIdentifier+="/"+process.env.WEBSITE_HOME_STAMPNAME)):process.env.FUNCTIONS_WORKER_RUNTIME?(t._resourceProvider=zi.StatsbeatResourceProvider.functions,process.env.WEBSITE_HOSTNAME&&(t._resourceIdentifier=process.env.WEBSITE_HOSTNAME)):t._config&&(t._isVM===void 0||t._isVM==!0?(i=!0,Ppi.AzureVirtualMachine.getAzureComputeMetadata(t._config,function(a){t._isVM=a.isVM,t._isVM&&(t._resourceProvider=zi.StatsbeatResourceProvider.vm,t._resourceIdentifier=a.id+"/"+a.subscriptionId,a.osType&&(t._os=a.osType)),r()})):t._resourceProvider=zi.StatsbeatResourceProvider.unknown),i||r()})},e.prototype._shutdownStatsbeat=function(){this.enable(!1)},e.prototype._getConnectionString=function(t){for(var r=t.endpointUrl,n=["westeurope","northeurope","francecentral","francesouth","germanywestcentral","norwayeast","norwaywest","swedencentral","switzerlandnorth","switzerlandwest","uksouth","ukwest"],i=0;i<n.length;i++)if(r.indexOf(n[i])>-1)return e.EU_CONNECTION_STRING;return e.NON_EU_CONNECTION_STRING},e.NON_EU_CONNECTION_STRING="InstrumentationKey=c4a29126-a7cb-47e5-b348-11414998b11e;IngestionEndpoint=https://westus-0.in.applicationinsights.azure.com",e.EU_CONNECTION_STRING="InstrumentationKey=7dc56bab-3c0c-4e9f-9ebb-d1acadee8d0f;IngestionEndpoint=https://westeurope-5.in.applicationinsights.azure.com",e.STATS_COLLECTION_SHORT_INTERVAL=9e5,e.STATS_COLLECTION_LONG_INTERVAL=864e5,e.STATS_COLLECTION_INITIAL_DELAY=15e3,e.TAG="Statsbeat",e}();Pir.exports=Rpi});var Rir=y((Rha,Iir)=>{"use strict";var Lpi=require("url"),kpi=bFe(),$pi=cir(),Mpi=NI(),Eb=Mc(),Fpi=lir(),Vje=yir(),Nir=w_(),jpi=Dir(),qpi=Fje(),Uje=qs(),gie=li(),Vpi=kje(),Upi=function(){function e(t){this._telemetryProcessors=[];var r=new kpi(t);if(this.config=r,!this.config.instrumentationKey||this.config.instrumentationKey=="")throw new Error("Instrumentation key not found, please provide a connection string before starting Application Insights SDK.");this.context=new Mpi,this.commonProperties={},this.authorizationHandler=null,this.config.disableStatsbeat||(this._statsbeat=new jpi(this.config,this.context),this._statsbeat.enable(!0));var n=new qpi(this.config,this.getAuthorizationHandler,null,null,this._statsbeat);this.channel=new Fpi(function(){return r.disableAppInsights},function(){return r.maxBatchSize},function(){return r.maxBatchIntervalMs},n)}return e.prototype.trackAvailability=function(t){this.track(t,Eb.TelemetryType.Availability)},e.prototype.trackPageView=function(t){this.track(t,Eb.TelemetryType.PageView)},e.prototype.trackTrace=function(t){this.track(t,Eb.TelemetryType.Trace)},e.prototype.trackMetric=function(t){this.track(t,Eb.TelemetryType.Metric)},e.prototype.trackException=function(t){t&&t.exception&&!Uje.isError(t.exception)&&(t.exception=new Error(t.exception.toString())),this.track(t,Eb.TelemetryType.Exception)},e.prototype.trackEvent=function(t){this.track(t,Eb.TelemetryType.Event)},e.prototype.trackRequest=function(t){this.track(t,Eb.TelemetryType.Request)},e.prototype.trackDependency=function(t){if(t&&!t.target&&t.data)try{t.target=new Lpi.URL(t.data).host}catch(r){t.target=null,gie.warn(e.TAG,"The URL object is failed to create.",r)}this.track(t,Eb.TelemetryType.Dependency)},e.prototype.flush=function(t){this.channel.triggerSend(t?!!t.isAppCrashing:!1,t?t.callback:void 0)},e.prototype.track=function(t,r){if(t&&Eb.telemetryTypeToBaseType(r)){var n=Vpi.createEnvelope(t,r,this.commonProperties,this.context,this.config);t.time&&(n.time=t.time.toISOString());var i=this.runTelemetryProcessors(n,t.contextObjects);i=i&&Vje.samplingTelemetryProcessor(n,{correlationContext:Nir.CorrelationContextManager.getCurrentContext()}),Vje.preAggregatedMetricsTelemetryProcessor(n,this.context),i&&(Vje.performanceMetricsTelemetryProcessor(n,this.quickPulseClient),this.channel.send(n))}else gie.warn(e.TAG,"track() requires telemetry object and telemetryType to be specified.")},e.prototype.setAutoPopulateAzureProperties=function(t){},e.prototype.getAuthorizationHandler=function(t){return t&&t.aadTokenCredential?(this.authorizationHandler||(gie.info(e.TAG,"Adding authorization handler"),this.authorizationHandler=new $pi(t.aadTokenCredential,t.aadAudience)),this.authorizationHandler):null},e.prototype.addTelemetryProcessor=function(t){this._telemetryProcessors.push(t)},e.prototype.clearTelemetryProcessors=function(){this._telemetryProcessors=[]},e.prototype.runTelemetryProcessors=function(t,r){var n=!0,i=this._telemetryProcessors.length;if(i===0)return n;r=r||{},r.correlationContext=Nir.CorrelationContextManager.getCurrentContext();for(var a=0;a<i;++a)try{var o=this._telemetryProcessors[a];if(o&&o.apply(null,[t,r])===!1){n=!1;break}}catch(s){n=!0,gie.warn(e.TAG,"One of telemetry processors failed, telemetry item will be sent.",s,t)}return n&&(t&&t.tags&&(t.tags=Uje.validateStringMap(t.tags)),t&&t.data&&t.data.baseData&&t.data.baseData.properties&&(t.data.baseData.properties=Uje.validateStringMap(t.data.baseData.properties))),n},e.prototype.getStatsbeat=function(){return this._statsbeat},e.TAG="TelemetryClient",e}();Iir.exports=Upi});var $ir=y((Bje,kir)=>{"use strict";var Bpi=Bje&&Bje.__extends||function(){var e=function(t,r){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,i){n.__proto__=i}||function(n,i){for(var a in i)Object.prototype.hasOwnProperty.call(i,a)&&(n[a]=i[a])},e(t,r)};return function(t,r){if(typeof r!="function"&&r!==null)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");e(t,r);function n(){this.constructor=t}t.prototype=r===null?Object.create(r):(n.prototype=r.prototype,new n)}}(),zpi=Rir(),Lir=fFe(),Hpi=FI(),yie=li(),Gpi=function(e){Bpi(t,e);function t(){return e!==null&&e.apply(this,arguments)||this}return t.prototype.trackNodeHttpRequestSync=function(r){r&&r.request&&r.response&&r.duration?Lir.trackRequestSync(this,r):yie.warn("trackNodeHttpRequestSync requires NodeHttpRequestTelemetry object with request, response and duration specified.")},t.prototype.trackNodeHttpRequest=function(r){(r.duration||r.error)&&yie.warn("trackNodeHttpRequest will ignore supplied duration and error parameters. These values are collected from the request and response objects."),r&&r.request&&r.response?Lir.trackRequest(this,r):yie.warn("trackNodeHttpRequest requires NodeHttpRequestTelemetry object with request and response specified.")},t.prototype.trackNodeHttpDependency=function(r){r&&r.request?Hpi.trackRequest(this,r):yie.warn("trackNodeHttpDependency requires NodeHttpDependencyTelemetry object with request specified.")},t}(zpi);kir.exports=Gpi});var Fir=y(Mir=>{"use strict";Object.defineProperty(Mir,"__esModule",{value:!0})});var Wje=y(oe=>{"use strict";Object.defineProperty(oe,"__esModule",{value:!0});oe.Configuration=oe.liveMetricsClient=oe.defaultClient=oe.DistributedTracingModes=void 0;oe.setup=tfi;oe.start=Vir;oe.getCorrelationContext=nfi;oe.startOperation=ifi;oe.wrapWithCorrelationContext=afi;oe.dispose=ofi;var Hje=w_(),Kpi=Ier(),Ypi=Ler(),Gje=dne(),Wpi=ZMe(),Xpi=zer(),Jpi=ttr(),Zpi=FI(),Qpi=fFe(),jir=X1(),ZU=li(),qir=ktr(),Kje=Mtr(),efi=qtr();oe.TelemetryClient=$ir();oe.Contracts=Mc();oe.azureFunctionsTypes=Fir();var zje;(function(e){e[e.AI=0]="AI",e[e.AI_AND_W3C=1]="AI_AND_W3C"})(zje||(oe.DistributedTracingModes=zje={}));var QU,eB,tB,rB,nB,uR,lR,xS,iB,aB,Ip=!1,vie;function tfi(e){return oe.defaultClient?ZU.info("The default client is already setup"):(oe.defaultClient=new oe.TelemetryClient(e),QU=new Kpi(oe.defaultClient),eB=new Ypi(oe.defaultClient),tB=new Gje(oe.defaultClient),rB=new Wpi(oe.defaultClient),nB=new Xpi(oe.defaultClient),uR=new Jpi(oe.defaultClient),xS=new Qpi(oe.defaultClient),iB=new Zpi(oe.defaultClient),lR||(lR=new Kje.AutoCollectNativePerformance(oe.defaultClient)),aB=new efi.AzureFunctionsHook(oe.defaultClient)),Yje}function rfi(){oe.defaultClient&&(oe.defaultClient.config.enableAutoCollectExternalLoggers==null&&(oe.defaultClient.config.enableAutoCollectExternalLoggers=!0),oe.defaultClient.config.enableAutoCollectConsole==null&&(oe.defaultClient.config.enableAutoCollectConsole=!1),oe.defaultClient.config.enableAutoCollectExceptions==null&&(oe.defaultClient.config.enableAutoCollectExceptions=!0),oe.defaultClient.config.enableAutoCollectPerformance==null&&(oe.defaultClient.config.enableAutoCollectPerformance=!0),oe.defaultClient.config.enableAutoCollectPreAggregatedMetrics==null&&(oe.defaultClient.config.enableAutoCollectPreAggregatedMetrics=!0),oe.defaultClient.config.enableAutoCollectHeartbeat==null&&(oe.defaultClient.config.enableAutoCollectHeartbeat=!0),oe.defaultClient.config.enableAutoCollectRequests==null&&(oe.defaultClient.config.enableAutoCollectRequests=!0),oe.defaultClient.config.enableAutoCollectDependencies==null&&(oe.defaultClient.config.enableAutoCollectDependencies=!0),oe.defaultClient.config.enableUseDiskRetryCaching==null&&(oe.defaultClient.config.enableUseDiskRetryCaching=!0),oe.defaultClient.config.enableAutoDependencyCorrelation==null&&(oe.defaultClient.config.enableAutoDependencyCorrelation=!0),oe.defaultClient.config.enableSendLiveMetrics==null&&(oe.defaultClient.config.enableSendLiveMetrics=!1),oe.defaultClient.config.enableAutoCollectExtendedMetrics==null&&(oe.defaultClient.config.enableAutoCollectExtendedMetrics=!0),oe.defaultClient.config.enableWebInstrumentation==null&&(oe.defaultClient.config.enableWebInstrumentation=!1),oe.defaultClient.config.enableAutoCollectIncomingRequestAzureFunctions==null&&(oe.defaultClient.config.enableAutoCollectIncomingRequestAzureFunctions=!1))}function Vir(){if(oe.defaultClient){Ip=!0,rfi(),QU.enable(oe.defaultClient.config.enableAutoCollectExternalLoggers,oe.defaultClient.config.enableAutoCollectConsole),eB.enable(oe.defaultClient.config.enableAutoCollectExceptions),tB.enable(oe.defaultClient.config.enableAutoCollectPerformance),rB.enable(oe.defaultClient.config.enableAutoCollectPreAggregatedMetrics),nB.enable(oe.defaultClient.config.enableAutoCollectHeartbeat),xS.useAutoCorrelation(oe.defaultClient.config.enableAutoDependencyCorrelation,oe.defaultClient.config.enableUseAsyncHooks),xS.enable(oe.defaultClient.config.enableAutoCollectRequests),iB.enable(oe.defaultClient.config.enableAutoCollectDependencies),uR.enable(oe.defaultClient.config.enableWebInstrumentation,oe.defaultClient.config.webInstrumentationConnectionString),oe.defaultClient.config.enableSendLiveMetrics&&(oe.liveMetricsClient||(oe.liveMetricsClient=new qir(oe.defaultClient.config,oe.defaultClient.context,oe.defaultClient.getAuthorizationHandler,oe.defaultClient),vie=new Gje(oe.liveMetricsClient,1e3,!0),oe.liveMetricsClient.addCollector(vie),oe.defaultClient.quickPulseClient=oe.liveMetricsClient),oe.liveMetricsClient.enable(oe.defaultClient.config.enableSendLiveMetrics)),aB.enable(oe.defaultClient.config.enableAutoCollectIncomingRequestAzureFunctions);var e=Kje.AutoCollectNativePerformance.parseEnabled(oe.defaultClient.config.enableAutoCollectExtendedMetrics,oe.defaultClient.config);lR.enable(oe.defaultClient.config.enableAutoCollectExtendedMetrics,e.disabledMetrics),oe.defaultClient&&oe.defaultClient.channel&&oe.defaultClient.channel.setUseDiskRetryCaching(oe.defaultClient.config.enableUseDiskRetryCaching,oe.defaultClient.config.enableResendInterval,oe.defaultClient.config.enableMaxBytesOnDisk)}else ZU.warn("Start cannot be called before setup");return Yje}function nfi(){return Hje.CorrelationContextManager.getCurrentContext()}function ifi(e,t){return Hje.CorrelationContextManager.startOperation(e,t)}function afi(e,t){return Hje.CorrelationContextManager.wrapCallback(e,t)}var Yje=function(){function e(){}return e.setDistributedTracingMode=function(t){return jir.w3cEnabled=t===zje.AI_AND_W3C,e},e.setAutoCollectConsole=function(t,r){return r===void 0&&(r=!1),oe.defaultClient&&(oe.defaultClient.config.enableAutoCollectExternalLoggers=t,oe.defaultClient.config.enableAutoCollectConsole=r,Ip&&QU.enable(t,r)),e},e.setAutoCollectExceptions=function(t){return oe.defaultClient&&(oe.defaultClient.config.enableAutoCollectExceptions=t,Ip&&eB.enable(t)),e},e.setAutoCollectPerformance=function(t,r){if(r===void 0&&(r=!0),oe.defaultClient){oe.defaultClient.config.enableAutoCollectPerformance=t;var n=Kje.AutoCollectNativePerformance.parseEnabled(r,oe.defaultClient.config);oe.defaultClient.config.enableAutoCollectExtendedMetrics=n.isEnabled,Ip&&(tB.enable(t),lR.enable(oe.defaultClient.config.enableAutoCollectExtendedMetrics,n.disabledMetrics))}return e},e.setAutoCollectPreAggregatedMetrics=function(t){return oe.defaultClient&&(oe.defaultClient.config.enableAutoCollectPreAggregatedMetrics=t,Ip&&rB.enable(t)),e},e.setAutoCollectHeartbeat=function(t){return oe.defaultClient&&(oe.defaultClient.config.enableAutoCollectHeartbeat=t,Ip&&nB.enable(t)),e},e.enableAutoWebSnippetInjection=function(t,r){return oe.defaultClient&&(oe.defaultClient.config.enableWebInstrumentation=t,oe.defaultClient.config.webInstrumentationConnectionString=r,Ip&&uR.enable(oe.defaultClient.config.enableAutoWebSnippetInjection,oe.defaultClient.config.webSnippetConnectionString)),e},e.enableWebInstrumentation=function(t,r){return oe.defaultClient&&(oe.defaultClient.config.enableWebInstrumentation=t,oe.defaultClient.config.webInstrumentationConnectionString=r,Ip&&uR.enable(oe.defaultClient.config.enableWebInstrumentation,oe.defaultClient.config.webInstrumentationConnectionString)),e},e.setAutoCollectRequests=function(t){return oe.defaultClient&&(oe.defaultClient.config.enableAutoCollectRequests=t,Ip&&xS.enable(t)),e},e.setAutoCollectDependencies=function(t){return oe.defaultClient&&(oe.defaultClient.config.enableAutoCollectDependencies=t,Ip&&iB.enable(t)),e},e.setAutoDependencyCorrelation=function(t,r){return oe.defaultClient&&(oe.defaultClient.config.enableAutoDependencyCorrelation=t,oe.defaultClient.config.enableUseAsyncHooks=r,Ip&&xS.useAutoCorrelation(t,r)),e},e.setUseDiskRetryCaching=function(t,r,n){return oe.defaultClient&&(oe.defaultClient.config.enableUseDiskRetryCaching=t,oe.defaultClient.config.enableResendInterval=r,oe.defaultClient.config.enableMaxBytesOnDisk=n,oe.defaultClient.channel&&oe.defaultClient.channel.setUseDiskRetryCaching(oe.defaultClient.config.enableUseDiskRetryCaching,oe.defaultClient.config.enableResendInterval,oe.defaultClient.config.enableMaxBytesOnDisk)),e},e.setInternalLogging=function(t,r){return t===void 0&&(t=!1),r===void 0&&(r=!0),ZU.enableDebug=t,ZU.disableWarnings=!r,e},e.setAutoCollectIncomingRequestAzureFunctions=function(t){return oe.defaultClient&&(oe.defaultClient.config.enableAutoCollectIncomingRequestAzureFunctions=t,Ip&&aB.enable(t)),e},e.setSendLiveMetrics=function(t){return t===void 0&&(t=!1),oe.defaultClient?(!oe.liveMetricsClient&&t?(oe.liveMetricsClient=new qir(oe.defaultClient.config,oe.defaultClient.context,oe.defaultClient.getAuthorizationHandler,oe.defaultClient),vie=new Gje(oe.liveMetricsClient,1e3,!0),oe.liveMetricsClient.addCollector(vie),oe.defaultClient.quickPulseClient=oe.liveMetricsClient):oe.liveMetricsClient&&oe.liveMetricsClient.enable(t),oe.defaultClient.config.enableSendLiveMetrics=t,e):(ZU.warn("Live metrics client cannot be setup without the default client"),e)},e.start=Vir,e}();oe.Configuration=Yje;function ofi(){jir.w3cEnabled=!0,oe.defaultClient=null,Ip=!1,QU&&QU.dispose(),eB&&eB.dispose(),tB&&tB.dispose(),rB&&rB.dispose(),nB&&nB.dispose(),uR&&uR.dispose(),lR&&lR.dispose(),xS&&xS.dispose(),iB&&iB.dispose(),oe.liveMetricsClient&&(oe.liveMetricsClient.enable(!1),oe.liveMetricsClient=void 0),aB&&aB.dispose()}});var Eie=y(bie=>{"use strict";Object.defineProperty(bie,"__esModule",{value:!0});bie.EventHeader=void 0;var Xje=class{extensionName;eventName;constructor(t,r){this.extensionName=t,this.eventName=r}getExtensionName(){return this.extensionName}getEventName(){return this.eventName}toString(){return`${this.extensionName}/${this.eventName}`}};bie.EventHeader=Xje});var xie=y(_ie=>{"use strict";Object.defineProperty(_ie,"__esModule",{value:!0});_ie.SampleRate=void 0;var Uir;(function(e){e[e.OnePercent=0]="OnePercent",e[e.TenPercent=1]="TenPercent",e[e.NoSampling=2]="NoSampling"})(Uir||(_ie.SampleRate=Uir={}))});var Zje=y(Jje=>{"use strict";Object.defineProperty(Jje,"__esModule",{value:!0});Jje.configAzureTelemetryClient=sfi;function sfi(e){e.channel.setUseDiskRetryCaching(!0),e.addTelemetryProcessor(t=>(t.tags["ai.location.ip"]="0.0.0.0",t.tags["ai.cloud.roleInstance"]="masked",t.tags["ai.cloud.role"]="masked",t.tags["ai.device.type"]="masked",!0))}});var Bir=y((jha,cfi)=>{cfi.exports={name:"@sap-ux/telemetry",version:"0.6.43",description:"Library for sending usage telemetry data",repository:{type:"git",url:"https://github.com/SAP/open-ux-tools.git",directory:"packages/telemetry"},bugs:{url:"https://github.com/SAP/open-ux-tools/issues?q=is%3Aopen+is%3Aissue+label%3Abug+label%3Atelemetry"},license:"Apache-2.0",private:!1,main:"dist/index.js",scripts:{build:"tsc --build",watch:"tsc --watch",clean:"rimraf --glob dist coverage *.tsbuildinfo",format:"prettier --write '**/*.{js,json,ts,yaml,yml}' --ignore-path ../../.prettierignore",lint:"eslint . --ext .ts","lint:fix":"eslint . --ext .ts --fix",test:"jest --ci --forceExit --detectOpenHandles --colors","test-u":"jest --ci --forceExit --detectOpenHandles --colors -u",link:"pnpm link --global",unlink:"pnpm unlink --global",example:"ts-node example/index.ts"},dependencies:{"@sap-ux/store":"workspace:*","@sap-ux/project-access":"workspace:*","@sap-ux/btp-utils":"workspace:*","@sap-ux/ui5-config":"workspace:*","@sap-ux/logger":"workspace:*","@sap-ux/nodejs-utils":"workspace:*",applicationinsights:"2.9.8",axios:"1.12.2","performance-now":"2.1.0",yaml:"2.3.3"},devDependencies:{"jest-extended":"6.0.0",memfs:"3.4.13",unionfs:"4.4.0",dotenv:"16.3.1"},files:["dist","LICENSE","!dist/*.map","!dist/**/*.map"],engines:{node:">=20.x"}}});var oB=y(pR=>{"use strict";var ufi=pR&&pR.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(pR,"__esModule",{value:!0});pR.TelemetrySettings=void 0;var zir=ufi(Bir());pR.TelemetrySettings={azureInstrumentationKey:"",telemetryEnabled:!0,telemetryLibName:zir.default.name,telemetryLibVersion:zir.default.version,consumerModuleName:"",consumerModuleVersion:""}});var eqe=y(Fg=>{"use strict";var lfi=Fg&&Fg.__createBinding||(Object.create?function(e,t,r,n){n===void 0&&(n=r);var i=Object.getOwnPropertyDescriptor(t,r);(!i||("get"in i?!t.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,n,i)}:function(e,t,r,n){n===void 0&&(n=r),e[n]=t[r]}),pfi=Fg&&Fg.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e.default=t}),ffi=Fg&&Fg.__importStar||function(){var e=function(t){return e=Object.getOwnPropertyNames||function(r){var n=[];for(var i in r)Object.prototype.hasOwnProperty.call(r,i)&&(n[n.length]=i);return n},e(t)};return function(t){if(t&&t.__esModule)return t;var r={};if(t!=null)for(var n=e(t),i=0;i<n.length;i++)n[i]!=="default"&&lfi(r,t,n[i]);return pfi(r,t),r}}();Object.defineProperty(Fg,"__esModule",{value:!0});Fg.ApplicationInsightClient=void 0;var dfi=yke(),hfi=ffi(Wje()),mfi=Eie(),Mg=xie(),gfi=Zje(),Hir=oB(),Qje=class extends dfi.Client{clients;constructor(t,r,n){super(),this.clients=new Map,this.applicationKey=t,this.extensionVersion=n,this.extensionName=r;let i=this.createTelemetryClient(Mg.SampleRate.OnePercent),a=this.createTelemetryClient(Mg.SampleRate.TenPercent),o=this.createTelemetryClient(Mg.SampleRate.NoSampling);this.clients.set(Mg.SampleRate.OnePercent,i),this.clients.set(Mg.SampleRate.TenPercent,a),this.clients.set(Mg.SampleRate.NoSampling,o)}reportBlocking(t,r,n,i,a=!1){if(!a||Hir.TelemetrySettings.telemetryEnabled){let{client:o,event:s}=this.prepareClientAndEvent(t,r,n,i);return this.trackEventBlocking(o,s)}return Promise.resolve()}async report(t,r,n,i,a,o){if(o!==void 0&&!o||!Hir.TelemetrySettings.telemetryEnabled)return;let{client:s,event:c}=this.prepareClientAndEvent(t,r,n,i);this.trackEvent(s,c)}prepareClientAndEvent(t,r,n,i=Mg.SampleRate.NoSampling){let a=this.clients.get(i),s={name:new mfi.EventHeader(this.extensionName,t).toString(),properties:r,measurements:n};return{client:a,event:s}}async trackEventBlocking(t,r){if(process.env.SAP_UX_FIORI_TOOLS_DISABLE_TELEMETRY!=="true")return new Promise((n,i)=>{try{t.trackEvent(r),t.flush({callback:()=>n()})}catch(a){i(a)}})}trackEvent(t,r){return process.env.SAP_UX_FIORI_TOOLS_DISABLE_TELEMETRY!=="true"?(t.trackEvent(r),!0):!1}createTelemetryClient(t){let r;switch(t){case Mg.SampleRate.OnePercent:r=1;break;case Mg.SampleRate.TenPercent:r=10;break;case Mg.SampleRate.NoSampling:default:r=100;break}let n=new hfi.TelemetryClient(this.applicationKey);return n.config.samplingPercentage=r,(0,gfi.configAzureTelemetryClient)(n),n}};Fg.ApplicationInsightClient=Qje});var Gir=y(Tie=>{"use strict";Object.defineProperty(Tie,"__esModule",{value:!0});Tie.localDatetimeToUTC=void 0;var yfi=()=>{let e=new Date().getTime();return new Date(e).toISOString()};Tie.localDatetimeToUTC=yfi});var Wir=y(Oie=>{"use strict";Object.defineProperty(Oie,"__esModule",{value:!0});Oie.ToolsSuiteTelemetryClient=void 0;var vfi=eqe(),Kir=Sie(),Yir=Gir(),tqe=class extends vfi.ApplicationInsightClient{constructor(t,r,n){super(t,r,n)}async report(t,r,n,i,a,o){let s=await(0,Kir.processToolsSuiteTelemetry)(a),c={v:this.extensionVersion,datetime:(0,Yir.localDatetimeToUTC)()},u={...r,...s,...c};await super.report(t,u,n,i,a,o)}async reportEvent(t,r,n,i){let{finalProperties:a,finalMeasurements:o}=await this.collectToolsSuiteTelemetry(t,n);return super.report(t.eventName,a,o,r,n,i)}async reportEventBlocking(t,r,n,i){let{finalProperties:a,finalMeasurements:o}=await this.collectToolsSuiteTelemetry(t,n);return super.reportBlocking(t.eventName,a,o,r,i)}async collectToolsSuiteTelemetry(t,r){let n=await(0,Kir.processToolsSuiteTelemetry)(r),i={v:this.extensionVersion,datetime:(0,Yir.localDatetimeToUTC)()},a={...t.properties,...n,...i},o={...t.measurements};return{finalProperties:a,finalMeasurements:o}}};Oie.ToolsSuiteTelemetryClient=tqe});var Cn=y(Hs=>{"use strict";var rqe=Symbol.for("yaml.alias"),Xir=Symbol.for("yaml.document"),Aie=Symbol.for("yaml.map"),Jir=Symbol.for("yaml.pair"),nqe=Symbol.for("yaml.scalar"),Cie=Symbol.for("yaml.seq"),_b=Symbol.for("yaml.node.type"),bfi=e=>!!e&&typeof e=="object"&&e[_b]===rqe,Efi=e=>!!e&&typeof e=="object"&&e[_b]===Xir,_fi=e=>!!e&&typeof e=="object"&&e[_b]===Aie,xfi=e=>!!e&&typeof e=="object"&&e[_b]===Jir,Zir=e=>!!e&&typeof e=="object"&&e[_b]===nqe,Tfi=e=>!!e&&typeof e=="object"&&e[_b]===Cie;function Qir(e){if(e&&typeof e=="object")switch(e[_b]){case Aie:case Cie:return!0}return!1}function Ofi(e){if(e&&typeof e=="object")switch(e[_b]){case rqe:case Aie:case nqe:case Cie:return!0}return!1}var Sfi=e=>(Zir(e)||Qir(e))&&!!e.anchor;Hs.ALIAS=rqe;Hs.DOC=Xir;Hs.MAP=Aie;Hs.NODE_TYPE=_b;Hs.PAIR=Jir;Hs.SCALAR=nqe;Hs.SEQ=Cie;Hs.hasAnchor=Sfi;Hs.isAlias=bfi;Hs.isCollection=Qir;Hs.isDocument=Efi;Hs.isMap=_fi;Hs.isNode=Ofi;Hs.isPair=xfi;Hs.isScalar=Zir;Hs.isSeq=Tfi});var sB=y(iqe=>{"use strict";var qo=Cn(),Nl=Symbol("break visit"),ear=Symbol("skip children"),jg=Symbol("remove node");function wie(e,t){let r=tar(t);qo.isDocument(e)?fR(null,e.contents,r,Object.freeze([e]))===jg&&(e.contents=null):fR(null,e,r,Object.freeze([]))}wie.BREAK=Nl;wie.SKIP=ear;wie.REMOVE=jg;function fR(e,t,r,n){let i=rar(e,t,r,n);if(qo.isNode(i)||qo.isPair(i))return nar(e,n,i),fR(e,i,r,n);if(typeof i!="symbol"){if(qo.isCollection(t)){n=Object.freeze(n.concat(t));for(let a=0;a<t.items.length;++a){let o=fR(a,t.items[a],r,n);if(typeof o=="number")a=o-1;else{if(o===Nl)return Nl;o===jg&&(t.items.splice(a,1),a-=1)}}}else if(qo.isPair(t)){n=Object.freeze(n.concat(t));let a=fR("key",t.key,r,n);if(a===Nl)return Nl;a===jg&&(t.key=null);let o=fR("value",t.value,r,n);if(o===Nl)return Nl;o===jg&&(t.value=null)}}return i}async function Pie(e,t){let r=tar(t);qo.isDocument(e)?await dR(null,e.contents,r,Object.freeze([e]))===jg&&(e.contents=null):await dR(null,e,r,Object.freeze([]))}Pie.BREAK=Nl;Pie.SKIP=ear;Pie.REMOVE=jg;async function dR(e,t,r,n){let i=await rar(e,t,r,n);if(qo.isNode(i)||qo.isPair(i))return nar(e,n,i),dR(e,i,r,n);if(typeof i!="symbol"){if(qo.isCollection(t)){n=Object.freeze(n.concat(t));for(let a=0;a<t.items.length;++a){let o=await dR(a,t.items[a],r,n);if(typeof o=="number")a=o-1;else{if(o===Nl)return Nl;o===jg&&(t.items.splice(a,1),a-=1)}}}else if(qo.isPair(t)){n=Object.freeze(n.concat(t));let a=await dR("key",t.key,r,n);if(a===Nl)return Nl;a===jg&&(t.key=null);let o=await dR("value",t.value,r,n);if(o===Nl)return Nl;o===jg&&(t.value=null)}}return i}function tar(e){return typeof e=="object"&&(e.Collection||e.Node||e.Value)?Object.assign({Alias:e.Node,Map:e.Node,Scalar:e.Node,Seq:e.Node},e.Value&&{Map:e.Value,Scalar:e.Value,Seq:e.Value},e.Collection&&{Map:e.Collection,Seq:e.Collection},e):e}function rar(e,t,r,n){if(typeof r=="function")return r(e,t,n);if(qo.isMap(t))return r.Map?.(e,t,n);if(qo.isSeq(t))return r.Seq?.(e,t,n);if(qo.isPair(t))return r.Pair?.(e,t,n);if(qo.isScalar(t))return r.Scalar?.(e,t,n);if(qo.isAlias(t))return r.Alias?.(e,t,n)}function nar(e,t,r){let n=t[t.length-1];if(qo.isCollection(n))n.items[e]=r;else if(qo.isPair(n))e==="key"?n.key=r:n.value=r;else if(qo.isDocument(n))n.contents=r;else{let i=qo.isAlias(n)?"alias":"scalar";throw new Error(`Cannot replace node with ${i} parent`)}}iqe.visit=wie;iqe.visitAsync=Pie});var aqe=y(aar=>{"use strict";var iar=Cn(),Afi=sB(),Cfi={"!":"%21",",":"%2C","[":"%5B","]":"%5D","{":"%7B","}":"%7D"},wfi=e=>e.replace(/[!,[\]{}]/g,t=>Cfi[t]),cB=class e{constructor(t,r){this.docStart=null,this.docEnd=!1,this.yaml=Object.assign({},e.defaultYaml,t),this.tags=Object.assign({},e.defaultTags,r)}clone(){let t=new e(this.yaml,this.tags);return t.docStart=this.docStart,t}atDocument(){let t=new e(this.yaml,this.tags);switch(this.yaml.version){case"1.1":this.atNextDocument=!0;break;case"1.2":this.atNextDocument=!1,this.yaml={explicit:e.defaultYaml.explicit,version:"1.2"},this.tags=Object.assign({},e.defaultTags);break}return t}add(t,r){this.atNextDocument&&(this.yaml={explicit:e.defaultYaml.explicit,version:"1.1"},this.tags=Object.assign({},e.defaultTags),this.atNextDocument=!1);let n=t.trim().split(/[ \t]+/),i=n.shift();switch(i){case"%TAG":{if(n.length!==2&&(r(0,"%TAG directive should contain exactly two parts"),n.length<2))return!1;let[a,o]=n;return this.tags[a]=o,!0}case"%YAML":{if(this.yaml.explicit=!0,n.length!==1)return r(0,"%YAML directive should contain exactly one part"),!1;let[a]=n;if(a==="1.1"||a==="1.2")return this.yaml.version=a,!0;{let o=/^\d+\.\d+$/.test(a);return r(6,`Unsupported YAML version ${a}`,o),!1}}default:return r(0,`Unknown directive ${i}`,!0),!1}}tagName(t,r){if(t==="!")return"!";if(t[0]!=="!")return r(`Not a valid tag: ${t}`),null;if(t[1]==="<"){let o=t.slice(2,-1);return o==="!"||o==="!!"?(r(`Verbatim tags aren't resolved, so ${t} is invalid.`),null):(t[t.length-1]!==">"&&r("Verbatim tags must end with a >"),o)}let[,n,i]=t.match(/^(.*!)([^!]*)$/);i||r(`The ${t} tag has no suffix`);let a=this.tags[n];if(a)try{return a+decodeURIComponent(i)}catch(o){return r(String(o)),null}return n==="!"?t:(r(`Could not resolve tag: ${t}`),null)}tagString(t){for(let[r,n]of Object.entries(this.tags))if(t.startsWith(n))return r+wfi(t.substring(n.length));return t[0]==="!"?t:`!<${t}>`}toString(t){let r=this.yaml.explicit?[`%YAML ${this.yaml.version||"1.2"}`]:[],n=Object.entries(this.tags),i;if(t&&n.length>0&&iar.isNode(t.contents)){let a={};Afi.visit(t.contents,(o,s)=>{iar.isNode(s)&&s.tag&&(a[s.tag]=!0)}),i=Object.keys(a)}else i=[];for(let[a,o]of n)a==="!!"&&o==="tag:yaml.org,2002:"||(!t||i.some(s=>s.startsWith(o)))&&r.push(`%TAG ${a} ${o}`);return r.join(`
|
|
1478
1478
|
`)}};cB.defaultYaml={explicit:!1,version:"1.2"};cB.defaultTags={"!!":"tag:yaml.org,2002:"};aar.Directives=cB});var Die=y(uB=>{"use strict";var oar=Cn(),Pfi=sB();function Dfi(e){if(/[\x00-\x19\s,[\]{}]/.test(e)){let r=`Anchor must not contain whitespace or control characters: ${JSON.stringify(e)}`;throw new Error(r)}return!0}function sar(e){let t=new Set;return Pfi.visit(e,{Value(r,n){n.anchor&&t.add(n.anchor)}}),t}function car(e,t){for(let r=1;;++r){let n=`${e}${r}`;if(!t.has(n))return n}}function Nfi(e,t){let r=[],n=new Map,i=null;return{onAnchor:a=>{r.push(a),i||(i=sar(e));let o=car(t,i);return i.add(o),o},setAnchors:()=>{for(let a of r){let o=n.get(a);if(typeof o=="object"&&o.anchor&&(oar.isScalar(o.node)||oar.isCollection(o.node)))o.node.anchor=o.anchor;else{let s=new Error("Failed to resolve repeated object (this should not happen)");throw s.source=a,s}}},sourceObjects:n}}uB.anchorIsValid=Dfi;uB.anchorNames=sar;uB.createNodeAnchors=Nfi;uB.findNewAnchor=car});var oqe=y(uar=>{"use strict";function lB(e,t,r,n){if(n&&typeof n=="object")if(Array.isArray(n))for(let i=0,a=n.length;i<a;++i){let o=n[i],s=lB(e,n,String(i),o);s===void 0?delete n[i]:s!==o&&(n[i]=s)}else if(n instanceof Map)for(let i of Array.from(n.keys())){let a=n.get(i),o=lB(e,n,i,a);o===void 0?n.delete(i):o!==a&&n.set(i,o)}else if(n instanceof Set)for(let i of Array.from(n)){let a=lB(e,n,i,i);a===void 0?n.delete(i):a!==i&&(n.delete(i),n.add(a))}else for(let[i,a]of Object.entries(n)){let o=lB(e,n,i,a);o===void 0?delete n[i]:o!==a&&(n[i]=o)}return e.call(t,r,n)}uar.applyReviver=lB});var q_=y(par=>{"use strict";var Ifi=Cn();function lar(e,t,r){if(Array.isArray(e))return e.map((n,i)=>lar(n,String(i),r));if(e&&typeof e.toJSON=="function"){if(!r||!Ifi.hasAnchor(e))return e.toJSON(t,r);let n={aliasCount:0,count:1,res:void 0};r.anchors.set(e,n),r.onCreate=a=>{n.res=a,delete r.onCreate};let i=e.toJSON(t,r);return r.onCreate&&r.onCreate(i),i}return typeof e=="bigint"&&!r?.keep?Number(e):e}par.toJS=lar});var Nie=y(dar=>{"use strict";var Rfi=oqe(),far=Cn(),Lfi=q_(),sqe=class{constructor(t){Object.defineProperty(this,far.NODE_TYPE,{value:t})}clone(){let t=Object.create(Object.getPrototypeOf(this),Object.getOwnPropertyDescriptors(this));return this.range&&(t.range=this.range.slice()),t}toJS(t,{mapAsMap:r,maxAliasCount:n,onAnchor:i,reviver:a}={}){if(!far.isDocument(t))throw new TypeError("A document argument is required");let o={anchors:new Map,doc:t,keep:!0,mapAsMap:r===!0,mapKeyWarned:!1,maxAliasCount:typeof n=="number"?n:100},s=Lfi.toJS(this,"",o);if(typeof i=="function")for(let{count:c,res:u}of o.anchors.values())i(u,c);return typeof a=="function"?Rfi.applyReviver(a,{"":s},"",s):s}};dar.NodeBase=sqe});var pB=y(mar=>{"use strict";var kfi=Die(),har=sB(),Iie=Cn(),$fi=Nie(),Mfi=q_(),cqe=class extends $fi.NodeBase{constructor(t){super(Iie.ALIAS),this.source=t,Object.defineProperty(this,"tag",{set(){throw new Error("Alias nodes cannot have tags")}})}resolve(t){let r;return har.visit(t,{Node:(n,i)=>{if(i===this)return har.visit.BREAK;i.anchor===this.source&&(r=i)}}),r}toJSON(t,r){if(!r)return{source:this.source};let{anchors:n,doc:i,maxAliasCount:a}=r,o=this.resolve(i);if(!o){let c=`Unresolved alias (the anchor must be set before the alias): ${this.source}`;throw new ReferenceError(c)}let s=n.get(o);if(s||(Mfi.toJS(o,null,r),s=n.get(o)),!s||s.res===void 0){let c="This should not happen: Alias anchor was not resolved?";throw new ReferenceError(c)}if(a>=0&&(s.count+=1,s.aliasCount===0&&(s.aliasCount=Rie(i,o,n)),s.count*s.aliasCount>a)){let c="Excessive alias count indicates a resource exhaustion attack";throw new ReferenceError(c)}return s.res}toString(t,r,n){let i=`*${this.source}`;if(t){if(kfi.anchorIsValid(this.source),t.options.verifyAliasOrder&&!t.anchors.has(this.source)){let a=`Unresolved alias (the anchor must be set before the alias): ${this.source}`;throw new Error(a)}if(t.implicitKey)return`${i} `}return i}};function Rie(e,t,r){if(Iie.isAlias(t)){let n=t.resolve(e),i=r&&n&&r.get(n);return i?i.count*i.aliasCount:0}else if(Iie.isCollection(t)){let n=0;for(let i of t.items){let a=Rie(e,i,r);a>n&&(n=a)}return n}else if(Iie.isPair(t)){let n=Rie(e,t.key,r),i=Rie(e,t.value,r);return Math.max(n,i)}return 1}mar.Alias=cqe});var xo=y(uqe=>{"use strict";var Ffi=Cn(),jfi=Nie(),qfi=q_(),Vfi=e=>!e||typeof e!="function"&&typeof e!="object",V_=class extends jfi.NodeBase{constructor(t){super(Ffi.SCALAR),this.value=t}toJSON(t,r){return r?.keep?this.value:qfi.toJS(this.value,t,r)}toString(){return String(this.value)}};V_.BLOCK_FOLDED="BLOCK_FOLDED";V_.BLOCK_LITERAL="BLOCK_LITERAL";V_.PLAIN="PLAIN";V_.QUOTE_DOUBLE="QUOTE_DOUBLE";V_.QUOTE_SINGLE="QUOTE_SINGLE";uqe.Scalar=V_;uqe.isScalarValue=Vfi});var fB=y(yar=>{"use strict";var Ufi=pB(),TS=Cn(),gar=xo(),Bfi="tag:yaml.org,2002:";function zfi(e,t,r){if(t){let n=r.filter(a=>a.tag===t),i=n.find(a=>!a.format)??n[0];if(!i)throw new Error(`Tag ${t} not found`);return i}return r.find(n=>n.identify?.(e)&&!n.format)}function Hfi(e,t,r){if(TS.isDocument(e)&&(e=e.contents),TS.isNode(e))return e;if(TS.isPair(e)){let p=r.schema[TS.MAP].createNode?.(r.schema,null,r);return p.items.push(e),p}(e instanceof String||e instanceof Number||e instanceof Boolean||typeof BigInt<"u"&&e instanceof BigInt)&&(e=e.valueOf());let{aliasDuplicateObjects:n,onAnchor:i,onTagObj:a,schema:o,sourceObjects:s}=r,c;if(n&&e&&typeof e=="object"){if(c=s.get(e),c)return c.anchor||(c.anchor=i(e)),new Ufi.Alias(c.anchor);c={anchor:null,node:null},s.set(e,c)}t?.startsWith("!!")&&(t=Bfi+t.slice(2));let u=zfi(e,t,o.tags);if(!u){if(e&&typeof e.toJSON=="function"&&(e=e.toJSON()),!e||typeof e!="object"){let p=new gar.Scalar(e);return c&&(c.node=p),p}u=e instanceof Map?o[TS.MAP]:Symbol.iterator in Object(e)?o[TS.SEQ]:o[TS.MAP]}a&&(a(u),delete r.onTagObj);let l=u?.createNode?u.createNode(r.schema,e,r):typeof u?.nodeClass?.from=="function"?u.nodeClass.from(r.schema,e,r):new gar.Scalar(e);return t?l.tag=t:u.default||(l.tag=u.tag),c&&(c.node=l),l}yar.createNode=Hfi});var dB=y(kie=>{"use strict";var Gfi=fB(),qg=Cn(),Kfi=Nie();function lqe(e,t,r){let n=r;for(let i=t.length-1;i>=0;--i){let a=t[i];if(typeof a=="number"&&Number.isInteger(a)&&a>=0){let o=[];o[a]=n,n=o}else n=new Map([[a,n]])}return Gfi.createNode(n,void 0,{aliasDuplicateObjects:!1,keepUndefined:!1,onAnchor:()=>{throw new Error("This should not happen, please report a bug.")},schema:e,sourceObjects:new Map})}var bar=e=>e==null||typeof e=="object"&&!!e[Symbol.iterator]().next().done,Lie=class extends Kfi.NodeBase{constructor(t,r){super(t),Object.defineProperty(this,"schema",{value:r,configurable:!0,enumerable:!1,writable:!0})}clone(t){let r=Object.create(Object.getPrototypeOf(this),Object.getOwnPropertyDescriptors(this));return t&&(r.schema=t),r.items=r.items.map(n=>qg.isNode(n)||qg.isPair(n)?n.clone(t):n),this.range&&(r.range=this.range.slice()),r}addIn(t,r){if(bar(t))this.add(r);else{let[n,...i]=t,a=this.get(n,!0);if(qg.isCollection(a))a.addIn(i,r);else if(a===void 0&&this.schema)this.set(n,lqe(this.schema,i,r));else throw new Error(`Expected YAML collection at ${n}. Remaining path: ${i}`)}}deleteIn(t){let[r,...n]=t;if(n.length===0)return this.delete(r);let i=this.get(r,!0);if(qg.isCollection(i))return i.deleteIn(n);throw new Error(`Expected YAML collection at ${r}. Remaining path: ${n}`)}getIn(t,r){let[n,...i]=t,a=this.get(n,!0);return i.length===0?!r&&qg.isScalar(a)?a.value:a:qg.isCollection(a)?a.getIn(i,r):void 0}hasAllNullValues(t){return this.items.every(r=>{if(!qg.isPair(r))return!1;let n=r.value;return n==null||t&&qg.isScalar(n)&&n.value==null&&!n.commentBefore&&!n.comment&&!n.tag})}hasIn(t){let[r,...n]=t;if(n.length===0)return this.has(r);let i=this.get(r,!0);return qg.isCollection(i)?i.hasIn(n):!1}setIn(t,r){let[n,...i]=t;if(i.length===0)this.set(n,r);else{let a=this.get(n,!0);if(qg.isCollection(a))a.setIn(i,r);else if(a===void 0&&this.schema)this.set(n,lqe(this.schema,i,r));else throw new Error(`Expected YAML collection at ${n}. Remaining path: ${i}`)}}};Lie.maxFlowStringSingleLineLength=60;kie.Collection=Lie;kie.collectionFromPath=lqe;kie.isEmptyPath=bar});var hB=y($ie=>{"use strict";var Yfi=e=>e.replace(/^(?!$)(?: $)?/gm,"#");function pqe(e,t){return/^\n+$/.test(e)?e.substring(1):t?e.replace(/^(?! *$)/gm,t):e}var Wfi=(e,t,r)=>e.endsWith(`
|
|
1479
1479
|
`)?pqe(r,t):r.includes(`
|
|
1480
1480
|
`)?`
|
|
@@ -1640,7 +1640,7 @@ ${n.message}`:h,_=[v,t,e].filter(Boolean).join(`
|
|
|
1640
1640
|
|
|
1641
1641
|
Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.`)}for(let l of this.seen.entries()){let p=l[1];if(t===l[0]){o(l);continue}if(n.external){let d=n.external.registry.get(l[0])?.id;if(t!==l[0]&&d){o(l);continue}}if(this.metadataRegistry.get(l[0])?.id){o(l);continue}if(p.cycle){o(l);continue}if(p.count>1&&n.reused==="ref"){o(l);continue}}let s=(l,p)=>{let f=this.seen.get(l),d=f.def??f.schema,h={...d};if(f.ref===null)return;let m=f.ref;if(f.ref=null,m){s(m,p);let v=this.seen.get(m).schema;v.$ref&&(p.target==="draft-7"||p.target==="draft-4"||p.target==="openapi-3.0")?(d.allOf=d.allOf??[],d.allOf.push(v)):(Object.assign(d,v),Object.assign(d,h))}f.isParent||this.override({zodSchema:l,jsonSchema:d,path:f.path??[]})};for(let l of[...this.seen.entries()].reverse())s(l[0],{target:this.target});let c={};if(this.target==="draft-2020-12"?c.$schema="https://json-schema.org/draft/2020-12/schema":this.target==="draft-7"?c.$schema="http://json-schema.org/draft-07/schema#":this.target==="draft-4"?c.$schema="http://json-schema.org/draft-04/schema#":this.target==="openapi-3.0"||console.warn(`Invalid target: ${this.target}`),n.external?.uri){let l=n.external.registry.get(t)?.id;if(!l)throw new Error("Schema is missing an `id` property");c.$id=n.external.uri(l)}Object.assign(c,i.def);let u=n.external?.defs??{};for(let l of this.seen.entries()){let p=l[1];p.def&&p.defId&&(u[p.defId]=p.def)}n.external||Object.keys(u).length>0&&(this.target==="draft-2020-12"?c.$defs=u:c.definitions=u);try{return JSON.parse(JSON.stringify(c))}catch{throw new Error("Error converting schema to JSON.")}}};function Ix(e,t){if(e instanceof YA){let n=new Ok(t),i={};for(let s of e._idmap.entries()){let[c,u]=s;n.process(u)}let a={},o={registry:e,uri:t?.uri,defs:i};for(let s of e._idmap.entries()){let[c,u]=s;a[c]=n.emit(u,{...t,external:o})}if(Object.keys(i).length>0){let s=n.target==="draft-2020-12"?"$defs":"definitions";a.__shared={[s]:i}}return{schemas:a}}let r=new Ok(t);return r.process(e),r.emit(e,t)}function Hc(e,t){let r=t??{seen:new Set};if(r.seen.has(e))return!1;r.seen.add(e);let n=e._zod.def;if(n.type==="transform")return!0;if(n.type==="array")return Hc(n.element,r);if(n.type==="set")return Hc(n.valueType,r);if(n.type==="lazy")return Hc(n.getter(),r);if(n.type==="promise"||n.type==="optional"||n.type==="nonoptional"||n.type==="nullable"||n.type==="readonly"||n.type==="default"||n.type==="prefault")return Hc(n.innerType,r);if(n.type==="intersection")return Hc(n.left,r)||Hc(n.right,r);if(n.type==="record"||n.type==="map")return Hc(n.keyType,r)||Hc(n.valueType,r);if(n.type==="pipe")return Hc(n.in,r)||Hc(n.out,r);if(n.type==="object"){for(let i in n.shape)if(Hc(n.shape[i],r))return!0;return!1}if(n.type==="union"){for(let i of n.options)if(Hc(i,r))return!0;return!1}if(n.type==="tuple"){for(let i of n.items)if(Hc(i,r))return!0;return!!(n.rest&&Hc(n.rest,r))}return!1}var iKe={};function uC(e){return!!e._zod}function n0(e,t){return uC(e)?Ax(e,t):e.safeParse(t)}function c5(e){var t,r;if(!e)return;let n;if(uC(e)?n=(r=(t=e._zod)===null||t===void 0?void 0:t.def)===null||r===void 0?void 0:r.shape:n=e.shape,!!n){if(typeof n=="function")try{return n()}catch{return}return n}}function sKe(e){var t;if(uC(e)){let o=(t=e._zod)===null||t===void 0?void 0:t.def;if(o){if(o.value!==void 0)return o.value;if(Array.isArray(o.values)&&o.values.length>0)return o.values[0]}}let n=e._def;if(n){if(n.value!==void 0)return n.value;if(Array.isArray(n.values)&&n.values.length>0)return n.values[0]}let i=e.value;if(i!==void 0)return i}var Rx={};Ci(Rx,{$brand:()=>jL,$input:()=>v6,$output:()=>y6,NEVER:()=>V3,TimePrecision:()=>x6,ZodAny:()=>hKe,ZodArray:()=>vKe,ZodBase64:()=>ppe,ZodBase64URL:()=>fpe,ZodBigInt:()=>Dk,ZodBigIntFormat:()=>mpe,ZodBoolean:()=>Pk,ZodCIDRv4:()=>upe,ZodCIDRv6:()=>lpe,ZodCUID:()=>rpe,ZodCUID2:()=>npe,ZodCatch:()=>kKe,ZodCodec:()=>Tpe,ZodCustom:()=>x5,ZodCustomStringFormat:()=>Ck,ZodDate:()=>b5,ZodDefault:()=>PKe,ZodDiscriminatedUnion:()=>bKe,ZodE164:()=>dpe,ZodEmail:()=>Zle,ZodEmoji:()=>epe,ZodEnum:()=>Sk,ZodError:()=>Mle,ZodFile:()=>AKe,ZodFirstPartyTypeKind:()=>Spe,ZodFunction:()=>zKe,ZodGUID:()=>h5,ZodIPv4:()=>spe,ZodIPv6:()=>cpe,ZodISODate:()=>l5,ZodISODateTime:()=>u5,ZodISODuration:()=>f5,ZodISOTime:()=>p5,ZodIntersection:()=>EKe,ZodIssueCode:()=>$wr,ZodJWT:()=>hpe,ZodKSUID:()=>ope,ZodLazy:()=>VKe,ZodLiteral:()=>SKe,ZodMAC:()=>lKe,ZodMap:()=>TKe,ZodNaN:()=>MKe,ZodNanoID:()=>tpe,ZodNever:()=>gKe,ZodNonOptional:()=>_pe,ZodNull:()=>dKe,ZodNullable:()=>wKe,ZodNumber:()=>wk,ZodNumberFormat:()=>lC,ZodObject:()=>E5,ZodOptional:()=>Epe,ZodPipe:()=>xpe,ZodPrefault:()=>NKe,ZodPromise:()=>BKe,ZodReadonly:()=>FKe,ZodRealError:()=>ku,ZodRecord:()=>vpe,ZodSet:()=>OKe,ZodString:()=>Ak,ZodStringFormat:()=>ai,ZodSuccess:()=>LKe,ZodSymbol:()=>pKe,ZodTemplateLiteral:()=>qKe,ZodTransform:()=>CKe,ZodTuple:()=>_Ke,ZodType:()=>Tr,ZodULID:()=>ipe,ZodURL:()=>y5,ZodUUID:()=>fy,ZodUndefined:()=>fKe,ZodUnion:()=>ype,ZodUnknown:()=>mKe,ZodVoid:()=>yKe,ZodXID:()=>ape,_ZodString:()=>Jle,_default:()=>DKe,_function:()=>Pwr,any:()=>v5,array:()=>Ut,base64:()=>JCr,base64url:()=>ZCr,bigint:()=>uwr,boolean:()=>Ki,catch:()=>$Ke,check:()=>Dwr,cidrv4:()=>WCr,cidrv6:()=>XCr,clone:()=>vs,codec:()=>Awr,coerce:()=>Ape,config:()=>fa,core:()=>Xl,cuid:()=>VCr,cuid2:()=>UCr,custom:()=>Ope,date:()=>mwr,decode:()=>Ble,decodeAsync:()=>Hle,describe:()=>Nwr,discriminatedUnion:()=>_5,e164:()=>QCr,email:()=>ICr,emoji:()=>jCr,encode:()=>Ule,encodeAsync:()=>zle,endsWith:()=>nC,enum:()=>Dn,file:()=>xwr,flattenError:()=>kA,float32:()=>awr,float64:()=>owr,formatError:()=>$A,function:()=>Pwr,getErrorMap:()=>Fwr,globalRegistry:()=>Xs,gt:()=>Uh,gte:()=>Js,guid:()=>RCr,hash:()=>iwr,hex:()=>nwr,hostname:()=>rwr,httpUrl:()=>FCr,includes:()=>tC,instanceof:()=>Rwr,int:()=>Xle,int32:()=>swr,int64:()=>lwr,intersection:()=>Ik,ipv4:()=>GCr,ipv6:()=>YCr,iso:()=>d5,json:()=>kwr,jwt:()=>ewr,keyof:()=>gwr,ksuid:()=>HCr,lazy:()=>UKe,length:()=>Dx,literal:()=>pt,locales:()=>KA,looseObject:()=>Jl,lowercase:()=>QA,lt:()=>Vh,lte:()=>Lu,mac:()=>KCr,map:()=>bwr,maxLength:()=>Px,maxSize:()=>wx,meta:()=>Iwr,mime:()=>iC,minLength:()=>py,minSize:()=>r0,multipleOf:()=>t0,nan:()=>Swr,nanoid:()=>qCr,nativeEnum:()=>_wr,negative:()=>J6,never:()=>gpe,nonnegative:()=>Q6,nonoptional:()=>RKe,nonpositive:()=>Z6,normalize:()=>aC,null:()=>Nk,nullable:()=>m5,nullish:()=>Twr,number:()=>Pn,object:()=>xe,optional:()=>ut,overwrite:()=>Ad,parse:()=>Fle,parseAsync:()=>jle,partialRecord:()=>vwr,pipe:()=>g5,positive:()=>X6,prefault:()=>IKe,preprocess:()=>T5,prettifyError:()=>H3,promise:()=>wwr,property:()=>e5,readonly:()=>jKe,record:()=>di,refine:()=>HKe,regex:()=>ZA,regexes:()=>Ru,registry:()=>rk,safeDecode:()=>Kle,safeDecodeAsync:()=>Wle,safeEncode:()=>Gle,safeEncodeAsync:()=>Yle,safeParse:()=>qle,safeParseAsync:()=>Vle,set:()=>Ewr,setErrorMap:()=>Mwr,size:()=>JA,slugify:()=>Tk,startsWith:()=>rC,strictObject:()=>ywr,string:()=>Q,stringFormat:()=>twr,stringbool:()=>Lwr,success:()=>Owr,superRefine:()=>GKe,symbol:()=>fwr,templateLiteral:()=>Cwr,toJSONSchema:()=>Ix,toLowerCase:()=>sC,toUpperCase:()=>cC,transform:()=>bpe,treeifyError:()=>z3,trim:()=>oC,tuple:()=>xKe,uint32:()=>cwr,uint64:()=>pwr,ulid:()=>BCr,undefined:()=>dwr,union:()=>an,unknown:()=>oi,uppercase:()=>eC,url:()=>Qle,util:()=>Ne,uuid:()=>LCr,uuidv4:()=>kCr,uuidv6:()=>$Cr,uuidv7:()=>MCr,void:()=>hwr,xid:()=>zCr});var d5={};Ci(d5,{ZodISODate:()=>l5,ZodISODateTime:()=>u5,ZodISODuration:()=>f5,ZodISOTime:()=>p5,date:()=>Lle,datetime:()=>Rle,duration:()=>$le,time:()=>kle});var u5=ee("ZodISODateTime",(e,t)=>{b8.init(e,t),ai.init(e,t)});function Rle(e){return T6(u5,e)}var l5=ee("ZodISODate",(e,t)=>{E8.init(e,t),ai.init(e,t)});function Lle(e){return O6(l5,e)}var p5=ee("ZodISOTime",(e,t)=>{_8.init(e,t),ai.init(e,t)});function kle(e){return S6(p5,e)}var f5=ee("ZodISODuration",(e,t)=>{x8.init(e,t),ai.init(e,t)});function $le(e){return A6(f5,e)}var uKe=(e,t)=>{GL.init(e,t),e.name="ZodError",Object.defineProperties(e,{format:{value:r=>$A(e,r)},flatten:{value:r=>kA(e,r)},addIssue:{value:r=>{e.issues.push(r),e.message=JSON.stringify(e.issues,IA,2)}},addIssues:{value:r=>{e.issues.push(...r),e.message=JSON.stringify(e.issues,IA,2)}},isEmpty:{get(){return e.issues.length===0}}})},Mle=ee("ZodError",uKe),ku=ee("ZodError",uKe,{Parent:Error});var Fle=MA(ku),jle=jA(ku),qle=VA(ku),Vle=UA(ku),Ule=G3(ku),Ble=K3(ku),zle=Y3(ku),Hle=W3(ku),Gle=X3(ku),Kle=J3(ku),Yle=Z3(ku),Wle=Q3(ku);var Tr=ee("ZodType",(e,t)=>(Wt.init(e,t),e.def=t,e.type=t.type,Object.defineProperty(e,"_def",{value:t}),e.check=(...r)=>e.clone(Ne.mergeDefs(t,{checks:[...t.checks??[],...r.map(n=>typeof n=="function"?{_zod:{check:n,def:{check:"custom"},onattach:[]}}:n)]})),e.clone=(r,n)=>vs(e,r,n),e.brand=()=>e,e.register=(r,n)=>(r.add(e,n),e),e.parse=(r,n)=>Fle(e,r,n,{callee:e.parse}),e.safeParse=(r,n)=>qle(e,r,n),e.parseAsync=async(r,n)=>jle(e,r,n,{callee:e.parseAsync}),e.safeParseAsync=async(r,n)=>Vle(e,r,n),e.spa=e.safeParseAsync,e.encode=(r,n)=>Ule(e,r,n),e.decode=(r,n)=>Ble(e,r,n),e.encodeAsync=async(r,n)=>zle(e,r,n),e.decodeAsync=async(r,n)=>Hle(e,r,n),e.safeEncode=(r,n)=>Gle(e,r,n),e.safeDecode=(r,n)=>Kle(e,r,n),e.safeEncodeAsync=async(r,n)=>Yle(e,r,n),e.safeDecodeAsync=async(r,n)=>Wle(e,r,n),e.refine=(r,n)=>e.check(HKe(r,n)),e.superRefine=r=>e.check(GKe(r)),e.overwrite=r=>e.check(Ad(r)),e.optional=()=>ut(e),e.nullable=()=>m5(e),e.nullish=()=>ut(m5(e)),e.nonoptional=r=>RKe(e,r),e.array=()=>Ut(e),e.or=r=>an([e,r]),e.and=r=>Ik(e,r),e.transform=r=>g5(e,bpe(r)),e.default=r=>DKe(e,r),e.prefault=r=>IKe(e,r),e.catch=r=>$Ke(e,r),e.pipe=r=>g5(e,r),e.readonly=()=>jKe(e),e.describe=r=>{let n=e.clone();return Xs.add(n,{description:r}),n},Object.defineProperty(e,"description",{get(){return Xs.get(e)?.description},configurable:!0}),e.meta=(...r)=>{if(r.length===0)return Xs.get(e);let n=e.clone();return Xs.add(n,r[0]),n},e.isOptional=()=>e.safeParse(void 0).success,e.isNullable=()=>e.safeParse(null).success,e)),Jle=ee("_ZodString",(e,t)=>{e0.init(e,t),Tr.init(e,t);let r=e._zod.bag;e.format=r.format??null,e.minLength=r.minimum??null,e.maxLength=r.maximum??null,e.regex=(...n)=>e.check(ZA(...n)),e.includes=(...n)=>e.check(tC(...n)),e.startsWith=(...n)=>e.check(rC(...n)),e.endsWith=(...n)=>e.check(nC(...n)),e.min=(...n)=>e.check(py(...n)),e.max=(...n)=>e.check(Px(...n)),e.length=(...n)=>e.check(Dx(...n)),e.nonempty=(...n)=>e.check(py(1,...n)),e.lowercase=n=>e.check(QA(n)),e.uppercase=n=>e.check(eC(n)),e.trim=()=>e.check(oC()),e.normalize=(...n)=>e.check(aC(...n)),e.toLowerCase=()=>e.check(sC()),e.toUpperCase=()=>e.check(cC()),e.slugify=()=>e.check(Tk())}),Ak=ee("ZodString",(e,t)=>{e0.init(e,t),Jle.init(e,t),e.email=r=>e.check(nk(Zle,r)),e.url=r=>e.check(XA(y5,r)),e.jwt=r=>e.check(xk(hpe,r)),e.emoji=r=>e.check(ck(epe,r)),e.guid=r=>e.check(WA(h5,r)),e.uuid=r=>e.check(ik(fy,r)),e.uuidv4=r=>e.check(ak(fy,r)),e.uuidv6=r=>e.check(ok(fy,r)),e.uuidv7=r=>e.check(sk(fy,r)),e.nanoid=r=>e.check(uk(tpe,r)),e.guid=r=>e.check(WA(h5,r)),e.cuid=r=>e.check(lk(rpe,r)),e.cuid2=r=>e.check(pk(npe,r)),e.ulid=r=>e.check(fk(ipe,r)),e.base64=r=>e.check(bk(ppe,r)),e.base64url=r=>e.check(Ek(fpe,r)),e.xid=r=>e.check(dk(ape,r)),e.ksuid=r=>e.check(hk(ope,r)),e.ipv4=r=>e.check(mk(spe,r)),e.ipv6=r=>e.check(gk(cpe,r)),e.cidrv4=r=>e.check(yk(upe,r)),e.cidrv6=r=>e.check(vk(lpe,r)),e.e164=r=>e.check(_k(dpe,r)),e.datetime=r=>e.check(Rle(r)),e.date=r=>e.check(Lle(r)),e.time=r=>e.check(kle(r)),e.duration=r=>e.check($le(r))});function Q(e){return b6(Ak,e)}var ai=ee("ZodStringFormat",(e,t)=>{Un.init(e,t),Jle.init(e,t)}),Zle=ee("ZodEmail",(e,t)=>{l8.init(e,t),ai.init(e,t)});function ICr(e){return nk(Zle,e)}var h5=ee("ZodGUID",(e,t)=>{c8.init(e,t),ai.init(e,t)});function RCr(e){return WA(h5,e)}var fy=ee("ZodUUID",(e,t)=>{u8.init(e,t),ai.init(e,t)});function LCr(e){return ik(fy,e)}function kCr(e){return ak(fy,e)}function $Cr(e){return ok(fy,e)}function MCr(e){return sk(fy,e)}var y5=ee("ZodURL",(e,t)=>{p8.init(e,t),ai.init(e,t)});function Qle(e){return XA(y5,e)}function FCr(e){return XA(y5,{protocol:/^https?$/,hostname:Ru.domain,...Ne.normalizeParams(e)})}var epe=ee("ZodEmoji",(e,t)=>{f8.init(e,t),ai.init(e,t)});function jCr(e){return ck(epe,e)}var tpe=ee("ZodNanoID",(e,t)=>{d8.init(e,t),ai.init(e,t)});function qCr(e){return uk(tpe,e)}var rpe=ee("ZodCUID",(e,t)=>{h8.init(e,t),ai.init(e,t)});function VCr(e){return lk(rpe,e)}var npe=ee("ZodCUID2",(e,t)=>{m8.init(e,t),ai.init(e,t)});function UCr(e){return pk(npe,e)}var ipe=ee("ZodULID",(e,t)=>{g8.init(e,t),ai.init(e,t)});function BCr(e){return fk(ipe,e)}var ape=ee("ZodXID",(e,t)=>{y8.init(e,t),ai.init(e,t)});function zCr(e){return dk(ape,e)}var ope=ee("ZodKSUID",(e,t)=>{v8.init(e,t),ai.init(e,t)});function HCr(e){return hk(ope,e)}var spe=ee("ZodIPv4",(e,t)=>{T8.init(e,t),ai.init(e,t)});function GCr(e){return mk(spe,e)}var lKe=ee("ZodMAC",(e,t)=>{S8.init(e,t),ai.init(e,t)});function KCr(e){return _6(lKe,e)}var cpe=ee("ZodIPv6",(e,t)=>{O8.init(e,t),ai.init(e,t)});function YCr(e){return gk(cpe,e)}var upe=ee("ZodCIDRv4",(e,t)=>{A8.init(e,t),ai.init(e,t)});function WCr(e){return yk(upe,e)}var lpe=ee("ZodCIDRv6",(e,t)=>{C8.init(e,t),ai.init(e,t)});function XCr(e){return vk(lpe,e)}var ppe=ee("ZodBase64",(e,t)=>{w8.init(e,t),ai.init(e,t)});function JCr(e){return bk(ppe,e)}var fpe=ee("ZodBase64URL",(e,t)=>{P8.init(e,t),ai.init(e,t)});function ZCr(e){return Ek(fpe,e)}var dpe=ee("ZodE164",(e,t)=>{D8.init(e,t),ai.init(e,t)});function QCr(e){return _k(dpe,e)}var hpe=ee("ZodJWT",(e,t)=>{N8.init(e,t),ai.init(e,t)});function ewr(e){return xk(hpe,e)}var Ck=ee("ZodCustomStringFormat",(e,t)=>{I8.init(e,t),ai.init(e,t)});function twr(e,t,r={}){return Nx(Ck,e,t,r)}function rwr(e){return Nx(Ck,"hostname",Ru.hostname,e)}function nwr(e){return Nx(Ck,"hex",Ru.hex,e)}function iwr(e,t){let r=t?.enc??"hex",n=`${e}_${r}`,i=Ru[n];if(!i)throw new Error(`Unrecognized hash format: ${n}`);return Nx(Ck,n,i,t)}var wk=ee("ZodNumber",(e,t)=>{XL.init(e,t),Tr.init(e,t),e.gt=(n,i)=>e.check(Uh(n,i)),e.gte=(n,i)=>e.check(Js(n,i)),e.min=(n,i)=>e.check(Js(n,i)),e.lt=(n,i)=>e.check(Vh(n,i)),e.lte=(n,i)=>e.check(Lu(n,i)),e.max=(n,i)=>e.check(Lu(n,i)),e.int=n=>e.check(Xle(n)),e.safe=n=>e.check(Xle(n)),e.positive=n=>e.check(Uh(0,n)),e.nonnegative=n=>e.check(Js(0,n)),e.negative=n=>e.check(Vh(0,n)),e.nonpositive=n=>e.check(Lu(0,n)),e.multipleOf=(n,i)=>e.check(t0(n,i)),e.step=(n,i)=>e.check(t0(n,i)),e.finite=()=>e;let r=e._zod.bag;e.minValue=Math.max(r.minimum??Number.NEGATIVE_INFINITY,r.exclusiveMinimum??Number.NEGATIVE_INFINITY)??null,e.maxValue=Math.min(r.maximum??Number.POSITIVE_INFINITY,r.exclusiveMaximum??Number.POSITIVE_INFINITY)??null,e.isInt=(r.format??"").includes("int")||Number.isSafeInteger(r.multipleOf??.5),e.isFinite=!0,e.format=r.format??null});function Pn(e){return C6(wk,e)}var lC=ee("ZodNumberFormat",(e,t)=>{R8.init(e,t),wk.init(e,t)});function Xle(e){return P6(lC,e)}function awr(e){return D6(lC,e)}function owr(e){return N6(lC,e)}function swr(e){return I6(lC,e)}function cwr(e){return R6(lC,e)}var Pk=ee("ZodBoolean",(e,t)=>{HA.init(e,t),Tr.init(e,t)});function Ki(e){return L6(Pk,e)}var Dk=ee("ZodBigInt",(e,t)=>{JL.init(e,t),Tr.init(e,t),e.gte=(n,i)=>e.check(Js(n,i)),e.min=(n,i)=>e.check(Js(n,i)),e.gt=(n,i)=>e.check(Uh(n,i)),e.gte=(n,i)=>e.check(Js(n,i)),e.min=(n,i)=>e.check(Js(n,i)),e.lt=(n,i)=>e.check(Vh(n,i)),e.lte=(n,i)=>e.check(Lu(n,i)),e.max=(n,i)=>e.check(Lu(n,i)),e.positive=n=>e.check(Uh(BigInt(0),n)),e.negative=n=>e.check(Vh(BigInt(0),n)),e.nonpositive=n=>e.check(Lu(BigInt(0),n)),e.nonnegative=n=>e.check(Js(BigInt(0),n)),e.multipleOf=(n,i)=>e.check(t0(n,i));let r=e._zod.bag;e.minValue=r.minimum??null,e.maxValue=r.maximum??null,e.format=r.format??null});function uwr(e){return $6(Dk,e)}var mpe=ee("ZodBigIntFormat",(e,t)=>{L8.init(e,t),Dk.init(e,t)});function lwr(e){return F6(mpe,e)}function pwr(e){return j6(mpe,e)}var pKe=ee("ZodSymbol",(e,t)=>{k8.init(e,t),Tr.init(e,t)});function fwr(e){return q6(pKe,e)}var fKe=ee("ZodUndefined",(e,t)=>{$8.init(e,t),Tr.init(e,t)});function dwr(e){return V6(fKe,e)}var dKe=ee("ZodNull",(e,t)=>{M8.init(e,t),Tr.init(e,t)});function Nk(e){return U6(dKe,e)}var hKe=ee("ZodAny",(e,t)=>{F8.init(e,t),Tr.init(e,t)});function v5(){return B6(hKe)}var mKe=ee("ZodUnknown",(e,t)=>{j8.init(e,t),Tr.init(e,t)});function oi(){return z6(mKe)}var gKe=ee("ZodNever",(e,t)=>{q8.init(e,t),Tr.init(e,t)});function gpe(e){return H6(gKe,e)}var yKe=ee("ZodVoid",(e,t)=>{V8.init(e,t),Tr.init(e,t)});function hwr(e){return G6(yKe,e)}var b5=ee("ZodDate",(e,t)=>{U8.init(e,t),Tr.init(e,t),e.min=(n,i)=>e.check(Js(n,i)),e.max=(n,i)=>e.check(Lu(n,i));let r=e._zod.bag;e.minDate=r.minimum?new Date(r.minimum):null,e.maxDate=r.maximum?new Date(r.maximum):null});function mwr(e){return K6(b5,e)}var vKe=ee("ZodArray",(e,t)=>{B8.init(e,t),Tr.init(e,t),e.element=t.element,e.min=(r,n)=>e.check(py(r,n)),e.nonempty=r=>e.check(py(1,r)),e.max=(r,n)=>e.check(Px(r,n)),e.length=(r,n)=>e.check(Dx(r,n)),e.unwrap=()=>e.element});function Ut(e,t){return Ile(vKe,e,t)}function gwr(e){let t=e._zod.def.shape;return Dn(Object.keys(t))}var E5=ee("ZodObject",(e,t)=>{Nle.init(e,t),Tr.init(e,t),Ne.defineLazy(e,"shape",()=>t.shape),e.keyof=()=>Dn(Object.keys(e._zod.def.shape)),e.catchall=r=>e.clone({...e._zod.def,catchall:r}),e.passthrough=()=>e.clone({...e._zod.def,catchall:oi()}),e.loose=()=>e.clone({...e._zod.def,catchall:oi()}),e.strict=()=>e.clone({...e._zod.def,catchall:gpe()}),e.strip=()=>e.clone({...e._zod.def,catchall:void 0}),e.extend=r=>Ne.extend(e,r),e.safeExtend=r=>Ne.safeExtend(e,r),e.merge=r=>Ne.merge(e,r),e.pick=r=>Ne.pick(e,r),e.omit=r=>Ne.omit(e,r),e.partial=(...r)=>Ne.partial(Epe,e,r[0]),e.required=(...r)=>Ne.required(_pe,e,r[0])});function xe(e,t){let r={type:"object",shape:e??{},...Ne.normalizeParams(t)};return new E5(r)}function ywr(e,t){return new E5({type:"object",shape:e,catchall:gpe(),...Ne.normalizeParams(t)})}function Jl(e,t){return new E5({type:"object",shape:e,catchall:oi(),...Ne.normalizeParams(t)})}var ype=ee("ZodUnion",(e,t)=>{ZL.init(e,t),Tr.init(e,t),e.options=t.options});function an(e,t){return new ype({type:"union",options:e,...Ne.normalizeParams(t)})}var bKe=ee("ZodDiscriminatedUnion",(e,t)=>{ype.init(e,t),z8.init(e,t)});function _5(e,t,r){return new bKe({type:"union",options:t,discriminator:e,...Ne.normalizeParams(r)})}var EKe=ee("ZodIntersection",(e,t)=>{H8.init(e,t),Tr.init(e,t)});function Ik(e,t){return new EKe({type:"intersection",left:e,right:t})}var _Ke=ee("ZodTuple",(e,t)=>{QL.init(e,t),Tr.init(e,t),e.rest=r=>e.clone({...e._zod.def,rest:r})});function xKe(e,t,r){let n=t instanceof Wt,i=n?r:t,a=n?t:null;return new _Ke({type:"tuple",items:e,rest:a,...Ne.normalizeParams(i)})}var vpe=ee("ZodRecord",(e,t)=>{G8.init(e,t),Tr.init(e,t),e.keyType=t.keyType,e.valueType=t.valueType});function di(e,t,r){return new vpe({type:"record",keyType:e,valueType:t,...Ne.normalizeParams(r)})}function vwr(e,t,r){let n=vs(e);return n._zod.values=void 0,new vpe({type:"record",keyType:n,valueType:t,...Ne.normalizeParams(r)})}var TKe=ee("ZodMap",(e,t)=>{K8.init(e,t),Tr.init(e,t),e.keyType=t.keyType,e.valueType=t.valueType});function bwr(e,t,r){return new TKe({type:"map",keyType:e,valueType:t,...Ne.normalizeParams(r)})}var OKe=ee("ZodSet",(e,t)=>{Y8.init(e,t),Tr.init(e,t),e.min=(...r)=>e.check(r0(...r)),e.nonempty=r=>e.check(r0(1,r)),e.max=(...r)=>e.check(wx(...r)),e.size=(...r)=>e.check(JA(...r))});function Ewr(e,t){return new OKe({type:"set",valueType:e,...Ne.normalizeParams(t)})}var Sk=ee("ZodEnum",(e,t)=>{W8.init(e,t),Tr.init(e,t),e.enum=t.entries,e.options=Object.values(t.entries);let r=new Set(Object.keys(t.entries));e.extract=(n,i)=>{let a={};for(let o of n)if(r.has(o))a[o]=t.entries[o];else throw new Error(`Key ${o} not found in enum`);return new Sk({...t,checks:[],...Ne.normalizeParams(i),entries:a})},e.exclude=(n,i)=>{let a={...t.entries};for(let o of n)if(r.has(o))delete a[o];else throw new Error(`Key ${o} not found in enum`);return new Sk({...t,checks:[],...Ne.normalizeParams(i),entries:a})}});function Dn(e,t){let r=Array.isArray(e)?Object.fromEntries(e.map(n=>[n,n])):e;return new Sk({type:"enum",entries:r,...Ne.normalizeParams(t)})}function _wr(e,t){return new Sk({type:"enum",entries:e,...Ne.normalizeParams(t)})}var SKe=ee("ZodLiteral",(e,t)=>{X8.init(e,t),Tr.init(e,t),e.values=new Set(t.values),Object.defineProperty(e,"value",{get(){if(t.values.length>1)throw new Error("This schema contains multiple valid literal values. Use `.values` instead.");return t.values[0]}})});function pt(e,t){return new SKe({type:"literal",values:Array.isArray(e)?e:[e],...Ne.normalizeParams(t)})}var AKe=ee("ZodFile",(e,t)=>{J8.init(e,t),Tr.init(e,t),e.min=(r,n)=>e.check(r0(r,n)),e.max=(r,n)=>e.check(wx(r,n)),e.mime=(r,n)=>e.check(iC(Array.isArray(r)?r:[r],n))});function xwr(e){return t5(AKe,e)}var CKe=ee("ZodTransform",(e,t)=>{Z8.init(e,t),Tr.init(e,t),e._zod.parse=(r,n)=>{if(n.direction==="backward")throw new Yb(e.constructor.name);r.addIssue=a=>{if(typeof a=="string")r.issues.push(Ne.issue(a,r.value,t));else{let o=a;o.fatal&&(o.continue=!1),o.code??(o.code="custom"),o.input??(o.input=r.value),o.inst??(o.inst=e),r.issues.push(Ne.issue(o))}};let i=t.transform(r.value,r);return i instanceof Promise?i.then(a=>(r.value=a,r)):(r.value=i,r)}});function bpe(e){return new CKe({type:"transform",transform:e})}var Epe=ee("ZodOptional",(e,t)=>{Q8.init(e,t),Tr.init(e,t),e.unwrap=()=>e._zod.def.innerType});function ut(e){return new Epe({type:"optional",innerType:e})}var wKe=ee("ZodNullable",(e,t)=>{e6.init(e,t),Tr.init(e,t),e.unwrap=()=>e._zod.def.innerType});function m5(e){return new wKe({type:"nullable",innerType:e})}function Twr(e){return ut(m5(e))}var PKe=ee("ZodDefault",(e,t)=>{t6.init(e,t),Tr.init(e,t),e.unwrap=()=>e._zod.def.innerType,e.removeDefault=e.unwrap});function DKe(e,t){return new PKe({type:"default",innerType:e,get defaultValue(){return typeof t=="function"?t():Ne.shallowClone(t)}})}var NKe=ee("ZodPrefault",(e,t)=>{r6.init(e,t),Tr.init(e,t),e.unwrap=()=>e._zod.def.innerType});function IKe(e,t){return new NKe({type:"prefault",innerType:e,get defaultValue(){return typeof t=="function"?t():Ne.shallowClone(t)}})}var _pe=ee("ZodNonOptional",(e,t)=>{n6.init(e,t),Tr.init(e,t),e.unwrap=()=>e._zod.def.innerType});function RKe(e,t){return new _pe({type:"nonoptional",innerType:e,...Ne.normalizeParams(t)})}var LKe=ee("ZodSuccess",(e,t)=>{i6.init(e,t),Tr.init(e,t),e.unwrap=()=>e._zod.def.innerType});function Owr(e){return new LKe({type:"success",innerType:e})}var kKe=ee("ZodCatch",(e,t)=>{a6.init(e,t),Tr.init(e,t),e.unwrap=()=>e._zod.def.innerType,e.removeCatch=e.unwrap});function $Ke(e,t){return new kKe({type:"catch",innerType:e,catchValue:typeof t=="function"?t:()=>t})}var MKe=ee("ZodNaN",(e,t)=>{o6.init(e,t),Tr.init(e,t)});function Swr(e){return W6(MKe,e)}var xpe=ee("ZodPipe",(e,t)=>{s6.init(e,t),Tr.init(e,t),e.in=t.in,e.out=t.out});function g5(e,t){return new xpe({type:"pipe",in:e,out:t})}var Tpe=ee("ZodCodec",(e,t)=>{xpe.init(e,t),GA.init(e,t)});function Awr(e,t,r){return new Tpe({type:"pipe",in:e,out:t,transform:r.decode,reverseTransform:r.encode})}var FKe=ee("ZodReadonly",(e,t)=>{c6.init(e,t),Tr.init(e,t),e.unwrap=()=>e._zod.def.innerType});function jKe(e){return new FKe({type:"readonly",innerType:e})}var qKe=ee("ZodTemplateLiteral",(e,t)=>{u6.init(e,t),Tr.init(e,t)});function Cwr(e,t){return new qKe({type:"template_literal",parts:e,...Ne.normalizeParams(t)})}var VKe=ee("ZodLazy",(e,t)=>{f6.init(e,t),Tr.init(e,t),e.unwrap=()=>e._zod.def.getter()});function UKe(e){return new VKe({type:"lazy",getter:e})}var BKe=ee("ZodPromise",(e,t)=>{p6.init(e,t),Tr.init(e,t),e.unwrap=()=>e._zod.def.innerType});function wwr(e){return new BKe({type:"promise",innerType:e})}var zKe=ee("ZodFunction",(e,t)=>{l6.init(e,t),Tr.init(e,t)});function Pwr(e){return new zKe({type:"function",input:Array.isArray(e?.input)?xKe(e?.input):e?.input??Ut(oi()),output:e?.output??oi()})}var x5=ee("ZodCustom",(e,t)=>{d6.init(e,t),Tr.init(e,t)});function Dwr(e){let t=new Jn({check:"custom"});return t._zod.check=e,t}function Ope(e,t){return r5(x5,e??(()=>!0),t)}function HKe(e,t={}){return n5(x5,e,t)}function GKe(e){return i5(e)}var Nwr=a5,Iwr=o5;function Rwr(e,t={error:`Input not instance of ${e.name}`}){let r=new x5({type:"custom",check:"custom",fn:n=>n instanceof e,abort:!0,...Ne.normalizeParams(t)});return r._zod.bag.Class=e,r}var Lwr=(...e)=>s5({Codec:Tpe,Boolean:Pk,String:Ak},...e);function kwr(e){let t=UKe(()=>an([Q(e),Pn(),Ki(),Nk(),Ut(t),di(Q(),t)]));return t}function T5(e,t){return g5(bpe(e),t)}var $wr={invalid_type:"invalid_type",too_big:"too_big",too_small:"too_small",invalid_format:"invalid_format",not_multiple_of:"not_multiple_of",unrecognized_keys:"unrecognized_keys",invalid_union:"invalid_union",invalid_key:"invalid_key",invalid_element:"invalid_element",invalid_value:"invalid_value",custom:"custom"};function Mwr(e){fa({customError:e})}function Fwr(){return fa().customError}var Spe;Spe||(Spe={});var Ape={};Ci(Ape,{bigint:()=>Uwr,boolean:()=>Vwr,date:()=>Bwr,number:()=>qwr,string:()=>jwr});function jwr(e){return E6(Ak,e)}function qwr(e){return w6(wk,e)}function Vwr(e){return k6(Pk,e)}function Uwr(e){return M6(Dk,e)}function Bwr(e){return Y6(b5,e)}fa(h6());var wpe="2025-11-25";var KKe=[wpe,"2025-06-18","2025-03-26","2024-11-05","2024-10-07"],zh="io.modelcontextprotocol/related-task",S5="2.0",Bh=Ope(e=>e!==null&&(typeof e=="object"||typeof e=="function")),YKe=an([Q(),Pn().int()]),WKe=Q(),Hwr=Jl({ttl:an([Pn(),Nk()]).optional(),pollInterval:Pn().optional()}),Ppe=Jl({taskId:Q()}),Gwr=Jl({progressToken:YKe.optional(),[zh]:Ppe.optional()}),$u=Jl({task:Hwr.optional(),_meta:Gwr.optional()}),bs=xe({method:Q(),params:$u.optional()}),Lx=Jl({_meta:xe({[zh]:ut(Ppe)}).passthrough().optional()}),Zp=xe({method:Q(),params:Lx.optional()}),Zs=Jl({_meta:Jl({[zh]:Ppe.optional()}).optional()}),A5=an([Q(),Pn().int()]),XKe=xe({jsonrpc:pt(S5),id:A5,...bs.shape}).strict(),Dpe=e=>XKe.safeParse(e).success,JKe=xe({jsonrpc:pt(S5),...Zp.shape}).strict(),ZKe=e=>JKe.safeParse(e).success,QKe=xe({jsonrpc:pt(S5),id:A5,result:Zs}).strict(),Rk=e=>QKe.safeParse(e).success,Qr;(function(e){e[e.ConnectionClosed=-32e3]="ConnectionClosed",e[e.RequestTimeout=-32001]="RequestTimeout",e[e.ParseError=-32700]="ParseError",e[e.InvalidRequest=-32600]="InvalidRequest",e[e.MethodNotFound=-32601]="MethodNotFound",e[e.InvalidParams=-32602]="InvalidParams",e[e.InternalError=-32603]="InternalError",e[e.UrlElicitationRequired=-32042]="UrlElicitationRequired"})(Qr||(Qr={}));var eYe=xe({jsonrpc:pt(S5),id:A5,error:xe({code:Pn().int(),message:Q(),data:ut(oi())})}).strict(),tYe=e=>eYe.safeParse(e).success,rYe=an([XKe,JKe,QKe,eYe]),C5=Zs.strict(),Kwr=Lx.extend({requestId:A5,reason:Q().optional()}),w5=Zp.extend({method:pt("notifications/cancelled"),params:Kwr}),Ywr=xe({src:Q(),mimeType:Q().optional(),sizes:Ut(Q()).optional()}),Lk=xe({icons:Ut(Ywr).optional()}),pC=xe({name:Q(),title:Q().optional()}),nYe=pC.extend({...pC.shape,...Lk.shape,version:Q(),websiteUrl:Q().optional()}),Wwr=Ik(xe({applyDefaults:Ki().optional()}),di(Q(),oi())),Xwr=T5(e=>e&&typeof e=="object"&&!Array.isArray(e)&&Object.keys(e).length===0?{form:{}}:e,Ik(xe({form:Wwr.optional(),url:Bh.optional()}),di(Q(),oi()).optional())),Jwr=xe({list:ut(xe({}).passthrough()),cancel:ut(xe({}).passthrough()),requests:ut(xe({sampling:ut(xe({createMessage:ut(xe({}).passthrough())}).passthrough()),elicitation:ut(xe({create:ut(xe({}).passthrough())}).passthrough())}).passthrough())}).passthrough(),Zwr=xe({list:ut(xe({}).passthrough()),cancel:ut(xe({}).passthrough()),requests:ut(xe({tools:ut(xe({call:ut(xe({}).passthrough())}).passthrough())}).passthrough())}).passthrough(),Qwr=xe({experimental:di(Q(),Bh).optional(),sampling:xe({context:Bh.optional(),tools:Bh.optional()}).optional(),elicitation:Xwr.optional(),roots:xe({listChanged:Ki().optional()}).optional(),tasks:ut(Jwr)}),ePr=$u.extend({protocolVersion:Q(),capabilities:Qwr,clientInfo:nYe}),Npe=bs.extend({method:pt("initialize"),params:ePr});var tPr=xe({experimental:di(Q(),Bh).optional(),logging:Bh.optional(),completions:Bh.optional(),prompts:ut(xe({listChanged:ut(Ki())})),resources:xe({subscribe:Ki().optional(),listChanged:Ki().optional()}).optional(),tools:xe({listChanged:Ki().optional()}).optional(),tasks:ut(Zwr)}).passthrough(),rPr=Zs.extend({protocolVersion:Q(),capabilities:tPr,serverInfo:nYe,instructions:Q().optional()}),Ipe=Zp.extend({method:pt("notifications/initialized")});var P5=bs.extend({method:pt("ping")}),nPr=xe({progress:Pn(),total:ut(Pn()),message:ut(Q())}),iPr=xe({...Lx.shape,...nPr.shape,progressToken:YKe}),D5=Zp.extend({method:pt("notifications/progress"),params:iPr}),aPr=$u.extend({cursor:WKe.optional()}),kk=bs.extend({params:aPr.optional()}),$k=Zs.extend({nextCursor:ut(WKe)}),Mk=xe({taskId:Q(),status:Dn(["working","input_required","completed","failed","cancelled"]),ttl:an([Pn(),Nk()]),createdAt:Q(),lastUpdatedAt:Q(),pollInterval:ut(Pn()),statusMessage:ut(Q())}),fC=Zs.extend({task:Mk}),oPr=Lx.merge(Mk),Fk=Zp.extend({method:pt("notifications/tasks/status"),params:oPr}),N5=bs.extend({method:pt("tasks/get"),params:$u.extend({taskId:Q()})}),I5=Zs.merge(Mk),R5=bs.extend({method:pt("tasks/result"),params:$u.extend({taskId:Q()})}),L5=kk.extend({method:pt("tasks/list")}),k5=$k.extend({tasks:Ut(Mk)}),iYe=bs.extend({method:pt("tasks/cancel"),params:$u.extend({taskId:Q()})}),aYe=Zs.merge(Mk),oYe=xe({uri:Q(),mimeType:ut(Q()),_meta:di(Q(),oi()).optional()}),sYe=oYe.extend({text:Q()}),Rpe=Q().refine(e=>{try{return atob(e),!0}catch{return!1}},{message:"Invalid Base64 string"}),cYe=oYe.extend({blob:Rpe}),uYe=xe({...pC.shape,...Lk.shape,uri:Q(),description:ut(Q()),mimeType:ut(Q()),_meta:ut(Jl({}))}),sPr=xe({...pC.shape,...Lk.shape,uriTemplate:Q(),description:ut(Q()),mimeType:ut(Q()),_meta:ut(Jl({}))}),cPr=kk.extend({method:pt("resources/list")}),uPr=$k.extend({resources:Ut(uYe)}),lPr=kk.extend({method:pt("resources/templates/list")}),pPr=$k.extend({resourceTemplates:Ut(sPr)}),Lpe=$u.extend({uri:Q()}),fPr=Lpe,dPr=bs.extend({method:pt("resources/read"),params:fPr}),hPr=Zs.extend({contents:Ut(an([sYe,cYe]))}),mPr=Zp.extend({method:pt("notifications/resources/list_changed")}),gPr=Lpe,yPr=bs.extend({method:pt("resources/subscribe"),params:gPr}),vPr=Lpe,bPr=bs.extend({method:pt("resources/unsubscribe"),params:vPr}),EPr=Lx.extend({uri:Q()}),_Pr=Zp.extend({method:pt("notifications/resources/updated"),params:EPr}),xPr=xe({name:Q(),description:ut(Q()),required:ut(Ki())}),TPr=xe({...pC.shape,...Lk.shape,description:ut(Q()),arguments:ut(Ut(xPr)),_meta:ut(Jl({}))}),OPr=kk.extend({method:pt("prompts/list")}),SPr=$k.extend({prompts:Ut(TPr)}),APr=$u.extend({name:Q(),arguments:di(Q(),Q()).optional()}),CPr=bs.extend({method:pt("prompts/get"),params:APr}),kpe=xe({type:pt("text"),text:Q(),_meta:di(Q(),oi()).optional()}),$pe=xe({type:pt("image"),data:Rpe,mimeType:Q(),_meta:di(Q(),oi()).optional()}),Mpe=xe({type:pt("audio"),data:Rpe,mimeType:Q(),_meta:di(Q(),oi()).optional()}),wPr=xe({type:pt("tool_use"),name:Q(),id:Q(),input:xe({}).passthrough(),_meta:ut(xe({}).passthrough())}).passthrough(),PPr=xe({type:pt("resource"),resource:an([sYe,cYe]),_meta:di(Q(),oi()).optional()}),DPr=uYe.extend({type:pt("resource_link")}),Fpe=an([kpe,$pe,Mpe,DPr,PPr]),NPr=xe({role:Dn(["user","assistant"]),content:Fpe}),IPr=Zs.extend({description:ut(Q()),messages:Ut(NPr)}),RPr=Zp.extend({method:pt("notifications/prompts/list_changed")}),LPr=xe({title:Q().optional(),readOnlyHint:Ki().optional(),destructiveHint:Ki().optional(),idempotentHint:Ki().optional(),openWorldHint:Ki().optional()}),kPr=xe({taskSupport:Dn(["required","optional","forbidden"]).optional()}),lYe=xe({...pC.shape,...Lk.shape,description:Q().optional(),inputSchema:xe({type:pt("object"),properties:di(Q(),Bh).optional(),required:Ut(Q()).optional()}).catchall(oi()),outputSchema:xe({type:pt("object"),properties:di(Q(),Bh).optional(),required:Ut(Q()).optional()}).catchall(oi()).optional(),annotations:ut(LPr),execution:ut(kPr),_meta:di(Q(),oi()).optional()}),jpe=kk.extend({method:pt("tools/list")}),$Pr=$k.extend({tools:Ut(lYe)}),$5=Zs.extend({content:Ut(Fpe).default([]),structuredContent:di(Q(),oi()).optional(),isError:ut(Ki())}),R1i=$5.or(Zs.extend({toolResult:oi()})),MPr=$u.extend({name:Q(),arguments:ut(di(Q(),oi()))}),jk=bs.extend({method:pt("tools/call"),params:MPr}),FPr=Zp.extend({method:pt("notifications/tools/list_changed")}),qk=Dn(["debug","info","notice","warning","error","critical","alert","emergency"]),jPr=$u.extend({level:qk}),qpe=bs.extend({method:pt("logging/setLevel"),params:jPr}),qPr=Lx.extend({level:qk,logger:Q().optional(),data:oi()}),VPr=Zp.extend({method:pt("notifications/message"),params:qPr}),UPr=xe({name:Q().optional()}),BPr=xe({hints:ut(Ut(UPr)),costPriority:ut(Pn().min(0).max(1)),speedPriority:ut(Pn().min(0).max(1)),intelligencePriority:ut(Pn().min(0).max(1))}),zPr=xe({mode:ut(Dn(["auto","required","none"]))}),HPr=xe({type:pt("tool_result"),toolUseId:Q().describe("The unique identifier for the corresponding tool call."),content:Ut(Fpe).default([]),structuredContent:xe({}).passthrough().optional(),isError:ut(Ki()),_meta:ut(xe({}).passthrough())}).passthrough(),GPr=_5("type",[kpe,$pe,Mpe]),O5=_5("type",[kpe,$pe,Mpe,wPr,HPr]),KPr=xe({role:Dn(["user","assistant"]),content:an([O5,Ut(O5)]),_meta:ut(xe({}).passthrough())}).passthrough(),YPr=$u.extend({messages:Ut(KPr),modelPreferences:BPr.optional(),systemPrompt:Q().optional(),includeContext:Dn(["none","thisServer","allServers"]).optional(),temperature:Pn().optional(),maxTokens:Pn().int(),stopSequences:Ut(Q()).optional(),metadata:Bh.optional(),tools:ut(Ut(lYe)),toolChoice:ut(zPr)}),WPr=bs.extend({method:pt("sampling/createMessage"),params:YPr}),Vpe=Zs.extend({model:Q(),stopReason:ut(Dn(["endTurn","stopSequence","maxTokens"]).or(Q())),role:Dn(["user","assistant"]),content:GPr}),Upe=Zs.extend({model:Q(),stopReason:ut(Dn(["endTurn","stopSequence","maxTokens","toolUse"]).or(Q())),role:Dn(["user","assistant"]),content:an([O5,Ut(O5)])}),XPr=xe({type:pt("boolean"),title:Q().optional(),description:Q().optional(),default:Ki().optional()}),JPr=xe({type:pt("string"),title:Q().optional(),description:Q().optional(),minLength:Pn().optional(),maxLength:Pn().optional(),format:Dn(["email","uri","date","date-time"]).optional(),default:Q().optional()}),ZPr=xe({type:Dn(["number","integer"]),title:Q().optional(),description:Q().optional(),minimum:Pn().optional(),maximum:Pn().optional(),default:Pn().optional()}),QPr=xe({type:pt("string"),title:Q().optional(),description:Q().optional(),enum:Ut(Q()),default:Q().optional()}),eDr=xe({type:pt("string"),title:Q().optional(),description:Q().optional(),oneOf:Ut(xe({const:Q(),title:Q()})),default:Q().optional()}),tDr=xe({type:pt("string"),title:Q().optional(),description:Q().optional(),enum:Ut(Q()),enumNames:Ut(Q()).optional(),default:Q().optional()}),rDr=an([QPr,eDr]),nDr=xe({type:pt("array"),title:Q().optional(),description:Q().optional(),minItems:Pn().optional(),maxItems:Pn().optional(),items:xe({type:pt("string"),enum:Ut(Q())}),default:Ut(Q()).optional()}),iDr=xe({type:pt("array"),title:Q().optional(),description:Q().optional(),minItems:Pn().optional(),maxItems:Pn().optional(),items:xe({anyOf:Ut(xe({const:Q(),title:Q()}))}),default:Ut(Q()).optional()}),aDr=an([nDr,iDr]),oDr=an([tDr,rDr,aDr]),sDr=an([oDr,XPr,JPr,ZPr]),cDr=$u.extend({mode:pt("form").optional(),message:Q(),requestedSchema:xe({type:pt("object"),properties:di(Q(),sDr),required:Ut(Q()).optional()})}),uDr=$u.extend({mode:pt("url"),message:Q(),elicitationId:Q(),url:Q().url()}),lDr=an([cDr,uDr]),pDr=bs.extend({method:pt("elicitation/create"),params:lDr}),fDr=Lx.extend({elicitationId:Q()}),dDr=Zp.extend({method:pt("notifications/elicitation/complete"),params:fDr}),M5=Zs.extend({action:Dn(["accept","decline","cancel"]),content:T5(e=>e===null?void 0:e,di(Q(),an([Q(),Pn(),Ki(),Ut(Q())])).optional())}),hDr=xe({type:pt("ref/resource"),uri:Q()});var mDr=xe({type:pt("ref/prompt"),name:Q()}),gDr=$u.extend({ref:an([mDr,hDr]),argument:xe({name:Q(),value:Q()}),context:xe({arguments:di(Q(),Q()).optional()}).optional()}),yDr=bs.extend({method:pt("completion/complete"),params:gDr});var vDr=Zs.extend({completion:Jl({values:Ut(Q()).max(100),total:ut(Pn().int()),hasMore:ut(Ki())})}),bDr=xe({uri:Q().startsWith("file://"),name:Q().optional(),_meta:di(Q(),oi()).optional()}),EDr=bs.extend({method:pt("roots/list")}),Bpe=Zs.extend({roots:Ut(bDr)}),_Dr=Zp.extend({method:pt("notifications/roots/list_changed")}),L1i=an([P5,Npe,yDr,qpe,CPr,OPr,cPr,lPr,dPr,yPr,bPr,jk,jpe,N5,R5,L5]),k1i=an([w5,D5,Ipe,_Dr,Fk]),$1i=an([C5,Vpe,Upe,M5,Bpe,I5,k5,fC]),M1i=an([P5,WPr,pDr,EDr,N5,R5,L5]),F1i=an([w5,D5,VPr,_Pr,mPr,FPr,RPr,Fk,dDr]),j1i=an([C5,rPr,vDr,IPr,SPr,uPr,pPr,hPr,$5,$Pr,I5,k5,fC]),Or=class e extends Error{constructor(t,r,n){super(`MCP error ${t}: ${r}`),this.code=t,this.data=n,this.name="McpError"}static fromError(t,r,n){if(t===Qr.UrlElicitationRequired&&n){let i=n;if(i.elicitations)return new Cpe(i.elicitations,r)}return new e(t,r,n)}},Cpe=class extends Or{constructor(t,r=`URL elicitation${t.length>1?"s":""} required`){super(Qr.UrlElicitationRequired,r,{elicitations:t})}get elicitations(){var t,r;return(r=(t=this.data)===null||t===void 0?void 0:t.elicitations)!==null&&r!==void 0?r:[]}};function i0(e){return e==="completed"||e==="failed"||e==="cancelled"}var xDr=Symbol("Let zodToJsonSchema decide on which parser to use");var bSi=new Set("ABCDEFGHIJKLMNOPQRSTUVXYZabcdefghijklmnopqrstuvxyz0123456789");function zpe(e){let t=c5(e),r=t?.method;if(!r)throw new Error("Schema is missing a method literal");let n=sKe(r);if(typeof n!="string")throw new Error("Schema method literal must be a string");return n}function Hpe(e,t){let r=n0(e,t);if(!r.success)throw r.error;return r.data}var wDr=6e4,F5=class{constructor(t){this._options=t,this._requestMessageId=0,this._requestHandlers=new Map,this._requestHandlerAbortControllers=new Map,this._notificationHandlers=new Map,this._responseHandlers=new Map,this._progressHandlers=new Map,this._timeoutInfo=new Map,this._pendingDebouncedNotifications=new Set,this._taskProgressTokens=new Map,this._requestResolvers=new Map,this.setNotificationHandler(w5,r=>{this._oncancel(r)}),this.setNotificationHandler(D5,r=>{this._onprogress(r)}),this.setRequestHandler(P5,r=>({})),this._taskStore=t?.taskStore,this._taskMessageQueue=t?.taskMessageQueue,this._taskStore&&(this.setRequestHandler(N5,async(r,n)=>{let i=await this._taskStore.getTask(r.params.taskId,n.sessionId);if(!i)throw new Or(Qr.InvalidParams,"Failed to retrieve task: Task not found");return{...i}}),this.setRequestHandler(R5,async(r,n)=>{let i=async()=>{var a;let o=r.params.taskId;if(this._taskMessageQueue){let c;for(;c=await this._taskMessageQueue.dequeue(o,n.sessionId);){if(c.type==="response"||c.type==="error"){let u=c.message,l=u.id,p=this._requestResolvers.get(l);if(p)if(this._requestResolvers.delete(l),c.type==="response")p(u);else{let f=u,d=new Or(f.error.code,f.error.message,f.error.data);p(d)}else{let f=c.type==="response"?"Response":"Error";this._onerror(new Error(`${f} handler missing for request ${l}`))}continue}await((a=this._transport)===null||a===void 0?void 0:a.send(c.message,{relatedRequestId:n.requestId}))}}let s=await this._taskStore.getTask(o,n.sessionId);if(!s)throw new Or(Qr.InvalidParams,`Task not found: ${o}`);if(!i0(s.status))return await this._waitForTaskUpdate(o,n.signal),await i();if(i0(s.status)){let c=await this._taskStore.getTaskResult(o,n.sessionId);return this._clearTaskQueue(o),{...c,_meta:{...c._meta,[zh]:{taskId:o}}}}return await i()};return await i()}),this.setRequestHandler(L5,async(r,n)=>{var i;try{let{tasks:a,nextCursor:o}=await this._taskStore.listTasks((i=r.params)===null||i===void 0?void 0:i.cursor,n.sessionId);return{tasks:a,nextCursor:o,_meta:{}}}catch(a){throw new Or(Qr.InvalidParams,`Failed to list tasks: ${a instanceof Error?a.message:String(a)}`)}}),this.setRequestHandler(iYe,async(r,n)=>{try{let i=await this._taskStore.getTask(r.params.taskId,n.sessionId);if(!i)throw new Or(Qr.InvalidParams,`Task not found: ${r.params.taskId}`);if(i0(i.status))throw new Or(Qr.InvalidParams,`Cannot cancel task in terminal status: ${i.status}`);await this._taskStore.updateTaskStatus(r.params.taskId,"cancelled","Client cancelled task execution.",n.sessionId),this._clearTaskQueue(r.params.taskId);let a=await this._taskStore.getTask(r.params.taskId,n.sessionId);if(!a)throw new Or(Qr.InvalidParams,`Task not found after cancellation: ${r.params.taskId}`);return{_meta:{},...a}}catch(i){throw i instanceof Or?i:new Or(Qr.InvalidRequest,`Failed to cancel task: ${i instanceof Error?i.message:String(i)}`)}}))}async _oncancel(t){let r=this._requestHandlerAbortControllers.get(t.params.requestId);r?.abort(t.params.reason)}_setupTimeout(t,r,n,i,a=!1){this._timeoutInfo.set(t,{timeoutId:setTimeout(i,r),startTime:Date.now(),timeout:r,maxTotalTimeout:n,resetTimeoutOnProgress:a,onTimeout:i})}_resetTimeout(t){let r=this._timeoutInfo.get(t);if(!r)return!1;let n=Date.now()-r.startTime;if(r.maxTotalTimeout&&n>=r.maxTotalTimeout)throw this._timeoutInfo.delete(t),Or.fromError(Qr.RequestTimeout,"Maximum total timeout exceeded",{maxTotalTimeout:r.maxTotalTimeout,totalElapsed:n});return clearTimeout(r.timeoutId),r.timeoutId=setTimeout(r.onTimeout,r.timeout),!0}_cleanupTimeout(t){let r=this._timeoutInfo.get(t);r&&(clearTimeout(r.timeoutId),this._timeoutInfo.delete(t))}async connect(t){var r,n,i;this._transport=t;let a=(r=this.transport)===null||r===void 0?void 0:r.onclose;this._transport.onclose=()=>{a?.(),this._onclose()};let o=(n=this.transport)===null||n===void 0?void 0:n.onerror;this._transport.onerror=c=>{o?.(c),this._onerror(c)};let s=(i=this._transport)===null||i===void 0?void 0:i.onmessage;this._transport.onmessage=(c,u)=>{s?.(c,u),Rk(c)||tYe(c)?this._onresponse(c):Dpe(c)?this._onrequest(c,u):ZKe(c)?this._onnotification(c):this._onerror(new Error(`Unknown message type: ${JSON.stringify(c)}`))},await this._transport.start()}_onclose(){var t;let r=this._responseHandlers;this._responseHandlers=new Map,this._progressHandlers.clear(),this._taskProgressTokens.clear(),this._pendingDebouncedNotifications.clear();let n=Or.fromError(Qr.ConnectionClosed,"Connection closed");this._transport=void 0,(t=this.onclose)===null||t===void 0||t.call(this);for(let i of r.values())i(n)}_onerror(t){var r;(r=this.onerror)===null||r===void 0||r.call(this,t)}_onnotification(t){var r;let n=(r=this._notificationHandlers.get(t.method))!==null&&r!==void 0?r:this.fallbackNotificationHandler;n!==void 0&&Promise.resolve().then(()=>n(t)).catch(i=>this._onerror(new Error(`Uncaught error in notification handler: ${i}`)))}_onrequest(t,r){var n,i,a,o,s,c;let u=(n=this._requestHandlers.get(t.method))!==null&&n!==void 0?n:this.fallbackRequestHandler,l=this._transport,p=(o=(a=(i=t.params)===null||i===void 0?void 0:i._meta)===null||a===void 0?void 0:a[zh])===null||o===void 0?void 0:o.taskId;if(u===void 0){let v={jsonrpc:"2.0",id:t.id,error:{code:Qr.MethodNotFound,message:"Method not found"}};p&&this._taskMessageQueue?this._enqueueTaskMessage(p,{type:"error",message:v,timestamp:Date.now()},l?.sessionId).catch(_=>this._onerror(new Error(`Failed to enqueue error response: ${_}`))):l?.send(v).catch(_=>this._onerror(new Error(`Failed to send an error response: ${_}`)));return}let f=new AbortController;this._requestHandlerAbortControllers.set(t.id,f);let d=(s=t.params)===null||s===void 0?void 0:s.task,h=this._taskStore?this.requestTaskStore(t,l?.sessionId):void 0,m={signal:f.signal,sessionId:l?.sessionId,_meta:(c=t.params)===null||c===void 0?void 0:c._meta,sendNotification:async v=>{let _={relatedRequestId:t.id};p&&(_.relatedTask={taskId:p}),await this.notification(v,_)},sendRequest:async(v,_,T)=>{var O,S;let A={...T,relatedRequestId:t.id};p&&!A.relatedTask&&(A.relatedTask={taskId:p});let P=(S=(O=A.relatedTask)===null||O===void 0?void 0:O.taskId)!==null&&S!==void 0?S:p;return P&&h&&await h.updateTaskStatus(P,"input_required"),await this.request(v,_,A)},authInfo:r?.authInfo,requestId:t.id,requestInfo:r?.requestInfo,taskId:p,taskStore:h,taskRequestedTtl:d?.ttl,closeSSEStream:r?.closeSSEStream,closeStandaloneSSEStream:r?.closeStandaloneSSEStream};Promise.resolve().then(()=>{d&&this.assertTaskHandlerCapability(t.method)}).then(()=>u(t,m)).then(async v=>{if(f.signal.aborted)return;let _={result:v,jsonrpc:"2.0",id:t.id};p&&this._taskMessageQueue?await this._enqueueTaskMessage(p,{type:"response",message:_,timestamp:Date.now()},l?.sessionId):await l?.send(_)},async v=>{var _;if(f.signal.aborted)return;let T={jsonrpc:"2.0",id:t.id,error:{code:Number.isSafeInteger(v.code)?v.code:Qr.InternalError,message:(_=v.message)!==null&&_!==void 0?_:"Internal error",...v.data!==void 0&&{data:v.data}}};p&&this._taskMessageQueue?await this._enqueueTaskMessage(p,{type:"error",message:T,timestamp:Date.now()},l?.sessionId):await l?.send(T)}).catch(v=>this._onerror(new Error(`Failed to send response: ${v}`))).finally(()=>{this._requestHandlerAbortControllers.delete(t.id)})}_onprogress(t){let{progressToken:r,...n}=t.params,i=Number(r),a=this._progressHandlers.get(i);if(!a){this._onerror(new Error(`Received a progress notification for an unknown token: ${JSON.stringify(t)}`));return}let o=this._responseHandlers.get(i),s=this._timeoutInfo.get(i);if(s&&o&&s.resetTimeoutOnProgress)try{this._resetTimeout(i)}catch(c){this._responseHandlers.delete(i),this._progressHandlers.delete(i),this._cleanupTimeout(i),o(c);return}a(n)}_onresponse(t){let r=Number(t.id),n=this._requestResolvers.get(r);if(n){if(this._requestResolvers.delete(r),Rk(t))n(t);else{let o=new Or(t.error.code,t.error.message,t.error.data);n(o)}return}let i=this._responseHandlers.get(r);if(i===void 0){this._onerror(new Error(`Received a response for an unknown message ID: ${JSON.stringify(t)}`));return}this._responseHandlers.delete(r),this._cleanupTimeout(r);let a=!1;if(Rk(t)&&t.result&&typeof t.result=="object"){let o=t.result;if(o.task&&typeof o.task=="object"){let s=o.task;typeof s.taskId=="string"&&(a=!0,this._taskProgressTokens.set(s.taskId,r))}}if(a||this._progressHandlers.delete(r),Rk(t))i(t);else{let o=Or.fromError(t.error.code,t.error.message,t.error.data);i(o)}}get transport(){return this._transport}async close(){var t;await((t=this._transport)===null||t===void 0?void 0:t.close())}async*requestStream(t,r,n){var i,a,o,s;let{task:c}=n??{};if(!c){try{yield{type:"result",result:await this.request(t,r,n)}}catch(l){yield{type:"error",error:l instanceof Or?l:new Or(Qr.InternalError,String(l))}}return}let u;try{let l=await this.request(t,fC,n);if(l.task)u=l.task.taskId,yield{type:"taskCreated",task:l.task};else throw new Or(Qr.InternalError,"Task creation did not return a task");for(;;){let p=await this.getTask({taskId:u},n);if(yield{type:"taskStatus",task:p},i0(p.status)){p.status==="completed"?yield{type:"result",result:await this.getTaskResult({taskId:u},r,n)}:p.status==="failed"?yield{type:"error",error:new Or(Qr.InternalError,`Task ${u} failed`)}:p.status==="cancelled"&&(yield{type:"error",error:new Or(Qr.InternalError,`Task ${u} was cancelled`)});return}if(p.status==="input_required"){yield{type:"result",result:await this.getTaskResult({taskId:u},r,n)};return}let f=(o=(i=p.pollInterval)!==null&&i!==void 0?i:(a=this._options)===null||a===void 0?void 0:a.defaultTaskPollInterval)!==null&&o!==void 0?o:1e3;await new Promise(d=>setTimeout(d,f)),(s=n?.signal)===null||s===void 0||s.throwIfAborted()}}catch(l){yield{type:"error",error:l instanceof Or?l:new Or(Qr.InternalError,String(l))}}}request(t,r,n){let{relatedRequestId:i,resumptionToken:a,onresumptiontoken:o,task:s,relatedTask:c}=n??{};return new Promise((u,l)=>{var p,f,d,h,m,v,_;let T=k=>{l(k)};if(!this._transport){T(new Error("Not connected"));return}if(((p=this._options)===null||p===void 0?void 0:p.enforceStrictCapabilities)===!0)try{this.assertCapabilityForMethod(t.method),s&&this.assertTaskCapability(t.method)}catch(k){T(k);return}(f=n?.signal)===null||f===void 0||f.throwIfAborted();let O=this._requestMessageId++,S={...t,jsonrpc:"2.0",id:O};n?.onprogress&&(this._progressHandlers.set(O,n.onprogress),S.params={...t.params,_meta:{...((d=t.params)===null||d===void 0?void 0:d._meta)||{},progressToken:O}}),s&&(S.params={...S.params,task:s}),c&&(S.params={...S.params,_meta:{...((h=S.params)===null||h===void 0?void 0:h._meta)||{},[zh]:c}});let A=k=>{var z;this._responseHandlers.delete(O),this._progressHandlers.delete(O),this._cleanupTimeout(O),(z=this._transport)===null||z===void 0||z.send({jsonrpc:"2.0",method:"notifications/cancelled",params:{requestId:O,reason:String(k)}},{relatedRequestId:i,resumptionToken:a,onresumptiontoken:o}).catch(B=>this._onerror(new Error(`Failed to send cancellation: ${B}`)));let L=k instanceof Or?k:new Or(Qr.RequestTimeout,String(k));l(L)};this._responseHandlers.set(O,k=>{var z;if(!(!((z=n?.signal)===null||z===void 0)&&z.aborted)){if(k instanceof Error)return l(k);try{let L=n0(r,k.result);L.success?u(L.data):l(L.error)}catch(L){l(L)}}}),(m=n?.signal)===null||m===void 0||m.addEventListener("abort",()=>{var k;A((k=n?.signal)===null||k===void 0?void 0:k.reason)});let P=(v=n?.timeout)!==null&&v!==void 0?v:wDr,I=()=>A(Or.fromError(Qr.RequestTimeout,"Request timed out",{timeout:P}));this._setupTimeout(O,P,n?.maxTotalTimeout,I,(_=n?.resetTimeoutOnProgress)!==null&&_!==void 0?_:!1);let j=c?.taskId;if(j){let k=z=>{let L=this._responseHandlers.get(O);L?L(z):this._onerror(new Error(`Response handler missing for side-channeled request ${O}`))};this._requestResolvers.set(O,k),this._enqueueTaskMessage(j,{type:"request",message:S,timestamp:Date.now()}).catch(z=>{this._cleanupTimeout(O),l(z)})}else this._transport.send(S,{relatedRequestId:i,resumptionToken:a,onresumptiontoken:o}).catch(k=>{this._cleanupTimeout(O),l(k)})})}async getTask(t,r){return this.request({method:"tasks/get",params:t},I5,r)}async getTaskResult(t,r,n){return this.request({method:"tasks/result",params:t},r,n)}async listTasks(t,r){return this.request({method:"tasks/list",params:t},k5,r)}async cancelTask(t,r){return this.request({method:"tasks/cancel",params:t},aYe,r)}async notification(t,r){var n,i,a,o,s;if(!this._transport)throw new Error("Not connected");this.assertNotificationCapability(t.method);let c=(n=r?.relatedTask)===null||n===void 0?void 0:n.taskId;if(c){let f={...t,jsonrpc:"2.0",params:{...t.params,_meta:{...((i=t.params)===null||i===void 0?void 0:i._meta)||{},[zh]:r.relatedTask}}};await this._enqueueTaskMessage(c,{type:"notification",message:f,timestamp:Date.now()});return}if(((o=(a=this._options)===null||a===void 0?void 0:a.debouncedNotificationMethods)!==null&&o!==void 0?o:[]).includes(t.method)&&!t.params&&!r?.relatedRequestId&&!r?.relatedTask){if(this._pendingDebouncedNotifications.has(t.method))return;this._pendingDebouncedNotifications.add(t.method),Promise.resolve().then(()=>{var f,d;if(this._pendingDebouncedNotifications.delete(t.method),!this._transport)return;let h={...t,jsonrpc:"2.0"};r?.relatedTask&&(h={...h,params:{...h.params,_meta:{...((f=h.params)===null||f===void 0?void 0:f._meta)||{},[zh]:r.relatedTask}}}),(d=this._transport)===null||d===void 0||d.send(h,r).catch(m=>this._onerror(m))});return}let p={...t,jsonrpc:"2.0"};r?.relatedTask&&(p={...p,params:{...p.params,_meta:{...((s=p.params)===null||s===void 0?void 0:s._meta)||{},[zh]:r.relatedTask}}}),await this._transport.send(p,r)}setRequestHandler(t,r){let n=zpe(t);this.assertRequestHandlerCapability(n),this._requestHandlers.set(n,(i,a)=>{let o=Hpe(t,i);return Promise.resolve(r(o,a))})}removeRequestHandler(t){this._requestHandlers.delete(t)}assertCanSetRequestHandler(t){if(this._requestHandlers.has(t))throw new Error(`A request handler for ${t} already exists, which would be overridden`)}setNotificationHandler(t,r){let n=zpe(t);this._notificationHandlers.set(n,i=>{let a=Hpe(t,i);return Promise.resolve(r(a))})}removeNotificationHandler(t){this._notificationHandlers.delete(t)}_cleanupTaskProgressHandler(t){let r=this._taskProgressTokens.get(t);r!==void 0&&(this._progressHandlers.delete(r),this._taskProgressTokens.delete(t))}async _enqueueTaskMessage(t,r,n){var i;if(!this._taskStore||!this._taskMessageQueue)throw new Error("Cannot enqueue task message: taskStore and taskMessageQueue are not configured");let a=(i=this._options)===null||i===void 0?void 0:i.maxTaskQueueSize;await this._taskMessageQueue.enqueue(t,r,n,a)}async _clearTaskQueue(t,r){if(this._taskMessageQueue){let n=await this._taskMessageQueue.dequeueAll(t,r);for(let i of n)if(i.type==="request"&&Dpe(i.message)){let a=i.message.id,o=this._requestResolvers.get(a);o?(o(new Or(Qr.InternalError,"Task cancelled or completed")),this._requestResolvers.delete(a)):this._onerror(new Error(`Resolver missing for request ${a} during task ${t} cleanup`))}}}async _waitForTaskUpdate(t,r){var n,i,a;let o=(i=(n=this._options)===null||n===void 0?void 0:n.defaultTaskPollInterval)!==null&&i!==void 0?i:1e3;try{let s=await((a=this._taskStore)===null||a===void 0?void 0:a.getTask(t));s?.pollInterval&&(o=s.pollInterval)}catch{}return new Promise((s,c)=>{if(r.aborted){c(new Or(Qr.InvalidRequest,"Request cancelled"));return}let u=setTimeout(s,o);r.addEventListener("abort",()=>{clearTimeout(u),c(new Or(Qr.InvalidRequest,"Request cancelled"))},{once:!0})})}requestTaskStore(t,r){let n=this._taskStore;if(!n)throw new Error("No task store configured");return{createTask:async i=>{if(!t)throw new Error("No request provided");return await n.createTask(i,t.id,{method:t.method,params:t.params},r)},getTask:async i=>{let a=await n.getTask(i,r);if(!a)throw new Or(Qr.InvalidParams,"Failed to retrieve task: Task not found");return a},storeTaskResult:async(i,a,o)=>{await n.storeTaskResult(i,a,o,r);let s=await n.getTask(i,r);if(s){let c=Fk.parse({method:"notifications/tasks/status",params:s});await this.notification(c),i0(s.status)&&this._cleanupTaskProgressHandler(i)}},getTaskResult:i=>n.getTaskResult(i,r),updateTaskStatus:async(i,a,o)=>{let s=await n.getTask(i,r);if(!s)throw new Or(Qr.InvalidParams,`Task "${i}" not found - it may have been cleaned up`);if(i0(s.status))throw new Or(Qr.InvalidParams,`Cannot update task "${i}" from terminal status "${s.status}" to "${a}". Terminal states (completed, failed, cancelled) cannot transition to other states.`);await n.updateTaskStatus(i,a,o,r);let c=await n.getTask(i,r);if(c){let u=Fk.parse({method:"notifications/tasks/status",params:c});await this.notification(u),i0(c.status)&&this._cleanupTaskProgressHandler(i)}},listTasks:i=>n.listTasks(i,r)}}};function pYe(e){return e!==null&&typeof e=="object"&&!Array.isArray(e)}function fYe(e,t){let r={...e};for(let n in t){let i=n,a=t[i];if(a===void 0)continue;let o=r[i];pYe(o)&&pYe(a)?r[i]={...o,...a}:r[i]=a}return r}var iXe=ft(bz(),1),aXe=ft(nXe(),1);function g$r(){let e=new iXe.Ajv({strict:!1,validateFormats:!0,validateSchema:!1,allErrors:!0});return(0,aXe.default)(e),e}var _z=class{constructor(t){this._ajv=t??g$r()}getValidator(t){var r;let n="$id"in t&&typeof t.$id=="string"?(r=this._ajv.getSchema(t.$id))!==null&&r!==void 0?r:this._ajv.compile(t):this._ajv.compile(t);return i=>n(i)?{valid:!0,data:i,errorMessage:void 0}:{valid:!1,data:void 0,errorMessage:this._ajv.errorsText(n.errors)}}};var xz=class{constructor(t){this._server=t}requestStream(t,r,n){return this._server.requestStream(t,r,n)}async getTask(t,r){return this._server.getTask({taskId:t},r)}async getTaskResult(t,r,n){return this._server.getTaskResult({taskId:t},r,n)}async listTasks(t,r){return this._server.listTasks(t?{cursor:t}:void 0,r)}async cancelTask(t,r){return this._server.cancelTask({taskId:t},r)}};function oXe(e,t,r){var n;if(!e)throw new Error(`${r} does not support task creation (required for ${t})`);switch(t){case"tools/call":if(!(!((n=e.tools)===null||n===void 0)&&n.call))throw new Error(`${r} does not support task creation for tools/call (required for ${t})`);break;default:break}}function sXe(e,t,r){var n,i;if(!e)throw new Error(`${r} does not support task creation (required for ${t})`);switch(t){case"sampling/createMessage":if(!(!((n=e.sampling)===null||n===void 0)&&n.createMessage))throw new Error(`${r} does not support task creation for sampling/createMessage (required for ${t})`);break;case"elicitation/create":if(!(!((i=e.elicitation)===null||i===void 0)&&i.create))throw new Error(`${r} does not support task creation for elicitation/create (required for ${t})`);break;default:break}}var Tz=class extends F5{constructor(t,r){var n,i;super(r),this._serverInfo=t,this._loggingLevels=new Map,this.LOG_LEVEL_SEVERITY=new Map(qk.options.map((a,o)=>[a,o])),this.isMessageIgnored=(a,o)=>{let s=this._loggingLevels.get(o);return s?this.LOG_LEVEL_SEVERITY.get(a)<this.LOG_LEVEL_SEVERITY.get(s):!1},this._capabilities=(n=r?.capabilities)!==null&&n!==void 0?n:{},this._instructions=r?.instructions,this._jsonSchemaValidator=(i=r?.jsonSchemaValidator)!==null&&i!==void 0?i:new _z,this.setRequestHandler(Npe,a=>this._oninitialize(a)),this.setNotificationHandler(Ipe,()=>{var a;return(a=this.oninitialized)===null||a===void 0?void 0:a.call(this)}),this._capabilities.logging&&this.setRequestHandler(qpe,async(a,o)=>{var s;let c=o.sessionId||((s=o.requestInfo)===null||s===void 0?void 0:s.headers["mcp-session-id"])||void 0,{level:u}=a.params,l=qk.safeParse(u);return l.success&&this._loggingLevels.set(c,l.data),{}})}get experimental(){return this._experimental||(this._experimental={tasks:new xz(this)}),this._experimental}registerCapabilities(t){if(this.transport)throw new Error("Cannot register capabilities after connecting to transport");this._capabilities=fYe(this._capabilities,t)}setRequestHandler(t,r){var n,i,a;let o=c5(t),s=o?.method;if(!s)throw new Error("Schema is missing a method literal");let c;if(uC(s)){let l=s,p=(n=l._zod)===null||n===void 0?void 0:n.def;c=(i=p?.value)!==null&&i!==void 0?i:l.value}else{let l=s,p=l._def;c=(a=p?.value)!==null&&a!==void 0?a:l.value}if(typeof c!="string")throw new Error("Schema method literal must be a string");if(c==="tools/call"){let l=async(p,f)=>{let d=n0(jk,p);if(!d.success){let _=d.error instanceof Error?d.error.message:String(d.error);throw new Or(Qr.InvalidParams,`Invalid tools/call request: ${_}`)}let{params:h}=d.data,m=await Promise.resolve(r(p,f));if(h.task){let _=n0(fC,m);if(!_.success){let T=_.error instanceof Error?_.error.message:String(_.error);throw new Or(Qr.InvalidParams,`Invalid task creation result: ${T}`)}return _.data}let v=n0($5,m);if(!v.success){let _=v.error instanceof Error?v.error.message:String(v.error);throw new Or(Qr.InvalidParams,`Invalid tools/call result: ${_}`)}return v.data};return super.setRequestHandler(t,l)}return super.setRequestHandler(t,r)}assertCapabilityForMethod(t){var r,n,i;switch(t){case"sampling/createMessage":if(!(!((r=this._clientCapabilities)===null||r===void 0)&&r.sampling))throw new Error(`Client does not support sampling (required for ${t})`);break;case"elicitation/create":if(!(!((n=this._clientCapabilities)===null||n===void 0)&&n.elicitation))throw new Error(`Client does not support elicitation (required for ${t})`);break;case"roots/list":if(!(!((i=this._clientCapabilities)===null||i===void 0)&&i.roots))throw new Error(`Client does not support listing roots (required for ${t})`);break;case"ping":break}}assertNotificationCapability(t){var r,n;switch(t){case"notifications/message":if(!this._capabilities.logging)throw new Error(`Server does not support logging (required for ${t})`);break;case"notifications/resources/updated":case"notifications/resources/list_changed":if(!this._capabilities.resources)throw new Error(`Server does not support notifying about resources (required for ${t})`);break;case"notifications/tools/list_changed":if(!this._capabilities.tools)throw new Error(`Server does not support notifying of tool list changes (required for ${t})`);break;case"notifications/prompts/list_changed":if(!this._capabilities.prompts)throw new Error(`Server does not support notifying of prompt list changes (required for ${t})`);break;case"notifications/elicitation/complete":if(!(!((n=(r=this._clientCapabilities)===null||r===void 0?void 0:r.elicitation)===null||n===void 0)&&n.url))throw new Error(`Client does not support URL elicitation (required for ${t})`);break;case"notifications/cancelled":break;case"notifications/progress":break}}assertRequestHandlerCapability(t){if(this._capabilities)switch(t){case"completion/complete":if(!this._capabilities.completions)throw new Error(`Server does not support completions (required for ${t})`);break;case"logging/setLevel":if(!this._capabilities.logging)throw new Error(`Server does not support logging (required for ${t})`);break;case"prompts/get":case"prompts/list":if(!this._capabilities.prompts)throw new Error(`Server does not support prompts (required for ${t})`);break;case"resources/list":case"resources/templates/list":case"resources/read":if(!this._capabilities.resources)throw new Error(`Server does not support resources (required for ${t})`);break;case"tools/call":case"tools/list":if(!this._capabilities.tools)throw new Error(`Server does not support tools (required for ${t})`);break;case"tasks/get":case"tasks/list":case"tasks/result":case"tasks/cancel":if(!this._capabilities.tasks)throw new Error(`Server does not support tasks capability (required for ${t})`);break;case"ping":case"initialize":break}}assertTaskCapability(t){var r,n;sXe((n=(r=this._clientCapabilities)===null||r===void 0?void 0:r.tasks)===null||n===void 0?void 0:n.requests,t,"Client")}assertTaskHandlerCapability(t){var r;this._capabilities&&oXe((r=this._capabilities.tasks)===null||r===void 0?void 0:r.requests,t,"Server")}async _oninitialize(t){let r=t.params.protocolVersion;return this._clientCapabilities=t.params.capabilities,this._clientVersion=t.params.clientInfo,{protocolVersion:KKe.includes(r)?r:wpe,capabilities:this.getCapabilities(),serverInfo:this._serverInfo,...this._instructions&&{instructions:this._instructions}}}getClientCapabilities(){return this._clientCapabilities}getClientVersion(){return this._clientVersion}getCapabilities(){return this._capabilities}async ping(){return this.request({method:"ping"},C5)}async createMessage(t,r){var n,i;if((t.tools||t.toolChoice)&&!(!((i=(n=this._clientCapabilities)===null||n===void 0?void 0:n.sampling)===null||i===void 0)&&i.tools))throw new Error("Client does not support sampling tools capability.");if(t.messages.length>0){let a=t.messages[t.messages.length-1],o=Array.isArray(a.content)?a.content:[a.content],s=o.some(p=>p.type==="tool_result"),c=t.messages.length>1?t.messages[t.messages.length-2]:void 0,u=c?Array.isArray(c.content)?c.content:[c.content]:[],l=u.some(p=>p.type==="tool_use");if(s){if(o.some(p=>p.type!=="tool_result"))throw new Error("The last message must contain only tool_result content if any is present");if(!l)throw new Error("tool_result blocks are not matching any tool_use from the previous message")}if(l){let p=new Set(u.filter(d=>d.type==="tool_use").map(d=>d.id)),f=new Set(o.filter(d=>d.type==="tool_result").map(d=>d.toolUseId));if(p.size!==f.size||![...p].every(d=>f.has(d)))throw new Error("ids of tool_result blocks and tool_use blocks from previous message do not match")}}return t.tools?this.request({method:"sampling/createMessage",params:t},Upe,r):this.request({method:"sampling/createMessage",params:t},Vpe,r)}async elicitInput(t,r){var n,i,a,o,s;switch((n=t.mode)!==null&&n!==void 0?n:"form"){case"url":{if(!(!((a=(i=this._clientCapabilities)===null||i===void 0?void 0:i.elicitation)===null||a===void 0)&&a.url))throw new Error("Client does not support url elicitation.");let u=t;return this.request({method:"elicitation/create",params:u},M5,r)}case"form":{if(!(!((s=(o=this._clientCapabilities)===null||o===void 0?void 0:o.elicitation)===null||s===void 0)&&s.form))throw new Error("Client does not support form elicitation.");let u=t.mode==="form"?t:{...t,mode:"form"},l=await this.request({method:"elicitation/create",params:u},M5,r);if(l.action==="accept"&&l.content&&u.requestedSchema)try{let f=this._jsonSchemaValidator.getValidator(u.requestedSchema)(l.content);if(!f.valid)throw new Or(Qr.InvalidParams,`Elicitation response content does not match requested schema: ${f.errorMessage}`)}catch(p){throw p instanceof Or?p:new Or(Qr.InternalError,`Error validating elicitation response: ${p instanceof Error?p.message:String(p)}`)}return l}}}createElicitationCompletionNotifier(t,r){var n,i;if(!(!((i=(n=this._clientCapabilities)===null||n===void 0?void 0:n.elicitation)===null||i===void 0)&&i.url))throw new Error("Client does not support URL elicitation (required for notifications/elicitation/complete)");return()=>this.notification({method:"notifications/elicitation/complete",params:{elicitationId:t}},r)}async listRoots(t,r){return this.request({method:"roots/list",params:t},Bpe,r)}async sendLoggingMessage(t,r){if(this._capabilities.logging&&!this.isMessageIgnored(t.level,r))return this.notification({method:"notifications/message",params:t})}async sendResourceUpdated(t){return this.notification({method:"notifications/resources/updated",params:t})}async sendResourceListChanged(){return this.notification({method:"notifications/resources/list_changed"})}async sendToolListChanged(){return this.notification({method:"notifications/tools/list_changed"})}async sendPromptListChanged(){return this.notification({method:"notifications/prompts/list_changed"})}};var $de=ft(require("node:process"),1);var Oz=class{append(t){this._buffer=this._buffer?Buffer.concat([this._buffer,t]):t}readMessage(){if(!this._buffer)return null;let t=this._buffer.indexOf(`
|
|
1642
1642
|
`);if(t===-1)return null;let r=this._buffer.toString("utf8",0,t).replace(/\r$/,"");return this._buffer=this._buffer.subarray(t+1),v$r(r)}clear(){this._buffer=void 0}};function v$r(e){return rYe.parse(JSON.parse(e))}function cXe(e){return JSON.stringify(e)+`
|
|
1643
|
-
`}var Sz=class{constructor(t=$de.default.stdin,r=$de.default.stdout){this._stdin=t,this._stdout=r,this._readBuffer=new Oz,this._started=!1,this._ondata=n=>{this._readBuffer.append(n),this.processReadBuffer()},this._onerror=n=>{var i;(i=this.onerror)===null||i===void 0||i.call(this,n)}}async start(){if(this._started)throw new Error("StdioServerTransport already started! If using Server class, note that connect() calls start() automatically.");this._started=!0,this._stdin.on("data",this._ondata),this._stdin.on("error",this._onerror)}processReadBuffer(){for(var t,r;;)try{let n=this._readBuffer.readMessage();if(n===null)break;(t=this.onmessage)===null||t===void 0||t.call(this,n)}catch(n){(r=this.onerror)===null||r===void 0||r.call(this,n)}}async close(){var t;this._stdin.off("data",this._ondata),this._stdin.off("error",this._onerror),this._stdin.listenerCount("data")===0&&this._stdin.pause(),this._readBuffer.clear(),(t=this.onclose)===null||t===void 0||t.call(this)}send(t){return new Promise(r=>{let n=cXe(t);this._stdout.write(n)?r():this._stdout.once("drain",r)})}};var lXe="0.4.8";var y$={name:"@sap-ux/fiori-mcp-server",description:"SAP Fiori - Model Context Protocol (MCP) server",version:lXe,keywords:["SAP Fiori tools","SAP Fiori elements","SAP Fiori freestyle","MCP","AI"],repository:{type:"git",url:"https://github.com/SAP/open-ux-tools.git",directory:"packages/fiori-mcp-server"},bugs:{url:"https://github.com/SAP/open-ux-tools/issues?q=is%3Aopen+is%3Aissue+label%3Abug+label%3Afiori-mcp-server"},license:"Apache-2.0",main:"dist/index.js",scripts:{"build-esbuild-base":"esbuild --bundle --platform=node --target=node20 --outdir=dist --external:vscode --external:@lancedb/lancedb --external:@xenova/transformers --external:@sap-ux/fiori-docs-embeddings --external:@sap-ux/store --main-fields=module,main src/index.ts","build-dev":"pnpm run build-esbuild-base --sourcemap=inline","build-compile":"tsc --noEmit","build-bundle":"pnpm run build-esbuild-base --minify",build:"npm-run-all build-compile build-bundle",watch:"tsc --watch",bundle:"npm-run-all build tgz:package tgz:rename","tgz:package":"pnpm pack","tgz:rename":"node -e \"const fs=require('fs'), p=require('./package.json'), d=new Date().toISOString().split('T')[0], oldName=p.name.startsWith('@') ? `${p.name.replace('@', '').replace('/', '-')}-${p.version}.tgz` : `${p.name}-${p.version}.tgz`; fs.renameSync(oldName, `${oldName.replace('.tgz','')}-${d}.tgz`)\"",clean:"rimraf --glob dist test/test-output *.tsbuildinfo",format:"prettier --write '**/*.{js,json,ts,yaml,yml}' --ignore-path ../../.prettierignore",lint:"eslint . --ext .ts","lint:fix":"eslint . --ext .ts --fix",test:"jest --ci --forceExit --detectOpenHandles --colors",inspector:"npx @modelcontextprotocol/inspector node dist/index.js",start:'npx -y supergateway --port 9881 --sessionTimeout 300000 --stdio "node ./dist/index.js"',"view:integration":"promptfoo view -y","test:integration:once":"promptfoo eval --config test/integration/scenarios/promptfooconfig.yaml --max-concurrency 1 --repeat 1 --output reports/integration.txt","test:integration:dev":"promptfoo eval --config test/integration/scenarios/test-dev.yaml --max-concurrency 1 --repeat 1 --output reports/integration.txt","test:integration:multiple":"npm run test:promptfoo -- --repeat 5"},files:["LICENSE","dist","!dist/**/*.map"],bin:{"fiori-mcp":"./dist/index.js"},devDependencies:{"npm-run-all2":"8.0.4",esbuild:"0.25.6","@modelcontextprotocol/sdk":"1.24.1","@sap-ux/axios-extension":"workspace:*","@sap/ux-specification":"1.139.1","@sap-ux/project-access":"workspace:*","@sap-ux/fiori-annotation-api":"workspace:*","@sap-ux/annotation-converter":"0.10.8","@sap-ux/fiori-docs-embeddings":"workspace:*","@sap-ux/i18n":"workspace:*","@sap-ux/logger":"workspace:*","@sap-ux/odata-annotation-core-types":"workspace:*","@sap-ux/odata-entity-model":"workspace:*","@sap-ux/text-document-utils":"workspace:*","@types/diff":"5.0.9","@types/json-schema":"7.0.5","@types/mem-fs":"1.1.2","@types/mem-fs-editor":"7.0.1","@sap-ux/btp-utils":"workspace:*","@sap-ux/feature-toggle":"workspace:*","@sap-ux/nodejs-utils":"workspace:*","@sap-ux/telemetry":"workspace:*",i18next:"25.3.0","os-name":"4.0.1",zod:"4.1.13","@sap-ai-sdk/foundation-models":"2.0.0","@sap-ai-sdk/langchain":"2.0.0",promptfoo:"0.118.6","@langchain/mcp-adapters":"0.6.0","@langchain/core":"0.3.75"},dependencies:{"@sap-ux/fiori-docs-embeddings":"workspace:*","@sap-ux/store":"workspace:*","@xenova/transformers":"2.17.2","@lancedb/lancedb":"0.22.0","mem-fs":"2.1.0","mem-fs-editor":"9.4.0"},engines:{node:">=20.x"}};var dXe=xe({name:Q().describe("Name of the Fiori application. Usually derived from the `sap.app/id` field in the application's manifest.json."),appPath:Q().describe("Absolute path to the Fiori application's root directory."),projectPath:Q().describe("Absolute path to the root directory of the project containing this Fiori application. For EDMXBackend (standalone) projects, this is the same as `appPath`. For CAP projects, this points to the CAP project root, which may contain multiple Fiori applications."),projectType:Dn(["EDMXBackend","CAPJava","CAPNodejs"]).describe("Type of project the application belongs to."),odataVersion:Q().describe("OData protocol version used by the application's main service.")}),Gx=an([Q(),Ut(an([Q(),Pn()]))]),hXe=xe({functionalityId:Gx.describe("Identifier to pass as the `functionalityId` parameter when calling `get_functionality_details` or `execute_functionality`"),description:Q()}),pXe=Dn(["object","array","string","number","boolean","null","integer","any"]),fXe=xe({type:an([pXe,Ut(pXe)]).optional(),description:Q().optional(),properties:v5().optional()}).catchall(v5()),mXe=fXe.extend({properties:di(Q(),an([fXe,Ki()])).optional()});var gXe=xe({searchPath:Ut(Q()).describe("Path to search for Fiori applications (defaults to current directory). If VSCode - list of VS Code workspace folder paths(`workspace.workspaceFolders`)")}),yXe=xe({appPath:Q().describe("Path to the root folder of the Fiori application (where package.json and ui5.yaml reside) if one exists or to the current directory. Path should be an absolute path.")}),vXe=xe({appPath:Q().describe("Path to the Fiori application if one exists or to the current directory. Path should be an absolute path."),functionalityId:Gx.describe("The ID of the functionality to get details for")}),bXe=xe({functionalityId:Gx.describe("The ID of the functionality to execute"),parameters:di(Q(),oi()).describe("Parameters for the functionality execution"),appPath:Q().describe("Path to the Fiori application if one exists or to the current directory. Path should be an absolute path.")}).describe('Input object for executing a functionality. Only three top-level properties are allowed: "functionalityId", "parameters", and "appPath". All other dynamic or functionality-specific inputs must be included inside the "parameters" object. Do not place any additional fields at the root level.'),nDi=xe({query:Q().min(2).describe("The search query for fiori elements, annotations, sapui5, fiori tools documentation")});var aDi=Q().describe("Search results as formatted text"),EXe=xe({applications:Ut(dXe)}),_Xe=xe({applicationPath:Q(),functionalities:Ut(hXe)}),xXe=xe({functionalityId:Gx.describe("Identifier to pass as the `functionalityId` parameter when calling `get_functionality_details` or `execute_functionality`"),name:Q(),description:Q(),technicalDescription:Q().optional(),parameters:mXe,prerequisites:Ut(Q()).optional(),impact:Q().optional(),examples:Ut(Q()).optional(),pageName:Q().optional()}),TXe=xe({functionalityId:Gx,status:Q(),message:Q(),parameters:oi(),appPath:Q(),changes:Ut(Q()),timestamp:Q()});var bge=ft(require("node:fs/promises")),uf=ft(require("node:path"));var cf=ft(w0());function m9r(){let e=globalThis.LOG_LEVEL,t=process.env.LOG_LEVEL,r=process.argv.find(i=>i.startsWith("--log-level="))?.split("=")[1],n=e||t||r;if(n)switch(n.toUpperCase()){case"ERROR":return cf.LogLevel.Error;case"WARN":return cf.LogLevel.Warn;case"INFO":return cf.LogLevel.Info;case"DEBUG":return cf.LogLevel.Debug;case"VERBOSE":return cf.LogLevel.Verbose;case"SILLY":return cf.LogLevel.Silly;default:break}return cf.LogLevel.Error}var g9r=m9r(),Dt=new cf.ToolsLogger({logLevel:g9r,transports:[new cf.ConsoleTransport],logPrefix:"fiori-mcp"});async function Jat(){try{let r;try{r=require("@sap-ux/fiori-docs-embeddings")}catch{try{r=await import("@sap-ux/fiori-docs-embeddings")}catch{r=null}}if(!r||typeof r.getDataPath!="function")throw new Error("Package not found or invalid");let n=r.getDataPath();return await bge.default.access(n),Dt.log("\u2713 Using @sap-ux/fiori-docs-embeddings package"),{dataPath:n,embeddingsPath:uf.default.join(n,"embeddings"),searchPath:uf.default.join(n,"search"),docsPath:uf.default.join(n,"docs"),isExternalPackage:!0,isAvailable:!0}}catch{Dt.warn("Could not load @sap-ux/fiori-docs-embeddings package, trying local data...")}let e=uf.default.join(__dirname,"../../data");try{return await bge.default.access(e),Dt.log("\u2713 Using local data directory"),{dataPath:e,embeddingsPath:uf.default.join(e,"embeddings"),searchPath:uf.default.join(e,"search"),docsPath:uf.default.join(e,"docs"),isExternalPackage:!1,isAvailable:!0}}catch{Dt.warn("Local data directory not available either")}let t=uf.default.join(__dirname,"../../data");return Dt.warn("\u26A0\uFE0F No embeddings data available - running in limited mode"),{dataPath:t,embeddingsPath:uf.default.join(t,"embeddings"),searchPath:uf.default.join(t,"search"),docsPath:uf.default.join(t,"docs"),isExternalPackage:!1,isAvailable:!1}}var fc=ft(Bd()),lF=require("node:path");async function nu(e){try{e=(0,lF.join)(e);try{let t=await(0,fc.createApplicationAccess)(e);return{root:t.project.root,appId:t.getAppId(),applicationAccess:t}}catch(t){Dt.warn(`Application was not found by given path. Error: ${t}`);let r=await(0,fc.findProjectRoot)(e),n=await(0,fc.getProject)(r);if(n)return{root:n.root,appId:""}}}catch(t){Dt.warn(`Project was not found by given path. Error: ${t}`);return}}var NY=e=>{let t;switch(e){case fc.DirName.View:{t=(0,lF.join)(fc.DirName.Ext,fc.DirName.View);break}case fc.DirName.Fragment:{t=(0,lF.join)(fc.DirName.Ext,fc.DirName.Fragment);break}case fc.DirName.Controller:{t=(0,lF.join)(fc.DirName.Ext,fc.DirName.Controller);break}default:t=e}return t},vm=(e,t,r=new Set)=>{if(!e||typeof e!="object")return{};if(e.$ref?.startsWith("#/definitions/")){let i=e.$ref,a=i.replace("#/definitions/",""),o=t.definitions?.[a]??null;if(r.has(i))return{...o};if(r.add(i),o){let s={...e};return delete s.$ref,vm({...o,...s},t,r)}}let n={...e};return n.properties&&(n.properties=Object.fromEntries(Object.entries(n.properties).map(([i,a])=>[i,vm(a,t,r)]))),n.items&&(Array.isArray(n.items)?n.items=n.items.map(i=>vm(i,t,r)):n.items=vm(n.items,t,r)),n.allOf&&(n.allOf=n.allOf.map(i=>vm(i,t,r))),n.anyOf&&(n.anyOf=n.anyOf.map(i=>vm(i,t,r))),n.oneOf&&(n.oneOf=n.oneOf.map(i=>vm(i,t,r))),typeof n.additionalProperties=="object"&&(n.additionalProperties=vm(n.additionalProperties,t,r)),n},Gxt=(e,t)=>({type:"object",properties:{[e]:t}}),va=e=>{let t=Ix(e);return delete t.$schema,t},bm=(e,t)=>{try{return e.parse(t)}catch(r){throw r instanceof Mle?new Error(`Missing required fields in parameters. ${JSON.stringify(r.issues,null,4)}`):new Error("Unknown error. Recheck input parameters.")}};var vRt=require("node:util"),bRt=require("node:child_process"),ERt=ft(mCe());async function FW(e="1.18.5"){let t="@sap/generator-fiori";if((await(0,ERt.findInstalledPackages)(t,{minVersion:e}))?.length<1)throw new Error(`Fiori generator not found. Please install the Fiori generator >=${e} with 'npm install -g ${t}' and retry this call`)}var jW=(0,vRt.promisify)(bRt.exec);var _Rt=require("@lancedb/lancedb");var gCe=ft(require("fs/promises")),yCe=ft(require("node:path")),qW=class{connection=null;tables=[];tableIndex=null;metadata=null;dataPath;constructor(t){this.dataPath=t||""}async initialize(){try{Dt.log("Loading vector database from pre-built embeddings...");let t=await Jat();if(!t.isAvailable)throw new Error("No embeddings data available");this.dataPath=t.embeddingsPath,Dt.log(`Using embeddings path: ${this.dataPath} (external: ${t.isExternalPackage})`);let r=yCe.default.join(this.dataPath,"metadata.json"),n=await gCe.default.readFile(r,"utf-8");this.metadata=JSON.parse(n),Dt.log("\u2713 Embedding metadata loaded:"),Dt.log(` Model: ${this?.metadata?.model}`),Dt.log(` Dimensions: ${this?.metadata?.dimensions}`),Dt.log(` Total vectors: ${this?.metadata?.totalVectors}`),Dt.log(` Created: ${this?.metadata?.createdAt}`),this.connection=await(0,_Rt.connect)(this.dataPath);let i=yCe.default.join(this.dataPath,"table_index.json");try{let a=await gCe.default.readFile(i,"utf-8");this.tableIndex=JSON.parse(a),this.tables=[];for(let o of this.tableIndex?.tables||[]){let s=await this.connection.openTable(o);this.tables.push(s)}Dt.log(`\u2713 Loaded ${this.tables.length} split tables`)}catch{Dt.log("No table index found, trying single table...");try{let a=await this.connection.openTable("documents");this.tables=[a],this.tableIndex={tables:["documents"],totalTables:1,maxVectorsPerTable:-1,totalVectors:this.metadata?.totalVectors||0}}catch(a){throw new Error(`No tables found: ${a}`)}}Dt.log("\u2713 Vector database loaded and ready")}catch(t){throw new Error(`Failed to load vector database: ${t}`)}}async semanticSearch(t,r=10,n){if(this.tables.length===0)throw new Error("Vector database not initialized");try{let i=[];for(let o of this.tables){let s=o.vectorSearch(t).limit(r*2);n&&(s=s.where(`category = "${n}"`));let c=await s.toArray();i.push(...c)}return i.sort((o,s)=>(o._distance||0)-(s._distance||0)),i.slice(0,r).map(o=>({document:{id:o.document_id,vector:o.vector,content:o.content,title:o.title,category:o.category,path:o.path,chunk_index:o.chunk_index,metadata:{tags:this.parseJsonField(o.tags_json)||[],headers:this.parseJsonField(o.headers_json)||[],lastModified:new Date(o.lastModified),wordCount:o.wordCount,excerpt:o.excerpt}},score:1-(o._distance||0),distance:o._distance||0}))}catch(i){throw Dt.error(`Semantic search failed: ${i}`),new Error(`Semantic search failed: ${i}`)}}async findSimilarToText(t,r=5){return Dt.warn("findSimilarToText requires embedding generation - not available in simplified mode"),[]}async findSimilarToDocument(t,r=5){if(this.tables.length===0)throw new Error("Vector database not initialized");try{let n=null;for(let s of this.tables){let c=await s.search("").where(`document_id = "${t}" AND chunk_index = 0`).limit(1).toArray();if(c.length>0){n=c[0].vector;break}}if(!n)return[];let i=[];for(let s of this.tables){let c=await s.vectorSearch(n).where(`document_id != "${t}"`).limit(r*2).toArray();i.push(...c)}let a=new Map;for(let s of i){let c=s.document_id,u=1-(s._distance||0);(!a.has(c)||a.get(c).score<u)&&a.set(c,{...s,score:u,distance:s._distance||0})}return Array.from(a.values()).sort((s,c)=>c.score-s.score).slice(0,r).map(s=>({document:{id:s.document_id,vector:s.vector,content:s.content,title:s.title,category:s.category,path:s.path,chunk_index:s.chunk_index,metadata:{tags:this.parseJsonField(s.tags_json)||[],headers:this.parseJsonField(s.headers_json)||[],lastModified:new Date(s.lastModified),wordCount:s.wordCount,excerpt:s.excerpt}},score:s.score,distance:s.distance}))}catch(n){return Dt.error(`Find similar documents failed: ${n}`),[]}}async getDocumentsByCategory(t,r){if(this.tables.length===0)throw new Error("Vector database not initialized");try{let n=[];for(let a of this.tables){let o=a.search("").where(`category = "${t}" AND chunk_index = 0`);r&&(o=o.limit(Math.ceil(r/this.tables.length)+10));let s=await o.toArray();n.push(...s)}return(r?n.slice(0,r):n).map(a=>({document:{id:a.document_id,vector:a.vector,content:a.content,title:a.title,category:a.category,path:a.path,chunk_index:a.chunk_index,metadata:{tags:this.parseJsonField(a.tags_json)||[],headers:this.parseJsonField(a.headers_json)||[],lastModified:new Date(a.lastModified),wordCount:a.wordCount,excerpt:a.excerpt}},score:1,distance:0}))}catch(n){return Dt.error(`Get documents by category failed: ${n}`),[]}}getMetadata(){return this.metadata}parseJsonField(t){try{return t?JSON.parse(t):[]}catch{return[]}}isInitialized(){return this.tables.length>0&&this.metadata!==null}async close(){this.connection&&(this.connection=null,this.tables=[],Dt.log("Vector database connection closed"))}};var VW=class{pipeline=null;initialized=!1;async initialize(){if(!this.initialized)try{let{pipeline:t}=await import("@xenova/transformers");this.pipeline=await t("feature-extraction","Xenova/all-MiniLM-L6-v2",{quantized:!1}),this.initialized=!0}catch(t){throw new Error(`Failed to initialize text embedding service: ${t}. Make sure @xenova/transformers is available.`)}}async generateEmbedding(t){if(!this.initialized||!this.pipeline)throw new Error("Text embedding service not initialized. Call initialize() first.");try{let r=t.replace(/\n+/g," ").replace(/\s+/g," ").trim().substring(0,8192);if(!r)throw new Error("Empty text provided for embedding");let n=await this.pipeline(r,{pooling:"mean",normalize:!0});return Array.from(n.data)}catch(r){throw new Error(`Failed to generate embedding: ${r}`)}}isInitialized(){return this.initialized}};async function vCe(e,t=!1){let{query:r,maxResults:n}=e;try{let i=new qW,a=new VW;await i.initialize(),await a.initialize();let o=await a.generateEmbedding(r),s=await i.semanticSearch(o,n??10);if(t){let c="";for(let[u,l]of s.entries())c+=`Result ${u+1}:
|
|
1643
|
+
`}var Sz=class{constructor(t=$de.default.stdin,r=$de.default.stdout){this._stdin=t,this._stdout=r,this._readBuffer=new Oz,this._started=!1,this._ondata=n=>{this._readBuffer.append(n),this.processReadBuffer()},this._onerror=n=>{var i;(i=this.onerror)===null||i===void 0||i.call(this,n)}}async start(){if(this._started)throw new Error("StdioServerTransport already started! If using Server class, note that connect() calls start() automatically.");this._started=!0,this._stdin.on("data",this._ondata),this._stdin.on("error",this._onerror)}processReadBuffer(){for(var t,r;;)try{let n=this._readBuffer.readMessage();if(n===null)break;(t=this.onmessage)===null||t===void 0||t.call(this,n)}catch(n){(r=this.onerror)===null||r===void 0||r.call(this,n)}}async close(){var t;this._stdin.off("data",this._ondata),this._stdin.off("error",this._onerror),this._stdin.listenerCount("data")===0&&this._stdin.pause(),this._readBuffer.clear(),(t=this.onclose)===null||t===void 0||t.call(this)}send(t){return new Promise(r=>{let n=cXe(t);this._stdout.write(n)?r():this._stdout.once("drain",r)})}};var lXe="0.4.9";var y$={name:"@sap-ux/fiori-mcp-server",description:"SAP Fiori - Model Context Protocol (MCP) server",version:lXe,keywords:["SAP Fiori tools","SAP Fiori elements","SAP Fiori freestyle","MCP","AI"],repository:{type:"git",url:"https://github.com/SAP/open-ux-tools.git",directory:"packages/fiori-mcp-server"},bugs:{url:"https://github.com/SAP/open-ux-tools/issues?q=is%3Aopen+is%3Aissue+label%3Abug+label%3Afiori-mcp-server"},license:"Apache-2.0",main:"dist/index.js",scripts:{"build-esbuild-base":"esbuild --bundle --platform=node --target=node20 --outdir=dist --external:vscode --external:@lancedb/lancedb --external:@xenova/transformers --external:@sap-ux/fiori-docs-embeddings --external:@sap-ux/store --main-fields=module,main src/index.ts","build-dev":"pnpm run build-esbuild-base --sourcemap=inline","build-compile":"tsc --noEmit","build-bundle":"pnpm run build-esbuild-base --minify",build:"npm-run-all build-compile build-bundle",watch:"tsc --watch",bundle:"npm-run-all build tgz:package tgz:rename","tgz:package":"pnpm pack","tgz:rename":"node -e \"const fs=require('fs'), p=require('./package.json'), d=new Date().toISOString().split('T')[0], oldName=p.name.startsWith('@') ? `${p.name.replace('@', '').replace('/', '-')}-${p.version}.tgz` : `${p.name}-${p.version}.tgz`; fs.renameSync(oldName, `${oldName.replace('.tgz','')}-${d}.tgz`)\"",clean:"rimraf --glob dist test/test-output *.tsbuildinfo",format:"prettier --write '**/*.{js,json,ts,yaml,yml}' --ignore-path ../../.prettierignore",lint:"eslint . --ext .ts","lint:fix":"eslint . --ext .ts --fix",test:"jest --ci --forceExit --detectOpenHandles --colors",inspector:"npx @modelcontextprotocol/inspector node dist/index.js",start:'npx -y supergateway --port 9881 --sessionTimeout 300000 --stdio "node ./dist/index.js"',"view:integration":"promptfoo view -y","test:integration:once":"promptfoo eval --config test/integration/scenarios/promptfooconfig.yaml --max-concurrency 1 --repeat 1 --output reports/integration.txt","test:integration:dev":"promptfoo eval --config test/integration/scenarios/test-dev.yaml --max-concurrency 1 --repeat 1 --output reports/integration.txt","test:integration:multiple":"npm run test:promptfoo -- --repeat 5"},files:["LICENSE","dist","!dist/**/*.map"],bin:{"fiori-mcp":"./dist/index.js"},devDependencies:{"npm-run-all2":"8.0.4",esbuild:"0.25.6","@modelcontextprotocol/sdk":"1.24.1","@sap-ux/axios-extension":"workspace:*","@sap/ux-specification":"1.139.1","@sap-ux/project-access":"workspace:*","@sap-ux/fiori-annotation-api":"workspace:*","@sap-ux/annotation-converter":"0.10.8","@sap-ux/fiori-docs-embeddings":"workspace:*","@sap-ux/i18n":"workspace:*","@sap-ux/logger":"workspace:*","@sap-ux/odata-annotation-core-types":"workspace:*","@sap-ux/odata-entity-model":"workspace:*","@sap-ux/text-document-utils":"workspace:*","@types/diff":"5.0.9","@types/json-schema":"7.0.5","@types/mem-fs":"1.1.2","@types/mem-fs-editor":"7.0.1","@sap-ux/btp-utils":"workspace:*","@sap-ux/feature-toggle":"workspace:*","@sap-ux/nodejs-utils":"workspace:*","@sap-ux/telemetry":"workspace:*",i18next:"25.3.0","os-name":"4.0.1",zod:"4.1.13","@sap-ai-sdk/foundation-models":"2.3.0","@sap-ai-sdk/langchain":"2.3.0",promptfoo:"0.119.14","@langchain/mcp-adapters":"1.0.2","@langchain/core":"1.1.1"},dependencies:{"@sap-ux/fiori-docs-embeddings":"workspace:*","@sap-ux/store":"workspace:*","@xenova/transformers":"2.17.2","@lancedb/lancedb":"0.22.0","mem-fs":"2.1.0","mem-fs-editor":"9.4.0"},engines:{node:">=20.x"}};var dXe=xe({name:Q().describe("Name of the Fiori application. Usually derived from the `sap.app/id` field in the application's manifest.json."),appPath:Q().describe("Absolute path to the Fiori application's root directory."),projectPath:Q().describe("Absolute path to the root directory of the project containing this Fiori application. For EDMXBackend (standalone) projects, this is the same as `appPath`. For CAP projects, this points to the CAP project root, which may contain multiple Fiori applications."),projectType:Dn(["EDMXBackend","CAPJava","CAPNodejs"]).describe("Type of project the application belongs to."),odataVersion:Q().describe("OData protocol version used by the application's main service.")}),Gx=an([Q(),Ut(an([Q(),Pn()]))]),hXe=xe({functionalityId:Gx.describe("Identifier to pass as the `functionalityId` parameter when calling `get_functionality_details` or `execute_functionality`"),description:Q()}),pXe=Dn(["object","array","string","number","boolean","null","integer","any"]),fXe=xe({type:an([pXe,Ut(pXe)]).optional(),description:Q().optional(),properties:v5().optional()}).catchall(v5()),mXe=fXe.extend({properties:di(Q(),an([fXe,Ki()])).optional()});var gXe=xe({searchPath:Ut(Q()).describe("Path to search for Fiori applications (defaults to current directory). If VSCode - list of VS Code workspace folder paths(`workspace.workspaceFolders`)")}),yXe=xe({appPath:Q().describe("Path to the root folder of the Fiori application (where package.json and ui5.yaml reside) if one exists or to the current directory. Path should be an absolute path.")}),vXe=xe({appPath:Q().describe("Path to the Fiori application if one exists or to the current directory. Path should be an absolute path."),functionalityId:Gx.describe("The ID of the functionality to get details for")}),bXe=xe({functionalityId:Gx.describe("The ID of the functionality to execute"),parameters:di(Q(),oi()).describe("Parameters for the functionality execution"),appPath:Q().describe("Path to the Fiori application if one exists or to the current directory. Path should be an absolute path.")}).describe('Input object for executing a functionality. Only three top-level properties are allowed: "functionalityId", "parameters", and "appPath". All other dynamic or functionality-specific inputs must be included inside the "parameters" object. Do not place any additional fields at the root level.'),nDi=xe({query:Q().min(2).describe("The search query for fiori elements, annotations, sapui5, fiori tools documentation")});var aDi=Q().describe("Search results as formatted text"),EXe=xe({applications:Ut(dXe)}),_Xe=xe({applicationPath:Q(),functionalities:Ut(hXe)}),xXe=xe({functionalityId:Gx.describe("Identifier to pass as the `functionalityId` parameter when calling `get_functionality_details` or `execute_functionality`"),name:Q(),description:Q(),technicalDescription:Q().optional(),parameters:mXe,prerequisites:Ut(Q()).optional(),impact:Q().optional(),examples:Ut(Q()).optional(),pageName:Q().optional()}),TXe=xe({functionalityId:Gx,status:Q(),message:Q(),parameters:oi(),appPath:Q(),changes:Ut(Q()),timestamp:Q()});var bge=ft(require("node:fs/promises")),uf=ft(require("node:path"));var cf=ft(w0());function m9r(){let e=globalThis.LOG_LEVEL,t=process.env.LOG_LEVEL,r=process.argv.find(i=>i.startsWith("--log-level="))?.split("=")[1],n=e||t||r;if(n)switch(n.toUpperCase()){case"ERROR":return cf.LogLevel.Error;case"WARN":return cf.LogLevel.Warn;case"INFO":return cf.LogLevel.Info;case"DEBUG":return cf.LogLevel.Debug;case"VERBOSE":return cf.LogLevel.Verbose;case"SILLY":return cf.LogLevel.Silly;default:break}return cf.LogLevel.Error}var g9r=m9r(),Dt=new cf.ToolsLogger({logLevel:g9r,transports:[new cf.ConsoleTransport],logPrefix:"fiori-mcp"});async function Jat(){try{let r;try{r=require("@sap-ux/fiori-docs-embeddings")}catch{try{r=await import("@sap-ux/fiori-docs-embeddings")}catch{r=null}}if(!r||typeof r.getDataPath!="function")throw new Error("Package not found or invalid");let n=r.getDataPath();return await bge.default.access(n),Dt.log("\u2713 Using @sap-ux/fiori-docs-embeddings package"),{dataPath:n,embeddingsPath:uf.default.join(n,"embeddings"),searchPath:uf.default.join(n,"search"),docsPath:uf.default.join(n,"docs"),isExternalPackage:!0,isAvailable:!0}}catch{Dt.warn("Could not load @sap-ux/fiori-docs-embeddings package, trying local data...")}let e=uf.default.join(__dirname,"../../data");try{return await bge.default.access(e),Dt.log("\u2713 Using local data directory"),{dataPath:e,embeddingsPath:uf.default.join(e,"embeddings"),searchPath:uf.default.join(e,"search"),docsPath:uf.default.join(e,"docs"),isExternalPackage:!1,isAvailable:!0}}catch{Dt.warn("Local data directory not available either")}let t=uf.default.join(__dirname,"../../data");return Dt.warn("\u26A0\uFE0F No embeddings data available - running in limited mode"),{dataPath:t,embeddingsPath:uf.default.join(t,"embeddings"),searchPath:uf.default.join(t,"search"),docsPath:uf.default.join(t,"docs"),isExternalPackage:!1,isAvailable:!1}}var fc=ft(Bd()),lF=require("node:path");async function nu(e){try{e=(0,lF.join)(e);try{let t=await(0,fc.createApplicationAccess)(e);return{root:t.project.root,appId:t.getAppId(),applicationAccess:t}}catch(t){Dt.warn(`Application was not found by given path. Error: ${t}`);let r=await(0,fc.findProjectRoot)(e),n=await(0,fc.getProject)(r);if(n)return{root:n.root,appId:""}}}catch(t){Dt.warn(`Project was not found by given path. Error: ${t}`);return}}var NY=e=>{let t;switch(e){case fc.DirName.View:{t=(0,lF.join)(fc.DirName.Ext,fc.DirName.View);break}case fc.DirName.Fragment:{t=(0,lF.join)(fc.DirName.Ext,fc.DirName.Fragment);break}case fc.DirName.Controller:{t=(0,lF.join)(fc.DirName.Ext,fc.DirName.Controller);break}default:t=e}return t},vm=(e,t,r=new Set)=>{if(!e||typeof e!="object")return{};if(e.$ref?.startsWith("#/definitions/")){let i=e.$ref,a=i.replace("#/definitions/",""),o=t.definitions?.[a]??null;if(r.has(i))return{...o};if(r.add(i),o){let s={...e};return delete s.$ref,vm({...o,...s},t,r)}}let n={...e};return n.properties&&(n.properties=Object.fromEntries(Object.entries(n.properties).map(([i,a])=>[i,vm(a,t,r)]))),n.items&&(Array.isArray(n.items)?n.items=n.items.map(i=>vm(i,t,r)):n.items=vm(n.items,t,r)),n.allOf&&(n.allOf=n.allOf.map(i=>vm(i,t,r))),n.anyOf&&(n.anyOf=n.anyOf.map(i=>vm(i,t,r))),n.oneOf&&(n.oneOf=n.oneOf.map(i=>vm(i,t,r))),typeof n.additionalProperties=="object"&&(n.additionalProperties=vm(n.additionalProperties,t,r)),n},Gxt=(e,t)=>({type:"object",properties:{[e]:t}}),va=e=>{let t=Ix(e);return delete t.$schema,t},bm=(e,t)=>{try{return e.parse(t)}catch(r){throw r instanceof Mle?new Error(`Missing required fields in parameters. ${JSON.stringify(r.issues,null,4)}`):new Error("Unknown error. Recheck input parameters.")}};var vRt=require("node:util"),bRt=require("node:child_process"),ERt=ft(mCe());async function FW(e="1.18.5"){let t="@sap/generator-fiori";if((await(0,ERt.findInstalledPackages)(t,{minVersion:e}))?.length<1)throw new Error(`Fiori generator not found. Please install the Fiori generator >=${e} with 'npm install -g ${t}' and retry this call`)}var jW=(0,vRt.promisify)(bRt.exec);var _Rt=require("@lancedb/lancedb");var gCe=ft(require("fs/promises")),yCe=ft(require("node:path")),qW=class{connection=null;tables=[];tableIndex=null;metadata=null;dataPath;constructor(t){this.dataPath=t||""}async initialize(){try{Dt.log("Loading vector database from pre-built embeddings...");let t=await Jat();if(!t.isAvailable)throw new Error("No embeddings data available");this.dataPath=t.embeddingsPath,Dt.log(`Using embeddings path: ${this.dataPath} (external: ${t.isExternalPackage})`);let r=yCe.default.join(this.dataPath,"metadata.json"),n=await gCe.default.readFile(r,"utf-8");this.metadata=JSON.parse(n),Dt.log("\u2713 Embedding metadata loaded:"),Dt.log(` Model: ${this?.metadata?.model}`),Dt.log(` Dimensions: ${this?.metadata?.dimensions}`),Dt.log(` Total vectors: ${this?.metadata?.totalVectors}`),Dt.log(` Created: ${this?.metadata?.createdAt}`),this.connection=await(0,_Rt.connect)(this.dataPath);let i=yCe.default.join(this.dataPath,"table_index.json");try{let a=await gCe.default.readFile(i,"utf-8");this.tableIndex=JSON.parse(a),this.tables=[];for(let o of this.tableIndex?.tables||[]){let s=await this.connection.openTable(o);this.tables.push(s)}Dt.log(`\u2713 Loaded ${this.tables.length} split tables`)}catch{Dt.log("No table index found, trying single table...");try{let a=await this.connection.openTable("documents");this.tables=[a],this.tableIndex={tables:["documents"],totalTables:1,maxVectorsPerTable:-1,totalVectors:this.metadata?.totalVectors||0}}catch(a){throw new Error(`No tables found: ${a}`)}}Dt.log("\u2713 Vector database loaded and ready")}catch(t){throw new Error(`Failed to load vector database: ${t}`)}}async semanticSearch(t,r=10,n){if(this.tables.length===0)throw new Error("Vector database not initialized");try{let i=[];for(let o of this.tables){let s=o.vectorSearch(t).limit(r*2);n&&(s=s.where(`category = "${n}"`));let c=await s.toArray();i.push(...c)}return i.sort((o,s)=>(o._distance||0)-(s._distance||0)),i.slice(0,r).map(o=>({document:{id:o.document_id,vector:o.vector,content:o.content,title:o.title,category:o.category,path:o.path,chunk_index:o.chunk_index,metadata:{tags:this.parseJsonField(o.tags_json)||[],headers:this.parseJsonField(o.headers_json)||[],lastModified:new Date(o.lastModified),wordCount:o.wordCount,excerpt:o.excerpt}},score:1-(o._distance||0),distance:o._distance||0}))}catch(i){throw Dt.error(`Semantic search failed: ${i}`),new Error(`Semantic search failed: ${i}`)}}async findSimilarToText(t,r=5){return Dt.warn("findSimilarToText requires embedding generation - not available in simplified mode"),[]}async findSimilarToDocument(t,r=5){if(this.tables.length===0)throw new Error("Vector database not initialized");try{let n=null;for(let s of this.tables){let c=await s.search("").where(`document_id = "${t}" AND chunk_index = 0`).limit(1).toArray();if(c.length>0){n=c[0].vector;break}}if(!n)return[];let i=[];for(let s of this.tables){let c=await s.vectorSearch(n).where(`document_id != "${t}"`).limit(r*2).toArray();i.push(...c)}let a=new Map;for(let s of i){let c=s.document_id,u=1-(s._distance||0);(!a.has(c)||a.get(c).score<u)&&a.set(c,{...s,score:u,distance:s._distance||0})}return Array.from(a.values()).sort((s,c)=>c.score-s.score).slice(0,r).map(s=>({document:{id:s.document_id,vector:s.vector,content:s.content,title:s.title,category:s.category,path:s.path,chunk_index:s.chunk_index,metadata:{tags:this.parseJsonField(s.tags_json)||[],headers:this.parseJsonField(s.headers_json)||[],lastModified:new Date(s.lastModified),wordCount:s.wordCount,excerpt:s.excerpt}},score:s.score,distance:s.distance}))}catch(n){return Dt.error(`Find similar documents failed: ${n}`),[]}}async getDocumentsByCategory(t,r){if(this.tables.length===0)throw new Error("Vector database not initialized");try{let n=[];for(let a of this.tables){let o=a.search("").where(`category = "${t}" AND chunk_index = 0`);r&&(o=o.limit(Math.ceil(r/this.tables.length)+10));let s=await o.toArray();n.push(...s)}return(r?n.slice(0,r):n).map(a=>({document:{id:a.document_id,vector:a.vector,content:a.content,title:a.title,category:a.category,path:a.path,chunk_index:a.chunk_index,metadata:{tags:this.parseJsonField(a.tags_json)||[],headers:this.parseJsonField(a.headers_json)||[],lastModified:new Date(a.lastModified),wordCount:a.wordCount,excerpt:a.excerpt}},score:1,distance:0}))}catch(n){return Dt.error(`Get documents by category failed: ${n}`),[]}}getMetadata(){return this.metadata}parseJsonField(t){try{return t?JSON.parse(t):[]}catch{return[]}}isInitialized(){return this.tables.length>0&&this.metadata!==null}async close(){this.connection&&(this.connection=null,this.tables=[],Dt.log("Vector database connection closed"))}};var VW=class{pipeline=null;initialized=!1;async initialize(){if(!this.initialized)try{let{pipeline:t}=await import("@xenova/transformers");this.pipeline=await t("feature-extraction","Xenova/all-MiniLM-L6-v2",{quantized:!1}),this.initialized=!0}catch(t){throw new Error(`Failed to initialize text embedding service: ${t}. Make sure @xenova/transformers is available.`)}}async generateEmbedding(t){if(!this.initialized||!this.pipeline)throw new Error("Text embedding service not initialized. Call initialize() first.");try{let r=t.replace(/\n+/g," ").replace(/\s+/g," ").trim().substring(0,8192);if(!r)throw new Error("Empty text provided for embedding");let n=await this.pipeline(r,{pooling:"mean",normalize:!0});return Array.from(n.data)}catch(r){throw new Error(`Failed to generate embedding: ${r}`)}}isInitialized(){return this.initialized}};async function vCe(e,t=!1){let{query:r,maxResults:n}=e;try{let i=new qW,a=new VW;await i.initialize(),await a.initialize();let o=await a.generateEmbedding(r),s=await i.semanticSearch(o,n??10);if(t){let c="";for(let[u,l]of s.entries())c+=`Result ${u+1}:
|
|
1644
1644
|
|
|
1645
1645
|
`,c+=`${l.document.content}
|
|
1646
1646
|
`,c+=`---
|