!function(t,e){"object"==typeofexports&&"undefined"!=typeofmodule?module.exports=e():"function"==typeofdefine&&define.amd?define(e):((t="undefined"!=typeofglobalThis?globalThis:t||self).prettierPlugins=t.prettierPlugins||{},t.prettierPlugins.angular=e())}(this,(function(){"use strict";functiont(e,s){const{ignoreDecorators:n}=s||{};if(!n){consts=e.declaration&&e.declaration.decorators||e.decorators;if(s&&s.length>0)returnt(s[0])}returne.range?e.range[0]:e.start}functione(t){consts=t.range?t.range[1]:t.end;returnt.typeAnnotation?Math.max(s,e(t.typeAnnotation)):s}functions(e,s){returnt(e)===t(s)}varn={locStart:t,locEnd:e,composeLoc:function(s,n=s){constr=t(s);return[r,"number"==typeofn?r+n:e(n)]},hasSameLocStart:s,hasSameLoc:function(t,n){returns(t,n)&&function(t,s){returne(t)===e(s)}(t,n)}};functionr(t,e,s){returnt(s={path:e,exports:{},require:function(t,e){returnfunction(){thrownewError("Dynamic requires are not currently supported by @rollup/plugin-commonjs")}(null==e&&s.path)}},s.exports),s.exports}vari,a=r((function(t,e){vars="\n",n=function(){functiont(t){this.string=t;for(vare=[0],n=0;n<t.length;)switch(t[n]){cases:n+=s.length,e.push(n);break;case"\r":t[n+="\r".length]===s&&(n+=s.length),e.push(n);break;default:n++}this.offsets=e}returnt.prototype.locationForIndex=function(t){if(t<0||t>this.string.length)returnnull;for(vare=0,s=this.offsets;s[e+1]<=t;)e++;return{line:e,column:t-s[e]}},t.prototype.indexForLocation=function(t){vare=t.line,s=t.column;returne<0||e>=this.offsets.length||s<0||s>this.lengthOfLine(e)?null:this.offsets[e]+s},t.prototype.lengthOfLine=function(t){vare=this.offsets[t];return(t===this.offsets.length-1?this.string.length:this.offsets[t+1])-e},t}();e.__esModule=!0,e.default=n})),o=r((function(t,e){Object.defineProperty(e,"__esModule",{value:!0});e.Context=class{constructor(t){this.text=t,this.locator=news(this.text)}};classs{constructor(t){this._lineAndColumn=newa.default(t)}locationForIndex(t){const{line:e,column:s}=this._lineAndColumn.locationForIndex(t);return{line:e+1,column:s}}}}));
classc{constructor(t,e,s,n){this.input=e,this.errLocation=s,this.ctxLocation=n,this.message="Parser Error: ".concat(t," ").concat(s," [").concat(e,"] in ").concat(n)}}classh{constructor(t,e){this.start=t,this.end=e}toAbsolute(t){returnnewM(t+this.start,t+this.end)}}classp{constructor(t,e){this.span=t,this.sourceSpan=e}visit(t,e=null){returnnull}toString(){return"AST"}}classuextendsp{constructor(t,e,s){super(t,e),this.nameSpan=s}}classlextendsp{constructor(t,e,s,n,r){super(t,e),this.prefix=s,this.uninterpretedExpression=n,this.location=r}visit(t,e=null){returnt.visitQuote(this,e)}toString(){return"Quote"}}classdextendsp{visit(t,e=null){}}classfextendsp{visit(t,e=null){returnt.visitImplicitReceiver(this,e)}}classvextendsp{constructor(t,e,s){super(t,e),this.expressions=s}visit(t,e=null){returnt.visitChain(this,e)}}classxextendsp{constructor(t,e,s,n,r){super(t,e),this.condition=s,this.trueExp=n,this.falseExp=r}visit(t,e=null){returnt.visitConditional(this,e)}}classgextendsu{constructor(t,e,s,n,r){super(t,e,s),this.receiver=n,this.name=r}visit(t,e=null){returnt.visitPropertyRead(this,e)}}classmextendsu{constructor(t,e,s,n,r,i){super(t,e,s),this.receiver=n,this.name=r,this.value=i}visit(t,e=null){returnt.visitPropertyWrite(this,e)}}classyextendsu{constructor(t,e,s,n,r){super(t,e,s),this.receiver=n,this.name=r}visit(t,e=null){returnt.visitSafePropertyRead(this,e)}}classSextendsp{constructor(t,e,s,n){super(t,e),this.obj=s,this.key=n}visit(t,e=null){returnt.visitKeyedRead(this,e)}}classwextendsp{constructor(t,e,s,n,r){super(t,e),this.obj=s,this.key=n,this.value=r}visit(t,e=null){returnt.visitKeyedWrite(this,e)}}classCextendsu{constructor(t,e,s,n,r,i){super(t,e,i),this.exp=s,this.name=n,this.args=r}visit(t,e=null){returnt.visitPipe(this,e)}}classPextendsp{constructor(t,e,s){super(t,e),this.value=s}visit(t,e=null){returnt.visitLiteralPrimitive(this,e)}}classEextendsp{constructor(t,e,s){super(t,e),this.expressions=s}visit(t,e=null){returnt.visitLiteralArray(this,e)}}classAextendsp{constructor(t,e,s,n){super(t,e),this.keys=s,this.values=n}visit(t,e=null){returnt.visitLiteralMap(this,e)}}classbextendsp{constructor(t,e,s,n){super(t,e),this.strings=s,this.expressions=n}visit(t,e=null){returnt.visitInterpolation(this,e)}}classOextendsp{constructor(t,e,s,n,r){super(t,e),this.operation=s,this.left=n,this.right=r}visit(t,e=null){returnt.visitBinary(this,e)}}classkextendsO{constructor(t,e,s,n,r,i,a){super(t,e,r,i,a),this.operator=s,this.expr=n}staticcreateMinus(t,e,s){returnnewk(t,e,"-",s,"-",newP(t,e,0),s)}staticcreatePlus(t,e,s){returnnewk(t,e,"+",s,"-",s,newP(t,e,0))}visit(t,e=null){returnvoid0!==t.visitUnary?t.visitUnary(this,e):t.visitBinary(this,e)}}classNextendsp{constructor(t,e,s){super(t,e),this.expression=s}visit(t,e=null){returnt.visitPrefixNot(this,e)}}classIextendsp{constructor(t,e,s){super(t,e),this.expression=s}visit(t,e=null){returnt.visitNonNullAssert(this,e)}}class_extendsu{constructor(t,e,s,n,r,i){super(t,e,s),this.receiver=n,this.name=r,this.args=i}visit(t,e=null){returnt.visitMethodCall(this,e)}}classLextendsu{constructor(t,e,s,n,r,i){super(t,e,s),this.receiver=n,this.name=r,this.args=i}visit(t,e=null){returnt.visitSafeMethodCall(this,e)}}classKextendsp{constructor(t,e,s,n){super(t,e),this.target=s,this.args=n}visit(t,e=null){returnt.visitFunctionCall(this,e)}}classM{constructor(t,e){this.start=t,this.end=e}}classTextendsp{constructor(t,e,s,n,r){super(newh(0,null===e?0:e.length),newM(n,null===e?n:n+e.length)),this.ast=t,this.source=e,this.location=s,this.errors=r}visit(t,e=null){returnt.visitASTWithSource?t.visitASTWithSource(this,e):this.ast.visit(t,e)}toString(){return"".concat(this.source," in ").concat(this.location)}}classB{constructor(t,e,s){this.sourceSpan=t,this.key=e,this.value=s}}classR{constructor(t,e,s){this.sourceSpan=t,this.key=e,this.value=s}}classj{visit(t,e){t.visit(this,e)}visitUnary(t,e){this.visit(t.expr,e)}visitBinary(t,e){this.visit(t.left,e),this.visit(t.right,e)}visitChain(t,e){this.
varV;!function(t){t[t.Character=0]="Character",t[t.Identifier=1]="Identifier",t[t.Keyword=2]="Keyword",t[t.String=3]="String",t[t.Operator=4]="Operator",t[t.Number=5]="Number",t[t.Error=6]="Error"}(V||(V={}));constQ=["var","let","as","null","undefined","true","false","if","else","this"];classD{constructor(t,e,s,n,r){this.index=t,this.end=e,this.type=s,this.numValue=n,this.strValue=r}isCharacter(t){returnthis.type==V.Character&&this.numValue==t}isNumber(){returnthis.type==V.Number}isString(){returnthis.type==V.String}isOperator(t){returnthis.type==V.Operator&&this.strValue==t}isIdentifier(){returnthis.type==V.Identifier}isKeyword(){returnthis.type==V.Keyword}isKeywordLet(){returnthis.type==V.Keyword&&"let"==this.strValue}isKeywordAs(){returnthis.type==V.Keyword&&"as"==this.strValue}isKeywordNull(){returnthis.type==V.Keyword&&"null"==this.strValue}isKeywordUndefined(){returnthis.type==V.Keyword&&"undefined"==this.strValue}isKeywordTrue(){returnthis.type==V.Keyword&&"true"==this.strValue}isKeywordFalse(){returnthis.type==V.Keyword&&"false"==this.strValue}isKeywordThis(){returnthis.type==V.Keyword&&"this"==this.strValue}isError(){returnthis.type==V.Error}toNumber(){returnthis.type==V.Number?this.numValue:-1}toString(){switch(this.type){caseV.Character:caseV.Identifier:caseV.Keyword:caseV.Operator:caseV.String:caseV.Error:returnthis.strValue;caseV.Number:returnthis.numValue.toString();default:returnnull}}}functionz(t,e,s){returnnewD(t,e,V.Character,s,String.fromCharCode(s))}functionq(t,e,s){returnnewD(t,e,V.Operator,0,s)}const$=newD(-1,-1,V.Character,0,"");classX{constructor(t){this.input=t,this.peek=0,this.index=-1,this.length=t.length,this.advance()}advance(){this.peek=++this.index>=this.length?0:this.input.charCodeAt(this.index)}scanToken(){constt=this.input,e=this.length;lets=this.peek,n=this.index;for(;s<=32;){if(++n>=e){s=0;break}s=t.charCodeAt(n)}if(this.peek=s,this.index=n,n>=e)returnnull;if(J(s))returnthis.scanIdentifier();if(W(s))returnthis.scanNumber(n);constr=n;switch(s){case46:returnthis.advance(),W(this.peek)?this.scanNumber(r):z(r,this.index,46);case40:caseG:case123:caseU:case91:case93:case44:case58:case59:returnthis.scanCharacter(r,s);case39:case34:returnthis.scanString();case35:case43:case45:case42:case47:case37:case94:returnthis.scanOperator(r,String.fromCharCode(s));case63:returnthis.scanComplexOperator(r,"?",46,".");case60:case62:returnthis.scanComplexOperator(r,String.fromCharCode(s),61,"=");case33:case61:returnthis.scanComplexOperator(r,String.fromCharCode(s),61,"=",61,"=");case38:returnthis.scanComplexOperator(r,"&",38,"&");case124:returnthis.scanComplexOperator(r,"|",124,"|");case160:for(;(i=this.peek)>=9&&i<=32||160==i;)this.advance();returnthis.scanToken()}vari;returnthis.advance(),this.error("Unexpected character [".concat(String.fromCharCode(s),"]"),0)}scanCharacter(t,e){returnthis.advance(),z(t,this.index,e)}scanOperator(t,e){returnthis.advance(),q(t,this.index,e)}scanComplexOperator(t,e,s,n,r,i){this.advance();leta=e;returnthis.peek==s&&(this.advance(),a+=n),null!=r&&this.peek==r&&(this.advance(),a+=i),q(t,this.index,a)}scanIdentifier(){constt=this.index;for(this.advance();Y(this.peek);)this.advance();conste=this.input.substring(t,this.index);returnQ.indexOf(e)>-1?(s=t,n=this.index,r=e,newD(s,n,V.Keyword,0,r)):function(t,e,s){returnnewD(t,e,V.Identifier,0,s)}(t,this.index,e);vars,n,r}scanNumber(t){lete=this.index===t;for(this.advance();;){if(W(this.peek));elseif(46==this.peek)e=!1;else{if(101!=(s=this.peek)&&69!=s)break;if(this.advance(),Z(this.peek)&&this.advance(),!W(this.peek))returnthis.error("Invalid exponent",-1);e=!1}this.advance()}vars;constn=this.input.substring(t,this.index),r=e?function(t){conste=parseInt(t);if(isNaN(e))thrownewError("Invalid integer literal when parsing "+t);returne}(n):parseFloat(n);returni=t,a=this.index,o=r,newD(i,a,V.Number,o,"");vari,a,o}scanString(){constt=this.index,e=this.peek;this.advance();lets="",n=this.index;constr=this.input;for(;this.peek!=e;)if(9
classrt{constructor(t,e){this.start=t,this.end=e}staticfromArray(t){returnt?(function(t,e){if(!(null==e||Array.isArray(e)&&2==e.length))thrownewError("Expected '".concat(t,"' to be an array, [start, end]."));if(null!=e){constt=e[0],s=e[1];nt.forEach((e=>{if(e.test(t)||e.test(s))thrownewError("['".concat(t,"', '").concat(s,"'] contains unusable interpolation symbol."))}))}}("interpolation",t),newrt(t[0],t[1])):it}}constit=newrt("{{","}}");functionat(t){returnt.replace(/([.*+?^=!:${}()|[\]\/\\])/g,"\\$1")}"undefined"!=typeofself&&"undefined"!=typeofWorkerGlobalScope&&selfinstanceofWorkerGlobalScope&&self;