UNPKG

vzcode

Version:
13 lines 2.06 MB
(function(){"use strict";var ZV=Object.create,t_=Object.defineProperty,eJ=Object.getOwnPropertyDescriptor,tJ=Object.getOwnPropertyNames,rJ=Object.getPrototypeOf,nJ=Object.prototype.hasOwnProperty,iJ=(e,t)=>()=>(t||e((t={exports:{}}).exports,t),t.exports),r_=(e,t)=>{for(var r in t)t_(e,r,{get:t[r],enumerable:!0})},sJ=(e,t,r,n)=>{if(t&&typeof t=="object"||typeof t=="function")for(let i of tJ(t))!nJ.call(e,i)&&i!==r&&t_(e,i,{get:()=>t[i],enumerable:!(n=eJ(t,i))||n.enumerable});return e},aJ=(e,t,r)=>(r=e!=null?ZV(rJ(e)):{},sJ(t_(r,"default",{value:e,enumerable:!0}),e)),oJ=iJ((e,t)=>{var r,n,i,s,a,u,o,p,l,d,f,m,y,g,x,b,D,_,S;y=/\/(?![*\/])(?:\[(?:[^\]\\\n\r\u2028\u2029]+|\\.)*\]|[^\/\\\n\r\u2028\u2029]+|\\.)*(\/[$_\u200C\u200D\p{ID_Continue}]*|\\)?/yu,m=/--|\+\+|=>|\.{3}|\??\.(?!\d)|(?:&&|\|\||\?\?|[+\-%&|^]|\*{1,2}|<{1,2}|>{1,3}|!=?|={1,2}|\/(?![\/*]))=?|[?~,:;[\](){}]/y,r=/(\x23?)(?=[$_\p{ID_Start}\\])(?:[$_\u200C\u200D\p{ID_Continue}]+|\\u[\da-fA-F]{4}|\\u\{[\da-fA-F]+\})+/yu,x=/(['"])(?:[^'"\\\n\r]+|(?!\1)['"]|\\(?:\r\n|[^]))*(\1)?/y,f=/(?:0[xX][\da-fA-F](?:_?[\da-fA-F])*|0[oO][0-7](?:_?[0-7])*|0[bB][01](?:_?[01])*)n?|0n|[1-9](?:_?\d)*n|(?:(?:0(?!\d)|0\d*[89]\d*|[1-9](?:_?\d)*)(?:\.(?:\d(?:_?\d)*)?)?|\.\d(?:_?\d)*)(?:[eE][+-]?\d(?:_?\d)*)?|0[0-7]+/y,b=/[`}](?:[^`\\$]+|\\[^]|\$(?!\{))*(`|\$\{)?/y,S=/[\t\v\f\ufeff\p{Zs}]+/yu,p=/\r?\n|[\r\u2028\u2029]/y,l=/\/\*(?:[^*]+|\*(?!\/))*(\*\/)?/y,g=/\/\/.*/y,i=/[<>.:={}]|\/(?![\/*])/y,n=/[$_\p{ID_Start}][$_\u200C\u200D\p{ID_Continue}-]*/yu,s=/(['"])(?:[^'"]+|(?!\1)['"])*(\1)?/y,a=/[^<>{}]+/y,_=/^(?:[\/+-]|\.{3}|\?(?:InterpolationIn(?:JSX|Template)|NoLineTerminatorHere|NonExpressionParenEnd|UnaryIncDec))?$|[{}([,;<>=*%&|^!~?:]$/,D=/^(?:=>|[;\]){}]|else|\?(?:NoLineTerminatorHere|NonExpressionParenEnd))?$/,u=/^(?:await|case|default|delete|do|else|instanceof|new|return|throw|typeof|void|yield)$/,o=/^(?:return|throw|yield)$/,d=RegExp(p.source),t.exports=function*(T,{jsx:A=!1}={}){var F,N,j,z,$,ie,W,ae,J,L,C,w,I,B;for({length:ie}=T,z=0,$="",B=[{tag:"JS"}],F=[],C=0,w=!1;z<ie;){switch(ae=B[B.length-1],ae.tag){case"JS":case"JSNonExpressionParen":case"InterpolationInTemplate":case"InterpolationInJSX":if(T[z]==="/"&&(_.test($)||u.test($))&&(y.lastIndex=z,W=y.exec(T))){z=y.lastIndex,$=W[0],w=!0,yield{type:"RegularExpressionLiteral",value:W[0],closed:W[1]!==void 0&&W[1]!=="\\"};continue}if(m.lastIndex=z,W=m.exec(T)){switch(I=W[0],J=m.lastIndex,L=I,I){case"(":$==="?NonExpressionParenKeyword"&&B.push({tag:"JSNonExpressionParen",nesting:C}),C++,w=!1;break;case")":C--,w=!0,ae.tag==="JSNonExpressionParen"&&C===ae.nesting&&(B.pop(),L="?NonExpressionParenEnd",w=!1);break;case"{":m.lastIndex=0,j=!D.test($)&&(_.test($)||u.test($)),F.push(j),w=!1;break;case"}":switch(ae.tag){case"InterpolationInTemplate":if(F.length===ae.nesting){b.lastIndex=z,W=b.exec(T),z=b.lastIndex,$=W[0],W[1]==="${"?($="?InterpolationInTemplate",w=!1,yield{type:"TemplateMiddle",value:W[0]}):(B.pop(),w=!0,yield{type:"TemplateTail",value:W[0],closed:W[1]==="`"});continue}break;case"InterpolationInJSX":if(F.length===ae.nesting){B.pop(),z+=1,$="}",yield{type:"JSXPunctuator",value:"}"};continue}}w=F.pop(),L=w?"?ExpressionBraceEnd":"}";break;case"]":w=!0;break;case"++":case"--":L=w?"?PostfixIncDec":"?UnaryIncDec";break;case"<":if(A&&(_.test($)||u.test($))){B.push({tag:"JSXTag"}),z+=1,$="<",yield{type:"JSXPunctuator",value:I};continue}w=!1;break;default:w=!1}z=J,$=L,yield{type:"Punctuator",value:I};continue}if(r.lastIndex=z,W=r.exec(T)){switch(z=r.lastIndex,L=W[0],W[0]){case"for":case"if":case"while":case"with":$!=="."&&$!=="?."&&(L="?NonExpressionParenKeyword")}$=L,w=!u.test(W[0]),yield{type:W[1]==="#"?"PrivateIdentifier":"IdentifierName",value:W[0]};continue}if(x.lastIndex=z,W=x.exec(T)){z=x.lastIndex,$=W[0],w=!0,yield{type:"StringLiteral",value:W[0],closed:W[2]!==void 0};continue}if(f.lastIndex=z,W=f.exec(T)){z=f.lastIndex,$=W[0],w=!0,yield{type:"NumericLiteral",value:W[0]};continue}if(b.lastIndex=z,W=b.exec(T)){z=b.lastIndex,$=W[0],W[1]==="${"?($="?InterpolationInTemplate",B.push({tag:"InterpolationInTemplate",nesting:F.length}),w=!1,yield{type:"TemplateHead",value:W[0]}):(w=!0,yield{type:"NoSubstitutionTemplate",value:W[0],closed:W[1]==="`"});continue}break;case"JSXTag":case"JSXTagEnd":if(i.lastIndex=z,W=i.exec(T)){switch(z=i.lastIndex,L=W[0],W[0]){case"<":B.push({tag:"JSXTag"});break;case">":B.pop(),$==="/"||ae.tag==="JSXTagEnd"?(L="?JSX",w=!0):B.push({tag:"JSXChildren"});break;case"{":B.push({tag:"InterpolationInJSX",nesting:F.length}),L="?InterpolationInJSX",w=!1;break;case"/":$==="<"&&(B.pop(),B[B.length-1].tag==="JSXChildren"&&B.pop(),B.push({tag:"JSXTagEnd"}))}$=L,yield{type:"JSXPunctuator",value:W[0]};continue}if(n.lastIndex=z,W=n.exec(T)){z=n.lastIndex,$=W[0],yield{type:"JSXIdentifier",value:W[0]};continue}if(s.lastIndex=z,W=s.exec(T)){z=s.lastIndex,$=W[0],yield{type:"JSXString",value:W[0],closed:W[2]!==void 0};continue}break;case"JSXChildren":if(a.lastIndex=z,W=a.exec(T)){z=a.lastIndex,$=W[0],yield{type:"JSXText",value:W[0]};continue}switch(T[z]){case"<":B.push({tag:"JSXTag"}),z++,$="<",yield{type:"JSXPunctuator",value:"<"};continue;case"{":B.push({tag:"InterpolationInJSX",nesting:F.length}),z++,$="?InterpolationInJSX",w=!1,yield{type:"JSXPunctuator",value:"{"};continue}}if(S.lastIndex=z,W=S.exec(T)){z=S.lastIndex,yield{type:"WhiteSpace",value:W[0]};continue}if(p.lastIndex=z,W=p.exec(T)){z=p.lastIndex,w=!1,o.test($)&&($="?NoLineTerminatorHere"),yield{type:"LineTerminatorSequence",value:W[0]};continue}if(l.lastIndex=z,W=l.exec(T)){z=l.lastIndex,d.test(W[0])&&(w=!1,o.test($)&&($="?NoLineTerminatorHere")),yield{type:"MultiLineComment",value:W[0],closed:W[1]!==void 0};continue}if(g.lastIndex=z,W=g.exec(T)){z=g.lastIndex,w=!1,yield{type:"SingleLineComment",value:W[0]};continue}N=String.fromCodePoint(T.codePointAt(z)),z+=N.length,$=N,w=!1,yield{type:ae.tag.startsWith("JSX")?"JSXInvalid":"Invalid",value:N}}}}),uJ={};r_(uJ,{__debug:()=>QW,check:()=>GW,doc:()=>Bu,format:()=>N_,formatWithCursor:()=>sw,getSupportInfo:()=>XW,util:()=>rw,version:()=>CW});var Yp=(e,t)=>(r,n,...i)=>r|1&&n==null?void 0:(t.call(n)??n[e]).apply(n,i),lJ=String.prototype.replaceAll??function(e,t){return e.global?this.replace(e,t):this.split(e).join(t)},cJ=Yp("replaceAll",function(){if(typeof this=="string")return lJ}),Og=cJ,pJ=class{diff(t,r,n={}){let i;typeof n=="function"?(i=n,n={}):"callback"in n&&(i=n.callback);let s=this.castInput(t,n),a=this.castInput(r,n),u=this.removeEmpty(this.tokenize(s,n)),o=this.removeEmpty(this.tokenize(a,n));return this.diffWithOptionsObj(u,o,n,i)}diffWithOptionsObj(t,r,n,i){var s;let a=D=>{if(D=this.postProcess(D,n),i){setTimeout(function(){i(D)},0);return}else return D},u=r.length,o=t.length,p=1,l=u+o;n.maxEditLength!=null&&(l=Math.min(l,n.maxEditLength));let d=(s=n.timeout)!==null&&s!==void 0?s:1/0,f=Date.now()+d,m=[{oldPos:-1,lastComponent:void 0}],y=this.extractCommon(m[0],r,t,0,n);if(m[0].oldPos+1>=o&&y+1>=u)return a(this.buildValues(m[0].lastComponent,r,t));let g=-1/0,x=1/0,b=()=>{for(let D=Math.max(g,-p);D<=Math.min(x,p);D+=2){let _,S=m[D-1],T=m[D+1];S&&(m[D-1]=void 0);let A=!1;if(T){let N=T.oldPos-D;A=T&&0<=N&&N<u}let F=S&&S.oldPos+1<o;if(!A&&!F){m[D]=void 0;continue}if(!F||A&&S.oldPos<T.oldPos?_=this.addToPath(T,!0,!1,0,n):_=this.addToPath(S,!1,!0,1,n),y=this.extractCommon(_,r,t,D,n),_.oldPos+1>=o&&y+1>=u)return a(this.buildValues(_.lastComponent,r,t))||!0;m[D]=_,_.oldPos+1>=o&&(x=Math.min(x,D-1)),y+1>=u&&(g=Math.max(g,D+1))}p++};if(i)(function D(){setTimeout(function(){if(p>l||Date.now()>f)return i(void 0);b()||D()},0)})();else for(;p<=l&&Date.now()<=f;){let D=b();if(D)return D}}addToPath(t,r,n,i,s){let a=t.lastComponent;return a&&!s.oneChangePerToken&&a.added===r&&a.removed===n?{oldPos:t.oldPos+i,lastComponent:{count:a.count+1,added:r,removed:n,previousComponent:a.previousComponent}}:{oldPos:t.oldPos+i,lastComponent:{count:1,added:r,removed:n,previousComponent:a}}}extractCommon(t,r,n,i,s){let a=r.length,u=n.length,o=t.oldPos,p=o-i,l=0;for(;p+1<a&&o+1<u&&this.equals(n[o+1],r[p+1],s);)p++,o++,l++,s.oneChangePerToken&&(t.lastComponent={count:1,previousComponent:t.lastComponent,added:!1,removed:!1});return l&&!s.oneChangePerToken&&(t.lastComponent={count:l,previousComponent:t.lastComponent,added:!1,removed:!1}),t.oldPos=o,p}equals(t,r,n){return n.comparator?n.comparator(t,r):t===r||!!n.ignoreCase&&t.toLowerCase()===r.toLowerCase()}removeEmpty(t){let r=[];for(let n=0;n<t.length;n++)t[n]&&r.push(t[n]);return r}castInput(t,r){return t}tokenize(t,r){return Array.from(t)}join(t){return t.join("")}postProcess(t,r){return t}get useLongestToken(){return!1}buildValues(t,r,n){let i=[],s;for(;t;)i.push(t),s=t.previousComponent,delete t.previousComponent,t=s;i.reverse();let a=i.length,u=0,o=0,p=0;for(;u<a;u++){let l=i[u];if(l.removed)l.value=this.join(n.slice(p,p+l.count)),p+=l.count;else{if(!l.added&&this.useLongestToken){let d=r.slice(o,o+l.count);d=d.map(function(f,m){let y=n[p+m];return y.length>f.length?y:f}),l.value=this.join(d)}else l.value=this.join(r.slice(o,o+l.count));o+=l.count,l.added||(p+=l.count)}}return i}},dJ=class extends pJ{tokenize(t){return t.slice()}join(t){return t}removeEmpty(t){return t}},hJ=new dJ;function fJ(e,t,r){return hJ.diff(e,t,r)}var mJ=()=>{},yJ=mJ,L6="cr",O6="crlf",gJ="lf",DJ=gJ,n_="\r",M6=`\r `,Mg=` `,vJ=Mg;function xJ(e){let t=e.indexOf(n_);return t!==-1?e.charAt(t+1)===Mg?O6:L6:DJ}function i_(e){return e===L6?n_:e===O6?M6:vJ}var bJ=new Map([[Mg,/\n/gu],[n_,/\r/gu],[M6,/\r\n/gu]]);function $6(e,t){let r=bJ.get(t);return e.match(r)?.length??0}var CJ=/\r\n?/gu;function _J(e){return Og(0,e,CJ,Mg)}function EJ(e){return this[e<0?this.length+e:e]}var TJ=Yp("at",function(){if(Array.isArray(this)||typeof this=="string")return EJ}),En=TJ,ku="string",Ma="array",No="cursor",$a="indent",qa="align",ja="trim",xi="group",Ys="fill",Vi="if-break",Ua="indent-if-break",Va="line-suffix",Ja="line-suffix-boundary",Mn="line",Zs="label",ps="break-parent",q6=new Set([No,$a,qa,ja,xi,Ys,Vi,Ua,Va,Ja,Mn,Zs,ps]);function AJ(e){let t=e.length;for(;t>0&&(e[t-1]==="\r"||e[t-1]===` `);)t--;return t<e.length?e.slice(0,t):e}function SJ(e){if(typeof e=="string")return ku;if(Array.isArray(e))return Ma;if(!e)return;let{type:t}=e;if(q6.has(t))return t}var Fu=SJ,wJ=e=>new Intl.ListFormat("en-US",{type:"disjunction"}).format(e);function kJ(e){let t=e===null?"null":typeof e;if(t!=="string"&&t!=="object")return`Unexpected doc '${t}', Expected it to be 'string' or 'object'.`;if(Fu(e))throw new Error("doc is valid.");let r=Object.prototype.toString.call(e);if(r!=="[object Object]")return`Unexpected doc '${r}'.`;let n=wJ([...q6].map(i=>`'${i}'`));return`Unexpected doc.type '${e.type}'. Expected it to be ${n}.`}var FJ=class extends Error{name="InvalidDocError";constructor(t){super(kJ(t)),this.doc=t}},Xl=FJ,j6={};function PJ(e,t,r,n){let i=[e];for(;i.length>0;){let s=i.pop();if(s===j6){r(i.pop());continue}r&&i.push(s,j6);let a=Fu(s);if(!a)throw new Xl(s);if(t?.(s)!==!1)switch(a){case Ma:case Ys:{let u=a===Ma?s:s.parts;for(let o=u.length,p=o-1;p>=0;--p)i.push(u[p]);break}case Vi:i.push(s.flatContents,s.breakContents);break;case xi:if(n&&s.expandedStates)for(let u=s.expandedStates.length,o=u-1;o>=0;--o)i.push(s.expandedStates[o]);else i.push(s.contents);break;case qa:case $a:case Ua:case Zs:case Va:i.push(s.contents);break;case ku:case No:case ja:case Ja:case Mn:case ps:break;default:throw new Xl(s)}}}var s_=PJ;function $g(e,t){if(typeof e=="string")return t(e);let r=new Map;return n(e);function n(s){if(r.has(s))return r.get(s);let a=i(s);return r.set(s,a),a}function i(s){switch(Fu(s)){case Ma:return t(s.map(n));case Ys:return t({...s,parts:s.parts.map(n)});case Vi:return t({...s,breakContents:n(s.breakContents),flatContents:n(s.flatContents)});case xi:{let{expandedStates:a,contents:u}=s;return a?(a=a.map(n),u=a[0]):u=n(u),t({...s,contents:u,expandedStates:a})}case qa:case $a:case Ua:case Zs:case Va:return t({...s,contents:n(s.contents)});case ku:case No:case ja:case Ja:case Mn:case ps:return t(s);default:throw new Xl(s)}}}function a_(e,t,r){let n=r,i=!1;function s(a){if(i)return!1;let u=t(a);u!==void 0&&(i=!0,n=u)}return s_(e,s),n}function NJ(e){if(e.type===xi&&e.break||e.type===Mn&&e.hard||e.type===ps)return!0}function IJ(e){return a_(e,NJ,!1)}function U6(e){if(e.length>0){let t=En(0,e,-1);!t.expandedStates&&!t.break&&(t.break="propagated")}return null}function BJ(e){let t=new Set,r=[];function n(s){if(s.type===ps&&U6(r),s.type===xi){if(r.push(s),t.has(s))return!1;t.add(s)}}function i(s){s.type===xi&&r.pop().break&&U6(r)}s_(e,n,i,!0)}function RJ(e){return e.type===Mn&&!e.hard?e.soft?"":" ":e.type===Vi?e.flatContents:e}function LJ(e){return $g(e,RJ)}function V6(e){for(e=[...e];e.length>=2&&En(0,e,-2).type===Mn&&En(0,e,-1).type===ps;)e.length-=2;if(e.length>0){let t=Zp(En(0,e,-1));e[e.length-1]=t}return e}function Zp(e){switch(Fu(e)){case $a:case Ua:case xi:case Va:case Zs:{let t=Zp(e.contents);return{...e,contents:t}}case Vi:return{...e,breakContents:Zp(e.breakContents),flatContents:Zp(e.flatContents)};case Ys:return{...e,parts:V6(e.parts)};case Ma:return V6(e);case ku:return AJ(e);case qa:case No:case ja:case Ja:case Mn:case ps:break;default:throw new Xl(e)}return e}function J6(e){return Zp(MJ(e))}function OJ(e){switch(Fu(e)){case Ys:if(e.parts.every(t=>t===""))return"";break;case xi:if(!e.contents&&!e.id&&!e.break&&!e.expandedStates)return"";if(e.contents.type===xi&&e.contents.id===e.id&&e.contents.break===e.break&&e.contents.expandedStates===e.expandedStates)return e.contents;break;case qa:case $a:case Ua:case Va:if(!e.contents)return"";break;case Vi:if(!e.flatContents&&!e.breakContents)return"";break;case Ma:{let t=[];for(let r of e){if(!r)continue;let[n,...i]=Array.isArray(r)?r:[r];typeof n=="string"&&typeof En(0,t,-1)=="string"?t[t.length-1]+=n:t.push(n),t.push(...i)}return t.length===0?"":t.length===1?t[0]:t}case ku:case No:case ja:case Ja:case Mn:case Zs:case ps:break;default:throw new Xl(e)}return e}function MJ(e){return $g(e,t=>OJ(t))}function $J(e,t=Q6){return $g(e,r=>typeof r=="string"?K6(t,r.split(` `)):r)}function qJ(e){if(e.type===Mn)return!0}function jJ(e){return a_(e,qJ,!1)}function qg(e,t){return e.type===Zs?{...e,contents:t(e.contents)}:t(e)}var UJ=yJ;function jg(e){return{type:$a,contents:e}}function Ql(e,t){return{type:qa,contents:t,n:e}}function VJ(e){return Ql(Number.NEGATIVE_INFINITY,e)}function H6(e){return Ql({type:"root"},e)}function JJ(e){return Ql(-1,e)}function z6(e,t,r){let n=e;if(t>0){for(let i=0;i<Math.floor(t/r);++i)n=jg(n);n=Ql(t%r,n),n=Ql(Number.NEGATIVE_INFINITY,n)}return n}var Ug={type:ps},Pu={type:No};function HJ(e){return{type:Ys,parts:e}}function W6(e,t={}){return UJ(t.expandedStates),{type:xi,id:t.id,contents:e,break:!!t.shouldBreak,expandedStates:t.expandedStates}}function zJ(e,t){return W6(e[0],{...t,expandedStates:e})}function WJ(e,t="",r={}){return{type:Vi,breakContents:e,flatContents:t,groupId:r.groupId}}function KJ(e,t){return{type:Ua,contents:e,groupId:t.groupId,negate:t.negate}}function K6(e,t){let r=[];for(let n=0;n<t.length;n++)n!==0&&r.push(e),r.push(t[n]);return r}function GJ(e,t){return e?{type:Zs,label:e,contents:t}:t}var G6={type:Mn},XJ={type:Mn,soft:!0},o_={type:Mn,hard:!0},Ha=[o_,Ug],X6={type:Mn,hard:!0,literal:!0},Q6=[X6,Ug];function u_(e){return{type:Va,contents:e}}var QJ={type:Ja},YJ={type:ja};function za(e){if(!e)return"";if(Array.isArray(e)){let t=[];for(let r of e)if(Array.isArray(r))t.push(...za(r));else{let n=za(r);n!==""&&t.push(n)}return t}return e.type===Vi?{...e,breakContents:za(e.breakContents),flatContents:za(e.flatContents)}:e.type===xi?{...e,contents:za(e.contents),expandedStates:e.expandedStates?.map(za)}:e.type===Ys?{type:"fill",parts:e.parts.map(za)}:e.contents?{...e,contents:za(e.contents)}:e}function ZJ(e){let t=Object.create(null),r=new Set;return n(za(e));function n(s,a,u){if(typeof s=="string")return JSON.stringify(s);if(Array.isArray(s)){let o=s.map(n).filter(Boolean);return o.length===1?o[0]:`[${o.join(", ")}]`}if(s.type===Mn){let o=u?.[a+1]?.type===ps;return s.literal?o?"literalline":"literallineWithoutBreakParent":s.hard?o?"hardline":"hardlineWithoutBreakParent":s.soft?"softline":"line"}if(s.type===ps)return u?.[a-1]?.type===Mn&&u[a-1].hard?void 0:"breakParent";if(s.type===ja)return"trim";if(s.type===$a)return"indent("+n(s.contents)+")";if(s.type===qa)return s.n===Number.NEGATIVE_INFINITY?"dedentToRoot("+n(s.contents)+")":s.n<0?"dedent("+n(s.contents)+")":s.n.type==="root"?"markAsRoot("+n(s.contents)+")":"align("+JSON.stringify(s.n)+", "+n(s.contents)+")";if(s.type===Vi)return"ifBreak("+n(s.breakContents)+(s.flatContents?", "+n(s.flatContents):"")+(s.groupId?(s.flatContents?"":', ""')+`, { groupId: ${i(s.groupId)} }`:"")+")";if(s.type===Ua){let o=[];s.negate&&o.push("negate: true"),s.groupId&&o.push(`groupId: ${i(s.groupId)}`);let p=o.length>0?`, { ${o.join(", ")} }`:"";return`indentIfBreak(${n(s.contents)}${p})`}if(s.type===xi){let o=[];s.break&&s.break!=="propagated"&&o.push("shouldBreak: true"),s.id&&o.push(`id: ${i(s.id)}`);let p=o.length>0?`, { ${o.join(", ")} }`:"";return s.expandedStates?`conditionalGroup([${s.expandedStates.map(l=>n(l)).join(",")}]${p})`:`group(${n(s.contents)}${p})`}if(s.type===Ys)return`fill([${s.parts.map(o=>n(o)).join(", ")}])`;if(s.type===Va)return"lineSuffix("+n(s.contents)+")";if(s.type===Ja)return"lineSuffixBoundary";if(s.type===Zs)return`label(${JSON.stringify(s.label)}, ${n(s.contents)})`;if(s.type===No)return"cursor";throw new Error("Unknown doc type "+s.type)}function i(s){if(typeof s!="symbol")return JSON.stringify(String(s));if(s in t)return t[s];let a=s.description||"symbol";for(let u=0;;u++){let o=a+(u>0?` #${u}`:"");if(!r.has(o))return r.add(o),t[s]=`Symbol.for(${JSON.stringify(o)})`}}}var eH=()=>/[#*0-9]\uFE0F?\u20E3|[\xA9\xAE\u203C\u2049\u2122\u2139\u2194-\u2199\u21A9\u21AA\u231A\u231B\u2328\u23CF\u23ED-\u23EF\u23F1\u23F2\u23F8-\u23FA\u24C2\u25AA\u25AB\u25B6\u25C0\u25FB\u25FC\u25FE\u2600-\u2604\u260E\u2611\u2614\u2615\u2618\u2620\u2622\u2623\u2626\u262A\u262E\u262F\u2638-\u263A\u2640\u2642\u2648-\u2653\u265F\u2660\u2663\u2665\u2666\u2668\u267B\u267E\u267F\u2692\u2694-\u2697\u2699\u269B\u269C\u26A0\u26A7\u26AA\u26B0\u26B1\u26BD\u26BE\u26C4\u26C8\u26CF\u26D1\u26E9\u26F0-\u26F5\u26F7\u26F8\u26FA\u2702\u2708\u2709\u270F\u2712\u2714\u2716\u271D\u2721\u2733\u2734\u2744\u2747\u2757\u2763\u27A1\u2934\u2935\u2B05-\u2B07\u2B1B\u2B1C\u2B55\u3030\u303D\u3297\u3299]\uFE0F?|[\u261D\u270C\u270D](?:\uD83C[\uDFFB-\uDFFF]|\uFE0F)?|[\u270A\u270B](?:\uD83C[\uDFFB-\uDFFF])?|[\u23E9-\u23EC\u23F0\u23F3\u25FD\u2693\u26A1\u26AB\u26C5\u26CE\u26D4\u26EA\u26FD\u2705\u2728\u274C\u274E\u2753-\u2755\u2795-\u2797\u27B0\u27BF\u2B50]|\u26D3\uFE0F?(?:\u200D\uD83D\uDCA5)?|\u26F9(?:\uD83C[\uDFFB-\uDFFF]|\uFE0F)?(?:\u200D[\u2640\u2642]\uFE0F?)?|\u2764\uFE0F?(?:\u200D(?:\uD83D\uDD25|\uD83E\uDE79))?|\uD83C(?:[\uDC04\uDD70\uDD71\uDD7E\uDD7F\uDE02\uDE37\uDF21\uDF24-\uDF2C\uDF36\uDF7D\uDF96\uDF97\uDF99-\uDF9B\uDF9E\uDF9F\uDFCD\uDFCE\uDFD4-\uDFDF\uDFF5\uDFF7]\uFE0F?|[\uDF85\uDFC2\uDFC7](?:\uD83C[\uDFFB-\uDFFF])?|[\uDFC4\uDFCA](?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D[\u2640\u2642]\uFE0F?)?|[\uDFCB\uDFCC](?:\uD83C[\uDFFB-\uDFFF]|\uFE0F)?(?:\u200D[\u2640\u2642]\uFE0F?)?|[\uDCCF\uDD8E\uDD91-\uDD9A\uDE01\uDE1A\uDE2F\uDE32-\uDE36\uDE38-\uDE3A\uDE50\uDE51\uDF00-\uDF20\uDF2D-\uDF35\uDF37-\uDF43\uDF45-\uDF4A\uDF4C-\uDF7C\uDF7E-\uDF84\uDF86-\uDF93\uDFA0-\uDFC1\uDFC5\uDFC6\uDFC8\uDFC9\uDFCF-\uDFD3\uDFE0-\uDFF0\uDFF8-\uDFFF]|\uDDE6\uD83C[\uDDE8-\uDDEC\uDDEE\uDDF1\uDDF2\uDDF4\uDDF6-\uDDFA\uDDFC\uDDFD\uDDFF]|\uDDE7\uD83C[\uDDE6\uDDE7\uDDE9-\uDDEF\uDDF1-\uDDF4\uDDF6-\uDDF9\uDDFB\uDDFC\uDDFE\uDDFF]|\uDDE8\uD83C[\uDDE6\uDDE8\uDDE9\uDDEB-\uDDEE\uDDF0-\uDDF7\uDDFA-\uDDFF]|\uDDE9\uD83C[\uDDEA\uDDEC\uDDEF\uDDF0\uDDF2\uDDF4\uDDFF]|\uDDEA\uD83C[\uDDE6\uDDE8\uDDEA\uDDEC\uDDED\uDDF7-\uDDFA]|\uDDEB\uD83C[\uDDEE-\uDDF0\uDDF2\uDDF4\uDDF7]|\uDDEC\uD83C[\uDDE6\uDDE7\uDDE9-\uDDEE\uDDF1-\uDDF3\uDDF5-\uDDFA\uDDFC\uDDFE]|\uDDED\uD83C[\uDDF0\uDDF2\uDDF3\uDDF7\uDDF9\uDDFA]|\uDDEE\uD83C[\uDDE8-\uDDEA\uDDF1-\uDDF4\uDDF6-\uDDF9]|\uDDEF\uD83C[\uDDEA\uDDF2\uDDF4\uDDF5]|\uDDF0\uD83C[\uDDEA\uDDEC-\uDDEE\uDDF2\uDDF3\uDDF5\uDDF7\uDDFC\uDDFE\uDDFF]|\uDDF1\uD83C[\uDDE6-\uDDE8\uDDEE\uDDF0\uDDF7-\uDDFB\uDDFE]|\uDDF2\uD83C[\uDDE6\uDDE8-\uDDED\uDDF0-\uDDFF]|\uDDF3\uD83C[\uDDE6\uDDE8\uDDEA-\uDDEC\uDDEE\uDDF1\uDDF4\uDDF5\uDDF7\uDDFA\uDDFF]|\uDDF4\uD83C\uDDF2|\uDDF5\uD83C[\uDDE6\uDDEA-\uDDED\uDDF0-\uDDF3\uDDF7-\uDDF9\uDDFC\uDDFE]|\uDDF6\uD83C\uDDE6|\uDDF7\uD83C[\uDDEA\uDDF4\uDDF8\uDDFA\uDDFC]|\uDDF8\uD83C[\uDDE6-\uDDEA\uDDEC-\uDDF4\uDDF7-\uDDF9\uDDFB\uDDFD-\uDDFF]|\uDDF9\uD83C[\uDDE6\uDDE8\uDDE9\uDDEB-\uDDED\uDDEF-\uDDF4\uDDF7\uDDF9\uDDFB\uDDFC\uDDFF]|\uDDFA\uD83C[\uDDE6\uDDEC\uDDF2\uDDF3\uDDF8\uDDFE\uDDFF]|\uDDFB\uD83C[\uDDE6\uDDE8\uDDEA\uDDEC\uDDEE\uDDF3\uDDFA]|\uDDFC\uD83C[\uDDEB\uDDF8]|\uDDFD\uD83C\uDDF0|\uDDFE\uD83C[\uDDEA\uDDF9]|\uDDFF\uD83C[\uDDE6\uDDF2\uDDFC]|\uDF44(?:\u200D\uD83D\uDFEB)?|\uDF4B(?:\u200D\uD83D\uDFE9)?|\uDFC3(?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D(?:[\u2640\u2642]\uFE0F?(?:\u200D\u27A1\uFE0F?)?|\u27A1\uFE0F?))?|\uDFF3\uFE0F?(?:\u200D(?:\u26A7\uFE0F?|\uD83C\uDF08))?|\uDFF4(?:\u200D\u2620\uFE0F?|\uDB40\uDC67\uDB40\uDC62\uDB40(?:\uDC65\uDB40\uDC6E\uDB40\uDC67|\uDC73\uDB40\uDC63\uDB40\uDC74|\uDC77\uDB40\uDC6C\uDB40\uDC73)\uDB40\uDC7F)?)|\uD83D(?:[\uDC3F\uDCFD\uDD49\uDD4A\uDD6F\uDD70\uDD73\uDD76-\uDD79\uDD87\uDD8A-\uDD8D\uDDA5\uDDA8\uDDB1\uDDB2\uDDBC\uDDC2-\uDDC4\uDDD1-\uDDD3\uDDDC-\uDDDE\uDDE1\uDDE3\uDDE8\uDDEF\uDDF3\uDDFA\uDECB\uDECD-\uDECF\uDEE0-\uDEE5\uDEE9\uDEF0\uDEF3]\uFE0F?|[\uDC42\uDC43\uDC46-\uDC50\uDC66\uDC67\uDC6B-\uDC6D\uDC72\uDC74-\uDC76\uDC78\uDC7C\uDC83\uDC85\uDC8F\uDC91\uDCAA\uDD7A\uDD95\uDD96\uDE4C\uDE4F\uDEC0\uDECC](?:\uD83C[\uDFFB-\uDFFF])?|[\uDC6E-\uDC71\uDC73\uDC77\uDC81\uDC82\uDC86\uDC87\uDE45-\uDE47\uDE4B\uDE4D\uDE4E\uDEA3\uDEB4\uDEB5](?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D[\u2640\u2642]\uFE0F?)?|[\uDD74\uDD90](?:\uD83C[\uDFFB-\uDFFF]|\uFE0F)?|[\uDC00-\uDC07\uDC09-\uDC14\uDC16-\uDC25\uDC27-\uDC3A\uDC3C-\uDC3E\uDC40\uDC44\uDC45\uDC51-\uDC65\uDC6A\uDC79-\uDC7B\uDC7D-\uDC80\uDC84\uDC88-\uDC8E\uDC90\uDC92-\uDCA9\uDCAB-\uDCFC\uDCFF-\uDD3D\uDD4B-\uDD4E\uDD50-\uDD67\uDDA4\uDDFB-\uDE2D\uDE2F-\uDE34\uDE37-\uDE41\uDE43\uDE44\uDE48-\uDE4A\uDE80-\uDEA2\uDEA4-\uDEB3\uDEB7-\uDEBF\uDEC1-\uDEC5\uDED0-\uDED2\uDED5-\uDED8\uDEDC-\uDEDF\uDEEB\uDEEC\uDEF4-\uDEFC\uDFE0-\uDFEB\uDFF0]|\uDC08(?:\u200D\u2B1B)?|\uDC15(?:\u200D\uD83E\uDDBA)?|\uDC26(?:\u200D(?:\u2B1B|\uD83D\uDD25))?|\uDC3B(?:\u200D\u2744\uFE0F?)?|\uDC41\uFE0F?(?:\u200D\uD83D\uDDE8\uFE0F?)?|\uDC68(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDC68\uDC69]\u200D\uD83D(?:\uDC66(?:\u200D\uD83D\uDC66)?|\uDC67(?:\u200D\uD83D[\uDC66\uDC67])?)|[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC66(?:\u200D\uD83D\uDC66)?|\uDC67(?:\u200D\uD83D[\uDC66\uDC67])?)|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]))|\uD83C(?:\uDFFB(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC68\uD83C[\uDFFC-\uDFFF])|\uD83E(?:[\uDD1D\uDEEF]\u200D\uD83D\uDC68\uD83C[\uDFFC-\uDFFF]|[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3])))?|\uDFFC(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC68\uD83C[\uDFFB\uDFFD-\uDFFF])|\uD83E(?:[\uDD1D\uDEEF]\u200D\uD83D\uDC68\uD83C[\uDFFB\uDFFD-\uDFFF]|[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3])))?|\uDFFD(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC68\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])|\uD83E(?:[\uDD1D\uDEEF]\u200D\uD83D\uDC68\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF]|[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3])))?|\uDFFE(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC68\uD83C[\uDFFB-\uDFFD\uDFFF])|\uD83E(?:[\uDD1D\uDEEF]\u200D\uD83D\uDC68\uD83C[\uDFFB-\uDFFD\uDFFF]|[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3])))?|\uDFFF(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC68\uD83C[\uDFFB-\uDFFE])|\uD83E(?:[\uDD1D\uDEEF]\u200D\uD83D\uDC68\uD83C[\uDFFB-\uDFFE]|[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3])))?))?|\uDC69(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?[\uDC68\uDC69]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC66(?:\u200D\uD83D\uDC66)?|\uDC67(?:\u200D\uD83D[\uDC66\uDC67])?|\uDC69\u200D\uD83D(?:\uDC66(?:\u200D\uD83D\uDC66)?|\uDC67(?:\u200D\uD83D[\uDC66\uDC67])?))|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]))|\uD83C(?:\uDFFB(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:[\uDC68\uDC69]|\uDC8B\u200D\uD83D[\uDC68\uDC69])\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC69\uD83C[\uDFFC-\uDFFF])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D[\uDC68\uDC69]\uD83C[\uDFFC-\uDFFF]|\uDEEF\u200D\uD83D\uDC69\uD83C[\uDFFC-\uDFFF])))?|\uDFFC(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:[\uDC68\uDC69]|\uDC8B\u200D\uD83D[\uDC68\uDC69])\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC69\uD83C[\uDFFB\uDFFD-\uDFFF])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D[\uDC68\uDC69]\uD83C[\uDFFB\uDFFD-\uDFFF]|\uDEEF\u200D\uD83D\uDC69\uD83C[\uDFFB\uDFFD-\uDFFF])))?|\uDFFD(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:[\uDC68\uDC69]|\uDC8B\u200D\uD83D[\uDC68\uDC69])\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC69\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D[\uDC68\uDC69]\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF]|\uDEEF\u200D\uD83D\uDC69\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])))?|\uDFFE(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:[\uDC68\uDC69]|\uDC8B\u200D\uD83D[\uDC68\uDC69])\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC69\uD83C[\uDFFB-\uDFFD\uDFFF])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D[\uDC68\uDC69]\uD83C[\uDFFB-\uDFFD\uDFFF]|\uDEEF\u200D\uD83D\uDC69\uD83C[\uDFFB-\uDFFD\uDFFF])))?|\uDFFF(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:[\uDC68\uDC69]|\uDC8B\u200D\uD83D[\uDC68\uDC69])\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC69\uD83C[\uDFFB-\uDFFE])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D[\uDC68\uDC69]\uD83C[\uDFFB-\uDFFE]|\uDEEF\u200D\uD83D\uDC69\uD83C[\uDFFB-\uDFFE])))?))?|\uDD75(?:\uD83C[\uDFFB-\uDFFF]|\uFE0F)?(?:\u200D[\u2640\u2642]\uFE0F?)?|\uDE2E(?:\u200D\uD83D\uDCA8)?|\uDE35(?:\u200D\uD83D\uDCAB)?|\uDE36(?:\u200D\uD83C\uDF2B\uFE0F?)?|\uDE42(?:\u200D[\u2194\u2195]\uFE0F?)?|\uDEB6(?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D(?:[\u2640\u2642]\uFE0F?(?:\u200D\u27A1\uFE0F?)?|\u27A1\uFE0F?))?)|\uD83E(?:[\uDD0C\uDD0F\uDD18-\uDD1F\uDD30-\uDD34\uDD36\uDD77\uDDB5\uDDB6\uDDBB\uDDD2\uDDD3\uDDD5\uDEC3-\uDEC5\uDEF0\uDEF2-\uDEF8](?:\uD83C[\uDFFB-\uDFFF])?|[\uDD26\uDD35\uDD37-\uDD39\uDD3C-\uDD3E\uDDB8\uDDB9\uDDCD\uDDCF\uDDD4\uDDD6-\uDDDD](?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D[\u2640\u2642]\uFE0F?)?|[\uDDDE\uDDDF](?:\u200D[\u2640\u2642]\uFE0F?)?|[\uDD0D\uDD0E\uDD10-\uDD17\uDD20-\uDD25\uDD27-\uDD2F\uDD3A\uDD3F-\uDD45\uDD47-\uDD76\uDD78-\uDDB4\uDDB7\uDDBA\uDDBC-\uDDCC\uDDD0\uDDE0-\uDDFF\uDE70-\uDE7C\uDE80-\uDE8A\uDE8E-\uDEC2\uDEC6\uDEC8\uDECD-\uDEDC\uDEDF-\uDEEA\uDEEF]|\uDDCE(?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D(?:[\u2640\u2642]\uFE0F?(?:\u200D\u27A1\uFE0F?)?|\u27A1\uFE0F?))?|\uDDD1(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3\uDE70]|\uDD1D\u200D\uD83E\uDDD1|\uDDD1\u200D\uD83E\uDDD2(?:\u200D\uD83E\uDDD2)?|\uDDD2(?:\u200D\uD83E\uDDD2)?))|\uD83C(?:\uDFFB(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1\uD83C[\uDFFC-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83E\uDDD1\uD83C[\uDFFC-\uDFFF])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3\uDE70]|\uDD1D\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFF]|\uDEEF\u200D\uD83E\uDDD1\uD83C[\uDFFC-\uDFFF])))?|\uDFFC(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1\uD83C[\uDFFB\uDFFD-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83E\uDDD1\uD83C[\uDFFB\uDFFD-\uDFFF])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3\uDE70]|\uDD1D\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFF]|\uDEEF\u200D\uD83E\uDDD1\uD83C[\uDFFB\uDFFD-\uDFFF])))?|\uDFFD(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83E\uDDD1\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3\uDE70]|\uDD1D\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFF]|\uDEEF\u200D\uD83E\uDDD1\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])))?|\uDFFE(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1\uD83C[\uDFFB-\uDFFD\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFD\uDFFF])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3\uDE70]|\uDD1D\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFF]|\uDEEF\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFD\uDFFF])))?|\uDFFF(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1\uD83C[\uDFFB-\uDFFE]|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFE])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3\uDE70]|\uDD1D\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFF]|\uDEEF\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFE])))?))?|\uDEF1(?:\uD83C(?:\uDFFB(?:\u200D\uD83E\uDEF2\uD83C[\uDFFC-\uDFFF])?|\uDFFC(?:\u200D\uD83E\uDEF2\uD83C[\uDFFB\uDFFD-\uDFFF])?|\uDFFD(?:\u200D\uD83E\uDEF2\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])?|\uDFFE(?:\u200D\uD83E\uDEF2\uD83C[\uDFFB-\uDFFD\uDFFF])?|\uDFFF(?:\u200D\uD83E\uDEF2\uD83C[\uDFFB-\uDFFE])?))?)/g;function tH(e){return e===12288||e>=65281&&e<=65376||e>=65504&&e<=65510}function rH(e){return e>=4352&&e<=4447||e===8986||e===8987||e===9001||e===9002||e>=9193&&e<=9196||e===9200||e===9203||e===9725||e===9726||e===9748||e===9749||e>=9776&&e<=9783||e>=9800&&e<=9811||e===9855||e>=9866&&e<=9871||e===9875||e===9889||e===9898||e===9899||e===9917||e===9918||e===9924||e===9925||e===9934||e===9940||e===9962||e===9970||e===9971||e===9973||e===9978||e===9981||e===9989||e===9994||e===9995||e===10024||e===10060||e===10062||e>=10067&&e<=10069||e===10071||e>=10133&&e<=10135||e===10160||e===10175||e===11035||e===11036||e===11088||e===11093||e>=11904&&e<=11929||e>=11931&&e<=12019||e>=12032&&e<=12245||e>=12272&&e<=12287||e>=12289&&e<=12350||e>=12353&&e<=12438||e>=12441&&e<=12543||e>=12549&&e<=12591||e>=12593&&e<=12686||e>=12688&&e<=12773||e>=12783&&e<=12830||e>=12832&&e<=12871||e>=12880&&e<=42124||e>=42128&&e<=42182||e>=43360&&e<=43388||e>=44032&&e<=55203||e>=63744&&e<=64255||e>=65040&&e<=65049||e>=65072&&e<=65106||e>=65108&&e<=65126||e>=65128&&e<=65131||e>=94176&&e<=94180||e>=94192&&e<=94198||e>=94208&&e<=101589||e>=101631&&e<=101662||e>=101760&&e<=101874||e>=110576&&e<=110579||e>=110581&&e<=110587||e===110589||e===110590||e>=110592&&e<=110882||e===110898||e>=110928&&e<=110930||e===110933||e>=110948&&e<=110951||e>=110960&&e<=111355||e>=119552&&e<=119638||e>=119648&&e<=119670||e===126980||e===127183||e===127374||e>=127377&&e<=127386||e>=127488&&e<=127490||e>=127504&&e<=127547||e>=127552&&e<=127560||e===127568||e===127569||e>=127584&&e<=127589||e>=127744&&e<=127776||e>=127789&&e<=127797||e>=127799&&e<=127868||e>=127870&&e<=127891||e>=127904&&e<=127946||e>=127951&&e<=127955||e>=127968&&e<=127984||e===127988||e>=127992&&e<=128062||e===128064||e>=128066&&e<=128252||e>=128255&&e<=128317||e>=128331&&e<=128334||e>=128336&&e<=128359||e===128378||e===128405||e===128406||e===128420||e>=128507&&e<=128591||e>=128640&&e<=128709||e===128716||e>=128720&&e<=128722||e>=128725&&e<=128728||e>=128732&&e<=128735||e===128747||e===128748||e>=128756&&e<=128764||e>=128992&&e<=129003||e===129008||e>=129292&&e<=129338||e>=129340&&e<=129349||e>=129351&&e<=129535||e>=129648&&e<=129660||e>=129664&&e<=129674||e>=129678&&e<=129734||e===129736||e>=129741&&e<=129756||e>=129759&&e<=129770||e>=129775&&e<=129784||e>=131072&&e<=196605||e>=196608&&e<=262141}var nH="©®‼⁉™ℹ↔↕↖↗↘↙↩↪⌨⏏⏱⏲⏸⏹⏺▪▫▶◀◻◼☀☁☂☃☄☎☑☘☝☠☢☣☦☪☮☯☸☹☺♀♂♟♠♣♥♦♨♻♾⚒⚔⚕⚖⚗⚙⚛⚜⚠⚧⚰⚱⛈⛏⛑⛓⛩⛱⛷⛸⛹✂✈✉✌✍✏✒✔✖✝✡✳✴❄❇❣❤➡⤴⤵⬅⬆⬇",iH=/[^\x20-\x7F]/u,sH=new Set(nH);function aH(e){if(!e)return 0;if(!iH.test(e))return e.length;e=e.replace(eH(),r=>sH.has(r)?" ":" ");let t=0;for(let r of e){let n=r.codePointAt(0);n<=31||n>=127&&n<=159||n>=768&&n<=879||n>=65024&&n<=65039||(t+=tH(n)||rH(n)?2:1)}return t}var l_=aH,oH={type:0},uH={type:1},Y6={value:"",length:0,queue:[],get root(){return Y6}};function Z6(e,t,r){let n=t.type===1?e.queue.slice(0,-1):[...e.queue,t],i="",s=0,a=0,u=0;for(let y of n)switch(y.type){case 0:l(),r.useTabs?o(1):p(r.tabWidth);break;case 3:{let{string:g}=y;l(),i+=g,s+=g.length;break}case 2:{let{width:g}=y;a+=1,u+=g;break}default:throw new Error(`Unexpected indent comment '${y.type}'.`)}return f(),{...e,value:i,length:s,queue:n};function o(y){i+=" ".repeat(y),s+=r.tabWidth*y}function p(y){i+=" ".repeat(y),s+=y}function l(){r.useTabs?d():f()}function d(){a>0&&o(a),m()}function f(){u>0&&p(u),m()}function m(){a=0,u=0}}function lH(e,t,r){if(!t)return e;if(t.type==="root")return{...e,root:e};if(t===Number.NEGATIVE_INFINITY)return e.root;let n;return typeof t=="number"?t<0?n=uH:n={type:2,width:t}:n={type:3,string:t},Z6(e,n,r)}function cH(e,t){return Z6(e,oH,t)}function pH(e){let t=0;for(let r=e.length-1;r>=0;r--){let n=e[r];if(n===" "||n===" ")t++;else break}return t}function e4(e){let t=pH(e);return{text:t===0?e:e.slice(0,e.length-t),count:t}}var bi=Symbol("MODE_BREAK"),ea=Symbol("MODE_FLAT"),c_=Symbol("DOC_FILL_PRINTED_LENGTH");function Vg(e,t,r,n,i,s){if(r===Number.POSITIVE_INFINITY)return!0;let a=t.length,u=!1,o=[e],p="";for(;r>=0;){if(o.length===0){if(a===0)return!0;o.push(t[--a]);continue}let{mode:l,doc:d}=o.pop(),f=Fu(d);switch(f){case ku:d&&(u&&(p+=" ",r-=1,u=!1),p+=d,r-=l_(d));break;case Ma:case Ys:{let m=f===Ma?d:d.parts,y=d[c_]??0;for(let g=m.length-1;g>=y;g--)o.push({mode:l,doc:m[g]});break}case $a:case qa:case Ua:case Zs:o.push({mode:l,doc:d.contents});break;case ja:{let{text:m,count:y}=e4(p);p=m,r+=y;break}case xi:{if(s&&d.break)return!1;let m=d.break?bi:l,y=d.expandedStates&&m===bi?En(0,d.expandedStates,-1):d.contents;o.push({mode:m,doc:y});break}case Vi:{let m=(d.groupId?i[d.groupId]||ea:l)===bi?d.breakContents:d.flatContents;m&&o.push({mode:l,doc:m});break}case Mn:if(l===bi||d.hard)return!0;d.soft||(u=!0);break;case Va:n=!0;break;case Ja:if(n)return!1;break}}return!1}function Jg(e,t){let r=Object.create(null),n=t.printWidth,i=i_(t.endOfLine),s=0,a=[{indent:Y6,mode:bi,doc:e}],u="",o=!1,p=[],l=[],d=[],f=[],m=0;for(BJ(e);a.length>0;){let{indent:D,mode:_,doc:S}=a.pop();switch(Fu(S)){case ku:{let T=i!==` `?Og(0,S,` `,i):S;T&&(u+=T,a.length>0&&(s+=l_(T)));break}case Ma:for(let T=S.length-1;T>=0;T--)a.push({indent:D,mode:_,doc:S[T]});break;case No:if(l.length>=2)throw new Error("There are too many 'cursor' in doc.");l.push(m+u.length);break;case $a:a.push({indent:cH(D,t),mode:_,doc:S.contents});break;case qa:a.push({indent:lH(D,S.n,t),mode:_,doc:S.contents});break;case ja:b();break;case xi:switch(_){case ea:if(!o){a.push({indent:D,mode:S.break?bi:ea,doc:S.contents});break}case bi:{o=!1;let T={indent:D,mode:ea,doc:S.contents},A=n-s,F=p.length>0;if(!S.break&&Vg(T,a,A,F,r))a.push(T);else if(S.expandedStates){let N=En(0,S.expandedStates,-1);if(S.break){a.push({indent:D,mode:bi,doc:N});break}else for(let j=1;j<S.expandedStates.length+1;j++)if(j>=S.expandedStates.length){a.push({indent:D,mode:bi,doc:N});break}else{let z=S.expandedStates[j],$={indent:D,mode:ea,doc:z};if(Vg($,a,A,F,r)){a.push($);break}}}else a.push({indent:D,mode:bi,doc:S.contents});break}}S.id&&(r[S.id]=En(0,a,-1).mode);break;case Ys:{let T=n-s,A=S[c_]??0,{parts:F}=S,N=F.length-A;if(N===0)break;let j=F[A+0],z=F[A+1],$={indent:D,mode:ea,doc:j},ie={indent:D,mode:bi,doc:j},W=Vg($,[],T,p.length>0,r,!0);if(N===1){W?a.push($):a.push(ie);break}let ae={indent:D,mode:ea,doc:z},J={indent:D,mode:bi,doc:z};if(N===2){W?a.push(ae,$):a.push(J,ie);break}let L=F[A+2],C={indent:D,mode:_,doc:{...S,[c_]:A+2}},w=Vg({indent:D,mode:ea,doc:[j,z,L]},[],T,p.length>0,r,!0);a.push(C),w?a.push(ae,$):W?a.push(J,$):a.push(J,ie);break}case Vi:case Ua:{let T=S.groupId?r[S.groupId]:_;if(T===bi){let A=S.type===Vi?S.breakContents:S.negate?S.contents:jg(S.contents);A&&a.push({indent:D,mode:_,doc:A})}if(T===ea){let A=S.type===Vi?S.flatContents:S.negate?jg(S.contents):S.contents;A&&a.push({indent:D,mode:_,doc:A})}break}case Va:p.push({indent:D,mode:_,doc:S.contents});break;case Ja:p.length>0&&a.push({indent:D,mode:_,doc:o_});break;case Mn:switch(_){case ea:if(S.hard)o=!0;else{S.soft||(u+=" ",s+=1);break}case bi:if(p.length>0){a.push({indent:D,mode:_,doc:S},...p.reverse()),p.length=0;break}S.literal?(u+=i,s=0,D.root&&(D.root.value&&(u+=D.root.value),s=D.root.length)):(b(),u+=i+D.value,s=D.length);break}break;case Zs:a.push({indent:D,mode:_,doc:S.contents});break;case ps:break;default:throw new Xl(S)}a.length===0&&p.length>0&&(a.push(...p.reverse()),p.length=0)}let y=d.join("")+u,g=[...f,...l];if(g.length!==2)return{formatted:y};let x=g[0];return{formatted:y,cursorNodeStart:x,cursorNodeText:y.slice(x,En(0,g,-1))};function b(){let{text:D,count:_}=e4(u);D&&(d.push(D),m+=D.length),u="",s-=_,l.length>0&&(f.push(...l.map(S=>Math.min(S,m))),l.length=0)}}function dH(e,t,r=0){let n=0;for(let i=r;i<e.length;++i)e[i]===" "?n=n+t-n%t:n++;return n}var p_=dH,hH=class{constructor(t){this.stack=[t]}get key(){let{stack:t,siblings:r}=this;return En(0,t,r===null?-2:-4)??null}get index(){return this.siblings===null?null:En(0,this.stack,-2)}get node(){return En(0,this.stack,-1)}get parent(){return this.getNode(1)}get grandparent(){return this.getNode(2)}get isInArray(){return this.siblings!==null}get siblings(){let{stack:t}=this,r=En(0,t,-3);return Array.isArray(r)?r:null}get next(){let{siblings:t}=this;return t===null?null:t[this.index+1]}get previous(){let{siblings:t}=this;return t===null?null:t[this.index-1]}get isFirst(){return this.index===0}get isLast(){let{siblings:t,index:r}=this;return t!==null&&r===t.length-1}get isRoot(){return this.stack.length===1}get root(){return this.stack[0]}get ancestors(){return[...this.#r()]}getName(){let{stack:t}=this,{length:r}=t;return r>1?En(0,t,-2):null}getValue(){return En(0,this.stack,-1)}getNode(t=0){let r=this.#t(t);return r===-1?null:this.stack[r]}getParentNode(t=0){return this.getNode(t+1)}#t(t){let{stack:r}=this;for(let n=r.length-1;n>=0;n-=2)if(!Array.isArray(r[n])&&--t<0)return n;return-1}call(t,...r){let{stack:n}=this,{length:i}=n,s=En(0,n,-1);for(let a of r)s=s?.[a],n.push(a,s);try{return t(this)}finally{n.length=i}}callParent(t,r=0){let n=this.#t(r+1),i=this.stack.splice(n+1);try{return t(this)}finally{this.stack.push(...i)}}each(t,...r){let{stack:n}=this,{length:i}=n,s=En(0,n,-1);for(let a of r)s=s[a],n.push(a,s);try{for(let a=0;a<s.length;++a)n.push(a,s[a]),t(this,a,s),n.length-=2}finally{n.length=i}}map(t,...r){let n=[];return this.each((i,s,a)=>{n[s]=t(i,s,a)},...r),n}match(...t){let r=this.stack.length-1,n=null,i=this.stack[r--];for(let s of t){if(i===void 0)return!1;let a=null;if(typeof n=="number"&&(a=n,n=this.stack[r--],i=this.stack[r--]),s&&!s(i,n,a))return!1;n=this.stack[r--],i=this.stack[r--]}return!0}findAncestor(t){for(let r of this.#r())if(t(r))return r}hasAncestor(t){for(let r of this.#r())if(t(r))return!0;return!1}*#r(){let{stack:t}=this;for(let r=t.length-3;r>=0;r-=2){let n=t[r];Array.isArray(n)||(yield n)}}},fH=hH;function mH(e){return e!==null&&typeof e=="object"}var d_=mH;function ed(e){return(t,r,n)=>{let i=!!n?.backwards;if(r===!1)return!1;let{length:s}=t,a=r;for(;a>=0&&a<s;){let u=t.charAt(a);if(e instanceof RegExp){if(!e.test(u))return a}else if(!e.includes(u))return a;i?a--:a++}return a===-1||a===s?a:!1}}var yH=ed(/\s/u),Io=ed(" "),t4=ed(",; "),r4=ed(/[^\n\r]/u),n4=e=>e===` `||e==="\r"||e==="\u2028"||e==="\u2029";function gH(e,t,r){let n=!!r?.backwards;if(t===!1)return!1;let i=e.charAt(t);if(n){if(e.charAt(t-1)==="\r"&&i===` `)return t-2;if(n4(i))return t-1}else{if(i==="\r"&&e.charAt(t+1)===` `)return t+2;if(n4(i))return t+1}return t}var Nu=gH;function DH(e,t,r={}){let n=Io(e,r.backwards?t-1:t,r),i=Nu(e,n,r);return n!==i}var Bo=DH;function vH(e){return Array.isArray(e)&&e.length>0}var xH=vH;function*Hg(e,t){let{getVisitorKeys:r,filter:n=()=>!0}=t,i=s=>d_(s)&&n(s);for(let s of r(e)){let a=e[s];if(Array.isArray(a))for(let u of a)i(u)&&(yield u);else i(a)&&(yield a)}}function*bH(e,t){let r=[e];for(let n=0;n<r.length;n++){let i=r[n];for(let s of Hg(i,t))yield s,r.push(s)}}function CH(e,t){return Hg(e,t).next().done}function i4(e,t,r){let{cache:n}=r;if(n.has(e))return n.get(e);let{filter:i}=r;if(!i)return[];let s,a=(r.getChildren?.(e,r)??[...Hg(e,{getVisitorKeys:r.getVisitorKeys})]).flatMap(p=>(s??(s=[e,...t]),i(p,s)?[p]:i4(p,s,r))),{locStart:u,locEnd:o}=r;return a.sort((p,l)=>u(p)-u(l)||o(p)-o(l)),n.set(e,a),a}var s4=i4;function _H(e){let t=e.type||e.kind||"(unknown type)",r=String(e.name||e.id&&(typeof e.id=="object"?e.id.name:e.id)||e.key&&(typeof e.key=="object"?e.key.name:e.key)||e.value&&(typeof e.value=="object"?"":String(e.value))||e.operator||"");return r.length>20&&(r=r.slice(0,19)+"…"),t+(r?" "+r:"")}function h_(e,t){(e.comments??(e.comments=[])).push(t),t.printed=!1,t.nodeDescription=_H(e)}function td(e,t){t.leading=!0,t.trailing=!1,h_(e,t)}function Iu(e,t,r){t.leading=!1,t.trailing=!1,r&&(t.marker=r),h_(e,t)}function rd(e,t){t.leading=!1,t.trailing=!0,h_(e,t)}var a4=new WeakMap;function o4(e,t,r,n,i=[]){let{locStart:s,locEnd:a}=r,u=s(t),o=a(t),p=s4(e,i,{cache:a4,locStart:s,locEnd:a,getVisitorKeys:r.getVisitorKeys,filter:r.printer.canAttachComment,getChildren:r.printer.getCommentChildNodes}),l,d,f=0,m=p.length;for(;f<m;){let y=f+m>>1,g=p[y],x=s(g),b=a(g);if(x<=u&&o<=b)return o4(g,t,r,g,[g,...i]);if(b<=u){l=g,f=y+1;continue}if(o<=x){d=g,m=y;continue}throw new Error("Comment location overlaps with node location")}if(n?.type==="TemplateLiteral"){let{quasis:y}=n,g=m_(y,t,r);l&&m_(y,l,r)!==g&&(l=null),d&&m_(y,d,r)!==g&&(d=null)}return{enclosingNode:n,precedingNode:l,followingNode:d}}var f_=()=>!1;function EH(e,t){let{comments:r}=e;if(delete e.comments,!xH(r)||!t.printer.canAttachComment)return;let n=[],{printer:{features:{experimental_avoidAstMutation:i},handleComments:s={}},originalText:a}=t,{ownLine:u=f_,endOfLine:o=f_,remaining:p=f_}=s,l=r.map((d,f)=>({...o4(e,d,t),comment:d,text:a,options:t,ast:e,isLastComment:r.length-1===f}));for(let[d,f]of l.entries()){let{comment:m,precedingNode:y,enclosingNode:g,followingNode:x,text:b,options:D,ast:_,isLastComment:S}=f,T;if(i?T=[f]:(m.enclosingNode=g,m.precedingNode=y,m.followingNode=x,T=[m,b,D,_,S]),TH(b,D,l,d))m.placement="ownLine",u(...T)||(x?td(x,m):y?rd(y,m):Iu(g||_,m));else if(AH(b,D,l,d))m.placement="endOfLine",o(...T)||(y?rd(y,m):x?td(x,m):Iu(g||_,m));else if(m.placement="remaining",!p(...T))if(y&&x){let A=n.length;A>0&&n[A-1].followingNode!==x&&l4(n,D),n.push(f)}else y?rd(y,m):x?td(x,m):Iu(g||_,m)}if(l4(n,t),!i)for(let d of r)delete d.precedingNode,delete d.enclosingNode,delete d.followingNode}var u4=e=>!/[\S\n\u2028\u2029]/u.test(e);function TH(e,t,r,n){let{comment:i,precedingNode:s}=r[n],{locStart:a,locEnd:u}=t,o=a(i);if(s)for(let p=n-1;p>=0;p--){let{comment:l,precedingNode:d}=r[p];if(d!==s||!u4(e.slice(u(l),o)))break;o=a(l)}return Bo(e,o,{backwards:!0})}function AH(e,t,r,n){let{comment:i,followingNode:s}=r[n],{locStart:a,locEnd:u}=t,o=u(i);if(s)for(let p=n+1;p<r.length;p++){let{comment:l,followingNode:d}=r[p];if(d!==s||!u4(e.slice(o,a(l))))break;o=u(l)}return Bo(e,o)}function l4(e,t){let r=e.length;if(r===0)return;let{precedingNode:n,followingNode:i}=e[0],s=t.locStart(i),a;for(a=r;a>0;--a){let{comment:u,precedingNode:o,followingNode:p}=e[a-1],l=t.originalText.slice(t.locEnd(u),s);if(t.printer.isGap?.(l,t)??/^[\s(]*$/u.test(l))s=t.locStart(u);else break}for(let[u,{comment:o}]of e.entries())u<a?rd(n,o):td(i,o);for(let u of[n,i])u.comments&&u.comments.length>1&&u.comments.sort((o,p)=>t.locStart(o)-t.locStart(p));e.length=0}function m_(e,t,r){let n=r.locStart(t)-1;for(let i=1;i<e.length;++i)if(n<r.locStart(e[i]))return i-1;return 0}function SH(e,t){let r=t-1;r=Io(e,r,{backwards:!0}),r=Nu(e,r,{backwards:!0}),r=Io(e,r,{backwards:!0});let n=Nu(e,r,{backwards:!0});return r!==n}var y_=SH;function c4(e,t){let r=e.node;return r.printed=!0,t.printer.printComment(e,t)}function wH(e,t){let r=e.node,n=[c4(e,t)],{printer:i,originalText:s,locStart:a,locEnd:u}=t;if(i.isBlockComment?.(r)){let p=Bo(s,u(r))?Bo(s,a(r),{backwards:!0})?Ha:G6:" ";n.push(p)}else n.push(Ha);let o=Nu(s,Io(s,u(r)));return o!==!1&&Bo(s,o)&&n.push(Ha),n}function kH(e,t,r){let n=e.node,i=c4(e,t),{printer:s,originalText:a,locStart:u}=t,o=s.isBlockComment?.(n);if(r?.hasLineSuffix&&!r?.isBlock||Bo(a,u(n),{backwards:!0})){let p=y_(a,u(n));return{doc:u_([Ha,p?Ha:"",i]),isBlock:o,hasLineSuffix:!0}}return!o||r?.hasLineSuffix?{doc:[u_([" ",i]),Ug],isBlock:o,hasLineSuffix:!0}:{doc:[" ",i],isBlock:o,hasLineSuffix:!1}}function FH(e,t){let r=e.node;if(!r)return{};let n=t[Symbol.for("printedComments")];if((r.comments||[]).filter(u=>!n.has(u)).length===0)return{leading:"",trailing:""};let i=[],s=[],a;return e.each(()=>{let u=e.node;if(n?.has(u))return;let{leading:o,trailing:p}=u;o?i.push(wH(e,t)):p&&(a=kH(e,t,a),s.push(a.doc))},"comments"),{leading:i,trailing:s}}function PH(e,t,r){let{leading:n,trailing:i}=FH(e,r);return!n&&!i?t:qg(t,s=>[n,s,i])}function NH(e){let{[Symbol.for("comments")]:t,[Symbol.for("printedComments")]:r}=e;for(let n of t){if(!n.printed&&!r.has(n))throw new Error('Comment "'+n.value.trim()+'" was not printed. Please report this error!');delete n.printed}}var p4=class extends Error{name="ConfigError"},d4=class extends Error{name="UndefinedParserError"},IH={checkIgnorePragma:{category:"Special",type:"boolean",default:!1,description:"Check whether the file's first docblock comment contains '@noprettier' or '@noformat' to determine if it should be formatted.",cliCategory:"Other"},cursorOffset:{category:"Special",type:"int",default:-1,range:{start:-1,end:1/0,step:1},description:"Print (to stderr) where a cursor at the given position would move to after formatting.",cliCategory:"Editor"},endOfLine:{category:"Global",type:"choice",default:"lf",description:"Which end of line characters to apply.",choices:[{value:"lf",description:"Line Feed only (\\n), common on Linux and macOS as well as inside git repos"},{value:"crlf",description:"Carriage Return + Line Feed characters (\\r\\n), common on Windows"},{value:"cr",description:"Carriage Return character only (\\r), used very rarely"},{value:"auto",description:`Maintain existing (mixed values within one file are normalised by looking at what's used after the first line)`}]},filepath:{category:"Special",type:"path",description:"Specify the input filepath. This will be used to do parser inference.",cliName:"stdin-filepath",cliCategory:"Other",cliDescription:"Path to the file to pretend that stdin comes from."},insertPragma:{category:"Special",type:"boolean",default:!1,description:"Insert @format pragma into file's first docblock comment.",cliCategory:"Other"},parser:{category:"Global",type:"choice",default:void 0,description:"Which parser to use.",exception:e=>typeof e=="string"||typeof e=="function",choices:[{value:"flow",description:"Flow"},{value:"babel",description:"JavaScript"},{value:"babel-flow",description:"Flow"},{value:"babel-ts",description:"TypeScript"},{value:"typescript",description:"TypeScript"},{value:"acorn",description:"JavaScript"},{value:"espree",description:"JavaScript"},{value:"meriyah",description:"JavaScript"},{value:"css",description:"CSS"},{value:"less",description:"Less"},{value:"scss",description:"SCSS"},{value:"json",description:"JSON"},{value:"json5",description:"JSON5"},{value:"jsonc",description:"JSON with Comments"},{value:"json-stri