 ICU message. Missing '}'.")),null;if(this._peek.type===s.TokenType.EXPANSION_FORM_END)if(v(p,s.TokenType.EXPANSION_FORM_START))p.pop();else return this._errors.push(n.create(null,i.sourceSpan,"Invalid ICU message. Missing '}'.")),null;if(this._peek.type===s.TokenType.EOF)return this._errors.push(n.create(null,i.sourceSpan,"Invalid ICU message. Missing '}'.")),null;l.push(this._advance())}}_getText(i){let l=i.parts[0];if(l.length>0&&l[0]==`
`){let p=this._getParentElement();p!=null&&p.children.length==0&&this.getTagDefinition(p.name).ignoreFirstLf&&(l=l.substring(1))}return l}_consumeText(i){let l=this._getText(i);l.length>0&&this._addToParent(new t.Text(l,i.sourceSpan))}_closeVoidElement(){let i=this._getParentElement();i&&this.getTagDefinition(i.name).isVoid&&this._elementStack.pop()}_consumeStartTag(i){let l=i.parts[0],p=i.parts[1],g=[];for(;this._peek.type===s.TokenType.ATTR_NAME;)g.push(this._consumeAttr(this._advance()));let C=this._getElementFullName(l,p,this._getParentElement()),m=!1;if(this._peek.type===s.TokenType.TAG_OPEN_END_VOID){this._advance(),m=!0;let b=this.getTagDefinition(C);this.canSelfClose||b.canSelfClose||c.getNsPrefix(C)!==null||b.isVoid||this._errors.push(n.create(C,i.sourceSpan,'Only void and foreign elements can be self closed "'.concat(i.parts[1],'"')))}else this._peek.type===s.TokenType.TAG_OPEN_END&&(this._advance(),m=!1);let B=this._peek.sourceSpan.start,w=new r.ParseSourceSpan(i.sourceSpan.start,B),S=new r.ParseSourceSpan(i.sourceSpan.start.moveBy(1),i.sourceSpan.end),N=new t.Element(C,g,[],w,w,void 0,S);this._pushElement(N),m&&(this._popElement(C),N.endSourceSpan=w)}_pushElement(i){let l=this._getParentElement();l&&this.getTagDefinition(l.name).isClosedByChild(i.name)&&this._elementStack.pop(),this._addToParent(i),this._elementStack.push(i)}_consumeEndTag(i){let l=this.allowHtmComponentClosingTags&&i.parts.length===0?null:this._getElementFullName(i.parts[0],i.parts[1],this._getParentElement());if(this._getParentElement()&&(this._getParentElement().endSourceSpan=i.sourceSpan),l&&this.getTagDefinition(l).isVoid)this._errors.push(n.create(l,i.sourceSpan,'Void elements do not have end tags "'.concat(i.parts[1],'"')));else if(!this._popElement(l)){let p='Unexpected closing tag "'.concat(l,'". It may happen when the tag has already been closed by another tag. For more info see https://www.w3.org/TR/html5/syntax.html#closing-elements-that-have-implied-end-tags');this._errors.push(n.create(l,i.sourceSpan,p))}}_popElement(i){for(let l=this._elementStack.length-1;l>=0;l--){let p=this._elementStack[l];if(!i||(c.getNsPrefix(p.name)?p.name==i:p.name.toLowerCase()==i.toLowerCase()))return this._elementStack.splice(l,this._elementStack.length-l),!0;if(!this.getTagDefinition(p.name).closedByParent)return!1}return!1}_consumeAttr(i){let l=c.mergeNsAndName(i.parts[0],i.parts[1]),p=i.sourceSpan.end,g="",C,m;if(this._peek.type===s.TokenType.ATTR_QUOTE&&(m=this._advance().sourceSpan.start),this._peek.type===s.TokenType.ATTR_VALUE){let B=this._advance();g=B.parts[0],p=B.sourceSpan.end,C=B.sourceSpan}return this._peek.type===s.TokenType.ATTR_QUOTE&&(p=this._advance().sourceSpan.end,C=new r.ParseSourceSpan(m,p)),new t.Attribute(l,g,new r.ParseSourceSpan(i.sourceSpan.start,p),C,i.sourceSpan)}_getParentElement(){return this._elementStack.length>0?this._elementStack[this._elementStack.length-1]:null}_getParentElementSkippingContainers(){let i=null;for(let l=this._elementStack.length-1;l>=0;l--){if(!c.isNgContainer(this._elementStack[l].name))return{parent:this._elementStack[l],container:i};i=this._elementStack[l]}return{parent:null,container:i}}_addToParent(i){let l=this._getParentElement();l!=null?l.children.push(i):this._rootNodes.push(i)}_insertBeforeContainer(i,l,p){if(!l)this._addToParent(p),this._elementStack.push(p);else{if(i){let g=i.children.indexOf(l);i.children[g]=p}else this._rootNodes.push(p);p.children.push(l),this._elementStack.splice(this._elementStack.indexOf(l),0,p)}}_getElementFullName(i,l,p){return i===""&&(i=this.getTagDefinition(l).implicitNamespacePrefix||"",i===""&&p!=null&&(i=c.getNsPrefix(p.name))),c.mergeNsAndName(i,l)}};function v(i,l){return i.length>0&&i[i.length-1]===l}}}),LD=I({"node_modules/angular-html-parser/lib/compiler/src/ml_parser/html_parser.js"(e){"use strict";O(),Object.defineProperty(e,"__esModule",{value:!0});var r=Es(),t=es(),s=es();e.ParseTreeResult=s.ParseTreeResult,e.TreeError=s.TreeError;var c=class extends t.Parser{constructor(){super(r.getHtmlTagDefinition)}parse(n,a,f){let D=arguments.length>3&&arguments[3]!==void 0?arguments[3]:!1,v=arguments.length>4?arguments[4]:void 0;return super.parse(n,a,f,D,v)}};e.HtmlParser=c}}),rs=I({"node_modules/angular-html-parser/lib/angular-html-parser/src/index.js"(e){"use strict";O(),Object.defineProperty(e,"__esModule",{value:!0});var r=LD(),t=Ze();e.TagContentType=t.TagContentType;var s=null,c=()=>(s||(s=new r.HtmlParser),s);function n(a){let f=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},{canSelfClose:D=!1,allowHtmComponentClosingTags:v=!1,isTagNameCaseSensitive:i=!1,getTagContentType:l}=f;return c().parse(a,"angular-html-parser",{tokenizeExpansionForms:!1,interpolationConfig:void 0,canSelfClose:D,allowHtmComponentClosingTags:v},i,l)}e.parse=n}}),MD=I({"src/language-html/parser-html.js"(e,r){O();var{ParseSourceSpan:t,ParseLocation:s,ParseSourceFile:c}=we(),n=Qc(),a=as(),f=Kc(),{inferParserByLanguage:D}=_D(),v=yD(),i=bD(),l=wD(),{hasPragma:p}=ND(),{Node:g}=OD(),{parseIeConditionalComment:C}=qD(),{locStart:m,locEnd:B}=ID();function w(b,j,R){let{recognizeSelfClosing:U,normalizeTagName:k,normalizeAttributeName:$,allowHtmComponentClosingTags:L,isTagNameCaseSensitive:u,getTagContentType:o}=j,d=rs(),{RecursiveVisitor:h,visitAll:F}=Cs(),{ParseSourceSpan:q}=we(),{getHtmlTagDefinition:P}=Es(),{rootNodes:G,errors:H}=d.parse(b,{canSelfClose:U,allowHtmComponentClosingTags:L,isTagNameCaseSensitive:u,getTagContentType:o});if(R.parser==="vue")if(G.some(A=>A.type==="docType"&&A.value==="html"||A.type==="element"&&A.name.toLowerCase()==="html")){U=!0,k=!0,$=!0,L=!0,u=!1;let A=d.parse(b,{canSelfClose:U,allowHtmComponentClosingTags:L,isTagNameCaseSensitive:u});G=A.rootNodes,H=A.errors}else{let A=y=>{if(!y||y.type!=="element"||y.name!=="template")return!1;let x=y.attrs.find(V=>V.name==="lang"),M=x&&x.value;return!M||D(M,R)==="html"};if(G.some(A)){let y,x=()=>d.parse(b,{canSelfClose:U,allowHtmComponentClosingTags:L,isTagNameCaseSensitive:u}),M=()=>y||(y=x()),V=W=>M().rootNodes.find(Q=>{let{startSourceSpan:se}=Q;return se&&se.start.offset===W.startSourceSpan.start.offset});for(let W=0;W<G.length;W++){let Q=G[W],{endSourceSpan:se,startSourceSpan:Ee}=Q;if(se===null)H=M().errors,G[W]=V(Q)||Q;else if(A(Q)){let Ae=M(),Ne=Ee.end.offset,ee=se.start.offset;for(let re of Ae.errors){let{offset:ie}=re.span.start;if(Ne<ie&&ie<ee){H=[re];break}}G[W]=V(Q)||Q}}}}if(H.length>0){let{msg:E,span:{start:A,end:y}}=H[0];throw f(E,{start:{line:A.line+1,column:A.col+1},end:{line:y.line+1,column:y.col+1}})}let K=E=>{let A=E.name.startsWith(":")?E.name.slice(1).split(":")[0]:null,y=E.nameSpan.toString(),x=A!==null&&y.startsWith("".concat(A,":")),M=x?y.slice(A.length+1):y;E.name=M,E.namespace=A,E.hasExplicitNamespace=x},z=E=>{switch(E.type){case"element":K(E);for(let A of E.attrs)K(A),A.valueSpan?(A.value=A.valueSpan.toString(),/["']/.test(A.value[0])&&(A.value=A.value.slice(1,-1))):A.value=null;break;case"comment":E.value=E.sourceSpan.toString().slice(4,-3);break;case"text":E.value=E.sourceSpan.toString();break}},Y=(E,A)=>{let y=E.toLowerCase();return A(y)?y:E},J=E=>{if(E.type==="element"&&(k&&(!E.namespace||E.namespace===E.tagDefinition.implicitNamespacePrefix||l(E))&&(E.name=Y(E.name,A=>A in v)),$)){let A=i[E.name]||Object.create(null);for(let y of E.attrs)y.namespace||(y.name=Y(y.name,x=>E.name in i&&(x in i["*"]||x in A)))}},Z=E=>{E.sourceSpan&&E.endSourceSpan&&(E.sourceSpan=new q(E.sourceSpan.start,E.endSourceSpan.end))},_=E=>{if(E.type==="element"){let A=P(u?E.name:E.name.toLowerCase());!E.namespace||E.namespace===A.implicitNamespacePrefix||l(E)?E.tagDefinition=A:E.tagDefinition=P("")}};return F(new class extends h{visit(E){z(E),_(E),J(E),Z(E)}},G),G}function S(b,j,R){let U=arguments.length>3&&arguments[3]!==void 0?arguments[3]:!0,{frontMatter:k,content:$}=U?n(b):{frontMatter:null,content:b},L=new c(b,j.filepath),u=new s(L,0,0,0),o=u.moveBy(b.length),d={type:"root",sourceSpan:new t(u,o),children:w($,R,j)};if(k){let q=new s(L,0,0,0),P=q.moveBy(k.raw.length);k.sourceSpan=new t(q,P),d.children.unshift(k)}let h=new g(d),F=(q,P)=>{let{offset:G}=P,H=b.slice(0,G).replace(/[^\n\r]/g," "),z=S(H+q,j,R,!1);z.sourceSpan=new t(P,a(z.children).sourceSpan.end);let Y=z.children[0];return Y.length===G?z.children.shift():(Y.sourceSpan=new t(Y.sourceSpan.start.moveBy(G),Y.sourceSpan.end),Y.value=Y.value.slice(G)),z};return h.walk(q=>{if(q.type==="comment"){let P=C(q,F);P&&q.parent.replaceChild(q,P)}}),h}function N(){let{name:b,recognizeSelfClosing:j=!1,normalizeTagName:R=!1,normalizeAttributeName:U=!1,allowHtmComponentClosingTags:k=!1,isTagNameCaseSensitive:$=!1,getTagContentType:L}=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};return{parse:(u,o,d)=>S(u,Object.assign({parser:b},d),{recognizeSelfClosing:j,normalizeTagName:R,normalizeAttributeName:U,allowHtmComponentClosingTags:k,isTagNameCaseSensitive:$,getTagContentType:L}),hasPragma:p,astFormat:"html",locStart:m,locEnd:B}}r.exports={parsers:{html:N({name:"html",recognizeSelfClosing:!0,normalizeTagName:!0,normalizeAttributeName:!0,allowHtmComponentClosingTags:!0}),angular:N({name:"angular"}),vue:N({name:"vue",recognizeSelfClosing:!0,isTagNameCaseSensitive:!0,getTagContentType:(b,j,R,U)=>{if(b.toLowerCase()!=="html"&&!R&&(b!=="template"||U.some(k=>{let{name:$,value:L}=k;return $==="lang"&&L!=="html"&&L!==""&&L!==void 0})))return rs().TagContentType.RAW_TEXT}}),lwc:N({name:"lwc"})}}}}),d2=MD();export{d2 as default};
