@mkbabb/keyframes.js 1.1.5 → 1.2.0
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/LICENSE +21 -674
- package/dist/keyframes.d.ts +450 -0
- package/dist/keyframes.js +1288 -0
- package/package.json +5 -13
- package/dist/assets/CSSCodeEditor.vue_vue_type_script_setup_true_lang-DoeFo9B0.js +0 -15
- package/dist/assets/KeyframeTimeline-DCuTtSyj.js +0 -3
- package/dist/assets/KeyframeTimeline-Jb8HiEJ9.css +0 -1
- package/dist/assets/KeyframesStringControls-gfJd8pQq.js +0 -6
- package/dist/assets/codicon-DCmgc-ay.ttf +0 -0
- package/dist/assets/css.worker-DaIVPe4I.js +0 -78
- package/dist/assets/cube-CrhWuGpy.png +0 -0
- package/dist/assets/editor.worker-D_e4rV1K.js +0 -11
- package/dist/assets/html2canvas.esm-DXEQVQnt.js +0 -5
- package/dist/assets/index-BV83975F.css +0 -1
- package/dist/assets/index-DJ_IAlfb.js +0 -651
- package/dist/assets/ppmycota-logo-2-CAWHh5aE.svg +0 -5
- package/dist/assets/ppmycota-logo-3-BIN0nMRd.svg +0 -5
- package/dist/assets/vendor-highlight-CTbb6sRM.js +0 -1
- package/dist/assets/vendor-monaco-BS62pb6i.js +0 -1035
- package/dist/assets/vendor-monaco-bo9aZu7E.css +0 -1
- package/dist/assets/vendor-prettier-CT2Eqd5k.js +0 -89
- package/dist/index.html +0 -20
|
@@ -1,89 +0,0 @@
|
|
|
1
|
-
var nu=Object.create,Or=Object.defineProperty,su=Object.getOwnPropertyDescriptor,ou=Object.getOwnPropertyNames,uu=Object.getPrototypeOf,iu=Object.prototype.hasOwnProperty,au=(e,t)=>()=>(t||e((t={exports:{}}).exports,t),t.exports),Br=(e,t)=>{for(var n in t)Or(e,n,{get:t[n],enumerable:!0})},lu=(e,t,n,r)=>{if(t&&typeof t=="object"||typeof t=="function")for(let u of ou(t))!iu.call(e,u)&&u!==n&&Or(e,u,{get:()=>t[u],enumerable:!(r=su(t,u))||r.enumerable});return e},cu=(e,t,n)=>(n=e!=null?nu(uu(e)):{},lu(Or(n,"default",{value:e,enumerable:!0}),e)),fu=au((e,t)=>{var n,r,u,s,i,l,f,d,a,o,p,c,D,h,y,g,m,F,b;D=/\/(?![*\/])(?:\[(?:[^\]\\\n\r\u2028\u2029]+|\\.)*\]|[^\/\\\n\r\u2028\u2029]+|\\.)*(\/[$_\u200C\u200D\p{ID_Continue}]*|\\)?/yu,c=/--|\+\+|=>|\.{3}|\??\.(?!\d)|(?:&&|\|\||\?\?|[+\-%&|^]|\*{1,2}|<{1,2}|>{1,3}|!=?|={1,2}|\/(?![\/*]))=?|[?~,:;[\](){}]/y,n=/(\x23?)(?=[$_\p{ID_Start}\\])(?:[$_\u200C\u200D\p{ID_Continue}]+|\\u[\da-fA-F]{4}|\\u\{[\da-fA-F]+\})+/yu,y=/(['"])(?:[^'"\\\n\r]+|(?!\1)['"]|\\(?:\r\n|[^]))*(\1)?/y,p=/(?: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,g=/[`}](?:[^`\\$]+|\\[^]|\$(?!\{))*(`|\$\{)?/y,b=/[\t\v\f\ufeff\p{Zs}]+/yu,d=/\r?\n|[\r\u2028\u2029]/y,a=/\/\*(?:[^*]+|\*(?!\/))*(\*\/)?/y,h=/\/\/.*/y,u=/[<>.:={}]|\/(?![\/*])/y,r=/[$_\p{ID_Start}][$_\u200C\u200D\p{ID_Continue}-]*/yu,s=/(['"])(?:[^'"]+|(?!\1)['"])*(\1)?/y,i=/[^<>{}]+/y,F=/^(?:[\/+-]|\.{3}|\?(?:InterpolationIn(?:JSX|Template)|NoLineTerminatorHere|NonExpressionParenEnd|UnaryIncDec))?$|[{}([,;<>=*%&|^!~?:]$/,m=/^(?:=>|[;\]){}]|else|\?(?:NoLineTerminatorHere|NonExpressionParenEnd))?$/,l=/^(?:await|case|default|delete|do|else|instanceof|new|return|throw|typeof|void|yield)$/,f=/^(?:return|throw|yield)$/,o=RegExp(d.source),t.exports=function*(v,{jsx:w=!1}={}){var x,C,B,k,O,N,S,I,j,$,z,M,se,W;for({length:N}=v,k=0,O="",W=[{tag:"JS"}],x=[],z=0,M=!1;k<N;){switch(I=W[W.length-1],I.tag){case"JS":case"JSNonExpressionParen":case"InterpolationInTemplate":case"InterpolationInJSX":if(v[k]==="/"&&(F.test(O)||l.test(O))&&(D.lastIndex=k,S=D.exec(v))){k=D.lastIndex,O=S[0],M=!0,yield{type:"RegularExpressionLiteral",value:S[0],closed:S[1]!==void 0&&S[1]!=="\\"};continue}if(c.lastIndex=k,S=c.exec(v)){switch(se=S[0],j=c.lastIndex,$=se,se){case"(":O==="?NonExpressionParenKeyword"&&W.push({tag:"JSNonExpressionParen",nesting:z}),z++,M=!1;break;case")":z--,M=!0,I.tag==="JSNonExpressionParen"&&z===I.nesting&&(W.pop(),$="?NonExpressionParenEnd",M=!1);break;case"{":c.lastIndex=0,B=!m.test(O)&&(F.test(O)||l.test(O)),x.push(B),M=!1;break;case"}":switch(I.tag){case"InterpolationInTemplate":if(x.length===I.nesting){g.lastIndex=k,S=g.exec(v),k=g.lastIndex,O=S[0],S[1]==="${"?(O="?InterpolationInTemplate",M=!1,yield{type:"TemplateMiddle",value:S[0]}):(W.pop(),M=!0,yield{type:"TemplateTail",value:S[0],closed:S[1]==="`"});continue}break;case"InterpolationInJSX":if(x.length===I.nesting){W.pop(),k+=1,O="}",yield{type:"JSXPunctuator",value:"}"};continue}}M=x.pop(),$=M?"?ExpressionBraceEnd":"}";break;case"]":M=!0;break;case"++":case"--":$=M?"?PostfixIncDec":"?UnaryIncDec";break;case"<":if(w&&(F.test(O)||l.test(O))){W.push({tag:"JSXTag"}),k+=1,O="<",yield{type:"JSXPunctuator",value:se};continue}M=!1;break;default:M=!1}k=j,O=$,yield{type:"Punctuator",value:se};continue}if(n.lastIndex=k,S=n.exec(v)){switch(k=n.lastIndex,$=S[0],S[0]){case"for":case"if":case"while":case"with":O!=="."&&O!=="?."&&($="?NonExpressionParenKeyword")}O=$,M=!l.test(S[0]),yield{type:S[1]==="#"?"PrivateIdentifier":"IdentifierName",value:S[0]};continue}if(y.lastIndex=k,S=y.exec(v)){k=y.lastIndex,O=S[0],M=!0,yield{type:"StringLiteral",value:S[0],closed:S[2]!==void 0};continue}if(p.lastIndex=k,S=p.exec(v)){k=p.lastIndex,O=S[0],M=!0,yield{type:"NumericLiteral",value:S[0]};continue}if(g.lastIndex=k,S=g.exec(v)){k=g.lastIndex,O=S[0],S[1]==="${"?(O="?InterpolationInTemplate",W.push({tag:"InterpolationInTemplate",nesting:x.length}),M=!1,yield{type:"TemplateHead",value:S[0]}):(M=!0,yield{type:"NoSubstitutionTemplate",value:S[0],closed:S[1]==="`"});continue}break;case"JSXTag":case"JSXTagEnd":if(u.lastIndex=k,S=u.exec(v)){switch(k=u.lastIndex,$=S[0],S[0]){case"<":W.push({tag:"JSXTag"});break;case">":W.pop(),O==="/"||I.tag==="JSXTagEnd"?($="?JSX",M=!0):W.push({tag:"JSXChildren"});break;case"{":W.push({tag:"InterpolationInJSX",nesting:x.length}),$="?InterpolationInJSX",M=!1;break;case"/":O==="<"&&(W.pop(),W[W.length-1].tag==="JSXChildren"&&W.pop(),W.push({tag:"JSXTagEnd"}))}O=$,yield{type:"JSXPunctuator",value:S[0]};continue}if(r.lastIndex=k,S=r.exec(v)){k=r.lastIndex,O=S[0],yield{type:"JSXIdentifier",value:S[0]};continue}if(s.lastIndex=k,S=s.exec(v)){k=s.lastIndex,O=S[0],yield{type:"JSXString",value:S[0],closed:S[2]!==void 0};continue}break;case"JSXChildren":if(i.lastIndex=k,S=i.exec(v)){k=i.lastIndex,O=S[0],yield{type:"JSXText",value:S[0]};continue}switch(v[k]){case"<":W.push({tag:"JSXTag"}),k++,O="<",yield{type:"JSXPunctuator",value:"<"};continue;case"{":W.push({tag:"InterpolationInJSX",nesting:x.length}),k++,O="?InterpolationInJSX",M=!1,yield{type:"JSXPunctuator",value:"{"};continue}}if(b.lastIndex=k,S=b.exec(v)){k=b.lastIndex,yield{type:"WhiteSpace",value:S[0]};continue}if(d.lastIndex=k,S=d.exec(v)){k=d.lastIndex,M=!1,f.test(O)&&(O="?NoLineTerminatorHere"),yield{type:"LineTerminatorSequence",value:S[0]};continue}if(a.lastIndex=k,S=a.exec(v)){k=a.lastIndex,o.test(S[0])&&(M=!1,f.test(O)&&(O="?NoLineTerminatorHere")),yield{type:"MultiLineComment",value:S[0],closed:S[1]!==void 0};continue}if(h.lastIndex=k,S=h.exec(v)){k=h.lastIndex,M=!1,yield{type:"SingleLineComment",value:S[0]};continue}C=String.fromCodePoint(v.codePointAt(k)),k+=C.length,O=C,M=!1,yield{type:I.tag.startsWith("JSX")?"JSXInvalid":"Invalid",value:C}}}}),pu={};Br(pu,{__debug:()=>tc,check:()=>Zl,doc:()=>Hs,format:()=>Ys,formatWithCursor:()=>Qs,getSupportInfo:()=>ec,util:()=>Gs,version:()=>El});var vt=(e,t)=>(n,r,...u)=>n|1&&r==null?void 0:(t.call(r)??r[e]).apply(r,u),hu=String.prototype.replaceAll??function(e,t){return e.global?this.replace(e,t):this.split(e).join(t)},du=vt("replaceAll",function(){if(typeof this=="string")return hu}),zt=du,Du=class{diff(t,n,r={}){let u;typeof r=="function"?(u=r,r={}):"callback"in r&&(u=r.callback);let s=this.castInput(t,r),i=this.castInput(n,r),l=this.removeEmpty(this.tokenize(s,r)),f=this.removeEmpty(this.tokenize(i,r));return this.diffWithOptionsObj(l,f,r,u)}diffWithOptionsObj(t,n,r,u){var s;let i=m=>{if(m=this.postProcess(m,r),u){setTimeout(function(){u(m)},0);return}else return m},l=n.length,f=t.length,d=1,a=l+f;r.maxEditLength!=null&&(a=Math.min(a,r.maxEditLength));let o=(s=r.timeout)!==null&&s!==void 0?s:1/0,p=Date.now()+o,c=[{oldPos:-1,lastComponent:void 0}],D=this.extractCommon(c[0],n,t,0,r);if(c[0].oldPos+1>=f&&D+1>=l)return i(this.buildValues(c[0].lastComponent,n,t));let h=-1/0,y=1/0,g=()=>{for(let m=Math.max(h,-d);m<=Math.min(y,d);m+=2){let F,b=c[m-1],v=c[m+1];b&&(c[m-1]=void 0);let w=!1;if(v){let C=v.oldPos-m;w=v&&0<=C&&C<l}let x=b&&b.oldPos+1<f;if(!w&&!x){c[m]=void 0;continue}if(!x||w&&b.oldPos<v.oldPos?F=this.addToPath(v,!0,!1,0,r):F=this.addToPath(b,!1,!0,1,r),D=this.extractCommon(F,n,t,m,r),F.oldPos+1>=f&&D+1>=l)return i(this.buildValues(F.lastComponent,n,t))||!0;c[m]=F,F.oldPos+1>=f&&(y=Math.min(y,m-1)),D+1>=l&&(h=Math.max(h,m+1))}d++};if(u)(function m(){setTimeout(function(){if(d>a||Date.now()>p)return u(void 0);g()||m()},0)})();else for(;d<=a&&Date.now()<=p;){let m=g();if(m)return m}}addToPath(t,n,r,u,s){let i=t.lastComponent;return i&&!s.oneChangePerToken&&i.added===n&&i.removed===r?{oldPos:t.oldPos+u,lastComponent:{count:i.count+1,added:n,removed:r,previousComponent:i.previousComponent}}:{oldPos:t.oldPos+u,lastComponent:{count:1,added:n,removed:r,previousComponent:i}}}extractCommon(t,n,r,u,s){let i=n.length,l=r.length,f=t.oldPos,d=f-u,a=0;for(;d+1<i&&f+1<l&&this.equals(r[f+1],n[d+1],s);)d++,f++,a++,s.oneChangePerToken&&(t.lastComponent={count:1,previousComponent:t.lastComponent,added:!1,removed:!1});return a&&!s.oneChangePerToken&&(t.lastComponent={count:a,previousComponent:t.lastComponent,added:!1,removed:!1}),t.oldPos=f,d}equals(t,n,r){return r.comparator?r.comparator(t,n):t===n||!!r.ignoreCase&&t.toLowerCase()===n.toLowerCase()}removeEmpty(t){let n=[];for(let r=0;r<t.length;r++)t[r]&&n.push(t[r]);return n}castInput(t,n){return t}tokenize(t,n){return Array.from(t)}join(t){return t.join("")}postProcess(t,n){return t}get useLongestToken(){return!1}buildValues(t,n,r){let u=[],s;for(;t;)u.push(t),s=t.previousComponent,delete t.previousComponent,t=s;u.reverse();let i=u.length,l=0,f=0,d=0;for(;l<i;l++){let a=u[l];if(a.removed)a.value=this.join(r.slice(d,d+a.count)),d+=a.count;else{if(!a.added&&this.useLongestToken){let o=n.slice(f,f+a.count);o=o.map(function(p,c){let D=r[d+c];return D.length>p.length?D:p}),a.value=this.join(o)}else a.value=this.join(n.slice(f,f+a.count));f+=a.count,a.added||(d+=a.count)}}return u}},mu=class extends Du{tokenize(t){return t.slice()}join(t){return t}removeEmpty(t){return t}},gu=new mu;function yu(e,t,n){return gu.diff(e,t,n)}var vu=()=>{},Fu=vu,Zn="cr",es="crlf",wu="lf",bu=wu,Tr="\r",ts=`\r
|
|
2
|
-
`,qt=`
|
|
3
|
-
`,xu=qt;function Cu(e){let t=e.indexOf(Tr);return t!==-1?e.charAt(t+1)===qt?es:Zn:bu}function $r(e){return e===Zn?Tr:e===es?ts:xu}var ku=new Map([[qt,/\n/gu],[Tr,/\r/gu],[ts,/\r\n/gu]]);function rs(e,t){let n=ku.get(t);return e.match(n)?.length??0}var Eu=/\r\n?/gu;function Au(e){return zt(0,e,Eu,qt)}function Su(e){return this[e<0?this.length+e:e]}var Ou=vt("at",function(){if(Array.isArray(this)||typeof this=="string")return Su}),H=Ou,We="string",ge="array",$e="cursor",ye="indent",ve="align",Fe="trim",Z="group",pe="fill",re="if-break",we="indent-if-break",be="line-suffix",xe="line-suffix-boundary",G="line",he="label",ie="break-parent",ns=new Set([$e,ye,ve,Fe,Z,pe,re,we,be,xe,G,he,ie]);function Bu(e){let t=e.length;for(;t>0&&(e[t-1]==="\r"||e[t-1]===`
|
|
4
|
-
`);)t--;return t<e.length?e.slice(0,t):e}function Tu(e){if(typeof e=="string")return We;if(Array.isArray(e))return ge;if(!e)return;let{type:t}=e;if(ns.has(t))return t}var ze=Tu,$u=e=>new Intl.ListFormat("en-US",{type:"disjunction"}).format(e);function _u(e){let t=e===null?"null":typeof e;if(t!=="string"&&t!=="object")return`Unexpected doc '${t}',
|
|
5
|
-
Expected it to be 'string' or 'object'.`;if(ze(e))throw new Error("doc is valid.");let n=Object.prototype.toString.call(e);if(n!=="[object Object]")return`Unexpected doc '${n}'.`;let r=$u([...ns].map(u=>`'${u}'`));return`Unexpected doc.type '${e.type}'.
|
|
6
|
-
Expected it to be ${r}.`}var Iu=class extends Error{name="InvalidDocError";constructor(t){super(_u(t)),this.doc=t}},Ze=Iu,vn={};function ju(e,t,n,r){let u=[e];for(;u.length>0;){let s=u.pop();if(s===vn){n(u.pop());continue}n&&u.push(s,vn);let i=ze(s);if(!i)throw new Ze(s);if(t?.(s)!==!1)switch(i){case ge:case pe:{let l=i===ge?s:s.parts;for(let f=l.length,d=f-1;d>=0;--d)u.push(l[d]);break}case re:u.push(s.flatContents,s.breakContents);break;case Z:if(r&&s.expandedStates)for(let l=s.expandedStates.length,f=l-1;f>=0;--f)u.push(s.expandedStates[f]);else u.push(s.contents);break;case ve:case ye:case we:case he:case be:u.push(s.contents);break;case We:case $e:case Fe:case xe:case G:case ie:break;default:throw new Ze(s)}}}var _r=ju;function Jt(e,t){if(typeof e=="string")return t(e);let n=new Map;return r(e);function r(s){if(n.has(s))return n.get(s);let i=u(s);return n.set(s,i),i}function u(s){switch(ze(s)){case ge:return t(s.map(r));case pe:return t({...s,parts:s.parts.map(r)});case re:return t({...s,breakContents:r(s.breakContents),flatContents:r(s.flatContents)});case Z:{let{expandedStates:i,contents:l}=s;return i?(i=i.map(r),l=i[0]):l=r(l),t({...s,contents:l,expandedStates:i})}case ve:case ye:case we:case he:case be:return t({...s,contents:r(s.contents)});case We:case $e:case Fe:case xe:case G:case ie:return t(s);default:throw new Ze(s)}}}function Ir(e,t,n){let r=n,u=!1;function s(i){if(u)return!1;let l=t(i);l!==void 0&&(u=!0,r=l)}return _r(e,s),r}function Nu(e){if(e.type===Z&&e.break||e.type===G&&e.hard||e.type===ie)return!0}function Pu(e){return Ir(e,Nu,!1)}function Fn(e){if(e.length>0){let t=H(0,e,-1);!t.expandedStates&&!t.break&&(t.break="propagated")}return null}function Lu(e){let t=new Set,n=[];function r(s){if(s.type===ie&&Fn(n),s.type===Z){if(n.push(s),t.has(s))return!1;t.add(s)}}function u(s){s.type===Z&&n.pop().break&&Fn(n)}_r(e,r,u,!0)}function Mu(e){return e.type===G&&!e.hard?e.soft?"":" ":e.type===re?e.flatContents:e}function Ru(e){return Jt(e,Mu)}function wn(e){for(e=[...e];e.length>=2&&H(0,e,-2).type===G&&H(0,e,-1).type===ie;)e.length-=2;if(e.length>0){let t=pt(H(0,e,-1));e[e.length-1]=t}return e}function pt(e){switch(ze(e)){case ye:case we:case Z:case be:case he:{let t=pt(e.contents);return{...e,contents:t}}case re:return{...e,breakContents:pt(e.breakContents),flatContents:pt(e.flatContents)};case pe:return{...e,parts:wn(e.parts)};case ge:return wn(e);case We:return Bu(e);case ve:case $e:case Fe:case xe:case G:case ie:break;default:throw new Ze(e)}return e}function ss(e){return pt(zu(e))}function Wu(e){switch(ze(e)){case pe:if(e.parts.every(t=>t===""))return"";break;case Z:if(!e.contents&&!e.id&&!e.break&&!e.expandedStates)return"";if(e.contents.type===Z&&e.contents.id===e.id&&e.contents.break===e.break&&e.contents.expandedStates===e.expandedStates)return e.contents;break;case ve:case ye:case we:case be:if(!e.contents)return"";break;case re:if(!e.flatContents&&!e.breakContents)return"";break;case ge:{let t=[];for(let n of e){if(!n)continue;let[r,...u]=Array.isArray(n)?n:[n];typeof r=="string"&&typeof H(0,t,-1)=="string"?t[t.length-1]+=r:t.push(r),t.push(...u)}return t.length===0?"":t.length===1?t[0]:t}case We:case $e:case Fe:case xe:case G:case he:case ie:break;default:throw new Ze(e)}return e}function zu(e){return Jt(e,t=>Wu(t))}function qu(e,t=fs){return Jt(e,n=>typeof n=="string"?as(t,n.split(`
|
|
7
|
-
`)):n)}function Ju(e){if(e.type===G)return!0}function Vu(e){return Ir(e,Ju,!1)}function Pt(e,t){return e.type===he?{...e,contents:t(e.contents)}:t(e)}var Uu=Fu;function Wt(e){return{type:ye,contents:e}}function et(e,t){return{type:ve,contents:t,n:e}}function Hu(e){return et(Number.NEGATIVE_INFINITY,e)}function os(e){return et({type:"root"},e)}function Gu(e){return et(-1,e)}function us(e,t,n){let r=e;if(t>0){for(let u=0;u<Math.floor(t/n);++u)r=Wt(r);r=et(t%n,r),r=et(Number.NEGATIVE_INFINITY,r)}return r}var Vt={type:ie},Le={type:$e};function Ku(e){return{type:pe,parts:e}}function is(e,t={}){return Uu(t.expandedStates),{type:Z,id:t.id,contents:e,break:!!t.shouldBreak,expandedStates:t.expandedStates}}function Xu(e,t){return is(e[0],{...t,expandedStates:e})}function Qu(e,t="",n={}){return{type:re,breakContents:e,flatContents:t,groupId:n.groupId}}function Yu(e,t){return{type:we,contents:e,groupId:t.groupId,negate:t.negate}}function as(e,t){let n=[];for(let r=0;r<t.length;r++)r!==0&&n.push(e),n.push(t[r]);return n}function Zu(e,t){return e?{type:he,label:e,contents:t}:t}var ls={type:G},ei={type:G,soft:!0},jr={type:G,hard:!0},me=[jr,Vt],cs={type:G,hard:!0,literal:!0},fs=[cs,Vt];function vr(e){return{type:be,contents:e}}var ti={type:xe},ri={type:Fe};function De(e){if(!e)return"";if(Array.isArray(e)){let t=[];for(let n of e)if(Array.isArray(n))t.push(...De(n));else{let r=De(n);r!==""&&t.push(r)}return t}return e.type===re?{...e,breakContents:De(e.breakContents),flatContents:De(e.flatContents)}:e.type===Z?{...e,contents:De(e.contents),expandedStates:e.expandedStates?.map(De)}:e.type===pe?{type:"fill",parts:e.parts.map(De)}:e.contents?{...e,contents:De(e.contents)}:e}function ni(e){let t=Object.create(null),n=new Set;return r(De(e));function r(s,i,l){if(typeof s=="string")return JSON.stringify(s);if(Array.isArray(s)){let f=s.map(r).filter(Boolean);return f.length===1?f[0]:`[${f.join(", ")}]`}if(s.type===G){let f=l?.[i+1]?.type===ie;return s.literal?f?"literalline":"literallineWithoutBreakParent":s.hard?f?"hardline":"hardlineWithoutBreakParent":s.soft?"softline":"line"}if(s.type===ie)return l?.[i-1]?.type===G&&l[i-1].hard?void 0:"breakParent";if(s.type===Fe)return"trim";if(s.type===ye)return"indent("+r(s.contents)+")";if(s.type===ve)return s.n===Number.NEGATIVE_INFINITY?"dedentToRoot("+r(s.contents)+")":s.n<0?"dedent("+r(s.contents)+")":s.n.type==="root"?"markAsRoot("+r(s.contents)+")":"align("+JSON.stringify(s.n)+", "+r(s.contents)+")";if(s.type===re)return"ifBreak("+r(s.breakContents)+(s.flatContents?", "+r(s.flatContents):"")+(s.groupId?(s.flatContents?"":', ""')+`, { groupId: ${u(s.groupId)} }`:"")+")";if(s.type===we){let f=[];s.negate&&f.push("negate: true"),s.groupId&&f.push(`groupId: ${u(s.groupId)}`);let d=f.length>0?`, { ${f.join(", ")} }`:"";return`indentIfBreak(${r(s.contents)}${d})`}if(s.type===Z){let f=[];s.break&&s.break!=="propagated"&&f.push("shouldBreak: true"),s.id&&f.push(`id: ${u(s.id)}`);let d=f.length>0?`, { ${f.join(", ")} }`:"";return s.expandedStates?`conditionalGroup([${s.expandedStates.map(a=>r(a)).join(",")}]${d})`:`group(${r(s.contents)}${d})`}if(s.type===pe)return`fill([${s.parts.map(f=>r(f)).join(", ")}])`;if(s.type===be)return"lineSuffix("+r(s.contents)+")";if(s.type===xe)return"lineSuffixBoundary";if(s.type===he)return`label(${JSON.stringify(s.label)}, ${r(s.contents)})`;if(s.type===$e)return"cursor";throw new Error("Unknown doc type "+s.type)}function u(s){if(typeof s!="symbol")return JSON.stringify(String(s));if(s in t)return t[s];let i=s.description||"symbol";for(let l=0;;l++){let f=i+(l>0?` #${l}`:"");if(!n.has(f))return n.add(f),t[s]=`Symbol.for(${JSON.stringify(f)})`}}}var si=()=>/[#*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 oi(e){return e===12288||e>=65281&&e<=65376||e>=65504&&e<=65510}function ui(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 ii="©®‼⁉™ℹ↔↕↖↗↘↙↩↪⌨⏏⏱⏲⏸⏹⏺▪▫▶◀◻◼☀☁☂☃☄☎☑☘☝☠☢☣☦☪☮☯☸☹☺♀♂♟♠♣♥♦♨♻♾⚒⚔⚕⚖⚗⚙⚛⚜⚠⚧⚰⚱⛈⛏⛑⛓⛩⛱⛷⛸⛹✂✈✉✌✍✏✒✔✖✝✡✳✴❄❇❣❤➡⤴⤵⬅⬆⬇",ai=/[^\x20-\x7F]/u,li=new Set(ii);function ci(e){if(!e)return 0;if(!ai.test(e))return e.length;e=e.replace(si(),n=>li.has(n)?" ":" ");let t=0;for(let n of e){let r=n.codePointAt(0);r<=31||r>=127&&r<=159||r>=768&&r<=879||r>=65024&&r<=65039||(t+=oi(r)||ui(r)?2:1)}return t}var Nr=ci,fi={type:0},pi={type:1},ps={value:"",length:0,queue:[],get root(){return ps}};function hs(e,t,n){let r=t.type===1?e.queue.slice(0,-1):[...e.queue,t],u="",s=0,i=0,l=0;for(let D of r)switch(D.type){case 0:a(),n.useTabs?f(1):d(n.tabWidth);break;case 3:{let{string:h}=D;a(),u+=h,s+=h.length;break}case 2:{let{width:h}=D;i+=1,l+=h;break}default:throw new Error(`Unexpected indent comment '${D.type}'.`)}return p(),{...e,value:u,length:s,queue:r};function f(D){u+=" ".repeat(D),s+=n.tabWidth*D}function d(D){u+=" ".repeat(D),s+=D}function a(){n.useTabs?o():p()}function o(){i>0&&f(i),c()}function p(){l>0&&d(l),c()}function c(){i=0,l=0}}function hi(e,t,n){if(!t)return e;if(t.type==="root")return{...e,root:e};if(t===Number.NEGATIVE_INFINITY)return e.root;let r;return typeof t=="number"?t<0?r=pi:r={type:2,width:t}:r={type:3,string:t},hs(e,r,n)}function di(e,t){return hs(e,fi,t)}function Di(e){let t=0;for(let n=e.length-1;n>=0;n--){let r=e[n];if(r===" "||r===" ")t++;else break}return t}function ds(e){let t=Di(e);return{text:t===0?e:e.slice(0,e.length-t),count:t}}var X=Symbol("MODE_BREAK"),ce=Symbol("MODE_FLAT"),Fr=Symbol("DOC_FILL_PRINTED_LENGTH");function Tt(e,t,n,r,u,s){if(n===Number.POSITIVE_INFINITY)return!0;let i=t.length,l=!1,f=[e],d="";for(;n>=0;){if(f.length===0){if(i===0)return!0;f.push(t[--i]);continue}let{mode:a,doc:o}=f.pop(),p=ze(o);switch(p){case We:o&&(l&&(d+=" ",n-=1,l=!1),d+=o,n-=Nr(o));break;case ge:case pe:{let c=p===ge?o:o.parts,D=o[Fr]??0;for(let h=c.length-1;h>=D;h--)f.push({mode:a,doc:c[h]});break}case ye:case ve:case we:case he:f.push({mode:a,doc:o.contents});break;case Fe:{let{text:c,count:D}=ds(d);d=c,n+=D;break}case Z:{if(s&&o.break)return!1;let c=o.break?X:a,D=o.expandedStates&&c===X?H(0,o.expandedStates,-1):o.contents;f.push({mode:c,doc:D});break}case re:{let c=(o.groupId?u[o.groupId]||ce:a)===X?o.breakContents:o.flatContents;c&&f.push({mode:a,doc:c});break}case G:if(a===X||o.hard)return!0;o.soft||(l=!0);break;case be:r=!0;break;case xe:if(r)return!1;break}}return!1}function Ut(e,t){let n=Object.create(null),r=t.printWidth,u=$r(t.endOfLine),s=0,i=[{indent:ps,mode:X,doc:e}],l="",f=!1,d=[],a=[],o=[],p=[],c=0;for(Lu(e);i.length>0;){let{indent:m,mode:F,doc:b}=i.pop();switch(ze(b)){case We:{let v=u!==`
|
|
8
|
-
`?zt(0,b,`
|
|
9
|
-
`,u):b;v&&(l+=v,i.length>0&&(s+=Nr(v)));break}case ge:for(let v=b.length-1;v>=0;v--)i.push({indent:m,mode:F,doc:b[v]});break;case $e:if(a.length>=2)throw new Error("There are too many 'cursor' in doc.");a.push(c+l.length);break;case ye:i.push({indent:di(m,t),mode:F,doc:b.contents});break;case ve:i.push({indent:hi(m,b.n,t),mode:F,doc:b.contents});break;case Fe:g();break;case Z:switch(F){case ce:if(!f){i.push({indent:m,mode:b.break?X:ce,doc:b.contents});break}case X:{f=!1;let v={indent:m,mode:ce,doc:b.contents},w=r-s,x=d.length>0;if(!b.break&&Tt(v,i,w,x,n))i.push(v);else if(b.expandedStates){let C=H(0,b.expandedStates,-1);if(b.break){i.push({indent:m,mode:X,doc:C});break}else for(let B=1;B<b.expandedStates.length+1;B++)if(B>=b.expandedStates.length){i.push({indent:m,mode:X,doc:C});break}else{let k=b.expandedStates[B],O={indent:m,mode:ce,doc:k};if(Tt(O,i,w,x,n)){i.push(O);break}}}else i.push({indent:m,mode:X,doc:b.contents});break}}b.id&&(n[b.id]=H(0,i,-1).mode);break;case pe:{let v=r-s,w=b[Fr]??0,{parts:x}=b,C=x.length-w;if(C===0)break;let B=x[w+0],k=x[w+1],O={indent:m,mode:ce,doc:B},N={indent:m,mode:X,doc:B},S=Tt(O,[],v,d.length>0,n,!0);if(C===1){S?i.push(O):i.push(N);break}let I={indent:m,mode:ce,doc:k},j={indent:m,mode:X,doc:k};if(C===2){S?i.push(I,O):i.push(j,N);break}let $=x[w+2],z={indent:m,mode:F,doc:{...b,[Fr]:w+2}},M=Tt({indent:m,mode:ce,doc:[B,k,$]},[],v,d.length>0,n,!0);i.push(z),M?i.push(I,O):S?i.push(j,O):i.push(j,N);break}case re:case we:{let v=b.groupId?n[b.groupId]:F;if(v===X){let w=b.type===re?b.breakContents:b.negate?b.contents:Wt(b.contents);w&&i.push({indent:m,mode:F,doc:w})}if(v===ce){let w=b.type===re?b.flatContents:b.negate?Wt(b.contents):b.contents;w&&i.push({indent:m,mode:F,doc:w})}break}case be:d.push({indent:m,mode:F,doc:b.contents});break;case xe:d.length>0&&i.push({indent:m,mode:F,doc:jr});break;case G:switch(F){case ce:if(b.hard)f=!0;else{b.soft||(l+=" ",s+=1);break}case X:if(d.length>0){i.push({indent:m,mode:F,doc:b},...d.reverse()),d.length=0;break}b.literal?(l+=u,s=0,m.root&&(m.root.value&&(l+=m.root.value),s=m.root.length)):(g(),l+=u+m.value,s=m.length);break}break;case he:i.push({indent:m,mode:F,doc:b.contents});break;case ie:break;default:throw new Ze(b)}i.length===0&&d.length>0&&(i.push(...d.reverse()),d.length=0)}let D=o.join("")+l,h=[...p,...a];if(h.length!==2)return{formatted:D};let y=h[0];return{formatted:D,cursorNodeStart:y,cursorNodeText:D.slice(y,H(0,h,-1))};function g(){let{text:m,count:F}=ds(l);m&&(o.push(m),c+=m.length),l="",s-=F,a.length>0&&(p.push(...a.map(b=>Math.min(b,c))),a.length=0)}}function mi(e,t,n=0){let r=0;for(let u=n;u<e.length;++u)e[u]===" "?r=r+t-r%t:r++;return r}var Pr=mi,gi=class{constructor(t){this.stack=[t]}get key(){let{stack:t,siblings:n}=this;return H(0,t,n===null?-2:-4)??null}get index(){return this.siblings===null?null:H(0,this.stack,-2)}get node(){return H(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,n=H(0,t,-3);return Array.isArray(n)?n: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:n}=this;return t!==null&&n===t.length-1}get isRoot(){return this.stack.length===1}get root(){return this.stack[0]}get ancestors(){return[...this.#e()]}getName(){let{stack:t}=this,{length:n}=t;return n>1?H(0,t,-2):null}getValue(){return H(0,this.stack,-1)}getNode(t=0){let n=this.#t(t);return n===-1?null:this.stack[n]}getParentNode(t=0){return this.getNode(t+1)}#t(t){let{stack:n}=this;for(let r=n.length-1;r>=0;r-=2)if(!Array.isArray(n[r])&&--t<0)return r;return-1}call(t,...n){let{stack:r}=this,{length:u}=r,s=H(0,r,-1);for(let i of n)s=s?.[i],r.push(i,s);try{return t(this)}finally{r.length=u}}callParent(t,n=0){let r=this.#t(n+1),u=this.stack.splice(r+1);try{return t(this)}finally{this.stack.push(...u)}}each(t,...n){let{stack:r}=this,{length:u}=r,s=H(0,r,-1);for(let i of n)s=s[i],r.push(i,s);try{for(let i=0;i<s.length;++i)r.push(i,s[i]),t(this,i,s),r.length-=2}finally{r.length=u}}map(t,...n){let r=[];return this.each((u,s,i)=>{r[s]=t(u,s,i)},...n),r}match(...t){let n=this.stack.length-1,r=null,u=this.stack[n--];for(let s of t){if(u===void 0)return!1;let i=null;if(typeof r=="number"&&(i=r,r=this.stack[n--],u=this.stack[n--]),s&&!s(u,r,i))return!1;r=this.stack[n--],u=this.stack[n--]}return!0}findAncestor(t){for(let n of this.#e())if(t(n))return n}hasAncestor(t){for(let n of this.#e())if(t(n))return!0;return!1}*#e(){let{stack:t}=this;for(let n=t.length-3;n>=0;n-=2){let r=t[n];Array.isArray(r)||(yield r)}}},yi=gi;function vi(e){return e!==null&&typeof e=="object"}var Lr=vi;function Ft(e){return(t,n,r)=>{let u=!!r?.backwards;if(n===!1)return!1;let{length:s}=t,i=n;for(;i>=0&&i<s;){let l=t.charAt(i);if(e instanceof RegExp){if(!e.test(l))return i}else if(!e.includes(l))return i;u?i--:i++}return i===-1||i===s?i:!1}}var Fi=Ft(/\s/u),Te=Ft(" "),Ds=Ft(",; "),ms=Ft(/[^\n\r]/u),bn=e=>e===`
|
|
10
|
-
`||e==="\r"||e==="\u2028"||e==="\u2029";function wi(e,t,n){let r=!!n?.backwards;if(t===!1)return!1;let u=e.charAt(t);if(r){if(e.charAt(t-1)==="\r"&&u===`
|
|
11
|
-
`)return t-2;if(bn(u))return t-1}else{if(u==="\r"&&e.charAt(t+1)===`
|
|
12
|
-
`)return t+2;if(bn(u))return t+1}return t}var Me=wi;function bi(e,t,n={}){let r=Te(e,n.backwards?t-1:t,n),u=Me(e,r,n);return r!==u}var Be=bi;function xi(e){return Array.isArray(e)&&e.length>0}var Ci=xi;function*Ht(e,t){let{getVisitorKeys:n,filter:r=()=>!0}=t,u=s=>Lr(s)&&r(s);for(let s of n(e)){let i=e[s];if(Array.isArray(i))for(let l of i)u(l)&&(yield l);else u(i)&&(yield i)}}function*ki(e,t){let n=[e];for(let r=0;r<n.length;r++){let u=n[r];for(let s of Ht(u,t))yield s,n.push(s)}}function Ei(e,t){return Ht(e,t).next().done}function gs(e,t,n){let{cache:r}=n;if(r.has(e))return r.get(e);let{filter:u}=n;if(!u)return[];let s,i=(n.getChildren?.(e,n)??[...Ht(e,{getVisitorKeys:n.getVisitorKeys})]).flatMap(d=>(s??(s=[e,...t]),u(d,s)?[d]:gs(d,s,n))),{locStart:l,locEnd:f}=n;return i.sort((d,a)=>l(d)-l(a)||f(d)-f(a)),r.set(e,i),i}var ys=gs;function Ai(e){let t=e.type||e.kind||"(unknown type)",n=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 n.length>20&&(n=n.slice(0,19)+"…"),t+(n?" "+n:"")}function Mr(e,t){(e.comments??(e.comments=[])).push(t),t.printed=!1,t.nodeDescription=Ai(e)}function ht(e,t){t.leading=!0,t.trailing=!1,Mr(e,t)}function je(e,t,n){t.leading=!1,t.trailing=!1,n&&(t.marker=n),Mr(e,t)}function dt(e,t){t.leading=!1,t.trailing=!0,Mr(e,t)}var vs=new WeakMap;function Fs(e,t,n,r,u=[]){let{locStart:s,locEnd:i}=n,l=s(t),f=i(t),d=ys(e,u,{cache:vs,locStart:s,locEnd:i,getVisitorKeys:n.getVisitorKeys,filter:n.printer.canAttachComment,getChildren:n.printer.getCommentChildNodes}),a,o,p=0,c=d.length;for(;p<c;){let D=p+c>>1,h=d[D],y=s(h),g=i(h);if(y<=l&&f<=g)return Fs(h,t,n,h,[h,...u]);if(g<=l){a=h,p=D+1;continue}if(f<=y){o=h,c=D;continue}throw new Error("Comment location overlaps with node location")}if(r?.type==="TemplateLiteral"){let{quasis:D}=r,h=ar(D,t,n);a&&ar(D,a,n)!==h&&(a=null),o&&ar(D,o,n)!==h&&(o=null)}return{enclosingNode:r,precedingNode:a,followingNode:o}}var ir=()=>!1;function Si(e,t){let{comments:n}=e;if(delete e.comments,!Ci(n)||!t.printer.canAttachComment)return;let r=[],{printer:{features:{experimental_avoidAstMutation:u},handleComments:s={}},originalText:i}=t,{ownLine:l=ir,endOfLine:f=ir,remaining:d=ir}=s,a=n.map((o,p)=>({...Fs(e,o,t),comment:o,text:i,options:t,ast:e,isLastComment:n.length-1===p}));for(let[o,p]of a.entries()){let{comment:c,precedingNode:D,enclosingNode:h,followingNode:y,text:g,options:m,ast:F,isLastComment:b}=p,v;if(u?v=[p]:(c.enclosingNode=h,c.precedingNode=D,c.followingNode=y,v=[c,g,m,F,b]),Oi(g,m,a,o))c.placement="ownLine",l(...v)||(y?ht(y,c):D?dt(D,c):je(h||F,c));else if(Bi(g,m,a,o))c.placement="endOfLine",f(...v)||(D?dt(D,c):y?ht(y,c):je(h||F,c));else if(c.placement="remaining",!d(...v))if(D&&y){let w=r.length;w>0&&r[w-1].followingNode!==y&&xn(r,m),r.push(p)}else D?dt(D,c):y?ht(y,c):je(h||F,c)}if(xn(r,t),!u)for(let o of n)delete o.precedingNode,delete o.enclosingNode,delete o.followingNode}var ws=e=>!/[\S\n\u2028\u2029]/u.test(e);function Oi(e,t,n,r){let{comment:u,precedingNode:s}=n[r],{locStart:i,locEnd:l}=t,f=i(u);if(s)for(let d=r-1;d>=0;d--){let{comment:a,precedingNode:o}=n[d];if(o!==s||!ws(e.slice(l(a),f)))break;f=i(a)}return Be(e,f,{backwards:!0})}function Bi(e,t,n,r){let{comment:u,followingNode:s}=n[r],{locStart:i,locEnd:l}=t,f=l(u);if(s)for(let d=r+1;d<n.length;d++){let{comment:a,followingNode:o}=n[d];if(o!==s||!ws(e.slice(f,i(a))))break;f=l(a)}return Be(e,f)}function xn(e,t){let n=e.length;if(n===0)return;let{precedingNode:r,followingNode:u}=e[0],s=t.locStart(u),i;for(i=n;i>0;--i){let{comment:l,precedingNode:f,followingNode:d}=e[i-1],a=t.originalText.slice(t.locEnd(l),s);if(t.printer.isGap?.(a,t)??/^[\s(]*$/u.test(a))s=t.locStart(l);else break}for(let[l,{comment:f}]of e.entries())l<i?dt(r,f):ht(u,f);for(let l of[r,u])l.comments&&l.comments.length>1&&l.comments.sort((f,d)=>t.locStart(f)-t.locStart(d));e.length=0}function ar(e,t,n){let r=n.locStart(t)-1;for(let u=1;u<e.length;++u)if(r<n.locStart(e[u]))return u-1;return 0}function Ti(e,t){let n=t-1;n=Te(e,n,{backwards:!0}),n=Me(e,n,{backwards:!0}),n=Te(e,n,{backwards:!0});let r=Me(e,n,{backwards:!0});return n!==r}var Rr=Ti;function bs(e,t){let n=e.node;return n.printed=!0,t.printer.printComment(e,t)}function $i(e,t){let n=e.node,r=[bs(e,t)],{printer:u,originalText:s,locStart:i,locEnd:l}=t;if(u.isBlockComment?.(n)){let d=Be(s,l(n))?Be(s,i(n),{backwards:!0})?me:ls:" ";r.push(d)}else r.push(me);let f=Me(s,Te(s,l(n)));return f!==!1&&Be(s,f)&&r.push(me),r}function _i(e,t,n){let r=e.node,u=bs(e,t),{printer:s,originalText:i,locStart:l}=t,f=s.isBlockComment?.(r);if(n?.hasLineSuffix&&!n?.isBlock||Be(i,l(r),{backwards:!0})){let d=Rr(i,l(r));return{doc:vr([me,d?me:"",u]),isBlock:f,hasLineSuffix:!0}}return!f||n?.hasLineSuffix?{doc:[vr([" ",u]),Vt],isBlock:f,hasLineSuffix:!0}:{doc:[" ",u],isBlock:f,hasLineSuffix:!1}}function Ii(e,t){let n=e.node;if(!n)return{};let r=t[Symbol.for("printedComments")];if((n.comments||[]).filter(l=>!r.has(l)).length===0)return{leading:"",trailing:""};let u=[],s=[],i;return e.each(()=>{let l=e.node;if(r?.has(l))return;let{leading:f,trailing:d}=l;f?u.push($i(e,t)):d&&(i=_i(e,t,i),s.push(i.doc))},"comments"),{leading:u,trailing:s}}function ji(e,t,n){let{leading:r,trailing:u}=Ii(e,n);return!r&&!u?t:Pt(t,s=>[r,s,u])}function Ni(e){let{[Symbol.for("comments")]:t,[Symbol.for("printedComments")]:n}=e;for(let r of t){if(!r.printed&&!n.has(r))throw new Error('Comment "'+r.value.trim()+'" was not printed. Please report this error!');delete r.printed}}var xs=class extends Error{name="ConfigError"},Cn=class extends Error{name="UndefinedParserError"},Pi={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
|
|
13
|
-
(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-stringify",description:"JSON.stringify"},{value:"graphql",description:"GraphQL"},{value:"markdown",description:"Markdown"},{value:"mdx",description:"MDX"},{value:"vue",description:"Vue"},{value:"yaml",description:"YAML"},{value:"glimmer",description:"Ember / Handlebars"},{value:"html",description:"HTML"},{value:"angular",description:"Angular"},{value:"lwc",description:"Lightning Web Components"},{value:"mjml",description:"MJML"}]},plugins:{type:"path",array:!0,default:[{value:[]}],category:"Global",description:"Add a plugin. Multiple plugins can be passed as separate `--plugin`s.",exception:e=>typeof e=="string"||typeof e=="object",cliName:"plugin",cliCategory:"Config"},printWidth:{category:"Global",type:"int",default:80,description:"The line length where Prettier will try wrap.",range:{start:0,end:1/0,step:1}},rangeEnd:{category:"Special",type:"int",default:1/0,range:{start:0,end:1/0,step:1},description:`Format code ending at a given character offset (exclusive).
|
|
14
|
-
The range will extend forwards to the end of the selected statement.`,cliCategory:"Editor"},rangeStart:{category:"Special",type:"int",default:0,range:{start:0,end:1/0,step:1},description:`Format code starting at a given character offset.
|
|
15
|
-
The range will extend backwards to the start of the first line containing the selected statement.`,cliCategory:"Editor"},requirePragma:{category:"Special",type:"boolean",default:!1,description:"Require either '@prettier' or '@format' to be present in the file's first docblock comment in order for it to be formatted.",cliCategory:"Other"},tabWidth:{type:"int",category:"Global",default:2,description:"Number of spaces per indentation level.",range:{start:0,end:1/0,step:1}},useTabs:{category:"Global",type:"boolean",default:!1,description:"Indent with tabs instead of spaces."},embeddedLanguageFormatting:{category:"Global",type:"choice",default:"auto",description:"Control how Prettier formats quoted code embedded in the file.",choices:[{value:"auto",description:"Format embedded code if Prettier can automatically identify it."},{value:"off",description:"Never automatically format embedded code."}]}};function Cs({plugins:e=[],showDeprecated:t=!1}={}){let n=e.flatMap(u=>u.languages??[]),r=[];for(let u of Mi(Object.assign({},...e.map(({options:s})=>s),Pi)))!t&&u.deprecated||(Array.isArray(u.choices)&&(t||(u.choices=u.choices.filter(s=>!s.deprecated)),u.name==="parser"&&(u.choices=[...u.choices,...Li(u.choices,n,e)])),u.pluginDefaults=Object.fromEntries(e.filter(s=>s.defaultOptions?.[u.name]!==void 0).map(s=>[s.name,s.defaultOptions[u.name]])),r.push(u));return{languages:n,options:r}}function*Li(e,t,n){let r=new Set(e.map(u=>u.value));for(let u of t)if(u.parsers){for(let s of u.parsers)if(!r.has(s)){r.add(s);let i=n.find(f=>f.parsers&&Object.prototype.hasOwnProperty.call(f.parsers,s)),l=u.name;i?.name&&(l+=` (plugin: ${i.name})`),yield{value:s,description:l}}}}function Mi(e){let t=[];for(let[n,r]of Object.entries(e)){let u={name:n,...r};Array.isArray(u.default)&&(u.default=H(0,u.default,-1).value),t.push(u)}return t}var Ri=Array.prototype.toReversed??function(){return[...this].reverse()},Wi=vt("toReversed",function(){if(Array.isArray(this))return Ri}),zi=Wi;function qi(){let e=globalThis,t=e.Deno?.build?.os;return typeof t=="string"?t==="windows":e.navigator?.platform?.startsWith("Win")??e.process?.platform?.startsWith("win")??!1}var Ji=qi();function ks(e){if(e=e instanceof URL?e:new URL(e),e.protocol!=="file:")throw new TypeError(`URL must be a file URL: received "${e.protocol}"`);return e}function Vi(e){return e=ks(e),decodeURIComponent(e.pathname.replace(/%(?![0-9A-Fa-f]{2})/g,"%25"))}function Ui(e){e=ks(e);let t=decodeURIComponent(e.pathname.replace(/\//g,"\\").replace(/%(?![0-9A-Fa-f]{2})/g,"%25")).replace(/^\\*([A-Za-z]:)(\\|$)/,"$1\\");return e.hostname!==""&&(t=`\\\\${e.hostname}${t}`),t}function Hi(e){return Ji?Ui(e):Vi(e)}var Gi=e=>String(e).split(/[/\\]/u).pop(),Ki=e=>String(e).startsWith("file:");function kn(e,t){if(!t)return;let n=Gi(t).toLowerCase();return e.find(({filenames:r})=>r?.some(u=>u.toLowerCase()===n))??e.find(({extensions:r})=>r?.some(u=>n.endsWith(u)))}function Xi(e,t){if(t)return e.find(({name:n})=>n.toLowerCase()===t)??e.find(({aliases:n})=>n?.includes(t))??e.find(({extensions:n})=>n?.includes(`.${t}`))}var Qi=void 0;function En(e,t){if(t){if(Ki(t))try{t=Hi(t)}catch{return}if(typeof t=="string")return e.find(({isSupported:n})=>n?.({filepath:t}))}}function Yi(e,t){let n=zi(0,e.plugins).flatMap(r=>r.languages??[]);return(Xi(n,t.language)??kn(n,t.physicalFile)??kn(n,t.file)??En(n,t.physicalFile)??En(n,t.file)??Qi?.(n,t.physicalFile))?.parsers[0]}var Es=Yi,Ye={key:e=>/^[$_a-zA-Z][$_a-zA-Z0-9]*$/.test(e)?e:JSON.stringify(e),value(e){if(e===null||typeof e!="object")return JSON.stringify(e);if(Array.isArray(e))return`[${e.map(n=>Ye.value(n)).join(", ")}]`;let t=Object.keys(e);return t.length===0?"{}":`{ ${t.map(n=>`${Ye.key(n)}: ${Ye.value(e[n])}`).join(", ")} }`},pair:({key:e,value:t})=>Ye.value({[e]:t})},Wr=new Proxy(String,{get:()=>Wr}),fe=Wr,As=()=>Wr,Zi=(e,t,{descriptor:n})=>{let r=[`${fe.yellow(typeof e=="string"?n.key(e):n.pair(e))} is deprecated`];return t&&r.push(`we now treat it as ${fe.blue(typeof t=="string"?n.key(t):n.pair(t))}`),r.join("; ")+"."},Ss=Symbol.for("vnopts.VALUE_NOT_EXIST"),Lt=Symbol.for("vnopts.VALUE_UNCHANGED"),An=" ".repeat(2),ea=(e,t,n)=>{let{text:r,list:u}=n.normalizeExpectedResult(n.schemas[e].expected(n)),s=[];return r&&s.push(Sn(e,t,r,n.descriptor)),u&&s.push([Sn(e,t,u.title,n.descriptor)].concat(u.values.map(i=>Os(i,n.loggerPrintWidth))).join(`
|
|
16
|
-
`)),Bs(s,n.loggerPrintWidth)};function Sn(e,t,n,r){return[`Invalid ${fe.red(r.key(e))} value.`,`Expected ${fe.blue(n)},`,`but received ${t===Ss?fe.gray("nothing"):fe.red(r.value(t))}.`].join(" ")}function Os({text:e,list:t},n){let r=[];return e&&r.push(`- ${fe.blue(e)}`),t&&r.push([`- ${fe.blue(t.title)}:`].concat(t.values.map(u=>Os(u,n-An.length).replace(/^|\n/g,`$&${An}`))).join(`
|
|
17
|
-
`)),Bs(r,n)}function Bs(e,t){if(e.length===1)return e[0];let[n,r]=e,[u,s]=e.map(i=>i.split(`
|
|
18
|
-
`,1)[0].length);return u>t&&u>s?r:n}var Ge=[],lr=[];function cr(e,t,n){if(e===t)return 0;let r=n?.maxDistance,u=e;e.length>t.length&&(e=t,t=u);let s=e.length,i=t.length;for(;s>0&&e.charCodeAt(~-s)===t.charCodeAt(~-i);)s--,i--;let l=0;for(;l<s&&e.charCodeAt(l)===t.charCodeAt(l);)l++;if(s-=l,i-=l,r!==void 0&&i-s>r)return r;if(s===0)return r!==void 0&&i>r?r:i;let f,d,a,o,p=0,c=0;for(;p<s;)lr[p]=e.charCodeAt(l+p),Ge[p]=++p;for(;c<i;){for(f=t.charCodeAt(l+c),a=c++,d=c,p=0;p<s;p++)o=f===lr[p]?a:a+1,a=Ge[p],d=Ge[p]=a>d?o>d?d+1:o:o>a?a+1:o;if(r!==void 0){let D=d;for(p=0;p<s;p++)Ge[p]<D&&(D=Ge[p]);if(D>r)return r}}return Ge.length=s,lr.length=s,r!==void 0&&d>r?r:d}function ta(e,t,n){if(!Array.isArray(t)||t.length===0)return;let r=n?.maxDistance,u=e.length;for(let f of t)if(f===e)return f;let s,i=Number.POSITIVE_INFINITY,l=new Set;for(let f of t){if(l.has(f))continue;l.add(f);let d=Math.abs(f.length-u);if(d>=i||d>r)continue;let a=Number.isFinite(i)?Math.min(i,r):r,o=a===void 0?cr(e,f):cr(e,f,{maxDistance:a});if(o>r)continue;let p=o;if(a!==void 0&&o===a&&a===r&&(p=cr(e,f)),p<i&&(i=p,s=f,i===0))break}if(!(i>r))return s}var Ts=(e,t,{descriptor:n,logger:r,schemas:u})=>{let s=[`Ignored unknown option ${fe.yellow(n.pair({key:e,value:t}))}.`],i=ta(e,Object.keys(u),{maxDistance:3});i&&s.push(`Did you mean ${fe.blue(n.key(i))}?`),r.warn(s.join(" "))},ra=["default","expected","validate","deprecated","forward","redirect","overlap","preprocess","postprocess"];function na(e,t){let n=new e(t),r=Object.create(n);for(let u of ra)u in t&&(r[u]=sa(t[u],n,_e.prototype[u].length));return r}var _e=class{static create(e){return na(this,e)}constructor(e){this.name=e.name}default(e){}expected(e){return"nothing"}validate(e,t){return!1}deprecated(e,t){return!1}forward(e,t){}redirect(e,t){}overlap(e,t,n){return e}preprocess(e,t){return e}postprocess(e,t){return Lt}};function sa(e,t,n){return typeof e=="function"?(...r)=>e(...r.slice(0,n-1),t,...r.slice(n-1)):()=>e}var oa=class extends _e{constructor(e){super(e),this._sourceName=e.sourceName}expected(e){return e.schemas[this._sourceName].expected(e)}validate(e,t){return t.schemas[this._sourceName].validate(e,t)}redirect(e,t){return this._sourceName}},ua=class extends _e{expected(){return"anything"}validate(){return!0}},ia=class extends _e{constructor({valueSchema:e,name:t=e.name,...n}){super({...n,name:t}),this._valueSchema=e}expected(e){let{text:t,list:n}=e.normalizeExpectedResult(this._valueSchema.expected(e));return{text:t&&`an array of ${t}`,list:n&&{title:"an array of the following values",values:[{list:n}]}}}validate(e,t){if(!Array.isArray(e))return!1;let n=[];for(let r of e){let u=t.normalizeValidateResult(this._valueSchema.validate(r,t),r);u!==!0&&n.push(u.value)}return n.length===0?!0:{value:n}}deprecated(e,t){let n=[];for(let r of e){let u=t.normalizeDeprecatedResult(this._valueSchema.deprecated(r,t),r);u!==!1&&n.push(...u.map(({value:s})=>({value:[s]})))}return n}forward(e,t){let n=[];for(let r of e){let u=t.normalizeForwardResult(this._valueSchema.forward(r,t),r);n.push(...u.map(On))}return n}redirect(e,t){let n=[],r=[];for(let u of e){let s=t.normalizeRedirectResult(this._valueSchema.redirect(u,t),u);"remain"in s&&n.push(s.remain),r.push(...s.redirect.map(On))}return n.length===0?{redirect:r}:{redirect:r,remain:n}}overlap(e,t){return e.concat(t)}};function On({from:e,to:t}){return{from:[e],to:t}}var aa=class extends _e{expected(){return"true or false"}validate(t){return typeof t=="boolean"}};function la(e,t){let n=Object.create(null);for(let r of e){let u=r[t];if(n[u])throw new Error(`Duplicate ${t} ${JSON.stringify(u)}`);n[u]=r}return n}function ca(e,t){let n=new Map;for(let r of e){let u=r[t];if(n.has(u))throw new Error(`Duplicate ${t} ${JSON.stringify(u)}`);n.set(u,r)}return n}function fa(){let e=Object.create(null);return t=>{let n=JSON.stringify(t);return e[n]?!0:(e[n]=!0,!1)}}function pa(e,t){let n=[],r=[];for(let u of e)t(u)?n.push(u):r.push(u);return[n,r]}function ha(e){return e===Math.floor(e)}function da(e,t){if(e===t)return 0;let n=typeof e,r=typeof t,u=["undefined","object","boolean","number","string"];return n!==r?u.indexOf(n)-u.indexOf(r):n!=="string"?Number(e)-Number(t):e.localeCompare(t)}function Da(e){return(...t)=>{let n=e(...t);return typeof n=="string"?new Error(n):n}}function Bn(e){return e===void 0?{}:e}function $s(e){if(typeof e=="string")return{text:e};let{text:t,list:n}=e;return ma((t||n)!==void 0,"Unexpected `expected` result, there should be at least one field."),n?{text:t,list:{title:n.title,values:n.values.map($s)}}:{text:t}}function Tn(e,t){return e===!0?!0:e===!1?{value:t}:e}function $n(e,t,n=!1){return e===!1?!1:e===!0?n?!0:[{value:t}]:"value"in e?[e]:e.length===0?!1:e}function _n(e,t){return typeof e=="string"||"key"in e?{from:t,to:e}:"from"in e?{from:e.from,to:e.to}:{from:t,to:e.to}}function wr(e,t){return e===void 0?[]:Array.isArray(e)?e.map(n=>_n(n,t)):[_n(e,t)]}function In(e,t){let n=wr(typeof e=="object"&&"redirect"in e?e.redirect:e,t);return n.length===0?{remain:t,redirect:n}:typeof e=="object"&&"remain"in e?{remain:e.remain,redirect:n}:{redirect:n}}function ma(e,t){if(!e)throw new Error(t)}var ga=class extends _e{constructor(t){super(t),this._choices=ca(t.choices.map(n=>n&&typeof n=="object"?n:{value:n}),"value")}expected({descriptor:t}){let n=Array.from(this._choices.keys()).map(s=>this._choices.get(s)).filter(({hidden:s})=>!s).map(s=>s.value).sort(da).map(t.value),r=n.slice(0,-2),u=n.slice(-2);return{text:r.concat(u.join(" or ")).join(", "),list:{title:"one of the following values",values:n}}}validate(t){return this._choices.has(t)}deprecated(t){let n=this._choices.get(t);return n&&n.deprecated?{value:t}:!1}forward(t){let n=this._choices.get(t);return n?n.forward:void 0}redirect(t){let n=this._choices.get(t);return n?n.redirect:void 0}},ya=class extends _e{expected(){return"a number"}validate(t,n){return typeof t=="number"}},va=class extends ya{expected(){return"an integer"}validate(t,n){return n.normalizeValidateResult(super.validate(t,n),t)===!0&&ha(t)}},jn=class extends _e{expected(){return"a string"}validate(t){return typeof t=="string"}},Fa=Ye,wa=Ts,ba=ea,xa=Zi,Ca=class{constructor(e,t){let{logger:n=console,loggerPrintWidth:r=80,descriptor:u=Fa,unknown:s=wa,invalid:i=ba,deprecated:l=xa,missing:f=()=>!1,required:d=()=>!1,preprocess:a=p=>p,postprocess:o=()=>Lt}=t||{};this._utils={descriptor:u,logger:n||{warn:()=>{}},loggerPrintWidth:r,schemas:la(e,"name"),normalizeDefaultResult:Bn,normalizeExpectedResult:$s,normalizeDeprecatedResult:$n,normalizeForwardResult:wr,normalizeRedirectResult:In,normalizeValidateResult:Tn},this._unknownHandler=s,this._invalidHandler=Da(i),this._deprecatedHandler=l,this._identifyMissing=(p,c)=>!(p in c)||f(p,c),this._identifyRequired=d,this._preprocess=a,this._postprocess=o,this.cleanHistory()}cleanHistory(){this._hasDeprecationWarned=fa()}normalize(e){let t={},n=[this._preprocess(e,this._utils)],r=()=>{for(;n.length!==0;){let u=n.shift(),s=this._applyNormalization(u,t);n.push(...s)}};r();for(let u of Object.keys(this._utils.schemas)){let s=this._utils.schemas[u];if(!(u in t)){let i=Bn(s.default(this._utils));"value"in i&&n.push({[u]:i.value})}}r();for(let u of Object.keys(this._utils.schemas)){if(!(u in t))continue;let s=this._utils.schemas[u],i=t[u],l=s.postprocess(i,this._utils);l!==Lt&&(this._applyValidation(l,u,s),t[u]=l)}return this._applyPostprocess(t),this._applyRequiredCheck(t),t}_applyNormalization(e,t){let n=[],{knownKeys:r,unknownKeys:u}=this._partitionOptionKeys(e);for(let s of r){let i=this._utils.schemas[s],l=i.preprocess(e[s],this._utils);this._applyValidation(l,s,i);let f=({from:o,to:p})=>{n.push(typeof p=="string"?{[p]:o}:{[p.key]:p.value})},d=({value:o,redirectTo:p})=>{let c=$n(i.deprecated(o,this._utils),l,!0);if(c!==!1)if(c===!0)this._hasDeprecationWarned(s)||this._utils.logger.warn(this._deprecatedHandler(s,p,this._utils));else for(let{value:D}of c){let h={key:s,value:D};if(!this._hasDeprecationWarned(h)){let y=typeof p=="string"?{key:p,value:D}:p;this._utils.logger.warn(this._deprecatedHandler(h,y,this._utils))}}};wr(i.forward(l,this._utils),l).forEach(f);let a=In(i.redirect(l,this._utils),l);if(a.redirect.forEach(f),"remain"in a){let o=a.remain;t[s]=s in t?i.overlap(t[s],o,this._utils):o,d({value:o})}for(let{from:o,to:p}of a.redirect)d({value:o,redirectTo:p})}for(let s of u){let i=e[s];this._applyUnknownHandler(s,i,t,(l,f)=>{n.push({[l]:f})})}return n}_applyRequiredCheck(e){for(let t of Object.keys(this._utils.schemas))if(this._identifyMissing(t,e)&&this._identifyRequired(t))throw this._invalidHandler(t,Ss,this._utils)}_partitionOptionKeys(e){let[t,n]=pa(Object.keys(e).filter(r=>!this._identifyMissing(r,e)),r=>r in this._utils.schemas);return{knownKeys:t,unknownKeys:n}}_applyValidation(e,t,n){let r=Tn(n.validate(e,this._utils),e);if(r!==!0)throw this._invalidHandler(t,r.value,this._utils)}_applyUnknownHandler(e,t,n,r){let u=this._unknownHandler(e,t,this._utils);if(u)for(let s of Object.keys(u)){if(this._identifyMissing(s,u))continue;let i=u[s];s in this._utils.schemas?r(s,i):n[s]=i}}_applyPostprocess(e){let t=this._postprocess(e,this._utils);if(t!==Lt){if(t.delete)for(let n of t.delete)delete e[n];if(t.override){let{knownKeys:n,unknownKeys:r}=this._partitionOptionKeys(t.override);for(let u of n){let s=t.override[u];this._applyValidation(s,u,this._utils.schemas[u]),e[u]=s}for(let u of r){let s=t.override[u];this._applyUnknownHandler(u,s,e,(i,l)=>{let f=this._utils.schemas[i];this._applyValidation(l,i,f),e[i]=l})}}}}},fr;function ka(e,t,{logger:n=!1,isCLI:r=!1,passThrough:u=!1,FlagSchema:s,descriptor:i}={}){if(r){if(!s)throw new Error("'FlagSchema' option is required.");if(!i)throw new Error("'descriptor' option is required.")}else i=Ye;let l=u?Array.isArray(u)?(p,c)=>u.includes(p)?{[p]:c}:void 0:(p,c)=>({[p]:c}):(p,c,D)=>{let{_:h,...y}=D.schemas;return Ts(p,c,{...D,schemas:y})},f=Ea(t,{isCLI:r,FlagSchema:s}),d=new Ca(f,{logger:n,unknown:l,descriptor:i}),a=n!==!1;a&&fr&&(d._hasDeprecationWarned=fr);let o=d.normalize(e);return a&&(fr=d._hasDeprecationWarned),o}function Ea(e,{isCLI:t,FlagSchema:n}){let r=[];t&&r.push(ua.create({name:"_"}));for(let u of e)r.push(Aa(u,{isCLI:t,optionInfos:e,FlagSchema:n})),u.alias&&t&&r.push(oa.create({name:u.alias,sourceName:u.name}));return r}function Aa(e,{isCLI:t,optionInfos:n,FlagSchema:r}){let{name:u}=e,s={name:u},i,l={};switch(e.type){case"int":i=va,t&&(s.preprocess=Number);break;case"string":i=jn;break;case"choice":i=ga,s.choices=e.choices.map(f=>f?.redirect?{...f,redirect:{to:{key:e.name,value:f.redirect}}}:f);break;case"boolean":i=aa;break;case"flag":i=r,s.flags=n.flatMap(f=>[f.alias,f.description&&f.name,f.oppositeDescription&&`no-${f.name}`].filter(Boolean));break;case"path":i=jn;break;default:throw new Error(`Unexpected type ${e.type}`)}if(e.exception?s.validate=(f,d,a)=>e.exception(f)||d.validate(f,a):s.validate=(f,d,a)=>f===void 0||d.validate(f,a),e.redirect&&(l.redirect=f=>f?{to:typeof e.redirect=="string"?e.redirect:{key:e.redirect.option,value:e.redirect.value}}:void 0),e.deprecated&&(l.deprecated=!0),t&&!e.array){let f=s.preprocess||(d=>d);s.preprocess=(d,a,o)=>a.preprocess(f(Array.isArray(d)?H(0,d,-1):d),o)}return e.array?ia.create({...t?{preprocess:f=>Array.isArray(f)?f:[f]}:{},...l,valueSchema:i.create(s)}):i.create({...s,...l})}var Sa=ka,Oa=Array.prototype.findLast??function(e){for(let t=this.length-1;t>=0;t--){let n=this[t];if(e(n,t,this))return n}},Ba=vt("findLast",function(){if(Array.isArray(this))return Oa}),_s=Ba,Ta=Symbol.for("PRETTIER_IS_FRONT_MATTER"),$a=[];function _a(e){return!!e?.[Ta]}var zr=_a,Is=new Set(["yaml","toml"]),js=({node:e})=>zr(e)&&Is.has(e.language);async function Ia(e,t,n,r){let{node:u}=n,{language:s}=u;if(!Is.has(s))return;let i=u.value.trim(),l;if(i){let f=s==="yaml"?s:Es(r,{language:s});if(!f)return;l=i?await e(i,{parser:f}):""}else l=i;return os([u.startDelimiter,u.explicitLanguage??"",me,l,l?me:"",u.endDelimiter])}function ja(e,t){return js({node:e})&&(delete t.end,delete t.raw,delete t.value),t}var Na=ja;function Pa({node:e}){return e.raw}var La=Pa,Ns=new Set(["tokens","comments","parent","enclosingNode","precedingNode","followingNode"]),Ma=e=>Object.keys(e).filter(t=>!Ns.has(t));function Ra(e,t){let n=e?r=>e(r,Ns):Ma;return t?new Proxy(n,{apply:(r,u,s)=>zr(s[0])?$a:Reflect.apply(r,u,s)}):n}var Nn=Ra;function Ps(e,t){if(!t)throw new Error("parserName is required.");let n=_s(0,e,u=>u.parsers&&Object.prototype.hasOwnProperty.call(u.parsers,t));if(n)return n;let r=`Couldn't resolve parser "${t}".`;throw r+=" Plugins must be explicitly added to the standalone bundle.",new xs(r)}function Wa(e,t){if(!t)throw new Error("astFormat is required.");let n=_s(0,e,u=>u.printers&&Object.prototype.hasOwnProperty.call(u.printers,t));if(n)return n;let r=`Couldn't find plugin for AST format "${t}".`;throw r+=" Plugins must be explicitly added to the standalone bundle.",new xs(r)}function qr({plugins:e,parser:t}){let n=Ps(e,t);return Ls(n,t)}function Ls(e,t){let n=e.parsers[t];return typeof n=="function"?n():n}async function za(e,t){let n=e.printers[t],r=typeof n=="function"?await n():n;return qa(r)}var pr=new WeakMap;function qa(e){if(pr.has(e))return pr.get(e);let{features:t,getVisitorKeys:n,embed:r,massageAstNode:u,print:s,...i}=e;t=Ha(t);let l=t.experimental_frontMatterSupport;n=Nn(n,l.massageAstNode||l.embed||l.print);let f=u;u&&l.massageAstNode&&(f=new Proxy(u,{apply(p,c,D){return Na(...D),Reflect.apply(p,c,D)}}));let d=r;if(r){let p;d=new Proxy(r,{get(c,D,h){return D==="getVisitorKeys"?(p??(p=r.getVisitorKeys?Nn(r.getVisitorKeys,l.massageAstNode||l.embed):n),p):Reflect.get(c,D,h)},apply:(c,D,h)=>l.embed&&js(...h)?Ia:Reflect.apply(c,D,h)})}let a=s;l.print&&(a=new Proxy(s,{apply(p,c,D){let[h]=D;return zr(h.node)?La(h):Reflect.apply(p,c,D)}}));let o={features:t,getVisitorKeys:n,embed:d,massageAstNode:f,print:a,...i};return pr.set(e,o),o}var Ja=["clean","embed","print"],Va=Object.fromEntries(Ja.map(e=>[e,!1]));function Ua(e){return{...Va,...e}}function Ha(e){return{experimental_avoidAstMutation:!1,...e,experimental_frontMatterSupport:Ua(e?.experimental_frontMatterSupport)}}var Pn={astFormat:"estree",printer:{},originalText:void 0,locStart:null,locEnd:null,getVisitorKeys:null};async function Ga(e,t={}){let n={...e};if(!n.parser)if(n.filepath){if(n.parser=Es(n,{physicalFile:n.filepath}),!n.parser)throw new Cn(`No parser could be inferred for file "${n.filepath}".`)}else throw new Cn("No parser and no file path given, couldn't infer a parser.");let r=Cs({plugins:e.plugins,showDeprecated:!0}).options,u={...Pn,...Object.fromEntries(r.filter(o=>o.default!==void 0).map(o=>[o.name,o.default]))},s=Ps(n.plugins,n.parser),i=await Ls(s,n.parser);n.astFormat=i.astFormat,n.locEnd=i.locEnd,n.locStart=i.locStart;let l=s.printers?.[i.astFormat]?s:Wa(n.plugins,i.astFormat),f=await za(l,i.astFormat);n.printer=f,n.getVisitorKeys=f.getVisitorKeys;let d=l.defaultOptions?Object.fromEntries(Object.entries(l.defaultOptions).filter(([,o])=>o!==void 0)):{},a={...u,...d};for(let[o,p]of Object.entries(a))(n[o]===null||n[o]===void 0)&&(n[o]=p);return n.parser==="json"&&(n.trailingComma="none"),Sa(n,r,{passThrough:Object.keys(Pn),...t})}var tt=Ga;cu(fu());var Jr={keyword:["break","case","catch","continue","debugger","default","do","else","finally","for","function","if","return","switch","throw","try","var","const","while","with","new","this","super","class","extends","export","import","null","true","false","in","instanceof","typeof","void","delete"],strict:["implements","interface","let","package","private","protected","public","static","yield"],strictBind:["eval","arguments"]};new Set(Jr.keyword);new Set(Jr.strict);new Set(Jr.strictBind);var $t=(e,t)=>n=>e(t(n));function Ms(e){return{keyword:e.cyan,capitalized:e.yellow,jsxIdentifier:e.yellow,punctuator:e.yellow,number:e.magenta,string:e.green,regex:e.magenta,comment:e.gray,invalid:$t($t(e.white,e.bgRed),e.bold),gutter:e.gray,marker:$t(e.red,e.bold),message:$t(e.red,e.bold),reset:e.reset}}Ms(As());Ms(As());function Ka(){return new Proxy({},{get:()=>e=>e})}var Ln=/\r\n|[\n\r\u2028\u2029]/;function Xa(e,t,n){let r=Object.assign({column:0,line:-1},e.start),u=Object.assign({},r,e.end),{linesAbove:s=2,linesBelow:i=3}=n||{},l=r.line,f=r.column,d=u.line,a=u.column,o=Math.max(l-(s+1),0),p=Math.min(t.length,d+i);l===-1&&(o=0),d===-1&&(p=t.length);let c=d-l,D={};if(c)for(let h=0;h<=c;h++){let y=h+l;if(!f)D[y]=!0;else if(h===0){let g=t[y-1].length;D[y]=[f,g-f+1]}else if(h===c)D[y]=[0,a];else{let g=t[y-h].length;D[y]=[0,g]}}else f===a?f?D[l]=[f,0]:D[l]=!0:D[l]=[f,a-f];return{start:o,end:p,markerLines:D}}function Qa(e,t,n={}){let r=Ka(),u=e.split(Ln),{start:s,end:i,markerLines:l}=Xa(t,u,n),f=t.start&&typeof t.start.column=="number",d=String(i).length,a=e.split(Ln,i).slice(s,i).map((o,p)=>{let c=s+1+p,D=` ${` ${c}`.slice(-d)} |`,h=l[c],y=!l[c+1];if(h){let g="";if(Array.isArray(h)){let m=o.slice(0,Math.max(h[0]-1,0)).replace(/[^\t]/g," "),F=h[1]||1;g=[`
|
|
19
|
-
`,r.gutter(D.replace(/\d/g," "))," ",m,r.marker("^").repeat(F)].join(""),y&&n.message&&(g+=" "+r.message(n.message))}return[r.marker(">"),r.gutter(D),o.length>0?` ${o}`:"",g].join("")}else return` ${r.gutter(D)}${o.length>0?` ${o}`:""}`}).join(`
|
|
20
|
-
`);return n.message&&!f&&(a=`${" ".repeat(d+1)}${n.message}
|
|
21
|
-
${a}`),a}async function Ya(e,t){let n=await qr(t),r=n.preprocess?await n.preprocess(e,t):e;t.originalText=r;let u;try{u=await n.parse(r,t,t)}catch(s){Za(s,e)}return{text:r,ast:u}}function Za(e,t){let{loc:n}=e;if(n){let r=Qa(t,n,{});throw e.message+=`
|
|
22
|
-
`+r,e.codeFrame=r,e}throw e}var wt=Ya;async function el(e,t,n,r,u){if(n.embeddedLanguageFormatting!=="auto")return;let{printer:s}=n,{embed:i}=s;if(!i)return;if(i.length>2)throw new Error("printer.embed has too many parameters. The API changed in Prettier v3. Please update your plugin. See https://prettier.io/docs/plugins#optional-embed");let{hasPrettierIgnore:l}=s,{getVisitorKeys:f}=i,d=[];p();let a=e.stack;for(let{print:c,node:D,pathStack:h}of d)try{e.stack=h;let y=await c(o,t,e,n);y&&u.set(D,y)}catch(y){if(globalThis.PRETTIER_DEBUG)throw y}e.stack=a;function o(c,D){return tl(c,D,n,r)}function p(){let{node:c}=e;if(c===null||typeof c!="object"||l?.(e))return;for(let h of f(c))Array.isArray(c[h])?e.each(p,h):e.call(p,h);let D=i(e,n);if(D){if(typeof D=="function"){d.push({print:D,node:c,pathStack:[...e.stack]});return}u.set(c,D)}}}async function tl(e,t,n,r){let u=await tt({...n,...t,parentParser:n.parser,originalText:e,cursorOffset:void 0,rangeStart:void 0,rangeEnd:void 0},{passThrough:!0}),{ast:s}=await wt(e,u),i=await r(s,u);return ss(i)}function rl(e,t,n,r){let{originalText:u,[Symbol.for("comments")]:s,locStart:i,locEnd:l,[Symbol.for("printedComments")]:f}=t,{node:d}=e,a=i(d),o=l(d);for(let c of s)i(c)>=a&&l(c)<=o&&f.add(c);let{printPrettierIgnored:p}=t.printer;return p?p(e,t,n,r):u.slice(a,o)}var nl=rl;async function Gt(e,t){({ast:e}=await Rs(e,t));let n=new Map,r=new yi(e),u=new Map;await el(r,i,t,Gt,u);let s=await Mn(r,t,i,void 0,u);if(Ni(t),t.cursorOffset>=0){if(t.nodeAfterCursor&&!t.nodeBeforeCursor)return[Le,s];if(t.nodeBeforeCursor&&!t.nodeAfterCursor)return[s,Le]}return s;function i(f,d){return f===void 0||f===r?l(d):Array.isArray(f)?r.call(()=>l(d),...f):r.call(()=>l(d),f)}function l(f){let d=r.node;if(d==null)return"";let a=Lr(d)&&f===void 0;if(a&&n.has(d))return n.get(d);let o=Mn(r,t,i,f,u);return a&&n.set(d,o),o}}function Mn(e,t,n,r,u){let{node:s}=e,{printer:i}=t,l;switch(i.hasPrettierIgnore?.(e)?l=nl(e,t,n,r):u.has(s)?l=u.get(s):l=i.print(e,t,n,r),s){case t.cursorNode:l=Pt(l,f=>[Le,f,Le]);break;case t.nodeBeforeCursor:l=Pt(l,f=>[f,Le]);break;case t.nodeAfterCursor:l=Pt(l,f=>[Le,f]);break}return i.printComment&&!i.willPrintOwnComments?.(e,t)&&(l=ji(e,l,t)),l}async function Rs(e,t){let n=e.comments??[];t[Symbol.for("comments")]=n,t[Symbol.for("printedComments")]=new Set,Si(e,t);let{printer:{preprocess:r}}=t;return e=r?await r(e,t):e,{ast:e,comments:n}}function sl(e,t){let{cursorOffset:n,locStart:r,locEnd:u,getVisitorKeys:s}=t,i=c=>r(c)<=n&&u(c)>=n,l=e,f=[e];for(let c of ki(e,{getVisitorKeys:s,filter:i}))f.push(c),l=c;if(Ei(l,{getVisitorKeys:s}))return{cursorNode:l};let d,a,o=-1,p=Number.POSITIVE_INFINITY;for(;f.length>0&&(d===void 0||a===void 0);){l=f.pop();let c=d!==void 0,D=a!==void 0;for(let h of Ht(l,{getVisitorKeys:s})){if(!c){let y=u(h);y<=n&&y>o&&(d=h,o=y)}if(!D){let y=r(h);y>=n&&y<p&&(a=h,p=y)}}}return{nodeBeforeCursor:d,nodeAfterCursor:a}}var Ws=sl;function ol(e,t){let{printer:n}=t,r=n.massageAstNode;if(!r)return e;let{getVisitorKeys:u}=n,{ignoredProperties:s}=r;return i(e);function i(l,f){if(!Lr(l))return l;if(Array.isArray(l))return l.map(p=>i(p,f)).filter(Boolean);let d={},a=new Set(u(l));for(let p in l)!Object.prototype.hasOwnProperty.call(l,p)||s?.has(p)||(a.has(p)?d[p]=i(l[p],l):d[p]=l[p]);let o=r(l,d,f);if(o!==null)return o??d}}var ul=ol,il=Array.prototype.findLastIndex??function(e){for(let t=this.length-1;t>=0;t--){let n=this[t];if(e(n,t,this))return t}return-1},al=vt("findLastIndex",function(){if(Array.isArray(this))return il}),ll=al,cl=({parser:e})=>e==="json"||e==="json5"||e==="jsonc"||e==="json-stringify";function fl(e,t){return t=new Set(t),e.find(n=>zs.has(n.type)&&t.has(n))}function Rn(e){let t=ll(0,e,n=>n.type!=="Program"&&n.type!=="File");return t===-1?e:e.slice(0,t+1)}function pl(e,t,{locStart:n,locEnd:r}){let[u,...s]=e,[i,...l]=t;if(u===i)return[u,i];let f=n(u);for(let a of Rn(l))if(n(a)>=f)i=a;else break;let d=r(i);for(let a of Rn(s)){if(r(a)<=d)u=a;else break;if(u===i)break}return[u,i]}function br(e,t,n,r,u=[],s){let{locStart:i,locEnd:l}=n,f=i(e),d=l(e);if(t>d||t<f||s==="rangeEnd"&&t===f||s==="rangeStart"&&t===d)return;let a=[e,...u],o=ys(e,a,{cache:vs,locStart:i,locEnd:l,getVisitorKeys:n.getVisitorKeys,filter:n.printer.canAttachComment,getChildren:n.printer.getCommentChildNodes});for(let p of o){let c=br(p,t,n,r,a,s);if(c)return c}if(r(e,u[0]))return a}function hl(e,t){return t!=="DeclareExportDeclaration"&&e!=="TypeParameterDeclaration"&&(e==="Directive"||e==="TypeAlias"||e==="TSExportAssignment"||e.startsWith("Declare")||e.startsWith("TSDeclare")||e.endsWith("Statement")||e.endsWith("Declaration"))}var zs=new Set(["JsonRoot","ObjectExpression","ArrayExpression","StringLiteral","NumericLiteral","BooleanLiteral","NullLiteral","UnaryExpression","TemplateLiteral"]),dl=new Set(["OperationDefinition","FragmentDefinition","VariableDefinition","TypeExtensionDefinition","ObjectTypeDefinition","FieldDefinition","DirectiveDefinition","EnumTypeDefinition","EnumValueDefinition","InputValueDefinition","InputObjectTypeDefinition","SchemaDefinition","OperationTypeDefinition","InterfaceTypeDefinition","UnionTypeDefinition","ScalarTypeDefinition"]);function Wn(e,t,n){if(!t)return!1;switch(e.parser){case"flow":case"hermes":case"babel":case"babel-flow":case"babel-ts":case"typescript":case"acorn":case"espree":case"meriyah":case"oxc":case"oxc-ts":case"__babel_estree":return hl(t.type,n?.type);case"json":case"json5":case"jsonc":case"json-stringify":return zs.has(t.type);case"graphql":return dl.has(t.kind);case"vue":return t.tag!=="root"}return!1}function Dl(e,t,n){let{rangeStart:r,rangeEnd:u,locStart:s,locEnd:i}=t,l=e.slice(r,u).search(/\S/u),f=l===-1;if(!f)for(r+=l;u>r&&!/\S/u.test(e[u-1]);--u);let d=br(n,r,t,(c,D)=>Wn(t,c,D),[],"rangeStart");if(!d)return;let a=f?d:br(n,u,t,c=>Wn(t,c),[],"rangeEnd");if(!a)return;let o,p;if(cl(t)){let c=fl(d,a);o=c,p=c}else[o,p]=pl(d,a,t);return[Math.min(s(o),s(p)),Math.max(i(o),i(p))]}var qs="\uFEFF",zn=Symbol("cursor");async function Js(e,t,n=0){if(!e||e.trim().length===0)return{formatted:"",cursorOffset:-1,comments:[]};let{ast:r,text:u}=await wt(e,t);t.cursorOffset>=0&&(t={...t,...Ws(r,t)});let s=await Gt(r,t);n>0&&(s=us([me,s],n,t.tabWidth));let i=Ut(s,t);if(n>0){let f=i.formatted.trim();i.cursorNodeStart!==void 0&&(i.cursorNodeStart-=i.formatted.indexOf(f),i.cursorNodeStart<0&&(i.cursorNodeStart=0,i.cursorNodeText=i.cursorNodeText.trimStart()),i.cursorNodeStart+i.cursorNodeText.length>f.length&&(i.cursorNodeText=i.cursorNodeText.trimEnd())),i.formatted=f+$r(t.endOfLine)}let l=t[Symbol.for("comments")];if(t.cursorOffset>=0){let f,d,a,o;if((t.cursorNode||t.nodeBeforeCursor||t.nodeAfterCursor)&&i.cursorNodeText)if(a=i.cursorNodeStart,o=i.cursorNodeText,t.cursorNode)f=t.locStart(t.cursorNode),d=u.slice(f,t.locEnd(t.cursorNode));else{if(!t.nodeBeforeCursor&&!t.nodeAfterCursor)throw new Error("Cursor location must contain at least one of cursorNode, nodeBeforeCursor, nodeAfterCursor");f=t.nodeBeforeCursor?t.locEnd(t.nodeBeforeCursor):0;let g=t.nodeAfterCursor?t.locStart(t.nodeAfterCursor):u.length;d=u.slice(f,g)}else f=0,d=u,a=0,o=i.formatted;let p=t.cursorOffset-f;if(d===o)return{formatted:i.formatted,cursorOffset:a+p,comments:l};let c=d.split("");c.splice(p,0,zn);let D=o.split(""),h=yu(c,D),y=a;for(let g of h)if(g.removed){if(g.value.includes(zn))break}else y+=g.count;return{formatted:i.formatted,cursorOffset:y,comments:l}}return{formatted:i.formatted,cursorOffset:-1,comments:l}}async function ml(e,t){let{ast:n,text:r}=await wt(e,t),[u,s]=Dl(r,t,n)??[0,0],i=r.slice(u,s),l=Math.min(u,r.lastIndexOf(`
|
|
23
|
-
`,u)+1),f=r.slice(l,u).match(/^\s*/u)[0],d=Pr(f,t.tabWidth),a=await Js(i,{...t,rangeStart:0,rangeEnd:Number.POSITIVE_INFINITY,cursorOffset:t.cursorOffset>u&&t.cursorOffset<=s?t.cursorOffset-u:-1,endOfLine:"lf"},d),o=a.formatted.trimEnd(),{cursorOffset:p}=t;p>s?p+=o.length-i.length:a.cursorOffset>=0&&(p=a.cursorOffset+u);let c=r.slice(0,u)+o+r.slice(s);if(t.endOfLine!=="lf"){let D=$r(t.endOfLine);p>=0&&D===`\r
|
|
24
|
-
`&&(p+=rs(c.slice(0,p),`
|
|
25
|
-
`)),c=zt(0,c,`
|
|
26
|
-
`,D)}return{formatted:c,cursorOffset:p,comments:a.comments}}function hr(e,t,n){return typeof t!="number"||Number.isNaN(t)||t<0||t>e.length?n:t}function qn(e,t){let{cursorOffset:n,rangeStart:r,rangeEnd:u}=t;return n=hr(e,n,-1),r=hr(e,r,0),u=hr(e,u,e.length),{...t,cursorOffset:n,rangeStart:r,rangeEnd:u}}function Vs(e,t){let{cursorOffset:n,rangeStart:r,rangeEnd:u,endOfLine:s}=qn(e,t),i=e.charAt(0)===qs;if(i&&(e=e.slice(1),n--,r--,u--),s==="auto"&&(s=Cu(e)),e.includes("\r")){let l=f=>rs(e.slice(0,Math.max(f,0)),`\r
|
|
27
|
-
`);n-=l(n),r-=l(r),u-=l(u),e=Au(e)}return{hasBOM:i,text:e,options:qn(e,{...t,cursorOffset:n,rangeStart:r,rangeEnd:u,endOfLine:s})}}async function Jn(e,t){let n=await qr(t);return!n.hasPragma||n.hasPragma(e)}async function gl(e,t){return(await qr(t)).hasIgnorePragma?.(e)}async function Us(e,t){let{hasBOM:n,text:r,options:u}=Vs(e,await tt(t));if(u.rangeStart>=u.rangeEnd&&r!==""||u.requirePragma&&!await Jn(r,u)||u.checkIgnorePragma&&await gl(r,u))return{formatted:e,cursorOffset:t.cursorOffset,comments:[]};let s;return u.rangeStart>0||u.rangeEnd<r.length?s=await ml(r,u):(!u.requirePragma&&u.insertPragma&&u.printer.insertPragma&&!await Jn(r,u)&&(r=u.printer.insertPragma(r)),s=await Js(r,u)),n&&(s.formatted=qs+s.formatted,s.cursorOffset>=0&&s.cursorOffset++),s}async function yl(e,t,n){let{text:r,options:u}=Vs(e,await tt(t)),s=await wt(r,u);return n&&(n.preprocessForPrint&&(s.ast=await Rs(s.ast,u)),n.massage&&(s.ast=ul(s.ast,u))),s}async function vl(e,t){t=await tt(t);let n=await Gt(e,t);return Ut(n,t)}async function Fl(e,t){let n=ni(e),{formatted:r}=await Us(n,{...t,parser:"__js_expression"});return r}async function wl(e,t){t=await tt(t);let{ast:n}=await wt(e,t);return t.cursorOffset>=0&&(t={...t,...Ws(n,t)}),Gt(n,t)}async function bl(e,t){return Ut(e,await tt(t))}var Hs={};Br(Hs,{builders:()=>xl,printer:()=>Cl,utils:()=>kl});var xl={join:as,line:ls,softline:ei,hardline:me,literalline:fs,group:is,conditionalGroup:Xu,fill:Ku,lineSuffix:vr,lineSuffixBoundary:ti,cursor:Le,breakParent:Vt,ifBreak:Qu,trim:ri,indent:Wt,indentIfBreak:Yu,align:et,addAlignmentToDoc:us,markAsRoot:os,dedentToRoot:Hu,dedent:Gu,hardlineWithoutBreakParent:jr,literallineWithoutBreakParent:cs,label:Zu,concat:e=>e},Cl={printDocToString:Ut},kl={willBreak:Pu,traverseDoc:_r,findInDoc:Ir,mapDoc:Jt,removeLines:Ru,stripTrailingHardline:ss,replaceEndOfLine:qu,canBreak:Vu},El="3.8.1",Gs={};Br(Gs,{addDanglingComment:()=>je,addLeadingComment:()=>ht,addTrailingComment:()=>dt,getAlignmentSize:()=>Pr,getIndentSize:()=>$l,getMaxContinuousCount:()=>jl,getNextNonSpaceNonCommentCharacter:()=>Pl,getNextNonSpaceNonCommentCharacterIndex:()=>Hl,getPreferredQuote:()=>Wl,getStringWidth:()=>Nr,hasNewline:()=>Be,hasNewlineInRange:()=>ql,hasSpaces:()=>Vl,isNextLineEmpty:()=>Yl,isNextLineEmptyAfterIndex:()=>Gr,isPreviousLineEmpty:()=>Kl,makeString:()=>Ql,skip:()=>Ft,skipEverythingButNewLine:()=>ms,skipInlineComment:()=>Vr,skipNewline:()=>Me,skipSpaces:()=>Te,skipToLineEnd:()=>Ds,skipTrailingComment:()=>Ur,skipWhitespace:()=>Fi});function Al(e,t){if(t===!1)return!1;if(e.charAt(t)==="/"&&e.charAt(t+1)==="*"){for(let n=t+2;n<e.length;++n)if(e.charAt(n)==="*"&&e.charAt(n+1)==="/")return n+2}return t}var Vr=Al;function Sl(e,t){return t===!1?!1:e.charAt(t)==="/"&&e.charAt(t+1)==="/"?ms(e,t):t}var Ur=Sl;function Ol(e,t){let n=null,r=t;for(;r!==n;)n=r,r=Te(e,r),r=Vr(e,r),r=Ur(e,r),r=Me(e,r);return r}var Hr=Ol;function Bl(e,t){let n=null,r=t;for(;r!==n;)n=r,r=Ds(e,r),r=Vr(e,r),r=Te(e,r);return r=Ur(e,r),r=Me(e,r),r!==!1&&Be(e,r)}var Gr=Bl;function Tl(e,t){let n=e.lastIndexOf(`
|
|
28
|
-
`);return n===-1?0:Pr(e.slice(n+1).match(/^[\t ]*/u)[0],t)}var $l=Tl;function _l(e){if(typeof e!="string")throw new TypeError("Expected a string");return e.replace(/[|\\{}()[\]^$+*?.]/g,"\\$&").replace(/-/g,"\\x2d")}function Il(e,t){let n=e.matchAll(new RegExp(`(?:${_l(t)})+`,"gu"));return n.reduce||(n=[...n]),n.reduce((r,[u])=>Math.max(r,u.length),0)/t.length}var jl=Il;function Nl(e,t){let n=Hr(e,t);return n===!1?"":e.charAt(n)}var Pl=Nl,Ks=Object.freeze({character:"'",codePoint:39}),Xs=Object.freeze({character:'"',codePoint:34}),Ll=Object.freeze({preferred:Ks,alternate:Xs}),Ml=Object.freeze({preferred:Xs,alternate:Ks});function Rl(e,t){let{preferred:n,alternate:r}=t===!0||t==="'"?Ll:Ml,{length:u}=e,s=0,i=0;for(let l=0;l<u;l++){let f=e.charCodeAt(l);f===n.codePoint?s++:f===r.codePoint&&i++}return(s>i?r:n).character}var Wl=Rl;function zl(e,t,n){for(let r=t;r<n;++r)if(e.charAt(r)===`
|
|
29
|
-
`)return!0;return!1}var ql=zl;function Jl(e,t,n={}){return Te(e,n.backwards?t-1:t,n)!==t}var Vl=Jl;function Ul(e,t,n){return Hr(e,n(t))}function Hl(e,t){return arguments.length===2||typeof t=="number"?Hr(e,t):Ul(...arguments)}function Gl(e,t,n){return Rr(e,n(t))}function Kl(e,t){return arguments.length===2||typeof t=="number"?Rr(e,t):Gl(...arguments)}function Xl(e,t,n){return Gr(e,n(t))}function Ql(e,t,n){let r=t==='"'?"'":'"',u=zt(0,e,/\\(.)|(["'])/gsu,(s,i,l)=>i===r?i:l===t?"\\"+l:l||(n&&/^[^\n\r"'0-7\\bfnrt-vx\u2028\u2029]$/u.test(i)?i:"\\"+i));return t+u+t}function Yl(e,t){return arguments.length===2||typeof t=="number"?Gr(e,t):Xl(...arguments)}function Pe(e,t=1){return async(...n)=>{let r=n[t]??{},u=r.plugins??[];return n[t]={...r,plugins:Array.isArray(u)?u:Object.values(u)},e(...n)}}var Qs=Pe(Us);async function Ys(e,t){let{formatted:n}=await Qs(e,{...t,cursorOffset:-1});return n}async function Zl(e,t){return await Ys(e,t)===e}var ec=Pe(Cs,0),tc={parse:Pe(yl),formatAST:Pe(vl),formatDoc:Pe(Fl),printToDoc:Pe(wl),printDocToString:Pe(bl)},rc=Object.create,Kr=Object.defineProperty,nc=Object.getOwnPropertyDescriptor,sc=Object.getOwnPropertyNames,oc=Object.getPrototypeOf,uc=Object.prototype.hasOwnProperty,T=(e,t)=>()=>(t||e((t={exports:{}}).exports,t),t.exports),Zs=(e,t)=>{for(var n in t)Kr(e,n,{get:t[n],enumerable:!0})},ic=(e,t,n,r)=>{if(t&&typeof t=="object"||typeof t=="function")for(let u of sc(t))!uc.call(e,u)&&u!==n&&Kr(e,u,{get:()=>t[u],enumerable:!(r=nc(t,u))||r.enumerable});return e},rt=(e,t,n)=>(n=e!=null?rc(oc(e)):{},ic(Kr(n,"default",{value:e,enumerable:!0}),e)),ac=T((e,t)=>{var n=String,r=function(){return{isColorSupported:!1,reset:n,bold:n,dim:n,italic:n,underline:n,inverse:n,hidden:n,strikethrough:n,black:n,red:n,green:n,yellow:n,blue:n,magenta:n,cyan:n,white:n,gray:n,bgBlack:n,bgRed:n,bgGreen:n,bgYellow:n,bgBlue:n,bgMagenta:n,bgCyan:n,bgWhite:n,blackBright:n,redBright:n,greenBright:n,yellowBright:n,blueBright:n,magentaBright:n,cyanBright:n,whiteBright:n,bgBlackBright:n,bgRedBright:n,bgGreenBright:n,bgYellowBright:n,bgBlueBright:n,bgMagentaBright:n,bgCyanBright:n,bgWhiteBright:n}};t.exports=r(),t.exports.createColors=r}),eo=T(()=>{}),Xr=T((e,t)=>{var n=ac(),r=eo(),u=class to extends Error{constructor(i,l,f,d,a,o){super(i),this.name="CssSyntaxError",this.reason=i,a&&(this.file=a),d&&(this.source=d),o&&(this.plugin=o),typeof l<"u"&&typeof f<"u"&&(typeof l=="number"?(this.line=l,this.column=f):(this.line=l.line,this.column=l.column,this.endLine=f.line,this.endColumn=f.column)),this.setMessage(),Error.captureStackTrace&&Error.captureStackTrace(this,to)}setMessage(){this.message=this.plugin?this.plugin+": ":"",this.message+=this.file?this.file:"<css input>",typeof this.line<"u"&&(this.message+=":"+this.line+":"+this.column),this.message+=": "+this.reason}showSourceCode(i){if(!this.source)return"";let l=this.source;i==null&&(i=n.isColorSupported);let f=h=>h,d=h=>h,a=h=>h;if(i){let{bold:h,gray:y,red:g}=n.createColors(!0);d=m=>h(g(m)),f=m=>y(m),r&&(a=m=>r(m))}let o=l.split(/\r?\n/),p=Math.max(this.line-3,0),c=Math.min(this.line+2,o.length),D=String(c).length;return o.slice(p,c).map((h,y)=>{let g=p+1+y,m=" "+(" "+g).slice(-D)+" | ";if(g===this.line){if(h.length>160){let b=20,v=Math.max(0,this.column-b),w=Math.max(this.column+b,this.endColumn+b),x=h.slice(v,w),C=f(m.replace(/\d/g," "))+h.slice(0,Math.min(this.column-1,b-1)).replace(/[^\t]/g," ");return d(">")+f(m)+a(x)+`
|
|
30
|
-
`+C+d("^")}let F=f(m.replace(/\d/g," "))+h.slice(0,this.column-1).replace(/[^\t]/g," ");return d(">")+f(m)+a(h)+`
|
|
31
|
-
`+F+d("^")}return" "+f(m)+a(h)}).join(`
|
|
32
|
-
`)}toString(){let i=this.showSourceCode();return i&&(i=`
|
|
33
|
-
|
|
34
|
-
`+i+`
|
|
35
|
-
`),this.name+": "+this.message+i}};t.exports=u,u.default=u}),Qr=T((e,t)=>{var n={after:`
|
|
36
|
-
`,beforeClose:`
|
|
37
|
-
`,beforeComment:`
|
|
38
|
-
`,beforeDecl:`
|
|
39
|
-
`,beforeOpen:" ",beforeRule:`
|
|
40
|
-
`,colon:": ",commentLeft:" ",commentRight:" ",emptyBody:"",indent:" ",semicolon:!1};function r(s){return s[0].toUpperCase()+s.slice(1)}var u=class{constructor(s){this.builder=s}atrule(s,i){let l="@"+s.name,f=s.params?this.rawValue(s,"params"):"";if(typeof s.raws.afterName<"u"?l+=s.raws.afterName:f&&(l+=" "),s.nodes)this.block(s,l+f);else{let d=(s.raws.between||"")+(i?";":"");this.builder(l+f+d,s)}}beforeAfter(s,i){let l;s.type==="decl"?l=this.raw(s,null,"beforeDecl"):s.type==="comment"?l=this.raw(s,null,"beforeComment"):i==="before"?l=this.raw(s,null,"beforeRule"):l=this.raw(s,null,"beforeClose");let f=s.parent,d=0;for(;f&&f.type!=="root";)d+=1,f=f.parent;if(l.includes(`
|
|
41
|
-
`)){let a=this.raw(s,null,"indent");if(a.length)for(let o=0;o<d;o++)l+=a}return l}block(s,i){let l=this.raw(s,"between","beforeOpen");this.builder(i+l+"{",s,"start");let f;s.nodes&&s.nodes.length?(this.body(s),f=this.raw(s,"after")):f=this.raw(s,"after","emptyBody"),f&&this.builder(f),this.builder("}",s,"end")}body(s){let i=s.nodes.length-1;for(;i>0&&s.nodes[i].type==="comment";)i-=1;let l=this.raw(s,"semicolon");for(let f=0;f<s.nodes.length;f++){let d=s.nodes[f],a=this.raw(d,"before");a&&this.builder(a),this.stringify(d,i!==f||l)}}comment(s){let i=this.raw(s,"left","commentLeft"),l=this.raw(s,"right","commentRight");this.builder("/*"+i+s.text+l+"*/",s)}decl(s,i){let l=this.raw(s,"between","colon"),f=s.prop+l+this.rawValue(s,"value");s.important&&(f+=s.raws.important||" !important"),i&&(f+=";"),this.builder(f,s)}document(s){this.body(s)}raw(s,i,l){let f;if(l||(l=i),i&&(f=s.raws[i],typeof f<"u"))return f;let d=s.parent;if(l==="before"&&(!d||d.type==="root"&&d.first===s||d&&d.type==="document"))return"";if(!d)return n[l];let a=s.root();if(a.rawCache||(a.rawCache={}),typeof a.rawCache[l]<"u")return a.rawCache[l];if(l==="before"||l==="after")return this.beforeAfter(s,l);{let o="raw"+r(l);this[o]?f=this[o](a,s):a.walk(p=>{if(f=p.raws[i],typeof f<"u")return!1})}return typeof f>"u"&&(f=n[l]),a.rawCache[l]=f,f}rawBeforeClose(s){let i;return s.walk(l=>{if(l.nodes&&l.nodes.length>0&&typeof l.raws.after<"u")return i=l.raws.after,i.includes(`
|
|
42
|
-
`)&&(i=i.replace(/[^\n]+$/,"")),!1}),i&&(i=i.replace(/\S/g,"")),i}rawBeforeComment(s,i){let l;return s.walkComments(f=>{if(typeof f.raws.before<"u")return l=f.raws.before,l.includes(`
|
|
43
|
-
`)&&(l=l.replace(/[^\n]+$/,"")),!1}),typeof l>"u"?l=this.raw(i,null,"beforeDecl"):l&&(l=l.replace(/\S/g,"")),l}rawBeforeDecl(s,i){let l;return s.walkDecls(f=>{if(typeof f.raws.before<"u")return l=f.raws.before,l.includes(`
|
|
44
|
-
`)&&(l=l.replace(/[^\n]+$/,"")),!1}),typeof l>"u"?l=this.raw(i,null,"beforeRule"):l&&(l=l.replace(/\S/g,"")),l}rawBeforeOpen(s){let i;return s.walk(l=>{if(l.type!=="decl"&&(i=l.raws.between,typeof i<"u"))return!1}),i}rawBeforeRule(s){let i;return s.walk(l=>{if(l.nodes&&(l.parent!==s||s.first!==l)&&typeof l.raws.before<"u")return i=l.raws.before,i.includes(`
|
|
45
|
-
`)&&(i=i.replace(/[^\n]+$/,"")),!1}),i&&(i=i.replace(/\S/g,"")),i}rawColon(s){let i;return s.walkDecls(l=>{if(typeof l.raws.between<"u")return i=l.raws.between.replace(/[^\s:]/g,""),!1}),i}rawEmptyBody(s){let i;return s.walk(l=>{if(l.nodes&&l.nodes.length===0&&(i=l.raws.after,typeof i<"u"))return!1}),i}rawIndent(s){if(s.raws.indent)return s.raws.indent;let i;return s.walk(l=>{let f=l.parent;if(f&&f!==s&&f.parent&&f.parent===s&&typeof l.raws.before<"u"){let d=l.raws.before.split(`
|
|
46
|
-
`);return i=d[d.length-1],i=i.replace(/\S/g,""),!1}}),i}rawSemicolon(s){let i;return s.walk(l=>{if(l.nodes&&l.nodes.length&&l.last.type==="decl"&&(i=l.raws.semicolon,typeof i<"u"))return!1}),i}rawValue(s,i){let l=s[i],f=s.raws[i];return f&&f.value===l?f.raw:l}root(s){this.body(s),s.raws.after&&this.builder(s.raws.after)}rule(s){this.block(s,this.rawValue(s,"selector")),s.raws.ownSemicolon&&this.builder(s.raws.ownSemicolon,s,"end")}stringify(s,i){if(!this[s.type])throw new Error("Unknown AST node type "+s.type+". Maybe you need to change PostCSS stringifier.");this[s.type](s,i)}};t.exports=u,u.default=u}),Kt=T((e,t)=>{var n=Qr();function r(u,s){new n(s).stringify(u)}t.exports=r,r.default=r}),Yr=T((e,t)=>{t.exports.isClean=Symbol("isClean"),t.exports.my=Symbol("my")}),Xt=T((e,t)=>{var n=Xr(),r=Qr(),u=Kt(),{isClean:s,my:i}=Yr();function l(a,o){let p=new a.constructor;for(let c in a){if(!Object.prototype.hasOwnProperty.call(a,c)||c==="proxyCache")continue;let D=a[c],h=typeof D;c==="parent"&&h==="object"?o&&(p[c]=o):c==="source"?p[c]=D:Array.isArray(D)?p[c]=D.map(y=>l(y,p)):(h==="object"&&D!==null&&(D=l(D)),p[c]=D)}return p}function f(a,o){if(o&&typeof o.offset<"u")return o.offset;let p=1,c=1,D=0;for(let h=0;h<a.length;h++){if(c===o.line&&p===o.column){D=h;break}a[h]===`
|
|
47
|
-
`?(p=1,c+=1):p+=1}return D}var d=class{get proxyOf(){return this}constructor(a={}){this.raws={},this[s]=!1,this[i]=!0;for(let o in a)if(o==="nodes"){this.nodes=[];for(let p of a[o])typeof p.clone=="function"?this.append(p.clone()):this.append(p)}else this[o]=a[o]}addToError(a){if(a.postcssNode=this,a.stack&&this.source&&/\n\s{4}at /.test(a.stack)){let o=this.source;a.stack=a.stack.replace(/\n\s{4}at /,`$&${o.input.from}:${o.start.line}:${o.start.column}$&`)}return a}after(a){return this.parent.insertAfter(this,a),this}assign(a={}){for(let o in a)this[o]=a[o];return this}before(a){return this.parent.insertBefore(this,a),this}cleanRaws(a){delete this.raws.before,delete this.raws.after,a||delete this.raws.between}clone(a={}){let o=l(this);for(let p in a)o[p]=a[p];return o}cloneAfter(a={}){let o=this.clone(a);return this.parent.insertAfter(this,o),o}cloneBefore(a={}){let o=this.clone(a);return this.parent.insertBefore(this,o),o}error(a,o={}){if(this.source){let{end:p,start:c}=this.rangeBy(o);return this.source.input.error(a,{column:c.column,line:c.line},{column:p.column,line:p.line},o)}return new n(a)}getProxyProcessor(){return{get(a,o){return o==="proxyOf"?a:o==="root"?()=>a.root().toProxy():a[o]},set(a,o,p){return a[o]===p||(a[o]=p,(o==="prop"||o==="value"||o==="name"||o==="params"||o==="important"||o==="text")&&a.markDirty()),!0}}}markClean(){this[s]=!0}markDirty(){if(this[s]){this[s]=!1;let a=this;for(;a=a.parent;)a[s]=!1}}next(){if(!this.parent)return;let a=this.parent.index(this);return this.parent.nodes[a+1]}positionBy(a={}){let o=this.source.start;if(a.index)o=this.positionInside(a.index);else if(a.word){let p="document"in this.source.input?this.source.input.document:this.source.input.css,c=p.slice(f(p,this.source.start),f(p,this.source.end)).indexOf(a.word);c!==-1&&(o=this.positionInside(c))}return o}positionInside(a){let o=this.source.start.column,p=this.source.start.line,c="document"in this.source.input?this.source.input.document:this.source.input.css,D=f(c,this.source.start),h=D+a;for(let y=D;y<h;y++)c[y]===`
|
|
48
|
-
`?(o=1,p+=1):o+=1;return{column:o,line:p,offset:h}}prev(){if(!this.parent)return;let a=this.parent.index(this);return this.parent.nodes[a-1]}rangeBy(a={}){let o="document"in this.source.input?this.source.input.document:this.source.input.css,p={column:this.source.start.column,line:this.source.start.line,offset:f(o,this.source.start)},c=this.source.end?{column:this.source.end.column+1,line:this.source.end.line,offset:typeof this.source.end.offset=="number"?this.source.end.offset:f(o,this.source.end)+1}:{column:p.column+1,line:p.line,offset:p.offset+1};if(a.word){let D=o.slice(f(o,this.source.start),f(o,this.source.end)).indexOf(a.word);D!==-1&&(p=this.positionInside(D),c=this.positionInside(D+a.word.length))}else a.start?p={column:a.start.column,line:a.start.line,offset:f(o,a.start)}:a.index&&(p=this.positionInside(a.index)),a.end?c={column:a.end.column,line:a.end.line,offset:f(o,a.end)}:typeof a.endIndex=="number"?c=this.positionInside(a.endIndex):a.index&&(c=this.positionInside(a.index+1));return(c.line<p.line||c.line===p.line&&c.column<=p.column)&&(c={column:p.column+1,line:p.line,offset:p.offset+1}),{end:c,start:p}}raw(a,o){return new r().raw(this,a,o)}remove(){return this.parent&&this.parent.removeChild(this),this.parent=void 0,this}replaceWith(...a){if(this.parent){let o=this,p=!1;for(let c of a)c===this?p=!0:p?(this.parent.insertAfter(o,c),o=c):this.parent.insertBefore(o,c);p||this.remove()}return this}root(){let a=this;for(;a.parent&&a.parent.type!=="document";)a=a.parent;return a}toJSON(a,o){let p={},c=o==null;o=o||new Map;let D=0;for(let h in this){if(!Object.prototype.hasOwnProperty.call(this,h)||h==="parent"||h==="proxyCache")continue;let y=this[h];if(Array.isArray(y))p[h]=y.map(g=>typeof g=="object"&&g.toJSON?g.toJSON(null,o):g);else if(typeof y=="object"&&y.toJSON)p[h]=y.toJSON(null,o);else if(h==="source"){if(y==null)continue;let g=o.get(y.input);g==null&&(g=D,o.set(y.input,D),D++),p[h]={end:y.end,inputId:g,start:y.start}}else p[h]=y}return c&&(p.inputs=[...o.keys()].map(h=>h.toJSON())),p}toProxy(){return this.proxyCache||(this.proxyCache=new Proxy(this,this.getProxyProcessor())),this.proxyCache}toString(a=u){a.stringify&&(a=a.stringify);let o="";return a(this,p=>{o+=p}),o}warn(a,o,p={}){let c={node:this};for(let D in p)c[D]=p[D];return a.warn(o,c)}};t.exports=d,d.default=d}),bt=T((e,t)=>{var n=Xt(),r=class extends n{constructor(u){super(u),this.type="comment"}};t.exports=r,r.default=r}),Qt=T((e,t)=>{var n=Xt(),r=class extends n{get variable(){return this.prop.startsWith("--")||this.prop[0]==="$"}constructor(u){u&&typeof u.value<"u"&&typeof u.value!="string"&&(u={...u,value:String(u.value)}),super(u),this.type="decl"}};t.exports=r,r.default=r}),qe=T((e,t)=>{var n=bt(),r=Qt(),u=Xt(),{isClean:s,my:i}=Yr(),l,f,d,a;function o(D){return D.map(h=>(h.nodes&&(h.nodes=o(h.nodes)),delete h.source,h))}function p(D){if(D[s]=!1,D.proxyOf.nodes)for(let h of D.proxyOf.nodes)p(h)}var c=class ro extends u{get first(){if(this.proxyOf.nodes)return this.proxyOf.nodes[0]}get last(){if(this.proxyOf.nodes)return this.proxyOf.nodes[this.proxyOf.nodes.length-1]}append(...h){for(let y of h){let g=this.normalize(y,this.last);for(let m of g)this.proxyOf.nodes.push(m)}return this.markDirty(),this}cleanRaws(h){if(super.cleanRaws(h),this.nodes)for(let y of this.nodes)y.cleanRaws(h)}each(h){if(!this.proxyOf.nodes)return;let y=this.getIterator(),g,m;for(;this.indexes[y]<this.proxyOf.nodes.length&&(g=this.indexes[y],m=h(this.proxyOf.nodes[g],g),m!==!1);)this.indexes[y]+=1;return delete this.indexes[y],m}every(h){return this.nodes.every(h)}getIterator(){this.lastEach||(this.lastEach=0),this.indexes||(this.indexes={}),this.lastEach+=1;let h=this.lastEach;return this.indexes[h]=0,h}getProxyProcessor(){return{get(h,y){return y==="proxyOf"?h:h[y]?y==="each"||typeof y=="string"&&y.startsWith("walk")?(...g)=>h[y](...g.map(m=>typeof m=="function"?(F,b)=>m(F.toProxy(),b):m)):y==="every"||y==="some"?g=>h[y]((m,...F)=>g(m.toProxy(),...F)):y==="root"?()=>h.root().toProxy():y==="nodes"?h.nodes.map(g=>g.toProxy()):y==="first"||y==="last"?h[y].toProxy():h[y]:h[y]},set(h,y,g){return h[y]===g||(h[y]=g,(y==="name"||y==="params"||y==="selector")&&h.markDirty()),!0}}}index(h){return typeof h=="number"?h:(h.proxyOf&&(h=h.proxyOf),this.proxyOf.nodes.indexOf(h))}insertAfter(h,y){let g=this.index(h),m=this.normalize(y,this.proxyOf.nodes[g]).reverse();g=this.index(h);for(let b of m)this.proxyOf.nodes.splice(g+1,0,b);let F;for(let b in this.indexes)F=this.indexes[b],g<F&&(this.indexes[b]=F+m.length);return this.markDirty(),this}insertBefore(h,y){let g=this.index(h),m=g===0?"prepend":!1,F=this.normalize(y,this.proxyOf.nodes[g],m).reverse();g=this.index(h);for(let v of F)this.proxyOf.nodes.splice(g,0,v);let b;for(let v in this.indexes)b=this.indexes[v],g<=b&&(this.indexes[v]=b+F.length);return this.markDirty(),this}normalize(h,y){if(typeof h=="string")h=o(f(h).nodes);else if(typeof h>"u")h=[];else if(Array.isArray(h)){h=h.slice(0);for(let g of h)g.parent&&g.parent.removeChild(g,"ignore")}else if(h.type==="root"&&this.type!=="document"){h=h.nodes.slice(0);for(let g of h)g.parent&&g.parent.removeChild(g,"ignore")}else if(h.type)h=[h];else if(h.prop){if(typeof h.value>"u")throw new Error("Value field is missed in node creation");typeof h.value!="string"&&(h.value=String(h.value)),h=[new r(h)]}else if(h.selector||h.selectors)h=[new a(h)];else if(h.name)h=[new l(h)];else if(h.text)h=[new n(h)];else throw new Error("Unknown node type in node creation");return h.map(g=>(g[i]||ro.rebuild(g),g=g.proxyOf,g.parent&&g.parent.removeChild(g),g[s]&&p(g),g.raws||(g.raws={}),typeof g.raws.before>"u"&&y&&typeof y.raws.before<"u"&&(g.raws.before=y.raws.before.replace(/\S/g,"")),g.parent=this.proxyOf,g))}prepend(...h){h=h.reverse();for(let y of h){let g=this.normalize(y,this.first,"prepend").reverse();for(let m of g)this.proxyOf.nodes.unshift(m);for(let m in this.indexes)this.indexes[m]=this.indexes[m]+g.length}return this.markDirty(),this}push(h){return h.parent=this,this.proxyOf.nodes.push(h),this}removeAll(){for(let h of this.proxyOf.nodes)h.parent=void 0;return this.proxyOf.nodes=[],this.markDirty(),this}removeChild(h){h=this.index(h),this.proxyOf.nodes[h].parent=void 0,this.proxyOf.nodes.splice(h,1);let y;for(let g in this.indexes)y=this.indexes[g],y>=h&&(this.indexes[g]=y-1);return this.markDirty(),this}replaceValues(h,y,g){return g||(g=y,y={}),this.walkDecls(m=>{y.props&&!y.props.includes(m.prop)||y.fast&&!m.value.includes(y.fast)||(m.value=m.value.replace(h,g))}),this.markDirty(),this}some(h){return this.nodes.some(h)}walk(h){return this.each((y,g)=>{let m;try{m=h(y,g)}catch(F){throw y.addToError(F)}return m!==!1&&y.walk&&(m=y.walk(h)),m})}walkAtRules(h,y){return y?h instanceof RegExp?this.walk((g,m)=>{if(g.type==="atrule"&&h.test(g.name))return y(g,m)}):this.walk((g,m)=>{if(g.type==="atrule"&&g.name===h)return y(g,m)}):(y=h,this.walk((g,m)=>{if(g.type==="atrule")return y(g,m)}))}walkComments(h){return this.walk((y,g)=>{if(y.type==="comment")return h(y,g)})}walkDecls(h,y){return y?h instanceof RegExp?this.walk((g,m)=>{if(g.type==="decl"&&h.test(g.prop))return y(g,m)}):this.walk((g,m)=>{if(g.type==="decl"&&g.prop===h)return y(g,m)}):(y=h,this.walk((g,m)=>{if(g.type==="decl")return y(g,m)}))}walkRules(h,y){return y?h instanceof RegExp?this.walk((g,m)=>{if(g.type==="rule"&&h.test(g.selector))return y(g,m)}):this.walk((g,m)=>{if(g.type==="rule"&&g.selector===h)return y(g,m)}):(y=h,this.walk((g,m)=>{if(g.type==="rule")return y(g,m)}))}};c.registerParse=D=>{f=D},c.registerRule=D=>{a=D},c.registerAtRule=D=>{l=D},c.registerRoot=D=>{d=D},t.exports=c,c.default=c,c.rebuild=D=>{D.type==="atrule"?Object.setPrototypeOf(D,l.prototype):D.type==="rule"?Object.setPrototypeOf(D,a.prototype):D.type==="decl"?Object.setPrototypeOf(D,r.prototype):D.type==="comment"?Object.setPrototypeOf(D,n.prototype):D.type==="root"&&Object.setPrototypeOf(D,d.prototype),D[i]=!0,D.nodes&&D.nodes.forEach(h=>{c.rebuild(h)})}}),lc=T((e,t)=>{var n="useandom-26T198340PX75pxJACKVERYMINDBUSHWOLF_GQZbfghjklqvwyzrict",r=(s,i=21)=>(l=i)=>{let f="",d=l|0;for(;d--;)f+=s[Math.random()*s.length|0];return f},u=(s=21)=>{let i="",l=s|0;for(;l--;)i+=n[Math.random()*64|0];return i};t.exports={nanoid:u,customAlphabet:r}}),cc=T(()=>{}),no=T((e,t)=>{t.exports=class{}}),xt=T((e,t)=>{var{nanoid:n}=lc(),{isAbsolute:r,resolve:u}={},{SourceMapConsumer:s,SourceMapGenerator:i}=cc(),{fileURLToPath:l,pathToFileURL:f}={},d=Xr(),a=no(),o=eo(),p=Symbol("lineToIndexCache"),c=!!(s&&i),D=!!(u&&r);function h(g){if(g[p])return g[p];let m=g.css.split(`
|
|
49
|
-
`),F=new Array(m.length),b=0;for(let v=0,w=m.length;v<w;v++)F[v]=b,b+=m[v].length+1;return g[p]=F,F}var y=class{get from(){return this.file||this.id}constructor(g,m={}){if(g===null||typeof g>"u"||typeof g=="object"&&!g.toString)throw new Error(`PostCSS received ${g} instead of CSS string`);if(this.css=g.toString(),this.css[0]==="\uFEFF"||this.css[0]===""?(this.hasBOM=!0,this.css=this.css.slice(1)):this.hasBOM=!1,this.document=this.css,m.document&&(this.document=m.document.toString()),m.from&&(!D||/^\w+:\/\//.test(m.from)||r(m.from)?this.file=m.from:this.file=u(m.from)),D&&c){let F=new a(this.css,m);if(F.text){this.map=F;let b=F.consumer().file;!this.file&&b&&(this.file=this.mapResolve(b))}}this.file||(this.id="<input css "+n(6)+">"),this.map&&(this.map.file=this.from)}error(g,m,F,b={}){let v,w,x,C,B;if(m&&typeof m=="object"){let O=m,N=F;if(typeof O.offset=="number"){C=O.offset;let S=this.fromOffset(C);m=S.line,F=S.col}else m=O.line,F=O.column,C=this.fromLineAndColumn(m,F);if(typeof N.offset=="number"){x=N.offset;let S=this.fromOffset(x);w=S.line,v=S.col}else w=N.line,v=N.column,x=this.fromLineAndColumn(N.line,N.column)}else if(F)C=this.fromLineAndColumn(m,F);else{C=m;let O=this.fromOffset(C);m=O.line,F=O.col}let k=this.origin(m,F,w,v);return k?B=new d(g,k.endLine===void 0?k.line:{column:k.column,line:k.line},k.endLine===void 0?k.column:{column:k.endColumn,line:k.endLine},k.source,k.file,b.plugin):B=new d(g,w===void 0?m:{column:F,line:m},w===void 0?F:{column:v,line:w},this.css,this.file,b.plugin),B.input={column:F,endColumn:v,endLine:w,endOffset:x,line:m,offset:C,source:this.css},this.file&&(f&&(B.input.url=f(this.file).toString()),B.input.file=this.file),B}fromLineAndColumn(g,m){return h(this)[g-1]+m-1}fromOffset(g){let m=h(this),F=m[m.length-1],b=0;if(g>=F)b=m.length-1;else{let v=m.length-2,w;for(;b<v;)if(w=b+(v-b>>1),g<m[w])v=w-1;else if(g>=m[w+1])b=w+1;else{b=w;break}}return{col:g-m[b]+1,line:b+1}}mapResolve(g){return/^\w+:\/\//.test(g)?g:u(this.map.consumer().sourceRoot||this.map.root||".",g)}origin(g,m,F,b){if(!this.map)return!1;let v=this.map.consumer(),w=v.originalPositionFor({column:m,line:g});if(!w.source)return!1;let x;typeof F=="number"&&(x=v.originalPositionFor({column:b,line:F}));let C;r(w.source)?C=f(w.source):C=new URL(w.source,this.map.consumer().sourceRoot||f(this.map.mapFile));let B={column:w.column,endColumn:x&&x.column,endLine:x&&x.line,line:w.line,url:C.toString()};if(C.protocol==="file:")if(l)B.file=l(C);else throw new Error("file: protocol is not available in this PostCSS build");let k=v.sourceContentFor(w.source);return k&&(B.source=k),B}toJSON(){let g={};for(let m of["hasBOM","css","file","id"])this[m]!=null&&(g[m]=this[m]);return this.map&&(g.map={...this.map},g.map.consumerCache&&(g.map.consumerCache=void 0)),g}};t.exports=y,y.default=y,o&&o.registerInput&&o.registerInput(y)}),Zr=T((e,t)=>{var n=qe(),r=class extends n{constructor(u){super(u),this.type="atrule"}append(...u){return this.proxyOf.nodes||(this.nodes=[]),super.append(...u)}prepend(...u){return this.proxyOf.nodes||(this.nodes=[]),super.prepend(...u)}};t.exports=r,r.default=r,n.registerAtRule(r)}),Ct=T((e,t)=>{var n=qe(),r,u,s=class extends n{constructor(i){super(i),this.type="root",this.nodes||(this.nodes=[])}normalize(i,l,f){let d=super.normalize(i);if(l){if(f==="prepend")this.nodes.length>1?l.raws.before=this.nodes[1].raws.before:delete l.raws.before;else if(this.first!==l)for(let a of d)a.raws.before=l.raws.before}return d}removeChild(i,l){let f=this.index(i);return!l&&f===0&&this.nodes.length>1&&(this.nodes[1].raws.before=this.nodes[f].raws.before),super.removeChild(i)}toResult(i={}){return new r(new u,this,i).stringify()}};s.registerLazyResult=i=>{r=i},s.registerProcessor=i=>{u=i},t.exports=s,s.default=s,n.registerRoot(s)}),so=T((e,t)=>{var n={comma(r){return n.split(r,[","],!0)},space(r){let u=[" ",`
|
|
50
|
-
`," "];return n.split(r,u)},split(r,u,s){let i=[],l="",f=!1,d=0,a=!1,o="",p=!1;for(let c of r)p?p=!1:c==="\\"?p=!0:a?c===o&&(a=!1):c==='"'||c==="'"?(a=!0,o=c):c==="("?d+=1:c===")"?d>0&&(d-=1):d===0&&u.includes(c)&&(f=!0),f?(l!==""&&i.push(l.trim()),l="",f=!1):l+=c;return(s||l!=="")&&i.push(l.trim()),i}};t.exports=n,n.default=n}),en=T((e,t)=>{var n=qe(),r=so(),u=class extends n{get selectors(){return r.comma(this.selector)}set selectors(s){let i=this.selector?this.selector.match(/,\s*/):null,l=i?i[0]:","+this.raw("between","beforeOpen");this.selector=s.join(l)}constructor(s){super(s),this.type="rule",this.nodes||(this.nodes=[])}};t.exports=u,u.default=u,n.registerRule(u)}),tn=T((e,t)=>{var n=/[\t\n\f\r "#'()/;[\\\]{}]/g,r=/[\t\n\f\r !"#'():;@[\\\]{}]|\/(?=\*)/g,u=/.[\r\n"'(/\\]/,s=/[\da-f]/i;t.exports=function(i,l={}){let f=i.css.valueOf(),d=l.ignoreErrors,a,o,p,c,D,h,y,g,m,F,b=f.length,v=0,w=[],x=[];function C(){return v}function B(S){throw i.error("Unclosed "+S,v)}function k(){return x.length===0&&v>=b}function O(S){if(x.length)return x.pop();if(v>=b)return;let I=S?S.ignoreUnclosed:!1;switch(a=f.charCodeAt(v),a){case 10:case 32:case 9:case 13:case 12:{c=v;do c+=1,a=f.charCodeAt(c);while(a===32||a===10||a===9||a===13||a===12);h=["space",f.slice(v,c)],v=c-1;break}case 91:case 93:case 123:case 125:case 58:case 59:case 41:{let j=String.fromCharCode(a);h=[j,j,v];break}case 40:{if(F=w.length?w.pop()[1]:"",m=f.charCodeAt(v+1),F==="url"&&m!==39&&m!==34&&m!==32&&m!==10&&m!==9&&m!==12&&m!==13){c=v;do{if(y=!1,c=f.indexOf(")",c+1),c===-1)if(d||I){c=v;break}else B("bracket");for(g=c;f.charCodeAt(g-1)===92;)g-=1,y=!y}while(y);h=["brackets",f.slice(v,c+1),v,c],v=c}else c=f.indexOf(")",v+1),o=f.slice(v,c+1),c===-1||u.test(o)?h=["(","(",v]:(h=["brackets",o,v,c],v=c);break}case 39:case 34:{D=a===39?"'":'"',c=v;do{if(y=!1,c=f.indexOf(D,c+1),c===-1)if(d||I){c=v+1;break}else B("string");for(g=c;f.charCodeAt(g-1)===92;)g-=1,y=!y}while(y);h=["string",f.slice(v,c+1),v,c],v=c;break}case 64:{n.lastIndex=v+1,n.test(f),n.lastIndex===0?c=f.length-1:c=n.lastIndex-2,h=["at-word",f.slice(v,c+1),v,c],v=c;break}case 92:{for(c=v,p=!0;f.charCodeAt(c+1)===92;)c+=1,p=!p;if(a=f.charCodeAt(c+1),p&&a!==47&&a!==32&&a!==10&&a!==9&&a!==13&&a!==12&&(c+=1,s.test(f.charAt(c)))){for(;s.test(f.charAt(c+1));)c+=1;f.charCodeAt(c+1)===32&&(c+=1)}h=["word",f.slice(v,c+1),v,c],v=c;break}default:{a===47&&f.charCodeAt(v+1)===42?(c=f.indexOf("*/",v+2)+1,c===0&&(d||I?c=f.length:B("comment")),h=["comment",f.slice(v,c+1),v,c],v=c):(r.lastIndex=v+1,r.test(f),r.lastIndex===0?c=f.length-1:c=r.lastIndex-2,h=["word",f.slice(v,c+1),v,c],w.push(h),v=c);break}}return v++,h}function N(S){x.push(S)}return{back:N,endOfFile:k,nextToken:O,position:C}}}),rn=T((e,t)=>{var n=Zr(),r=bt(),u=Qt(),s=Ct(),i=en(),l=tn(),f={empty:!0,space:!0};function d(o){for(let p=o.length-1;p>=0;p--){let c=o[p],D=c[3]||c[2];if(D)return D}}var a=class{constructor(o){this.input=o,this.root=new s,this.current=this.root,this.spaces="",this.semicolon=!1,this.createTokenizer(),this.root.source={input:o,start:{column:1,line:1,offset:0}}}atrule(o){let p=new n;p.name=o[1].slice(1),p.name===""&&this.unnamedAtrule(p,o),this.init(p,o[2]);let c,D,h,y=!1,g=!1,m=[],F=[];for(;!this.tokenizer.endOfFile();){if(o=this.tokenizer.nextToken(),c=o[0],c==="("||c==="["?F.push(c==="("?")":"]"):c==="{"&&F.length>0?F.push("}"):c===F[F.length-1]&&F.pop(),F.length===0)if(c===";"){p.source.end=this.getPosition(o[2]),p.source.end.offset++,this.semicolon=!0;break}else if(c==="{"){g=!0;break}else if(c==="}"){if(m.length>0){for(h=m.length-1,D=m[h];D&&D[0]==="space";)D=m[--h];D&&(p.source.end=this.getPosition(D[3]||D[2]),p.source.end.offset++)}this.end(o);break}else m.push(o);else m.push(o);if(this.tokenizer.endOfFile()){y=!0;break}}p.raws.between=this.spacesAndCommentsFromEnd(m),m.length?(p.raws.afterName=this.spacesAndCommentsFromStart(m),this.raw(p,"params",m),y&&(o=m[m.length-1],p.source.end=this.getPosition(o[3]||o[2]),p.source.end.offset++,this.spaces=p.raws.between,p.raws.between="")):(p.raws.afterName="",p.params=""),g&&(p.nodes=[],this.current=p)}checkMissedSemicolon(o){let p=this.colon(o);if(p===!1)return;let c=0,D;for(let h=p-1;h>=0&&(D=o[h],!(D[0]!=="space"&&(c+=1,c===2)));h--);throw this.input.error("Missed semicolon",D[0]==="word"?D[3]+1:D[2])}colon(o){let p=0,c,D,h;for(let[y,g]of o.entries()){if(D=g,h=D[0],h==="("&&(p+=1),h===")"&&(p-=1),p===0&&h===":")if(!c)this.doubleColon(D);else{if(c[0]==="word"&&c[1]==="progid")continue;return y}c=D}return!1}comment(o){let p=new r;this.init(p,o[2]),p.source.end=this.getPosition(o[3]||o[2]),p.source.end.offset++;let c=o[1].slice(2,-2);if(/^\s*$/.test(c))p.text="",p.raws.left=c,p.raws.right="";else{let D=c.match(/^(\s*)([^]*\S)(\s*)$/);p.text=D[2],p.raws.left=D[1],p.raws.right=D[3]}}createTokenizer(){this.tokenizer=l(this.input)}decl(o,p){let c=new u;this.init(c,o[0][2]);let D=o[o.length-1];for(D[0]===";"&&(this.semicolon=!0,o.pop()),c.source.end=this.getPosition(D[3]||D[2]||d(o)),c.source.end.offset++;o[0][0]!=="word";)o.length===1&&this.unknownWord(o),c.raws.before+=o.shift()[1];for(c.source.start=this.getPosition(o[0][2]),c.prop="";o.length;){let m=o[0][0];if(m===":"||m==="space"||m==="comment")break;c.prop+=o.shift()[1]}c.raws.between="";let h;for(;o.length;)if(h=o.shift(),h[0]===":"){c.raws.between+=h[1];break}else h[0]==="word"&&/\w/.test(h[1])&&this.unknownWord([h]),c.raws.between+=h[1];(c.prop[0]==="_"||c.prop[0]==="*")&&(c.raws.before+=c.prop[0],c.prop=c.prop.slice(1));let y=[],g;for(;o.length&&(g=o[0][0],!(g!=="space"&&g!=="comment"));)y.push(o.shift());this.precheckMissedSemicolon(o);for(let m=o.length-1;m>=0;m--){if(h=o[m],h[1].toLowerCase()==="!important"){c.important=!0;let F=this.stringFrom(o,m);F=this.spacesFromEnd(o)+F,F!==" !important"&&(c.raws.important=F);break}else if(h[1].toLowerCase()==="important"){let F=o.slice(0),b="";for(let v=m;v>0;v--){let w=F[v][0];if(b.trim().startsWith("!")&&w!=="space")break;b=F.pop()[1]+b}b.trim().startsWith("!")&&(c.important=!0,c.raws.important=b,o=F)}if(h[0]!=="space"&&h[0]!=="comment")break}o.some(m=>m[0]!=="space"&&m[0]!=="comment")&&(c.raws.between+=y.map(m=>m[1]).join(""),y=[]),this.raw(c,"value",y.concat(o),p),c.value.includes(":")&&!p&&this.checkMissedSemicolon(o)}doubleColon(o){throw this.input.error("Double colon",{offset:o[2]},{offset:o[2]+o[1].length})}emptyRule(o){let p=new i;this.init(p,o[2]),p.selector="",p.raws.between="",this.current=p}end(o){this.current.nodes&&this.current.nodes.length&&(this.current.raws.semicolon=this.semicolon),this.semicolon=!1,this.current.raws.after=(this.current.raws.after||"")+this.spaces,this.spaces="",this.current.parent?(this.current.source.end=this.getPosition(o[2]),this.current.source.end.offset++,this.current=this.current.parent):this.unexpectedClose(o)}endFile(){this.current.parent&&this.unclosedBlock(),this.current.nodes&&this.current.nodes.length&&(this.current.raws.semicolon=this.semicolon),this.current.raws.after=(this.current.raws.after||"")+this.spaces,this.root.source.end=this.getPosition(this.tokenizer.position())}freeSemicolon(o){if(this.spaces+=o[1],this.current.nodes){let p=this.current.nodes[this.current.nodes.length-1];p&&p.type==="rule"&&!p.raws.ownSemicolon&&(p.raws.ownSemicolon=this.spaces,this.spaces="",p.source.end=this.getPosition(o[2]),p.source.end.offset+=p.raws.ownSemicolon.length)}}getPosition(o){let p=this.input.fromOffset(o);return{column:p.col,line:p.line,offset:o}}init(o,p){this.current.push(o),o.source={input:this.input,start:this.getPosition(p)},o.raws.before=this.spaces,this.spaces="",o.type!=="comment"&&(this.semicolon=!1)}other(o){let p=!1,c=null,D=!1,h=null,y=[],g=o[1].startsWith("--"),m=[],F=o;for(;F;){if(c=F[0],m.push(F),c==="("||c==="[")h||(h=F),y.push(c==="("?")":"]");else if(g&&D&&c==="{")h||(h=F),y.push("}");else if(y.length===0)if(c===";")if(D){this.decl(m,g);return}else break;else if(c==="{"){this.rule(m);return}else if(c==="}"){this.tokenizer.back(m.pop()),p=!0;break}else c===":"&&(D=!0);else c===y[y.length-1]&&(y.pop(),y.length===0&&(h=null));F=this.tokenizer.nextToken()}if(this.tokenizer.endOfFile()&&(p=!0),y.length>0&&this.unclosedBracket(h),p&&D){if(!g)for(;m.length&&(F=m[m.length-1][0],!(F!=="space"&&F!=="comment"));)this.tokenizer.back(m.pop());this.decl(m,g)}else this.unknownWord(m)}parse(){let o;for(;!this.tokenizer.endOfFile();)switch(o=this.tokenizer.nextToken(),o[0]){case"space":this.spaces+=o[1];break;case";":this.freeSemicolon(o);break;case"}":this.end(o);break;case"comment":this.comment(o);break;case"at-word":this.atrule(o);break;case"{":this.emptyRule(o);break;default:this.other(o);break}this.endFile()}precheckMissedSemicolon(){}raw(o,p,c,D){let h,y,g=c.length,m="",F=!0,b,v;for(let w=0;w<g;w+=1)h=c[w],y=h[0],y==="space"&&w===g-1&&!D?F=!1:y==="comment"?(v=c[w-1]?c[w-1][0]:"empty",b=c[w+1]?c[w+1][0]:"empty",!f[v]&&!f[b]?m.slice(-1)===","?F=!1:m+=h[1]:F=!1):m+=h[1];if(!F){let w=c.reduce((x,C)=>x+C[1],"");o.raws[p]={raw:w,value:m}}o[p]=m}rule(o){o.pop();let p=new i;this.init(p,o[0][2]),p.raws.between=this.spacesAndCommentsFromEnd(o),this.raw(p,"selector",o),this.current=p}spacesAndCommentsFromEnd(o){let p,c="";for(;o.length&&(p=o[o.length-1][0],!(p!=="space"&&p!=="comment"));)c=o.pop()[1]+c;return c}spacesAndCommentsFromStart(o){let p,c="";for(;o.length&&(p=o[0][0],!(p!=="space"&&p!=="comment"));)c+=o.shift()[1];return c}spacesFromEnd(o){let p,c="";for(;o.length&&(p=o[o.length-1][0],p==="space");)c=o.pop()[1]+c;return c}stringFrom(o,p){let c="";for(let D=p;D<o.length;D++)c+=o[D][1];return o.splice(p,o.length-p),c}unclosedBlock(){let o=this.current.source.start;throw this.input.error("Unclosed block",o.line,o.column)}unclosedBracket(o){throw this.input.error("Unclosed bracket",{offset:o[2]},{offset:o[2]+1})}unexpectedClose(o){throw this.input.error("Unexpected }",{offset:o[2]},{offset:o[2]+1})}unknownWord(o){throw this.input.error("Unknown word "+o[0][1],{offset:o[0][2]},{offset:o[0][2]+o[0][1].length})}unnamedAtrule(o,p){throw this.input.error("At-rule without name",{offset:p[2]},{offset:p[2]+p[1].length})}};t.exports=a}),Yt=T((e,t)=>{var n=qe(),r=xt(),u=rn();function s(i,l){let f=new r(i,l),d=new u(f);try{d.parse()}catch(a){throw a}return d.root}t.exports=s,s.default=s,n.registerParse(s)}),fc=T((e,t)=>{var n=tn(),r=xt();t.exports={isInlineComment(u){if(u[0]==="word"&&u[1].slice(0,2)==="//"){let s=u,i=[],l,f;for(;u;){if(/\r?\n/.test(u[1])){if(/['"].*\r?\n/.test(u[1])){i.push(u[1].substring(0,u[1].indexOf(`
|
|
51
|
-
`))),f=u[1].substring(u[1].indexOf(`
|
|
52
|
-
`));let a=this.input.css.valueOf().substring(this.tokenizer.position());f+=a,l=u[3]+a.length-f.length}else this.tokenizer.back(u);break}i.push(u[1]),l=u[2],u=this.tokenizer.nextToken({ignoreUnclosed:!0})}let d=["comment",i.join(""),s[2],l];return this.inlineComment(d),f&&(this.input=new r(f),this.tokenizer=n(this.input)),!0}else if(u[1]==="/"){let s=this.tokenizer.nextToken({ignoreUnclosed:!0});if(s[0]==="comment"&&/^\/\*/.test(s[1]))return s[0]="word",s[1]=s[1].slice(1),u[1]="//",this.tokenizer.back(s),t.exports.isInlineComment.bind(this)(u)}return!1}}}),pc=T((e,t)=>{t.exports={interpolation(n){let r=[n,this.tokenizer.nextToken()],u=["word","}"];if(r[0][1].length>1||r[1][0]!=="{")return this.tokenizer.back(r[1]),!1;for(n=this.tokenizer.nextToken();n&&u.includes(n[0]);)r.push(n),n=this.tokenizer.nextToken();let s=r.map(d=>d[1]),[i]=r,l=r.pop(),f=["word",s.join(""),i[2],l[2]];return this.tokenizer.back(n),this.tokenizer.back(f),!0}}}),hc=T((e,t)=>{var n=/^#[0-9a-fA-F]{6}$|^#[0-9a-fA-F]{3}$/,r=/\.[0-9]/,u=s=>{let[,i]=s,[l]=i;return(l==="."||l==="#")&&n.test(i)===!1&&r.test(i)===!1};t.exports={isMixinToken:u}}),dc=T((e,t)=>{var n=tn(),r=/^url\((.+)\)/;t.exports=u=>{let{name:s,params:i=""}=u;if(s==="import"&&i.length){u.import=!0;let l=n({css:i});for(u.filename=i.replace(r,"$1");!l.endOfFile();){let[f,d]=l.nextToken();if(f==="word"&&d==="url")return;if(f==="brackets"){u.options=d,u.filename=i.replace(d,"").trim();break}}}}}),Dc=T((e,t)=>{var n=/:$/,r=/^:(\s+)?/;t.exports=u=>{let{name:s,params:i=""}=u;if(u.name.slice(-1)===":"){if(n.test(s)){let[l]=s.match(n);u.name=s.replace(l,""),u.raws.afterName=l+(u.raws.afterName||""),u.variable=!0,u.value=u.params}if(r.test(i)){let[l]=i.match(r);u.value=i.replace(l,""),u.raws.afterName=(u.raws.afterName||"")+l,u.variable=!0}}}}),mc=T((e,t)=>{var n=bt(),r=rn(),{isInlineComment:u}=fc(),{interpolation:s}=pc(),{isMixinToken:i}=hc(),l=dc(),f=Dc(),d=/(!\s*important)$/i;t.exports=class extends r{constructor(...a){super(...a),this.lastNode=null}atrule(a){s.bind(this)(a)||(super.atrule(a),l(this.lastNode),f(this.lastNode))}decl(...a){super.decl(...a),/extend\(.+\)/i.test(this.lastNode.value)&&(this.lastNode.extend=!0)}each(a){a[0][1]=` ${a[0][1]}`;let o=a.findIndex(h=>h[0]==="("),p=a.reverse().find(h=>h[0]===")"),c=a.reverse().indexOf(p),D=a.splice(o,c).map(h=>h[1]).join("");for(let h of a.reverse())this.tokenizer.back(h);this.atrule(this.tokenizer.nextToken()),this.lastNode.function=!0,this.lastNode.params=D}init(a,o,p){super.init(a,o,p),this.lastNode=a}inlineComment(a){let o=new n,p=a[1].slice(2);if(this.init(o,a[2]),o.source.end=this.getPosition(a[3]||a[2]),o.inline=!0,o.raws.begin="//",/^\s*$/.test(p))o.text="",o.raws.left=p,o.raws.right="";else{let c=p.match(/^(\s*)([^]*[^\s])(\s*)$/);[,o.raws.left,o.text,o.raws.right]=c}}mixin(a){let[o]=a,p=o[1].slice(0,1),c=a.findIndex(m=>m[0]==="brackets"),D=a.findIndex(m=>m[0]==="("),h="";if((c<0||c>3)&&D>0){let m=a.reduce((O,N,S)=>N[0]===")"?S:O),F=a.slice(D,m+D).map(O=>O[1]).join(""),[b]=a.slice(D),v=[b[2],b[3]],[w]=a.slice(m,m+1),x=[w[2],w[3]],C=["brackets",F].concat(v,x),B=a.slice(0,D),k=a.slice(m+1);a=B,a.push(C),a=a.concat(k)}let y=[];for(let m of a)if((m[1]==="!"||y.length)&&y.push(m),m[1]==="important")break;if(y.length){let[m]=y,F=a.indexOf(m),b=y[y.length-1],v=[m[2],m[3]],w=[b[4],b[5]],x=["word",y.map(C=>C[1]).join("")].concat(v,w);a.splice(F,y.length,x)}let g=a.findIndex(m=>d.test(m[1]));g>0&&([,h]=a[g],a.splice(g,1));for(let m of a.reverse())this.tokenizer.back(m);this.atrule(this.tokenizer.nextToken()),this.lastNode.mixin=!0,this.lastNode.raws.identifier=p,h&&(this.lastNode.important=!0,this.lastNode.raws.important=h)}other(a){u.bind(this)(a)||super.other(a)}rule(a){let o=a[a.length-1],p=a[a.length-2];if(p[0]==="at-word"&&o[0]==="{"&&(this.tokenizer.back(o),s.bind(this)(p))){let c=this.tokenizer.nextToken();a=a.slice(0,a.length-2).concat([c]);for(let D of a.reverse())this.tokenizer.back(D);return}super.rule(a),/:extend\(.+\)/i.test(this.lastNode.selector)&&(this.lastNode.extend=!0)}unknownWord(a){let[o]=a;if(a[0][1]==="each"&&a[1][0]==="("){this.each(a);return}if(i(o)){this.mixin(a);return}super.unknownWord(a)}}}),gc=T((e,t)=>{var n=Qr();t.exports=class extends n{atrule(r,u){if(!r.mixin&&!r.variable&&!r.function){super.atrule(r,u);return}let s=`${r.function?"":r.raws.identifier||"@"}${r.name}`,i=r.params?this.rawValue(r,"params"):"",l=r.raws.important||"";if(r.variable&&(i=r.value),typeof r.raws.afterName<"u"?s+=r.raws.afterName:i&&(s+=" "),r.nodes)this.block(r,s+i+l);else{let f=(r.raws.between||"")+l+(u?";":"");this.builder(s+i+f,r)}}comment(r){if(r.inline){let u=this.raw(r,"left","commentLeft"),s=this.raw(r,"right","commentRight");this.builder(`//${u}${r.text}${s}`,r)}else super.comment(r)}}}),yc=T((e,t)=>{var n=xt(),r=mc(),u=gc();t.exports={parse(s,i){let l=new n(s,i),f=new r(l);return f.parse(),f.root.walk(d=>{let a=l.css.lastIndexOf(d.source.input.css);if(a===0)return;if(a+d.source.input.css.length!==l.css.length)throw new Error("Invalid state detected in postcss-less");let o=a+d.source.start.offset,p=l.fromOffset(a+d.source.start.offset);if(d.source.start={offset:o,line:p.line,column:p.col},d.source.end){let c=a+d.source.end.offset,D=l.fromOffset(a+d.source.end.offset);d.source.end={offset:c,line:D.line,column:D.col}}}),f.root},stringify(s,i){new u(i).stringify(s)},nodeToString(s){let i="";return t.exports.stringify(s,l=>{i+=l}),i}}}),nn=T((e,t)=>{var n=qe(),r,u,s=class extends n{constructor(i){super({type:"document",...i}),this.nodes||(this.nodes=[])}toResult(i={}){return new r(new u,this,i).stringify()}};s.registerLazyResult=i=>{r=i},s.registerProcessor=i=>{u=i},t.exports=s,s.default=s}),vc=T((e,t)=>{var n=Zr(),r=bt(),u=Qt(),s=xt(),i=no(),l=Ct(),f=en();function d(a,o){if(Array.isArray(a))return a.map(D=>d(D));let{inputs:p,...c}=a;if(p){o=[];for(let D of p){let h={...D,__proto__:s.prototype};h.map&&(h.map={...h.map,__proto__:i.prototype}),o.push(h)}}if(c.nodes&&(c.nodes=a.nodes.map(D=>d(D,o))),c.source){let{inputId:D,...h}=c.source;c.source=h,D!=null&&(c.source.input=o[D])}if(c.type==="root")return new l(c);if(c.type==="decl")return new u(c);if(c.type==="rule")return new f(c);if(c.type==="comment")return new r(c);if(c.type==="atrule")return new n(c);throw new Error("Unknown node type: "+a.type)}t.exports=d,d.default=d}),oo=T((e,t)=>{t.exports=class{generate(){}}}),uo=T((e,t)=>{var n=class{constructor(r,u={}){if(this.type="warning",this.text=r,u.node&&u.node.source){let s=u.node.rangeBy(u);this.line=s.start.line,this.column=s.start.column,this.endLine=s.end.line,this.endColumn=s.end.column}for(let s in u)this[s]=u[s]}toString(){return this.node?this.node.error(this.text,{index:this.index,plugin:this.plugin,word:this.word}).message:this.plugin?this.plugin+": "+this.text:this.text}};t.exports=n,n.default=n}),sn=T((e,t)=>{var n=uo(),r=class{get content(){return this.css}constructor(u,s,i){this.processor=u,this.messages=[],this.root=s,this.opts=i,this.css="",this.map=void 0}toString(){return this.css}warn(u,s={}){s.plugin||this.lastPlugin&&this.lastPlugin.postcssPlugin&&(s.plugin=this.lastPlugin.postcssPlugin);let i=new n(u,s);return this.messages.push(i),i}warnings(){return this.messages.filter(u=>u.type==="warning")}};t.exports=r,r.default=r}),io=T((e,t)=>{var n={};t.exports=function(r){n[r]||(n[r]=!0,typeof console<"u"&&console.warn&&console.warn(r))}}),ao=T((e,t)=>{var n=qe(),r=nn(),u=oo(),s=Yt(),i=sn(),l=Ct(),f=Kt(),{isClean:d,my:a}=Yr();io();var o={atrule:"AtRule",comment:"Comment",decl:"Declaration",document:"Document",root:"Root",rule:"Rule"},p={AtRule:!0,AtRuleExit:!0,Comment:!0,CommentExit:!0,Declaration:!0,DeclarationExit:!0,Document:!0,DocumentExit:!0,Once:!0,OnceExit:!0,postcssPlugin:!0,prepare:!0,Root:!0,RootExit:!0,Rule:!0,RuleExit:!0},c={Once:!0,postcssPlugin:!0,prepare:!0},D=0;function h(v){return typeof v=="object"&&typeof v.then=="function"}function y(v){let w=!1,x=o[v.type];return v.type==="decl"?w=v.prop.toLowerCase():v.type==="atrule"&&(w=v.name.toLowerCase()),w&&v.append?[x,x+"-"+w,D,x+"Exit",x+"Exit-"+w]:w?[x,x+"-"+w,x+"Exit",x+"Exit-"+w]:v.append?[x,D,x+"Exit"]:[x,x+"Exit"]}function g(v){let w;return v.type==="document"?w=["Document",D,"DocumentExit"]:v.type==="root"?w=["Root",D,"RootExit"]:w=y(v),{eventIndex:0,events:w,iterator:0,node:v,visitorIndex:0,visitors:[]}}function m(v){return v[d]=!1,v.nodes&&v.nodes.forEach(w=>m(w)),v}var F={},b=class lo{get content(){return this.stringify().content}get css(){return this.stringify().css}get map(){return this.stringify().map}get messages(){return this.sync().messages}get opts(){return this.result.opts}get processor(){return this.result.processor}get root(){return this.sync().root}get[Symbol.toStringTag](){return"LazyResult"}constructor(w,x,C){this.stringified=!1,this.processed=!1;let B;if(typeof x=="object"&&x!==null&&(x.type==="root"||x.type==="document"))B=m(x);else if(x instanceof lo||x instanceof i)B=m(x.root),x.map&&(typeof C.map>"u"&&(C.map={}),C.map.inline||(C.map.inline=!1),C.map.prev=x.map);else{let k=s;C.syntax&&(k=C.syntax.parse),C.parser&&(k=C.parser),k.parse&&(k=k.parse);try{B=k(x,C)}catch(O){this.processed=!0,this.error=O}B&&!B[a]&&n.rebuild(B)}this.result=new i(w,B,C),this.helpers={...F,postcss:F,result:this.result},this.plugins=this.processor.plugins.map(k=>typeof k=="object"&&k.prepare?{...k,...k.prepare(this.result)}:k)}async(){return this.error?Promise.reject(this.error):this.processed?Promise.resolve(this.result):(this.processing||(this.processing=this.runAsync()),this.processing)}catch(w){return this.async().catch(w)}finally(w){return this.async().then(w,w)}getAsyncError(){throw new Error("Use process(css).then(cb) to work with async plugins")}handleError(w,x){let C=this.result.lastPlugin;try{x&&x.addToError(w),this.error=w,w.name==="CssSyntaxError"&&!w.plugin?(w.plugin=C.postcssPlugin,w.setMessage()):C.postcssVersion}catch(B){console&&console.error&&console.error(B)}return w}prepareVisitors(){this.listeners={};let w=(x,C,B)=>{this.listeners[C]||(this.listeners[C]=[]),this.listeners[C].push([x,B])};for(let x of this.plugins)if(typeof x=="object")for(let C in x){if(!p[C]&&/^[A-Z]/.test(C))throw new Error(`Unknown event ${C} in ${x.postcssPlugin}. Try to update PostCSS (${this.processor.version} now).`);if(!c[C])if(typeof x[C]=="object")for(let B in x[C])B==="*"?w(x,C,x[C][B]):w(x,C+"-"+B.toLowerCase(),x[C][B]);else typeof x[C]=="function"&&w(x,C,x[C])}this.hasListener=Object.keys(this.listeners).length>0}async runAsync(){this.plugin=0;for(let w=0;w<this.plugins.length;w++){let x=this.plugins[w],C=this.runOnRoot(x);if(h(C))try{await C}catch(B){throw this.handleError(B)}}if(this.prepareVisitors(),this.hasListener){let w=this.result.root;for(;!w[d];){w[d]=!0;let x=[g(w)];for(;x.length>0;){let C=this.visitTick(x);if(h(C))try{await C}catch(B){let k=x[x.length-1].node;throw this.handleError(B,k)}}}if(this.listeners.OnceExit)for(let[x,C]of this.listeners.OnceExit){this.result.lastPlugin=x;try{if(w.type==="document"){let B=w.nodes.map(k=>C(k,this.helpers));await Promise.all(B)}else await C(w,this.helpers)}catch(B){throw this.handleError(B)}}}return this.processed=!0,this.stringify()}runOnRoot(w){this.result.lastPlugin=w;try{if(typeof w=="object"&&w.Once){if(this.result.root.type==="document"){let x=this.result.root.nodes.map(C=>w.Once(C,this.helpers));return h(x[0])?Promise.all(x):x}return w.Once(this.result.root,this.helpers)}else if(typeof w=="function")return w(this.result.root,this.result)}catch(x){throw this.handleError(x)}}stringify(){if(this.error)throw this.error;if(this.stringified)return this.result;this.stringified=!0,this.sync();let w=this.result.opts,x=f;w.syntax&&(x=w.syntax.stringify),w.stringifier&&(x=w.stringifier),x.stringify&&(x=x.stringify);let C=new u(x,this.result.root,this.result.opts).generate();return this.result.css=C[0],this.result.map=C[1],this.result}sync(){if(this.error)throw this.error;if(this.processed)return this.result;if(this.processed=!0,this.processing)throw this.getAsyncError();for(let w of this.plugins){let x=this.runOnRoot(w);if(h(x))throw this.getAsyncError()}if(this.prepareVisitors(),this.hasListener){let w=this.result.root;for(;!w[d];)w[d]=!0,this.walkSync(w);if(this.listeners.OnceExit)if(w.type==="document")for(let x of w.nodes)this.visitSync(this.listeners.OnceExit,x);else this.visitSync(this.listeners.OnceExit,w)}return this.result}then(w,x){return this.async().then(w,x)}toString(){return this.css}visitSync(w,x){for(let[C,B]of w){this.result.lastPlugin=C;let k;try{k=B(x,this.helpers)}catch(O){throw this.handleError(O,x.proxyOf)}if(x.type!=="root"&&x.type!=="document"&&!x.parent)return!0;if(h(k))throw this.getAsyncError()}}visitTick(w){let x=w[w.length-1],{node:C,visitors:B}=x;if(C.type!=="root"&&C.type!=="document"&&!C.parent){w.pop();return}if(B.length>0&&x.visitorIndex<B.length){let[O,N]=B[x.visitorIndex];x.visitorIndex+=1,x.visitorIndex===B.length&&(x.visitors=[],x.visitorIndex=0),this.result.lastPlugin=O;try{return N(C.toProxy(),this.helpers)}catch(S){throw this.handleError(S,C)}}if(x.iterator!==0){let O=x.iterator,N;for(;N=C.nodes[C.indexes[O]];)if(C.indexes[O]+=1,!N[d]){N[d]=!0,w.push(g(N));return}x.iterator=0,delete C.indexes[O]}let k=x.events;for(;x.eventIndex<k.length;){let O=k[x.eventIndex];if(x.eventIndex+=1,O===D){C.nodes&&C.nodes.length&&(C[d]=!0,x.iterator=C.getIterator());return}else if(this.listeners[O]){x.visitors=this.listeners[O];return}}w.pop()}walkSync(w){w[d]=!0;let x=y(w);for(let C of x)if(C===D)w.nodes&&w.each(B=>{B[d]||this.walkSync(B)});else{let B=this.listeners[C];if(B&&this.visitSync(B,w.toProxy()))return}}warnings(){return this.sync().warnings()}};b.registerPostcss=v=>{F=v},t.exports=b,b.default=b,l.registerLazyResult(b),r.registerLazyResult(b)}),Fc=T((e,t)=>{var n=oo(),r=Yt(),u=sn(),s=Kt();io();var i=class{get content(){return this.result.css}get css(){return this.result.css}get map(){return this.result.map}get messages(){return[]}get opts(){return this.result.opts}get processor(){return this.result.processor}get root(){if(this._root)return this._root;let l,f=r;try{l=f(this._css,this._opts)}catch(d){this.error=d}if(this.error)throw this.error;return this._root=l,l}get[Symbol.toStringTag](){return"NoWorkResult"}constructor(l,f,d){f=f.toString(),this.stringified=!1,this._processor=l,this._css=f,this._opts=d,this._map=void 0;let a,o=s;this.result=new u(this._processor,a,this._opts),this.result.css=f;let p=this;Object.defineProperty(this.result,"root",{get(){return p.root}});let c=new n(o,a,this._opts,f);if(c.isMap()){let[D,h]=c.generate();D&&(this.result.css=D),h&&(this.result.map=h)}else c.clearAnnotation(),this.result.css=c.css}async(){return this.error?Promise.reject(this.error):Promise.resolve(this.result)}catch(l){return this.async().catch(l)}finally(l){return this.async().then(l,l)}sync(){if(this.error)throw this.error;return this.result}then(l,f){return this.async().then(l,f)}toString(){return this._css}warnings(){return[]}};t.exports=i,i.default=i}),wc=T((e,t)=>{var n=nn(),r=ao(),u=Fc(),s=Ct(),i=class{constructor(l=[]){this.version="8.5.6",this.plugins=this.normalize(l)}normalize(l){let f=[];for(let d of l)if(d.postcss===!0?d=d():d.postcss&&(d=d.postcss),typeof d=="object"&&Array.isArray(d.plugins))f=f.concat(d.plugins);else if(typeof d=="object"&&d.postcssPlugin)f.push(d);else if(typeof d=="function")f.push(d);else if(!(typeof d=="object"&&(d.parse||d.stringify)))throw new Error(d+" is not a PostCSS plugin");return f}process(l,f={}){return!this.plugins.length&&!f.parser&&!f.stringifier&&!f.syntax?new u(this,l,f):new r(this,l,f)}use(l){return this.plugins=this.plugins.concat(this.normalize([l])),this}};t.exports=i,i.default=i,s.registerProcessor(i),n.registerProcessor(i)}),on=T((e,t)=>{var n=Zr(),r=bt(),u=qe(),s=Xr(),i=Qt(),l=nn(),f=vc(),d=xt(),a=ao(),o=so(),p=Xt(),c=Yt(),D=wc(),h=sn(),y=Ct(),g=en(),m=Kt(),F=uo();function b(...v){return v.length===1&&Array.isArray(v[0])&&(v=v[0]),new D(v)}b.plugin=function(v,w){let x=!1;function C(...k){console&&console.warn&&!x&&(x=!0,console.warn(v+`: postcss.plugin was deprecated. Migration guide:
|
|
53
|
-
https://evilmartians.com/chronicles/postcss-8-plugin-migration`));let O=w(...k);return O.postcssPlugin=v,O.postcssVersion=new D().version,O}let B;return Object.defineProperty(C,"postcss",{get(){return B||(B=C()),B}}),C.process=function(k,O,N){return b([C(N)]).process(k,O)},C},b.stringify=m,b.parse=c,b.fromJSON=f,b.list=o,b.comment=v=>new r(v),b.atRule=v=>new n(v),b.decl=v=>new i(v),b.rule=v=>new g(v),b.root=v=>new y(v),b.document=v=>new l(v),b.CssSyntaxError=s,b.Declaration=i,b.Container=u,b.Processor=D,b.Document=l,b.Comment=r,b.Warning=F,b.AtRule=n,b.Result=h,b.Input=d,b.Rule=g,b.Root=y,b.Node=p,a.registerPostcss(b),t.exports=b,b.default=b}),bc=T((e,t)=>{var{Container:n}=on(),r=class extends n{constructor(u){super(u),this.type="decl",this.isNested=!0,this.nodes||(this.nodes=[])}};t.exports=r}),xc=T((e,t)=>{var n=/[\t\n\f\r "#'()/;[\\\]{}]/g,r=/[,\t\n\f\r !"#'():;@[\\\]{}]|\/(?=\*)/g,u=/.[\r\n"'(/\\]/,s=/[\da-f]/i,i=/[\n\f\r]/g;t.exports=function(l,f={}){let d=l.css.valueOf(),a=f.ignoreErrors,o,p,c,D,h,y,g,m,F,b=d.length,v=0,w=[],x=[],C;function B(){return v}function k(j){throw l.error("Unclosed "+j,v)}function O(){return x.length===0&&v>=b}function N(){let j=1,$=!1,z=!1;for(;j>0;)p+=1,d.length<=p&&k("interpolation"),o=d.charCodeAt(p),m=d.charCodeAt(p+1),$?!z&&o===$?($=!1,z=!1):o===92?z=!z:z&&(z=!1):o===39||o===34?$=o:o===125?j-=1:o===35&&m===123&&(j+=1)}function S(j){if(x.length)return x.pop();if(v>=b)return;let $=j?j.ignoreUnclosed:!1;switch(o=d.charCodeAt(v),o){case 10:case 32:case 9:case 13:case 12:{p=v;do p+=1,o=d.charCodeAt(p);while(o===32||o===10||o===9||o===13||o===12);F=["space",d.slice(v,p)],v=p-1;break}case 91:case 93:case 123:case 125:case 58:case 59:case 41:{let z=String.fromCharCode(o);F=[z,z,v];break}case 44:{F=["word",",",v,v+1];break}case 40:{if(g=w.length?w.pop()[1]:"",m=d.charCodeAt(v+1),g==="url"&&m!==39&&m!==34){for(C=1,y=!1,p=v+1;p<=d.length-1;){if(m=d.charCodeAt(p),m===92)y=!y;else if(m===40)C+=1;else if(m===41&&(C-=1,C===0))break;p+=1}D=d.slice(v,p+1),F=["brackets",D,v,p],v=p}else p=d.indexOf(")",v+1),D=d.slice(v,p+1),p===-1||u.test(D)?F=["(","(",v]:(F=["brackets",D,v,p],v=p);break}case 39:case 34:{for(c=o,p=v,y=!1;p<b&&(p++,p===b&&k("string"),o=d.charCodeAt(p),m=d.charCodeAt(p+1),!(!y&&o===c));)o===92?y=!y:y?y=!1:o===35&&m===123&&N();F=["string",d.slice(v,p+1),v,p],v=p;break}case 64:{n.lastIndex=v+1,n.test(d),n.lastIndex===0?p=d.length-1:p=n.lastIndex-2,F=["at-word",d.slice(v,p+1),v,p],v=p;break}case 92:{for(p=v,h=!0;d.charCodeAt(p+1)===92;)p+=1,h=!h;if(o=d.charCodeAt(p+1),h&&o!==47&&o!==32&&o!==10&&o!==9&&o!==13&&o!==12&&(p+=1,s.test(d.charAt(p)))){for(;s.test(d.charAt(p+1));)p+=1;d.charCodeAt(p+1)===32&&(p+=1)}F=["word",d.slice(v,p+1),v,p],v=p;break}default:m=d.charCodeAt(v+1),o===35&&m===123?(p=v,N(),D=d.slice(v,p+1),F=["word",D,v,p],v=p):o===47&&m===42?(p=d.indexOf("*/",v+2)+1,p===0&&(a||$?p=d.length:k("comment")),F=["comment",d.slice(v,p+1),v,p],v=p):o===47&&m===47?(i.lastIndex=v+1,i.test(d),i.lastIndex===0?p=d.length-1:p=i.lastIndex-2,D=d.slice(v,p+1),F=["comment",D,v,p,"inline"],v=p):(r.lastIndex=v+1,r.test(d),r.lastIndex===0?p=d.length-1:p=r.lastIndex-2,F=["word",d.slice(v,p+1),v,p],w.push(F),v=p);break}return v++,F}function I(j){x.push(j)}return{back:I,endOfFile:O,nextToken:S,position:B}}}),Cc=T((e,t)=>{var{Comment:n}=on(),r=rn(),u=bc(),s=xc(),i=class extends r{atrule(l){let f=l[1],d=l;for(;!this.tokenizer.endOfFile();){let a=this.tokenizer.nextToken();if(a[0]==="word"&&a[2]===d[3]+1)f+=a[1],d=a;else{this.tokenizer.back(a);break}}super.atrule(["at-word",f,l[2],d[3]])}comment(l){if(l[4]==="inline"){let f=new n;this.init(f,l[2]),f.raws.inline=!0;let d=this.input.fromOffset(l[3]);f.source.end={column:d.col,line:d.line,offset:l[3]+1};let a=l[1].slice(2);if(/^\s*$/.test(a))f.text="",f.raws.left=a,f.raws.right="";else{let o=a.match(/^(\s*)([^]*\S)(\s*)$/),p=o[2].replace(/(\*\/|\/\*)/g,"*//*");f.text=p,f.raws.left=o[1],f.raws.right=o[3],f.raws.text=o[2]}}else super.comment(l)}createTokenizer(){this.tokenizer=s(this.input)}raw(l,f,d,a){if(super.raw(l,f,d,a),l.raws[f]){let o=l.raws[f].raw;l.raws[f].raw=d.reduce((p,c)=>{if(c[0]==="comment"&&c[4]==="inline"){let D=c[1].slice(2).replace(/(\*\/|\/\*)/g,"*//*");return p+"/*"+D+"*/"}else return p+c[1]},""),o!==l.raws[f].raw&&(l.raws[f].scss=o)}}rule(l){let f=!1,d=0,a="";for(let o of l)if(f)o[0]!=="comment"&&o[0]!=="{"&&(a+=o[1]);else{if(o[0]==="space"&&o[1].includes(`
|
|
54
|
-
`))break;o[0]==="("?d+=1:o[0]===")"?d-=1:d===0&&o[0]===":"&&(f=!0)}if(!f||a.trim()===""||/^[#:A-Za-z-]/.test(a))super.rule(l);else{l.pop();let o=new u;this.init(o,l[0][2]);let p;for(let D=l.length-1;D>=0;D--)if(l[D][0]!=="space"){p=l[D];break}if(p[3]){let D=this.input.fromOffset(p[3]);o.source.end={column:D.col,line:D.line,offset:p[3]+1}}else{let D=this.input.fromOffset(p[2]);o.source.end={column:D.col,line:D.line,offset:p[2]+1}}for(;l[0][0]!=="word";)o.raws.before+=l.shift()[1];if(l[0][2]){let D=this.input.fromOffset(l[0][2]);o.source.start={column:D.col,line:D.line,offset:l[0][2]}}for(o.prop="";l.length;){let D=l[0][0];if(D===":"||D==="space"||D==="comment")break;o.prop+=l.shift()[1]}o.raws.between="";let c;for(;l.length;)if(c=l.shift(),c[0]===":"){o.raws.between+=c[1];break}else o.raws.between+=c[1];(o.prop[0]==="_"||o.prop[0]==="*")&&(o.raws.before+=o.prop[0],o.prop=o.prop.slice(1)),o.raws.between+=this.spacesAndCommentsFromStart(l),this.precheckMissedSemicolon(l);for(let D=l.length-1;D>0;D--){if(c=l[D],c[1]==="!important"){o.important=!0;let h=this.stringFrom(l,D);h=this.spacesFromEnd(l)+h,h!==" !important"&&(o.raws.important=h);break}else if(c[1]==="important"){let h=l.slice(0),y="";for(let g=D;g>0;g--){let m=h[g][0];if(y.trim().indexOf("!")===0&&m!=="space")break;y=h.pop()[1]+y}y.trim().indexOf("!")===0&&(o.important=!0,o.raws.important=y,l=h)}if(c[0]!=="space"&&c[0]!=="comment")break}this.raw(o,"value",l),o.value.includes(":")&&this.checkMissedSemicolon(l),this.current=o}}};t.exports=i}),kc=T((e,t)=>{var{Input:n}=on(),r=Cc();t.exports=function(u,s){let i=new n(u,s),l=new r(i);return l.parse(),l.root}}),co=T(e=>{Object.defineProperty(e,"__esModule",{value:!0});function t(n){this.after=n.after,this.before=n.before,this.type=n.type,this.value=n.value,this.sourceIndex=n.sourceIndex}e.default=t}),fo=T(e=>{Object.defineProperty(e,"__esModule",{value:!0});var t=co(),n=r(t);function r(s){return s&&s.__esModule?s:{default:s}}function u(s){var i=this;this.constructor(s),this.nodes=s.nodes,this.after===void 0&&(this.after=this.nodes.length>0?this.nodes[this.nodes.length-1].after:""),this.before===void 0&&(this.before=this.nodes.length>0?this.nodes[0].before:""),this.sourceIndex===void 0&&(this.sourceIndex=this.before.length),this.nodes.forEach(function(l){l.parent=i})}u.prototype=Object.create(n.default.prototype),u.constructor=n.default,u.prototype.walk=function(s,i){for(var l=typeof s=="string"||s instanceof RegExp,f=l?i:s,d=typeof s=="string"?new RegExp(s):s,a=0;a<this.nodes.length;a++){var o=this.nodes[a],p=l?d.test(o.type):!0;if(p&&f&&f(o,a,this.nodes)===!1||o.nodes&&o.walk(s,i)===!1)return!1}return!0},u.prototype.each=function(){for(var s=arguments.length<=0||arguments[0]===void 0?function(){}:arguments[0],i=0;i<this.nodes.length;i++){var l=this.nodes[i];if(s(l,i,this.nodes)===!1)return!1}return!0},e.default=u}),Ec=T(e=>{Object.defineProperty(e,"__esModule",{value:!0}),e.parseMediaFeature=i,e.parseMediaQuery=l,e.parseMediaList=f;var t=co(),n=s(t),r=fo(),u=s(r);function s(d){return d&&d.__esModule?d:{default:d}}function i(d){var a=arguments.length<=1||arguments[1]===void 0?0:arguments[1],o=[{mode:"normal",character:null}],p=[],c=0,D="",h=null,y=null,g=a,m=d;d[0]==="("&&d[d.length-1]===")"&&(m=d.substring(1,d.length-1),g++);for(var F=0;F<m.length;F++){var b=m[F];if((b==="'"||b==='"')&&(o[c].isCalculationEnabled===!0?(o.push({mode:"string",isCalculationEnabled:!1,character:b}),c++):o[c].mode==="string"&&o[c].character===b&&m[F-1]!=="\\"&&(o.pop(),c--)),b==="{"?(o.push({mode:"interpolation",isCalculationEnabled:!0}),c++):b==="}"&&(o.pop(),c--),o[c].mode==="normal"&&b===":"){var v=m.substring(F+1);y={type:"value",before:/^(\s*)/.exec(v)[1],after:/(\s*)$/.exec(v)[1],value:v.trim()},y.sourceIndex=y.before.length+F+1+g,h={type:"colon",sourceIndex:F+g,after:y.before,value:":"};break}D+=b}return D={type:"media-feature",before:/^(\s*)/.exec(D)[1],after:/(\s*)$/.exec(D)[1],value:D.trim()},D.sourceIndex=D.before.length+g,p.push(D),h!==null&&(h.before=D.after,p.push(h)),y!==null&&p.push(y),p}function l(d){var a=arguments.length<=1||arguments[1]===void 0?0:arguments[1],o=[],p=0,c=!1,D=void 0;function h(){return{before:"",after:"",value:""}}D=h();for(var y=0;y<d.length;y++){var g=d[y];c?(D.value+=g,(g==="{"||g==="(")&&p++,(g===")"||g==="}")&&p--):g.search(/\s/)!==-1?D.before+=g:(g==="("&&(D.type="media-feature-expression",p++),D.value=g,D.sourceIndex=a+y,c=!0),c&&p===0&&(g===")"||y===d.length-1||d[y+1].search(/\s/)!==-1)&&(["not","only","and"].indexOf(D.value)!==-1&&(D.type="keyword"),D.type==="media-feature-expression"&&(D.nodes=i(D.value,D.sourceIndex)),o.push(Array.isArray(D.nodes)?new u.default(D):new n.default(D)),D=h(),c=!1)}for(var m=0;m<o.length;m++)if(D=o[m],m>0&&(o[m-1].after=D.before),D.type===void 0){if(m>0){if(o[m-1].type==="media-feature-expression"){D.type="keyword";continue}if(o[m-1].value==="not"||o[m-1].value==="only"){D.type="media-type";continue}if(o[m-1].value==="and"){D.type="media-feature-expression";continue}o[m-1].type==="media-type"&&(o[m+1]?D.type=o[m+1].type==="media-feature-expression"?"keyword":"media-feature-expression":D.type="media-feature-expression")}if(m===0){if(!o[m+1]){D.type="media-type";continue}if(o[m+1]&&(o[m+1].type==="media-feature-expression"||o[m+1].type==="keyword")){D.type="media-type";continue}if(o[m+2]){if(o[m+2].type==="media-feature-expression"){D.type="media-type",o[m+1].type="keyword";continue}if(o[m+2].type==="keyword"){D.type="keyword",o[m+1].type="media-type";continue}}if(o[m+3]&&o[m+3].type==="media-feature-expression"){D.type="keyword",o[m+1].type="media-type",o[m+2].type="keyword";continue}}}return o}function f(d){var a=[],o=0,p=0,c=/^(\s*)url\s*\(/.exec(d);if(c!==null){for(var D=c[0].length,h=1;h>0;){var y=d[D];y==="("&&h++,y===")"&&h--,D++}a.unshift(new n.default({type:"url",value:d.substring(0,D).trim(),sourceIndex:c[1].length,before:c[1],after:/^(\s*)/.exec(d.substring(D))[1]})),o=D}for(var g=o;g<d.length;g++){var m=d[g];if(m==="("&&p++,m===")"&&p--,p===0&&m===","){var F=d.substring(o,g),b=/^(\s*)/.exec(F)[1];a.push(new u.default({type:"media-query",value:F.trim(),sourceIndex:o+b.length,nodes:l(F,o),before:b,after:/(\s*)$/.exec(F)[1]})),o=g+1}}var v=d.substring(o),w=/^(\s*)/.exec(v)[1];return a.push(new u.default({type:"media-query",value:v.trim(),sourceIndex:o+w.length,nodes:l(v,o),before:w,after:/(\s*)$/.exec(v)[1]})),a}}),Ac=T(e=>{Object.defineProperty(e,"__esModule",{value:!0}),e.default=s;var t=fo(),n=u(t),r=Ec();function u(i){return i&&i.__esModule?i:{default:i}}function s(i){return new n.default({nodes:(0,r.parseMediaList)(i),type:"media-query-list",value:i.trim()})}}),po=T((e,t)=>{t.exports=function(n,r){if(r=typeof r=="number"?r:1/0,!r)return Array.isArray(n)?n.map(function(s){return s}):n;return u(n,1);function u(s,i){return s.reduce(function(l,f){return Array.isArray(f)&&i<r?l.concat(u(f,i+1)):l.concat(f)},[])}}}),ho=T((e,t)=>{t.exports=function(n,r){for(var u=-1,s=[];(u=n.indexOf(r,u+1))!==-1;)s.push(u);return s}}),Do=T((e,t)=>{function n(s,i){for(var l=1,f=s.length,d=s[0],a=s[0],o=1;o<f;++o)if(a=d,d=s[o],i(d,a)){if(o===l){l++;continue}s[l++]=d}return s.length=l,s}function r(s){for(var i=1,l=s.length,f=s[0],d=s[0],a=1;a<l;++a,d=f)if(d=f,f=s[a],f!==d){if(a===i){i++;continue}s[i++]=f}return s.length=i,s}function u(s,i,l){return s.length===0?s:i?(l||s.sort(i),n(s,i)):(l||s.sort(),r(s))}t.exports=u}),nt=T((e,t)=>{e.__esModule=!0;var n=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(i){return typeof i}:function(i){return i&&typeof Symbol=="function"&&i.constructor===Symbol&&i!==Symbol.prototype?"symbol":typeof i};function r(i,l){if(!(i instanceof l))throw new TypeError("Cannot call a class as a function")}var u=function i(l,f){if((typeof l>"u"?"undefined":n(l))!=="object")return l;var d=new l.constructor;for(var a in l)if(l.hasOwnProperty(a)){var o=l[a],p=typeof o>"u"?"undefined":n(o);a==="parent"&&p==="object"?f&&(d[a]=f):o instanceof Array?d[a]=o.map(function(c){return i(c,d)}):d[a]=i(o,d)}return d},s=(function(){function i(){var l=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};r(this,i);for(var f in l)this[f]=l[f];var d=l.spaces;d=d===void 0?{}:d;var a=d.before,o=a===void 0?"":a,p=d.after,c=p===void 0?"":p;this.spaces={before:o,after:c}}return i.prototype.remove=function(){return this.parent&&this.parent.removeChild(this),this.parent=void 0,this},i.prototype.replaceWith=function(){if(this.parent){for(var l in arguments)this.parent.insertBefore(this,arguments[l]);this.remove()}return this},i.prototype.next=function(){return this.parent.at(this.parent.index(this)+1)},i.prototype.prev=function(){return this.parent.at(this.parent.index(this)-1)},i.prototype.clone=function(){var l=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},f=u(this);for(var d in l)f[d]=l[d];return f},i.prototype.toString=function(){return[this.spaces.before,String(this.value),this.spaces.after].join("")},i})();e.default=s,t.exports=e.default}),ee=T(e=>{e.__esModule=!0,e.TAG="tag",e.STRING="string",e.SELECTOR="selector",e.ROOT="root",e.PSEUDO="pseudo",e.NESTING="nesting",e.ID="id",e.COMMENT="comment",e.COMBINATOR="combinator",e.CLASS="class",e.ATTRIBUTE="attribute",e.UNIVERSAL="universal"}),un=T((e,t)=>{e.__esModule=!0;var n=(function(){function c(D,h){for(var y=0;y<h.length;y++){var g=h[y];g.enumerable=g.enumerable||!1,g.configurable=!0,"value"in g&&(g.writable=!0),Object.defineProperty(D,g.key,g)}}return function(D,h,y){return h&&c(D.prototype,h),y&&c(D,y),D}})(),r=nt(),u=f(r),s=ee(),i=l(s);function l(c){if(c&&c.__esModule)return c;var D={};if(c!=null)for(var h in c)Object.prototype.hasOwnProperty.call(c,h)&&(D[h]=c[h]);return D.default=c,D}function f(c){return c&&c.__esModule?c:{default:c}}function d(c,D){if(!(c instanceof D))throw new TypeError("Cannot call a class as a function")}function a(c,D){if(!c)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return D&&(typeof D=="object"||typeof D=="function")?D:c}function o(c,D){if(typeof D!="function"&&D!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof D);c.prototype=Object.create(D&&D.prototype,{constructor:{value:c,enumerable:!1,writable:!0,configurable:!0}}),D&&(Object.setPrototypeOf?Object.setPrototypeOf(c,D):c.__proto__=D)}var p=(function(c){o(D,c);function D(h){d(this,D);var y=a(this,c.call(this,h));return y.nodes||(y.nodes=[]),y}return D.prototype.append=function(h){return h.parent=this,this.nodes.push(h),this},D.prototype.prepend=function(h){return h.parent=this,this.nodes.unshift(h),this},D.prototype.at=function(h){return this.nodes[h]},D.prototype.index=function(h){return typeof h=="number"?h:this.nodes.indexOf(h)},D.prototype.removeChild=function(h){h=this.index(h),this.at(h).parent=void 0,this.nodes.splice(h,1);var y=void 0;for(var g in this.indexes)y=this.indexes[g],y>=h&&(this.indexes[g]=y-1);return this},D.prototype.removeAll=function(){for(var g=this.nodes,h=Array.isArray(g),y=0,g=h?g:g[Symbol.iterator]();;){var m;if(h){if(y>=g.length)break;m=g[y++]}else{if(y=g.next(),y.done)break;m=y.value}var F=m;F.parent=void 0}return this.nodes=[],this},D.prototype.empty=function(){return this.removeAll()},D.prototype.insertAfter=function(h,y){var g=this.index(h);this.nodes.splice(g+1,0,y);var m=void 0;for(var F in this.indexes)m=this.indexes[F],g<=m&&(this.indexes[F]=m+this.nodes.length);return this},D.prototype.insertBefore=function(h,y){var g=this.index(h);this.nodes.splice(g,0,y);var m=void 0;for(var F in this.indexes)m=this.indexes[F],g<=m&&(this.indexes[F]=m+this.nodes.length);return this},D.prototype.each=function(h){this.lastEach||(this.lastEach=0),this.indexes||(this.indexes={}),this.lastEach++;var y=this.lastEach;if(this.indexes[y]=0,!!this.length){for(var g=void 0,m=void 0;this.indexes[y]<this.length&&(g=this.indexes[y],m=h(this.at(g),g),m!==!1);)this.indexes[y]+=1;if(delete this.indexes[y],m===!1)return!1}},D.prototype.walk=function(h){return this.each(function(y,g){var m=h(y,g);if(m!==!1&&y.length&&(m=y.walk(h)),m===!1)return!1})},D.prototype.walkAttributes=function(h){var y=this;return this.walk(function(g){if(g.type===i.ATTRIBUTE)return h.call(y,g)})},D.prototype.walkClasses=function(h){var y=this;return this.walk(function(g){if(g.type===i.CLASS)return h.call(y,g)})},D.prototype.walkCombinators=function(h){var y=this;return this.walk(function(g){if(g.type===i.COMBINATOR)return h.call(y,g)})},D.prototype.walkComments=function(h){var y=this;return this.walk(function(g){if(g.type===i.COMMENT)return h.call(y,g)})},D.prototype.walkIds=function(h){var y=this;return this.walk(function(g){if(g.type===i.ID)return h.call(y,g)})},D.prototype.walkNesting=function(h){var y=this;return this.walk(function(g){if(g.type===i.NESTING)return h.call(y,g)})},D.prototype.walkPseudos=function(h){var y=this;return this.walk(function(g){if(g.type===i.PSEUDO)return h.call(y,g)})},D.prototype.walkTags=function(h){var y=this;return this.walk(function(g){if(g.type===i.TAG)return h.call(y,g)})},D.prototype.walkUniversals=function(h){var y=this;return this.walk(function(g){if(g.type===i.UNIVERSAL)return h.call(y,g)})},D.prototype.split=function(h){var y=this,g=[];return this.reduce(function(m,F,b){var v=h.call(y,F);return g.push(F),v?(m.push(g),g=[]):b===y.length-1&&m.push(g),m},[])},D.prototype.map=function(h){return this.nodes.map(h)},D.prototype.reduce=function(h,y){return this.nodes.reduce(h,y)},D.prototype.every=function(h){return this.nodes.every(h)},D.prototype.some=function(h){return this.nodes.some(h)},D.prototype.filter=function(h){return this.nodes.filter(h)},D.prototype.sort=function(h){return this.nodes.sort(h)},D.prototype.toString=function(){return this.map(String).join("")},n(D,[{key:"first",get:function(){return this.at(0)}},{key:"last",get:function(){return this.at(this.length-1)}},{key:"length",get:function(){return this.nodes.length}}]),D})(u.default);e.default=p,t.exports=e.default}),Sc=T((e,t)=>{e.__esModule=!0;var n=un(),r=s(n),u=ee();function s(a){return a&&a.__esModule?a:{default:a}}function i(a,o){if(!(a instanceof o))throw new TypeError("Cannot call a class as a function")}function l(a,o){if(!a)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return o&&(typeof o=="object"||typeof o=="function")?o:a}function f(a,o){if(typeof o!="function"&&o!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof o);a.prototype=Object.create(o&&o.prototype,{constructor:{value:a,enumerable:!1,writable:!0,configurable:!0}}),o&&(Object.setPrototypeOf?Object.setPrototypeOf(a,o):a.__proto__=o)}var d=(function(a){f(o,a);function o(p){i(this,o);var c=l(this,a.call(this,p));return c.type=u.ROOT,c}return o.prototype.toString=function(){var p=this.reduce(function(c,D){var h=String(D);return h?c+h+",":""},"").slice(0,-1);return this.trailingComma?p+",":p},o})(r.default);e.default=d,t.exports=e.default}),Oc=T((e,t)=>{e.__esModule=!0;var n=un(),r=s(n),u=ee();function s(a){return a&&a.__esModule?a:{default:a}}function i(a,o){if(!(a instanceof o))throw new TypeError("Cannot call a class as a function")}function l(a,o){if(!a)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return o&&(typeof o=="object"||typeof o=="function")?o:a}function f(a,o){if(typeof o!="function"&&o!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof o);a.prototype=Object.create(o&&o.prototype,{constructor:{value:a,enumerable:!1,writable:!0,configurable:!0}}),o&&(Object.setPrototypeOf?Object.setPrototypeOf(a,o):a.__proto__=o)}var d=(function(a){f(o,a);function o(p){i(this,o);var c=l(this,a.call(this,p));return c.type=u.SELECTOR,c}return o})(r.default);e.default=d,t.exports=e.default}),kt=T((e,t)=>{e.__esModule=!0;var n=(function(){function a(o,p){for(var c=0;c<p.length;c++){var D=p[c];D.enumerable=D.enumerable||!1,D.configurable=!0,"value"in D&&(D.writable=!0),Object.defineProperty(o,D.key,D)}}return function(o,p,c){return p&&a(o.prototype,p),c&&a(o,c),o}})(),r=nt(),u=s(r);function s(a){return a&&a.__esModule?a:{default:a}}function i(a,o){if(!(a instanceof o))throw new TypeError("Cannot call a class as a function")}function l(a,o){if(!a)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return o&&(typeof o=="object"||typeof o=="function")?o:a}function f(a,o){if(typeof o!="function"&&o!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof o);a.prototype=Object.create(o&&o.prototype,{constructor:{value:a,enumerable:!1,writable:!0,configurable:!0}}),o&&(Object.setPrototypeOf?Object.setPrototypeOf(a,o):a.__proto__=o)}var d=(function(a){f(o,a);function o(){return i(this,o),l(this,a.apply(this,arguments))}return o.prototype.toString=function(){return[this.spaces.before,this.ns,String(this.value),this.spaces.after].join("")},n(o,[{key:"ns",get:function(){var p=this.namespace;return p?(typeof p=="string"?p:"")+"|":""}}]),o})(u.default);e.default=d,t.exports=e.default}),Bc=T((e,t)=>{e.__esModule=!0;var n=kt(),r=s(n),u=ee();function s(a){return a&&a.__esModule?a:{default:a}}function i(a,o){if(!(a instanceof o))throw new TypeError("Cannot call a class as a function")}function l(a,o){if(!a)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return o&&(typeof o=="object"||typeof o=="function")?o:a}function f(a,o){if(typeof o!="function"&&o!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof o);a.prototype=Object.create(o&&o.prototype,{constructor:{value:a,enumerable:!1,writable:!0,configurable:!0}}),o&&(Object.setPrototypeOf?Object.setPrototypeOf(a,o):a.__proto__=o)}var d=(function(a){f(o,a);function o(p){i(this,o);var c=l(this,a.call(this,p));return c.type=u.CLASS,c}return o.prototype.toString=function(){return[this.spaces.before,this.ns,"."+this.value,this.spaces.after].join("")},o})(r.default);e.default=d,t.exports=e.default}),Tc=T((e,t)=>{e.__esModule=!0;var n=nt(),r=s(n),u=ee();function s(a){return a&&a.__esModule?a:{default:a}}function i(a,o){if(!(a instanceof o))throw new TypeError("Cannot call a class as a function")}function l(a,o){if(!a)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return o&&(typeof o=="object"||typeof o=="function")?o:a}function f(a,o){if(typeof o!="function"&&o!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof o);a.prototype=Object.create(o&&o.prototype,{constructor:{value:a,enumerable:!1,writable:!0,configurable:!0}}),o&&(Object.setPrototypeOf?Object.setPrototypeOf(a,o):a.__proto__=o)}var d=(function(a){f(o,a);function o(p){i(this,o);var c=l(this,a.call(this,p));return c.type=u.COMMENT,c}return o})(r.default);e.default=d,t.exports=e.default}),$c=T((e,t)=>{e.__esModule=!0;var n=kt(),r=s(n),u=ee();function s(a){return a&&a.__esModule?a:{default:a}}function i(a,o){if(!(a instanceof o))throw new TypeError("Cannot call a class as a function")}function l(a,o){if(!a)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return o&&(typeof o=="object"||typeof o=="function")?o:a}function f(a,o){if(typeof o!="function"&&o!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof o);a.prototype=Object.create(o&&o.prototype,{constructor:{value:a,enumerable:!1,writable:!0,configurable:!0}}),o&&(Object.setPrototypeOf?Object.setPrototypeOf(a,o):a.__proto__=o)}var d=(function(a){f(o,a);function o(p){i(this,o);var c=l(this,a.call(this,p));return c.type=u.ID,c}return o.prototype.toString=function(){return[this.spaces.before,this.ns,"#"+this.value,this.spaces.after].join("")},o})(r.default);e.default=d,t.exports=e.default}),_c=T((e,t)=>{e.__esModule=!0;var n=kt(),r=s(n),u=ee();function s(a){return a&&a.__esModule?a:{default:a}}function i(a,o){if(!(a instanceof o))throw new TypeError("Cannot call a class as a function")}function l(a,o){if(!a)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return o&&(typeof o=="object"||typeof o=="function")?o:a}function f(a,o){if(typeof o!="function"&&o!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof o);a.prototype=Object.create(o&&o.prototype,{constructor:{value:a,enumerable:!1,writable:!0,configurable:!0}}),o&&(Object.setPrototypeOf?Object.setPrototypeOf(a,o):a.__proto__=o)}var d=(function(a){f(o,a);function o(p){i(this,o);var c=l(this,a.call(this,p));return c.type=u.TAG,c}return o})(r.default);e.default=d,t.exports=e.default}),Ic=T((e,t)=>{e.__esModule=!0;var n=nt(),r=s(n),u=ee();function s(a){return a&&a.__esModule?a:{default:a}}function i(a,o){if(!(a instanceof o))throw new TypeError("Cannot call a class as a function")}function l(a,o){if(!a)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return o&&(typeof o=="object"||typeof o=="function")?o:a}function f(a,o){if(typeof o!="function"&&o!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof o);a.prototype=Object.create(o&&o.prototype,{constructor:{value:a,enumerable:!1,writable:!0,configurable:!0}}),o&&(Object.setPrototypeOf?Object.setPrototypeOf(a,o):a.__proto__=o)}var d=(function(a){f(o,a);function o(p){i(this,o);var c=l(this,a.call(this,p));return c.type=u.STRING,c}return o})(r.default);e.default=d,t.exports=e.default}),jc=T((e,t)=>{e.__esModule=!0;var n=un(),r=s(n),u=ee();function s(a){return a&&a.__esModule?a:{default:a}}function i(a,o){if(!(a instanceof o))throw new TypeError("Cannot call a class as a function")}function l(a,o){if(!a)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return o&&(typeof o=="object"||typeof o=="function")?o:a}function f(a,o){if(typeof o!="function"&&o!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof o);a.prototype=Object.create(o&&o.prototype,{constructor:{value:a,enumerable:!1,writable:!0,configurable:!0}}),o&&(Object.setPrototypeOf?Object.setPrototypeOf(a,o):a.__proto__=o)}var d=(function(a){f(o,a);function o(p){i(this,o);var c=l(this,a.call(this,p));return c.type=u.PSEUDO,c}return o.prototype.toString=function(){var p=this.length?"("+this.map(String).join(",")+")":"";return[this.spaces.before,String(this.value),p,this.spaces.after].join("")},o})(r.default);e.default=d,t.exports=e.default}),Nc=T((e,t)=>{e.__esModule=!0;var n=kt(),r=s(n),u=ee();function s(a){return a&&a.__esModule?a:{default:a}}function i(a,o){if(!(a instanceof o))throw new TypeError("Cannot call a class as a function")}function l(a,o){if(!a)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return o&&(typeof o=="object"||typeof o=="function")?o:a}function f(a,o){if(typeof o!="function"&&o!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof o);a.prototype=Object.create(o&&o.prototype,{constructor:{value:a,enumerable:!1,writable:!0,configurable:!0}}),o&&(Object.setPrototypeOf?Object.setPrototypeOf(a,o):a.__proto__=o)}var d=(function(a){f(o,a);function o(p){i(this,o);var c=l(this,a.call(this,p));return c.type=u.ATTRIBUTE,c.raws={},c}return o.prototype.toString=function(){var p=[this.spaces.before,"[",this.ns,this.attribute];return this.operator&&p.push(this.operator),this.value&&p.push(this.value),this.raws.insensitive?p.push(this.raws.insensitive):this.insensitive&&p.push(" i"),p.push("]"),p.concat(this.spaces.after).join("")},o})(r.default);e.default=d,t.exports=e.default}),Pc=T((e,t)=>{e.__esModule=!0;var n=kt(),r=s(n),u=ee();function s(a){return a&&a.__esModule?a:{default:a}}function i(a,o){if(!(a instanceof o))throw new TypeError("Cannot call a class as a function")}function l(a,o){if(!a)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return o&&(typeof o=="object"||typeof o=="function")?o:a}function f(a,o){if(typeof o!="function"&&o!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof o);a.prototype=Object.create(o&&o.prototype,{constructor:{value:a,enumerable:!1,writable:!0,configurable:!0}}),o&&(Object.setPrototypeOf?Object.setPrototypeOf(a,o):a.__proto__=o)}var d=(function(a){f(o,a);function o(p){i(this,o);var c=l(this,a.call(this,p));return c.type=u.UNIVERSAL,c.value="*",c}return o})(r.default);e.default=d,t.exports=e.default}),Lc=T((e,t)=>{e.__esModule=!0;var n=nt(),r=s(n),u=ee();function s(a){return a&&a.__esModule?a:{default:a}}function i(a,o){if(!(a instanceof o))throw new TypeError("Cannot call a class as a function")}function l(a,o){if(!a)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return o&&(typeof o=="object"||typeof o=="function")?o:a}function f(a,o){if(typeof o!="function"&&o!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof o);a.prototype=Object.create(o&&o.prototype,{constructor:{value:a,enumerable:!1,writable:!0,configurable:!0}}),o&&(Object.setPrototypeOf?Object.setPrototypeOf(a,o):a.__proto__=o)}var d=(function(a){f(o,a);function o(p){i(this,o);var c=l(this,a.call(this,p));return c.type=u.COMBINATOR,c}return o})(r.default);e.default=d,t.exports=e.default}),Mc=T((e,t)=>{e.__esModule=!0;var n=nt(),r=s(n),u=ee();function s(a){return a&&a.__esModule?a:{default:a}}function i(a,o){if(!(a instanceof o))throw new TypeError("Cannot call a class as a function")}function l(a,o){if(!a)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return o&&(typeof o=="object"||typeof o=="function")?o:a}function f(a,o){if(typeof o!="function"&&o!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof o);a.prototype=Object.create(o&&o.prototype,{constructor:{value:a,enumerable:!1,writable:!0,configurable:!0}}),o&&(Object.setPrototypeOf?Object.setPrototypeOf(a,o):a.__proto__=o)}var d=(function(a){f(o,a);function o(p){i(this,o);var c=l(this,a.call(this,p));return c.type=u.NESTING,c.value="&",c}return o})(r.default);e.default=d,t.exports=e.default}),Rc=T((e,t)=>{e.__esModule=!0,e.default=n;function n(r){return r.sort(function(u,s){return u-s})}t.exports=e.default}),Wc=T((e,t)=>{e.__esModule=!0,e.default=O;var n=39,r=34,u=92,s=47,i=10,l=32,f=12,d=9,a=13,o=43,p=62,c=126,D=124,h=44,y=40,g=41,m=91,F=93,b=59,v=42,w=58,x=38,C=64,B=/[ \n\t\r\{\(\)'"\\;/]/g,k=/[ \n\t\r\(\)\*:;@!&'"\+\|~>,\[\]\\]|\/(?=\*)/g;function O(N){for(var S=[],I=N.css.valueOf(),j=void 0,$=void 0,z=void 0,M=void 0,se=void 0,W=void 0,Je=void 0,Ve=void 0,Ue=void 0,q=void 0,ot=void 0,ur=I.length,_=-1,E=1,A=0,L=function(R,J){if(N.safe)I+=J,$=I.length-1;else throw N.error("Unclosed "+R,E,A-_,A)};A<ur;){switch(j=I.charCodeAt(A),j===i&&(_=A,E+=1),j){case i:case l:case d:case a:case f:$=A;do $+=1,j=I.charCodeAt($),j===i&&(_=$,E+=1);while(j===l||j===i||j===d||j===a||j===f);S.push(["space",I.slice(A,$),E,A-_,A]),A=$-1;break;case o:case p:case c:case D:$=A;do $+=1,j=I.charCodeAt($);while(j===o||j===p||j===c||j===D);S.push(["combinator",I.slice(A,$),E,A-_,A]),A=$-1;break;case v:S.push(["*","*",E,A-_,A]);break;case x:S.push(["&","&",E,A-_,A]);break;case h:S.push([",",",",E,A-_,A]);break;case m:S.push(["[","[",E,A-_,A]);break;case F:S.push(["]","]",E,A-_,A]);break;case w:S.push([":",":",E,A-_,A]);break;case b:S.push([";",";",E,A-_,A]);break;case y:S.push(["(","(",E,A-_,A]);break;case g:S.push([")",")",E,A-_,A]);break;case n:case r:z=j===n?"'":'"',$=A;do for(q=!1,$=I.indexOf(z,$+1),$===-1&&L("quote",z),ot=$;I.charCodeAt(ot-1)===u;)ot-=1,q=!q;while(q);S.push(["string",I.slice(A,$+1),E,A-_,E,$-_,A]),A=$;break;case C:B.lastIndex=A+1,B.test(I),B.lastIndex===0?$=I.length-1:$=B.lastIndex-2,S.push(["at-word",I.slice(A,$+1),E,A-_,E,$-_,A]),A=$;break;case u:for($=A,Je=!0;I.charCodeAt($+1)===u;)$+=1,Je=!Je;j=I.charCodeAt($+1),Je&&j!==s&&j!==l&&j!==i&&j!==d&&j!==a&&j!==f&&($+=1),S.push(["word",I.slice(A,$+1),E,A-_,E,$-_,A]),A=$;break;default:j===s&&I.charCodeAt(A+1)===v?($=I.indexOf("*/",A+2)+1,$===0&&L("comment","*/"),W=I.slice(A,$+1),M=W.split(`
|
|
55
|
-
`),se=M.length-1,se>0?(Ve=E+se,Ue=$-M[se].length):(Ve=E,Ue=_),S.push(["comment",W,E,A-_,Ve,$-Ue,A]),_=Ue,E=Ve,A=$):(k.lastIndex=A+1,k.test(I),k.lastIndex===0?$=I.length-1:$=k.lastIndex-2,S.push(["word",I.slice(A,$+1),E,A-_,E,$-_,A]),A=$);break}A++}return S}t.exports=e.default}),zc=T((e,t)=>{e.__esModule=!0;var n=(function(){function _(E,A){for(var L=0;L<A.length;L++){var R=A[L];R.enumerable=R.enumerable||!1,R.configurable=!0,"value"in R&&(R.writable=!0),Object.defineProperty(E,R.key,R)}}return function(E,A,L){return A&&_(E.prototype,A),L&&_(E,L),E}})(),r=po(),u=q(r),s=ho(),i=q(s),l=Do(),f=q(l),d=Sc(),a=q(d),o=Oc(),p=q(o),c=Bc(),D=q(c),h=Tc(),y=q(h),g=$c(),m=q(g),F=_c(),b=q(F),v=Ic(),w=q(v),x=jc(),C=q(x),B=Nc(),k=q(B),O=Pc(),N=q(O),S=Lc(),I=q(S),j=Mc(),$=q(j),z=Rc(),M=q(z),se=Wc(),W=q(se),Je=ee(),Ve=Ue(Je);function Ue(_){if(_&&_.__esModule)return _;var E={};if(_!=null)for(var A in _)Object.prototype.hasOwnProperty.call(_,A)&&(E[A]=_[A]);return E.default=_,E}function q(_){return _&&_.__esModule?_:{default:_}}function ot(_,E){if(!(_ instanceof E))throw new TypeError("Cannot call a class as a function")}var ur=(function(){function _(E){ot(this,_),this.input=E,this.lossy=E.options.lossless===!1,this.position=0,this.root=new a.default;var A=new p.default;return this.root.append(A),this.current=A,this.lossy?this.tokens=(0,W.default)({safe:E.safe,css:E.css.trim()}):this.tokens=(0,W.default)(E),this.loop()}return _.prototype.attribute=function(){var E="",A=void 0,L=this.currToken;for(this.position++;this.position<this.tokens.length&&this.currToken[0]!=="]";)E+=this.tokens[this.position][1],this.position++;this.position===this.tokens.length&&!~E.indexOf("]")&&this.error("Expected a closing square bracket.");var R=E.split(/((?:[*~^$|]?=))([^]*)/),J=R[0].split(/(\|)/g),ae={operator:R[1],value:R[2],source:{start:{line:L[2],column:L[3]},end:{line:this.currToken[2],column:this.currToken[3]}},sourceIndex:L[4]};if(J.length>1?(J[0]===""&&(J[0]=!0),ae.attribute=this.parseValue(J[2]),ae.namespace=this.parseNamespace(J[0])):ae.attribute=this.parseValue(R[0]),A=new k.default(ae),R[2]){var Ce=R[2].split(/(\s+i\s*?)$/),ke=Ce[0].trim();A.value=this.lossy?ke:Ce[0],Ce[1]&&(A.insensitive=!0,this.lossy||(A.raws.insensitive=Ce[1])),A.quoted=ke[0]==="'"||ke[0]==='"',A.raws.unquoted=A.quoted?ke.slice(1,-1):ke}this.newNode(A),this.position++},_.prototype.combinator=function(){if(this.currToken[1]==="|")return this.namespace();for(var E=new I.default({value:"",source:{start:{line:this.currToken[2],column:this.currToken[3]},end:{line:this.currToken[2],column:this.currToken[3]}},sourceIndex:this.currToken[4]});this.position<this.tokens.length&&this.currToken&&(this.currToken[0]==="space"||this.currToken[0]==="combinator");)this.nextToken&&this.nextToken[0]==="combinator"?(E.spaces.before=this.parseSpace(this.currToken[1]),E.source.start.line=this.nextToken[2],E.source.start.column=this.nextToken[3],E.source.end.column=this.nextToken[3],E.source.end.line=this.nextToken[2],E.sourceIndex=this.nextToken[4]):this.prevToken&&this.prevToken[0]==="combinator"?E.spaces.after=this.parseSpace(this.currToken[1]):this.currToken[0]==="combinator"?E.value=this.currToken[1]:this.currToken[0]==="space"&&(E.value=this.parseSpace(this.currToken[1]," ")),this.position++;return this.newNode(E)},_.prototype.comma=function(){if(this.position===this.tokens.length-1){this.root.trailingComma=!0,this.position++;return}var E=new p.default;this.current.parent.append(E),this.current=E,this.position++},_.prototype.comment=function(){var E=new y.default({value:this.currToken[1],source:{start:{line:this.currToken[2],column:this.currToken[3]},end:{line:this.currToken[4],column:this.currToken[5]}},sourceIndex:this.currToken[6]});this.newNode(E),this.position++},_.prototype.error=function(E){throw new this.input.error(E)},_.prototype.missingBackslash=function(){return this.error("Expected a backslash preceding the semicolon.")},_.prototype.missingParenthesis=function(){return this.error("Expected opening parenthesis.")},_.prototype.missingSquareBracket=function(){return this.error("Expected opening square bracket.")},_.prototype.namespace=function(){var E=this.prevToken&&this.prevToken[1]||!0;if(this.nextToken[0]==="word")return this.position++,this.word(E);if(this.nextToken[0]==="*")return this.position++,this.universal(E)},_.prototype.nesting=function(){this.newNode(new $.default({value:this.currToken[1],source:{start:{line:this.currToken[2],column:this.currToken[3]},end:{line:this.currToken[2],column:this.currToken[3]}},sourceIndex:this.currToken[4]})),this.position++},_.prototype.parentheses=function(){var E=this.current.last;if(E&&E.type===Ve.PSEUDO){var A=new p.default,L=this.current;E.append(A),this.current=A;var R=1;for(this.position++;this.position<this.tokens.length&&R;)this.currToken[0]==="("&&R++,this.currToken[0]===")"&&R--,R?this.parse():(A.parent.source.end.line=this.currToken[2],A.parent.source.end.column=this.currToken[3],this.position++);R&&this.error("Expected closing parenthesis."),this.current=L}else{var J=1;for(this.position++,E.value+="(";this.position<this.tokens.length&&J;)this.currToken[0]==="("&&J++,this.currToken[0]===")"&&J--,E.value+=this.parseParenthesisToken(this.currToken),this.position++;J&&this.error("Expected closing parenthesis.")}},_.prototype.pseudo=function(){for(var E=this,A="",L=this.currToken;this.currToken&&this.currToken[0]===":";)A+=this.currToken[1],this.position++;if(!this.currToken)return this.error("Expected pseudo-class or pseudo-element");if(this.currToken[0]==="word"){var R=void 0;this.splitWord(!1,function(J,ae){A+=J,R=new C.default({value:A,source:{start:{line:L[2],column:L[3]},end:{line:E.currToken[4],column:E.currToken[5]}},sourceIndex:L[4]}),E.newNode(R),ae>1&&E.nextToken&&E.nextToken[0]==="("&&E.error("Misplaced parenthesis.")})}else this.error('Unexpected "'+this.currToken[0]+'" found.')},_.prototype.space=function(){var E=this.currToken;this.position===0||this.prevToken[0]===","||this.prevToken[0]==="("?(this.spaces=this.parseSpace(E[1]),this.position++):this.position===this.tokens.length-1||this.nextToken[0]===","||this.nextToken[0]===")"?(this.current.last.spaces.after=this.parseSpace(E[1]),this.position++):this.combinator()},_.prototype.string=function(){var E=this.currToken;this.newNode(new w.default({value:this.currToken[1],source:{start:{line:E[2],column:E[3]},end:{line:E[4],column:E[5]}},sourceIndex:E[6]})),this.position++},_.prototype.universal=function(E){var A=this.nextToken;if(A&&A[1]==="|")return this.position++,this.namespace();this.newNode(new N.default({value:this.currToken[1],source:{start:{line:this.currToken[2],column:this.currToken[3]},end:{line:this.currToken[2],column:this.currToken[3]}},sourceIndex:this.currToken[4]}),E),this.position++},_.prototype.splitWord=function(E,A){for(var L=this,R=this.nextToken,J=this.currToken[1];R&&R[0]==="word";){this.position++;var ae=this.currToken[1];if(J+=ae,ae.lastIndexOf("\\")===ae.length-1){var Ce=this.nextToken;Ce&&Ce[0]==="space"&&(J+=this.parseSpace(Ce[1]," "),this.position++)}R=this.nextToken}var ke=(0,i.default)(J,"."),At=(0,i.default)(J,"#"),yn=(0,i.default)(J,"#{");yn.length&&(At=At.filter(function(Ee){return!~yn.indexOf(Ee)}));var He=(0,M.default)((0,f.default)((0,u.default)([[0],ke,At])));He.forEach(function(Ee,ut){var St=He[ut+1]||J.length,Ot=J.slice(Ee,St);if(ut===0&&A)return A.call(L,Ot,He.length);var Bt=void 0;~ke.indexOf(Ee)?Bt=new D.default({value:Ot.slice(1),source:{start:{line:L.currToken[2],column:L.currToken[3]+Ee},end:{line:L.currToken[4],column:L.currToken[3]+(St-1)}},sourceIndex:L.currToken[6]+He[ut]}):~At.indexOf(Ee)?Bt=new m.default({value:Ot.slice(1),source:{start:{line:L.currToken[2],column:L.currToken[3]+Ee},end:{line:L.currToken[4],column:L.currToken[3]+(St-1)}},sourceIndex:L.currToken[6]+He[ut]}):Bt=new b.default({value:Ot,source:{start:{line:L.currToken[2],column:L.currToken[3]+Ee},end:{line:L.currToken[4],column:L.currToken[3]+(St-1)}},sourceIndex:L.currToken[6]+He[ut]}),L.newNode(Bt,E)}),this.position++},_.prototype.word=function(E){var A=this.nextToken;return A&&A[1]==="|"?(this.position++,this.namespace()):this.splitWord(E)},_.prototype.loop=function(){for(;this.position<this.tokens.length;)this.parse(!0);return this.root},_.prototype.parse=function(E){switch(this.currToken[0]){case"space":this.space();break;case"comment":this.comment();break;case"(":this.parentheses();break;case")":E&&this.missingParenthesis();break;case"[":this.attribute();break;case"]":this.missingSquareBracket();break;case"at-word":case"word":this.word();break;case":":this.pseudo();break;case";":this.missingBackslash();break;case",":this.comma();break;case"*":this.universal();break;case"&":this.nesting();break;case"combinator":this.combinator();break;case"string":this.string();break}},_.prototype.parseNamespace=function(E){if(this.lossy&&typeof E=="string"){var A=E.trim();return A.length?A:!0}return E},_.prototype.parseSpace=function(E,A){return this.lossy?A||"":E},_.prototype.parseValue=function(E){return this.lossy&&E&&typeof E=="string"?E.trim():E},_.prototype.parseParenthesisToken=function(E){return this.lossy?E[0]==="space"?this.parseSpace(E[1]," "):this.parseValue(E[1]):E[1]},_.prototype.newNode=function(E,A){return A&&(E.namespace=this.parseNamespace(A)),this.spaces&&(E.spaces.before=this.spaces,this.spaces=""),this.current.append(E)},n(_,[{key:"currToken",get:function(){return this.tokens[this.position]}},{key:"nextToken",get:function(){return this.tokens[this.position+1]}},{key:"prevToken",get:function(){return this.tokens[this.position-1]}}]),_})();e.default=ur,t.exports=e.default}),qc=T((e,t)=>{e.__esModule=!0;var n=(function(){function f(d,a){for(var o=0;o<a.length;o++){var p=a[o];p.enumerable=p.enumerable||!1,p.configurable=!0,"value"in p&&(p.writable=!0),Object.defineProperty(d,p.key,p)}}return function(d,a,o){return a&&f(d.prototype,a),o&&f(d,o),d}})(),r=zc(),u=s(r);function s(f){return f&&f.__esModule?f:{default:f}}function i(f,d){if(!(f instanceof d))throw new TypeError("Cannot call a class as a function")}var l=(function(){function f(d){return i(this,f),this.func=d||function(){},this}return f.prototype.process=function(d){var a=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},o=new u.default({css:d,error:function(p){throw new Error(p)},options:a});return this.res=o,this.func(o),this},n(f,[{key:"result",get:function(){return String(this.res)}}]),f})();e.default=l,t.exports=e.default}),de=T((e,t)=>{var n=function(r,u){let s=new r.constructor;for(let i in r){if(!r.hasOwnProperty(i))continue;let l=r[i],f=typeof l;i==="parent"&&f==="object"?u&&(s[i]=u):i==="source"?s[i]=l:l instanceof Array?s[i]=l.map(d=>n(d,s)):i!=="before"&&i!=="after"&&i!=="between"&&i!=="semicolon"&&(f==="object"&&l!==null&&(l=n(l)),s[i]=l)}return s};t.exports=class{constructor(r){r=r||{},this.raws={before:"",after:""};for(let u in r)this[u]=r[u]}remove(){return this.parent&&this.parent.removeChild(this),this.parent=void 0,this}toString(){return[this.raws.before,String(this.value),this.raws.after].join("")}clone(r){r=r||{};let u=n(this);for(let s in r)u[s]=r[s];return u}cloneBefore(r){r=r||{};let u=this.clone(r);return this.parent.insertBefore(this,u),u}cloneAfter(r){r=r||{};let u=this.clone(r);return this.parent.insertAfter(this,u),u}replaceWith(){let r=Array.prototype.slice.call(arguments);if(this.parent){for(let u of r)this.parent.insertBefore(this,u);this.remove()}return this}moveTo(r){return this.cleanRaws(this.root()===r.root()),this.remove(),r.append(this),this}moveBefore(r){return this.cleanRaws(this.root()===r.root()),this.remove(),r.parent.insertBefore(r,this),this}moveAfter(r){return this.cleanRaws(this.root()===r.root()),this.remove(),r.parent.insertAfter(r,this),this}next(){let r=this.parent.index(this);return this.parent.nodes[r+1]}prev(){let r=this.parent.index(this);return this.parent.nodes[r-1]}toJSON(){let r={};for(let u in this){if(!this.hasOwnProperty(u)||u==="parent")continue;let s=this[u];s instanceof Array?r[u]=s.map(i=>typeof i=="object"&&i.toJSON?i.toJSON():i):typeof s=="object"&&s.toJSON?r[u]=s.toJSON():r[u]=s}return r}root(){let r=this;for(;r.parent;)r=r.parent;return r}cleanRaws(r){delete this.raws.before,delete this.raws.after,r||delete this.raws.between}positionInside(r){let u=this.toString(),s=this.source.start.column,i=this.source.start.line;for(let l=0;l<r;l++)u[l]===`
|
|
56
|
-
`?(s=1,i+=1):s+=1;return{line:i,column:s}}positionBy(r){let u=this.source.start;if(Object(r).index)u=this.positionInside(r.index);else if(Object(r).word){let s=this.toString().indexOf(r.word);s!==-1&&(u=this.positionInside(s))}return u}}}),ne=T((e,t)=>{var n=de(),r=class extends n{constructor(u){super(u),this.nodes||(this.nodes=[])}push(u){return u.parent=this,this.nodes.push(u),this}each(u){this.lastEach||(this.lastEach=0),this.indexes||(this.indexes={}),this.lastEach+=1;let s=this.lastEach,i,l;if(this.indexes[s]=0,!!this.nodes){for(;this.indexes[s]<this.nodes.length&&(i=this.indexes[s],l=u(this.nodes[i],i),l!==!1);)this.indexes[s]+=1;return delete this.indexes[s],l}}walk(u){return this.each((s,i)=>{let l=u(s,i);return l!==!1&&s.walk&&(l=s.walk(u)),l})}walkType(u,s){if(!u||!s)throw new Error("Parameters {type} and {callback} are required.");let i=typeof u=="function";return this.walk((l,f)=>{if(i&&l instanceof u||!i&&l.type===u)return s.call(this,l,f)})}append(u){return u.parent=this,this.nodes.push(u),this}prepend(u){return u.parent=this,this.nodes.unshift(u),this}cleanRaws(u){if(super.cleanRaws(u),this.nodes)for(let s of this.nodes)s.cleanRaws(u)}insertAfter(u,s){let i=this.index(u),l;this.nodes.splice(i+1,0,s);for(let f in this.indexes)l=this.indexes[f],i<=l&&(this.indexes[f]=l+this.nodes.length);return this}insertBefore(u,s){let i=this.index(u),l;this.nodes.splice(i,0,s);for(let f in this.indexes)l=this.indexes[f],i<=l&&(this.indexes[f]=l+this.nodes.length);return this}removeChild(u){u=this.index(u),this.nodes[u].parent=void 0,this.nodes.splice(u,1);let s;for(let i in this.indexes)s=this.indexes[i],s>=u&&(this.indexes[i]=s-1);return this}removeAll(){for(let u of this.nodes)u.parent=void 0;return this.nodes=[],this}every(u){return this.nodes.every(u)}some(u){return this.nodes.some(u)}index(u){return typeof u=="number"?u:this.nodes.indexOf(u)}get first(){if(this.nodes)return this.nodes[0]}get last(){if(this.nodes)return this.nodes[this.nodes.length-1]}toString(){let u=this.nodes.map(String).join("");return this.value&&(u=this.value+u),this.raws.before&&(u=this.raws.before+u),this.raws.after&&(u+=this.raws.after),u}};r.registerWalker=u=>{let s="walk"+u.name;s.lastIndexOf("s")!==s.length-1&&(s+="s"),!r.prototype[s]&&(r.prototype[s]=function(i){return this.walkType(u,i)})},t.exports=r}),Jc=T((e,t)=>{var n=ne();t.exports=class extends n{constructor(r){super(r),this.type="root"}}}),Vc=T((e,t)=>{var n=ne();t.exports=class extends n{constructor(r){super(r),this.type="value",this.unbalanced=0}}}),Uc=T((e,t)=>{var n=ne(),r=class extends n{constructor(u){super(u),this.type="atword"}toString(){return this.quoted&&this.raws.quote,[this.raws.before,"@",String.prototype.toString.call(this.value),this.raws.after].join("")}};n.registerWalker(r),t.exports=r}),Hc=T((e,t)=>{var n=ne(),r=de(),u=class extends r{constructor(s){super(s),this.type="colon"}};n.registerWalker(u),t.exports=u}),Gc=T((e,t)=>{var n=ne(),r=de(),u=class extends r{constructor(s){super(s),this.type="comma"}};n.registerWalker(u),t.exports=u}),Kc=T((e,t)=>{var n=ne(),r=de(),u=class extends r{constructor(s){super(s),this.type="comment",this.inline=Object(s).inline||!1}toString(){return[this.raws.before,this.inline?"//":"/*",String(this.value),this.inline?"":"*/",this.raws.after].join("")}};n.registerWalker(u),t.exports=u}),Xc=T((e,t)=>{var n=ne(),r=class extends n{constructor(u){super(u),this.type="func",this.unbalanced=-1}};n.registerWalker(r),t.exports=r}),Qc=T((e,t)=>{var n=ne(),r=de(),u=class extends r{constructor(s){super(s),this.type="number",this.unit=Object(s).unit||""}toString(){return[this.raws.before,String(this.value),this.unit,this.raws.after].join("")}};n.registerWalker(u),t.exports=u}),Yc=T((e,t)=>{var n=ne(),r=de(),u=class extends r{constructor(s){super(s),this.type="operator"}};n.registerWalker(u),t.exports=u}),Zc=T((e,t)=>{var n=ne(),r=de(),u=class extends r{constructor(s){super(s),this.type="paren",this.parenType=""}};n.registerWalker(u),t.exports=u}),ef=T((e,t)=>{var n=ne(),r=de(),u=class extends r{constructor(s){super(s),this.type="string"}toString(){let s=this.quoted?this.raws.quote:"";return[this.raws.before,s,this.value+"",s,this.raws.after].join("")}};n.registerWalker(u),t.exports=u}),tf=T((e,t)=>{var n=ne(),r=de(),u=class extends r{constructor(s){super(s),this.type="word"}};n.registerWalker(u),t.exports=u}),rf=T((e,t)=>{var n=ne(),r=de(),u=class extends r{constructor(s){super(s),this.type="unicode-range"}};n.registerWalker(u),t.exports=u}),nf=T((e,t)=>{var n=class extends Error{constructor(r){super(r),this.name=this.constructor.name,this.message=r||"An error ocurred while tokzenizing.",typeof Error.captureStackTrace=="function"?Error.captureStackTrace(this,this.constructor):this.stack=new Error(r).stack}};t.exports=n}),sf=T((e,t)=>{var n=/[ \n\t\r\{\(\)'"\\;,/]/g,r=/[ \n\t\r\(\)\{\}\*:;@!&'"\+\|~>,\[\]\\]|\/(?=\*)/g,u=/[ \n\t\r\(\)\{\}\*:;@!&'"\-\+\|~>,\[\]\\]|\//g,s=/^[a-z0-9]/i,i=/^[a-f0-9?\-]/i,l=nf();t.exports=function(f,d){d=d||{};let a=[],o=f.valueOf(),p=o.length,c=-1,D=1,h=0,y=0,g=null,m,F,b,v,w,x,C,B,k,O,N;function S(I){let j=`Unclosed ${I} at line: ${D}, column: ${h-c}, token: ${h}`;throw new l(j)}for(;h<p;){switch(m=o.charCodeAt(h),m===10&&(c=h,D+=1),m){case 10:case 32:case 9:case 13:case 12:F=h;do F+=1,m=o.charCodeAt(F),m===10&&(c=F,D+=1);while(m===32||m===10||m===9||m===13||m===12);a.push(["space",o.slice(h,F),D,h-c,D,F-c,h]),h=F-1;break;case 58:F=h+1,a.push(["colon",o.slice(h,F),D,h-c,D,F-c,h]),h=F-1;break;case 44:F=h+1,a.push(["comma",o.slice(h,F),D,h-c,D,F-c,h]),h=F-1;break;case 123:a.push(["{","{",D,h-c,D,F-c,h]);break;case 125:a.push(["}","}",D,h-c,D,F-c,h]);break;case 40:y++,g=!g&&y===1&&a.length>0&&a[a.length-1][0]==="word"&&a[a.length-1][1]==="url",a.push(["(","(",D,h-c,D,F-c,h]);break;case 41:y--,g=g&&y>0,a.push([")",")",D,h-c,D,F-c,h]);break;case 39:case 34:b=m===39?"'":'"',F=h;do for(k=!1,F=o.indexOf(b,F+1),F===-1&&S("quote"),O=F;o.charCodeAt(O-1)===92;)O-=1,k=!k;while(k);a.push(["string",o.slice(h,F+1),D,h-c,D,F-c,h]),h=F;break;case 64:n.lastIndex=h+1,n.test(o),n.lastIndex===0?F=o.length-1:F=n.lastIndex-2,a.push(["atword",o.slice(h,F+1),D,h-c,D,F-c,h]),h=F;break;case 92:F=h,m=o.charCodeAt(F+1),a.push(["word",o.slice(h,F+1),D,h-c,D,F-c,h]),h=F;break;case 43:case 45:case 42:if(F=h+1,N=o.slice(h+1,F+1),o.slice(h-1,h),m===45&&N.charCodeAt(0)===45){F++,a.push(["word",o.slice(h,F),D,h-c,D,F-c,h]),h=F-1;break}a.push(["operator",o.slice(h,F),D,h-c,D,F-c,h]),h=F-1;break;default:if(m===47&&(o.charCodeAt(h+1)===42||d.loose&&!g&&o.charCodeAt(h+1)===47)){if(o.charCodeAt(h+1)===42)F=o.indexOf("*/",h+2)+1,F===0&&S("comment");else{let I=o.indexOf(`
|
|
57
|
-
`,h+2);F=I!==-1?I-1:p}x=o.slice(h,F+1),v=x.split(`
|
|
58
|
-
`),w=v.length-1,w>0?(C=D+w,B=F-v[w].length):(C=D,B=c),a.push(["comment",x,D,h-c,C,F-B,h]),c=B,D=C,h=F}else if(m===35&&!s.test(o.slice(h+1,h+2)))F=h+1,a.push(["#",o.slice(h,F),D,h-c,D,F-c,h]),h=F-1;else if((m===117||m===85)&&o.charCodeAt(h+1)===43){F=h+2;do F+=1,m=o.charCodeAt(F);while(F<p&&i.test(o.slice(F,F+1)));a.push(["unicoderange",o.slice(h,F),D,h-c,D,F-c,h]),h=F-1}else if(m===47)F=h+1,a.push(["operator",o.slice(h,F),D,h-c,D,F-c,h]),h=F-1;else{let I=r;if(m>=48&&m<=57&&(I=u),I.lastIndex=h+1,I.test(o),I.lastIndex===0?F=o.length-1:F=I.lastIndex-2,I===u||m===46){let j=o.charCodeAt(F),$=o.charCodeAt(F+1),z=o.charCodeAt(F+2);(j===101||j===69)&&($===45||$===43)&&z>=48&&z<=57&&(u.lastIndex=F+2,u.test(o),u.lastIndex===0?F=o.length-1:F=u.lastIndex-2)}a.push(["word",o.slice(h,F+1),D,h-c,D,F-c,h]),h=F}break}h++}return a}}),of=T((e,t)=>{var n=class extends Error{constructor(r){super(r),this.name=this.constructor.name,this.message=r||"An error ocurred while parsing.",typeof Error.captureStackTrace=="function"?Error.captureStackTrace(this,this.constructor):this.stack=new Error(r).stack}};t.exports=n}),uf=T((e,t)=>{var n=Jc(),r=Vc(),u=Uc(),s=Hc(),i=Gc(),l=Kc(),f=Xc(),d=Qc(),a=Yc(),o=Zc(),p=ef(),c=tf(),D=rf(),h=sf(),y=po(),g=ho(),m=Do(),F=of();function b(v){return v.sort((w,x)=>w-x)}t.exports=class{constructor(v,w){let x={loose:!1};this.cache=[],this.input=v,this.options=Object.assign({},x,w),this.position=0,this.unbalanced=0,this.root=new n;let C=new r;this.root.append(C),this.current=C,this.tokens=h(v,this.options)}parse(){return this.loop()}colon(){let v=this.currToken;this.newNode(new s({value:v[1],source:{start:{line:v[2],column:v[3]},end:{line:v[4],column:v[5]}},sourceIndex:v[6]})),this.position++}comma(){let v=this.currToken;this.newNode(new i({value:v[1],source:{start:{line:v[2],column:v[3]},end:{line:v[4],column:v[5]}},sourceIndex:v[6]})),this.position++}comment(){let v=!1,w=this.currToken[1].replace(/\/\*|\*\//g,""),x;this.options.loose&&w.startsWith("//")&&(w=w.substring(2),v=!0),x=new l({value:w,inline:v,source:{start:{line:this.currToken[2],column:this.currToken[3]},end:{line:this.currToken[4],column:this.currToken[5]}},sourceIndex:this.currToken[6]}),this.newNode(x),this.position++}error(v,w){throw new F(v+` at line: ${w[2]}, column ${w[3]}`)}loop(){for(;this.position<this.tokens.length;)this.parseTokens();return!this.current.last&&this.spaces?this.current.raws.before+=this.spaces:this.spaces&&(this.current.last.raws.after+=this.spaces),this.spaces="",this.root}operator(){let v=this.currToken[1],w;if(v==="+"||v==="-"){if(this.options.loose||this.position>0&&(this.current.type==="func"&&this.current.value==="calc"?this.prevToken[0]!=="space"&&this.prevToken[0]!=="("?this.error("Syntax Error",this.currToken):this.nextToken[0]!=="space"&&this.nextToken[0]!=="word"?this.error("Syntax Error",this.currToken):this.nextToken[0]==="word"&&this.current.last.type!=="operator"&&this.current.last.value!=="("&&this.error("Syntax Error",this.currToken):(this.nextToken[0]==="space"||this.nextToken[0]==="operator"||this.prevToken[0]==="operator")&&this.error("Syntax Error",this.currToken)),this.options.loose){if((!this.current.nodes.length||this.current.last&&this.current.last.type==="operator")&&this.nextToken[0]==="word")return this.word()}else if(this.nextToken[0]==="word")return this.word()}return w=new a({value:this.currToken[1],source:{start:{line:this.currToken[2],column:this.currToken[3]},end:{line:this.currToken[2],column:this.currToken[3]}},sourceIndex:this.currToken[4]}),this.position++,this.newNode(w)}parseTokens(){switch(this.currToken[0]){case"space":this.space();break;case"colon":this.colon();break;case"comma":this.comma();break;case"comment":this.comment();break;case"(":this.parenOpen();break;case")":this.parenClose();break;case"atword":case"word":this.word();break;case"operator":this.operator();break;case"string":this.string();break;case"unicoderange":this.unicodeRange();break;default:this.word();break}}parenOpen(){let v=1,w=this.position+1,x=this.currToken,C;for(;w<this.tokens.length&&v;){let B=this.tokens[w];B[0]==="("&&v++,B[0]===")"&&v--,w++}if(v&&this.error("Expected closing parenthesis",x),C=this.current.last,C&&C.type==="func"&&C.unbalanced<0&&(C.unbalanced=0,this.current=C),this.current.unbalanced++,this.newNode(new o({value:x[1],source:{start:{line:x[2],column:x[3]},end:{line:x[4],column:x[5]}},sourceIndex:x[6]})),this.position++,this.current.type==="func"&&this.current.unbalanced&&this.current.value==="url"&&this.currToken[0]!=="string"&&this.currToken[0]!==")"&&!this.options.loose){let B=this.nextToken,k=this.currToken[1],O={line:this.currToken[2],column:this.currToken[3]};for(;B&&B[0]!==")"&&this.current.unbalanced;)this.position++,k+=this.currToken[1],B=this.nextToken;this.position!==this.tokens.length-1&&(this.position++,this.newNode(new c({value:k,source:{start:O,end:{line:this.currToken[4],column:this.currToken[5]}},sourceIndex:this.currToken[6]})))}}parenClose(){let v=this.currToken;this.newNode(new o({value:v[1],source:{start:{line:v[2],column:v[3]},end:{line:v[4],column:v[5]}},sourceIndex:v[6]})),this.position++,!(this.position>=this.tokens.length-1&&!this.current.unbalanced)&&(this.current.unbalanced--,this.current.unbalanced<0&&this.error("Expected opening parenthesis",v),!this.current.unbalanced&&this.cache.length&&(this.current=this.cache.pop()))}space(){let v=this.currToken;this.position===this.tokens.length-1||this.nextToken[0]===","||this.nextToken[0]===")"?(this.current.last.raws.after+=v[1],this.position++):(this.spaces=v[1],this.position++)}unicodeRange(){let v=this.currToken;this.newNode(new D({value:v[1],source:{start:{line:v[2],column:v[3]},end:{line:v[4],column:v[5]}},sourceIndex:v[6]})),this.position++}splitWord(){let v=this.nextToken,w=this.currToken[1],x=/^[\+\-]?((\d+(\.\d*)?)|(\.\d+))([eE][\+\-]?\d+)?/,C=/^(?!\#([a-z0-9]+))[\#\{\}]/gi,B,k;if(!C.test(w))for(;v&&v[0]==="word";){this.position++;let O=this.currToken[1];w+=O,v=this.nextToken}B=g(w,"@"),k=b(m(y([[0],B]))),k.forEach((O,N)=>{let S=k[N+1]||w.length,I=w.slice(O,S),j;if(~B.indexOf(O))j=new u({value:I.slice(1),source:{start:{line:this.currToken[2],column:this.currToken[3]+O},end:{line:this.currToken[4],column:this.currToken[3]+(S-1)}},sourceIndex:this.currToken[6]+k[N]});else if(x.test(this.currToken[1])){let $=I.replace(x,"");j=new d({value:I.replace($,""),source:{start:{line:this.currToken[2],column:this.currToken[3]+O},end:{line:this.currToken[4],column:this.currToken[3]+(S-1)}},sourceIndex:this.currToken[6]+k[N],unit:$})}else j=new(v&&v[0]==="("?f:c)({value:I,source:{start:{line:this.currToken[2],column:this.currToken[3]+O},end:{line:this.currToken[4],column:this.currToken[3]+(S-1)}},sourceIndex:this.currToken[6]+k[N]}),j.type==="word"?(j.isHex=/^#(.+)/.test(I),j.isColor=/^#([0-9a-f]{3}|[0-9a-f]{4}|[0-9a-f]{6}|[0-9a-f]{8})$/i.test(I)):this.cache.push(this.current);this.newNode(j)}),this.position++}string(){let v=this.currToken,w=this.currToken[1],x=/^(\"|\')/,C=x.test(w),B="",k;C&&(B=w.match(x)[0],w=w.slice(1,w.length-1)),k=new p({value:w,source:{start:{line:v[2],column:v[3]},end:{line:v[4],column:v[5]}},sourceIndex:v[6],quoted:C}),k.raws.quote=B,this.newNode(k),this.position++}word(){return this.splitWord()}newNode(v){return this.spaces&&(v.raws.before+=this.spaces,this.spaces=""),this.current.append(v)}get currToken(){return this.tokens[this.position]}get nextToken(){return this.tokens[this.position+1]}get prevToken(){return this.tokens[this.position-1]}}}),af={};Zs(af,{languages:()=>yh,options:()=>wh,parsers:()=>Ko,printers:()=>rd});var mo=(e,t)=>(n,r,...u)=>n|1&&r==null?void 0:(t.call(r)??r[e]).apply(r,u),lf=String.prototype.replaceAll??function(e,t){return e.global?this.replace(e,t):this.split(e).join(t)},cf=mo("replaceAll",function(){if(typeof this=="string")return lf}),V=cf;function ff(e){return this[e<0?this.length+e:e]}var pf=mo("at",function(){if(Array.isArray(this)||typeof this=="string")return ff}),Re=pf,hf=()=>{},df=hf,go="string",yo="array",vo="cursor",Zt="indent",an="align",Fo="trim",er="group",tr="fill",rr="if-break",wo="indent-if-break",ln="line-suffix",bo="line-suffix-boundary",st="line",xo="label",cn="break-parent",Co=new Set([vo,Zt,an,Fo,er,tr,rr,wo,ln,bo,st,xo,cn]);function Df(e){if(typeof e=="string")return go;if(Array.isArray(e))return yo;if(!e)return;let{type:t}=e;if(Co.has(t))return t}var Dt=Df,mf=e=>new Intl.ListFormat("en-US",{type:"disjunction"}).format(e);function gf(e){let t=e===null?"null":typeof e;if(t!=="string"&&t!=="object")return`Unexpected doc '${t}',
|
|
59
|
-
Expected it to be 'string' or 'object'.`;if(Dt(e))throw new Error("doc is valid.");let n=Object.prototype.toString.call(e);if(n!=="[object Object]")return`Unexpected doc '${n}'.`;let r=mf([...Co].map(u=>`'${u}'`));return`Unexpected doc.type '${e.type}'.
|
|
60
|
-
Expected it to be ${r}.`}var yf=class extends Error{name="InvalidDocError";constructor(e){super(gf(e)),this.doc=e}},vf=yf;function Ff(e,t){if(typeof e=="string")return t(e);let n=new Map;return r(e);function r(s){if(n.has(s))return n.get(s);let i=u(s);return n.set(s,i),i}function u(s){switch(Dt(s)){case yo:return t(s.map(r));case tr:return t({...s,parts:s.parts.map(r)});case rr:return t({...s,breakContents:r(s.breakContents),flatContents:r(s.flatContents)});case er:{let{expandedStates:i,contents:l}=s;return i?(i=i.map(r),l=i[0]):l=r(l),t({...s,contents:l,expandedStates:i})}case an:case Zt:case wo:case xo:case ln:return t({...s,contents:r(s.contents)});case go:case vo:case Fo:case bo:case st:case cn:return t(s);default:throw new vf(s)}}}function wf(e){return e.type===st&&!e.hard?e.soft?"":" ":e.type===rr?e.flatContents:e}function bf(e){return Ff(e,wf)}var xf=df;function te(e){return{type:Zt,contents:e}}function Cf(e,t){return{type:an,contents:t,n:e}}function yt(e){return Cf(-1,e)}var fn={type:cn};function Mt(e){return{type:tr,parts:e}}function ue(e,t={}){return xf(t.expandedStates),{type:er,id:t.id,contents:e,break:!!t.shouldBreak,expandedStates:t.expandedStates}}function ko(e,t="",n={}){return{type:rr,breakContents:e,flatContents:t,groupId:n.groupId}}function Oe(e,t){let n=[];for(let r=0;r<t.length;r++)r!==0&&n.push(e),n.push(t[r]);return n}var K={type:st},oe={type:st,soft:!0},kf={type:st,hard:!0},U=[kf,fn];function Ef(e){return{type:ln,contents:e}}function Af(e){return Array.isArray(e)&&e.length>0}var nr=Af,Eo=Object.freeze({character:"'",codePoint:39}),Ao=Object.freeze({character:'"',codePoint:34}),Sf=Object.freeze({preferred:Eo,alternate:Ao}),Of=Object.freeze({preferred:Ao,alternate:Eo});function Bf(e,t){let{preferred:n,alternate:r}=t===!0||t==="'"?Sf:Of,{length:u}=e,s=0,i=0;for(let l=0;l<u;l++){let f=e.charCodeAt(l);f===n.codePoint?s++:f===r.codePoint&&i++}return(s>i?r:n).character}var Tf=Bf,$f=/\\(["'\\])|(["'])/gu;function _f(e,t){let n=t==='"'?"'":'"',r=V(0,e,$f,(u,s,i)=>s?s===n?n:u:i===t?"\\"+i:i);return t+r+t}var If=_f;function jf(e,t){let n=e.slice(1,-1),r=t.parser==="json"||t.parser==="jsonc"||t.parser==="json5"&&t.quoteProps==="preserve"&&!t.singleQuote?'"':t.__isInHtmlAttribute?"'":Tf(n,t.singleQuote);return e.charAt(0)===r?e:If(n,r)}var So=jf,Nf=class extends Error{name="UnexpectedNodeError";constructor(e,t,n="type"){super(`Unexpected ${t} node ${n}: ${JSON.stringify(e[n])}.`),this.node=e}},Pf=Nf,Oo=Symbol.for("PRETTIER_IS_FRONT_MATTER");function Lf(e){return!!e?.[Oo]}var xr=Lf,it=3;function Mf(e){let t=e.slice(0,it);if(t!=="---"&&t!=="+++")return;let n=e.indexOf(`
|
|
61
|
-
`,it);if(n===-1)return;let r=e.slice(it,n).trim(),u=e.indexOf(`
|
|
62
|
-
${t}`,n),s=r;if(s||(s=t==="+++"?"toml":"yaml"),u===-1&&t==="---"&&s==="yaml"&&(u=e.indexOf(`
|
|
63
|
-
...`,n)),u===-1)return;let i=u+1+it,l=e.charAt(i+1);if(!/\s?/u.test(l))return;let f=e.slice(0,i),d;return{language:s,explicitLanguage:r||null,value:e.slice(n+1,u),startDelimiter:t,endDelimiter:f.slice(-it),raw:f,start:{line:1,column:0,index:0},end:{index:f.length,get line(){return d??(d=f.split(`
|
|
64
|
-
`)),d.length},get column(){return d??(d=f.split(`
|
|
65
|
-
`)),Re(0,d,-1).length}},[Oo]:!0}}function Rf(e){let t=Mf(e);return t?{frontMatter:t,get content(){let{raw:n}=t;return V(0,n,/[^\n]/gu," ")+e.slice(n.length)}}:{content:e}}var sr=Rf,Wf=new Set(["raw","raws","sourceIndex","source","before","after","trailingComma","spaces"]);function Bo(e,t,n){if(e.type==="css-comment"&&n.type==="css-root"&&n.nodes.length>0&&((n.nodes[0]===e||xr(n.nodes[0])&&n.nodes[1]===e)&&(delete t.text,/^\*\s*@(?:format|prettier)\s*$/u.test(e.text))||n.type==="css-root"&&Re(0,n.nodes,-1)===e))return null;if(e.type==="value-root"&&delete t.text,(e.type==="media-query"||e.type==="media-query-list"||e.type==="media-feature-expression")&&delete t.value,e.type==="css-rule"&&delete t.params,(e.type==="media-feature"||e.type==="media-keyword"||e.type==="media-type"||e.type==="media-unknown"||e.type==="media-url"||e.type==="media-value"||e.type==="selector-attribute"||e.type==="selector-string"||e.type==="selector-class"||e.type==="selector-combinator"||e.type==="value-string")&&e.value&&(t.value=zf(e.value)),e.type==="selector-combinator"&&(t.value=V(0,t.value,/\s+/gu," ")),e.type==="media-feature"&&(t.value=V(0,t.value," ","")),(e.type==="value-word"&&(e.isColor&&e.isHex||["initial","inherit","unset","revert"].includes(e.value.toLowerCase()))||e.type==="media-feature"||e.type==="selector-root-invalid"||e.type==="selector-pseudo")&&(t.value=t.value.toLowerCase()),e.type==="css-decl"&&(t.prop=e.prop.toLowerCase()),(e.type==="css-atrule"||e.type==="css-import")&&(t.name=e.name.toLowerCase()),e.type==="value-number"&&(t.unit=e.unit.toLowerCase()),e.type==="value-unknown"&&(t.value=V(0,t.value,/;$/gu,"")),e.type==="selector-attribute"&&(t.attribute=e.attribute.trim(),e.namespace&&typeof e.namespace=="string"&&(t.namespace=e.namespace.trim()||!0),e.value)){let{value:r}=t;/\s[a-zA-Z]$/u.test(r)&&(t.__prettier_attribute_selector_flag=Re(0,r,-1),r=r.slice(0,-1)),r=r.trim(),r=r.replace(/^(?<quote>["'])(?<value>.*?)\k<quote>$/u,"$<value>"),t.value=r,delete t.quoted}if((e.type==="media-value"||e.type==="media-type"||e.type==="value-number"||e.type==="selector-root-invalid"||e.type==="selector-class"||e.type==="selector-combinator"||e.type==="selector-tag")&&e.value&&(t.value=V(0,t.value,/([\d+.e-]+)([a-z]*)/giu,(r,u,s)=>{let i=Number(u);return Number.isNaN(i)?r:i+s.toLowerCase()})),e.type==="selector-tag"){let r=t.value.toLowerCase();["from","to"].includes(r)&&(t.value=r)}if(e.type==="css-atrule"&&e.name.toLowerCase()==="supports"&&delete t.value,e.type==="selector-unknown"&&delete t.value,e.type==="value-comma_group"){let r=e.groups.findIndex(u=>u.type==="value-number"&&u.unit==="...");r!==-1&&(t.groups[r].unit="",t.groups.splice(r+1,0,{type:"value-word",value:"...",isColor:!1,isHex:!1}))}if(e.type==="value-comma_group"&&e.groups.some(r=>r.type==="value-atword"&&(r.value.endsWith("[")||r.value.endsWith("]"))||r.type==="value-word"&&(r.value.startsWith("]")||r.value.startsWith("["))))return{type:"value-atword",value:e.groups.map(r=>r.value).join(""),group:{open:null,close:null,groups:[],type:"value-paren_group"}}}Bo.ignoredProperties=Wf;function zf(e){return V(0,V(0,e,"'",'"'),/\\([^\da-f])/giu,"$1")}var qf=Bo;function To(){}To.getVisitorKeys=e=>e.type==="css-root"?["frontMatter"]:[];var Jf=To,at=null;function mt(e){if(at!==null&&typeof at.property){let t=at;return at=mt.prototype=null,t}return at=mt.prototype=e??Object.create(null),new mt}var Vf=10;for(let e=0;e<=Vf;e++)mt();function Uf(e){return mt(e)}function Hf(e,t="type"){Uf(e);function n(r){let u=r[t],s=e[u];if(!Array.isArray(s))throw Object.assign(new Error(`Missing visitor keys for '${u}'.`),{node:r});return s}return n}var Gf=Hf,P=[[],["nodes"],["group"]],Kf={"css-root":["frontMatter","nodes"],"css-comment":P[0],"css-rule":["selector","nodes"],"css-decl":["value","selector","nodes"],"css-atrule":["selector","params","value","nodes"],"media-query-list":P[1],"media-query":P[1],"media-type":P[0],"media-feature-expression":P[1],"media-feature":P[0],"media-colon":P[0],"media-value":P[0],"media-keyword":P[0],"media-url":P[0],"media-unknown":P[0],"selector-root":P[1],"selector-selector":P[1],"selector-comment":P[0],"selector-string":P[0],"selector-tag":P[0],"selector-id":P[0],"selector-class":P[0],"selector-attribute":P[0],"selector-combinator":P[1],"selector-universal":P[0],"selector-pseudo":P[1],"selector-nesting":P[0],"selector-unknown":P[0],"value-value":P[2],"value-root":P[2],"value-comment":P[0],"value-comma_group":["groups"],"value-paren_group":["open","groups","close"],"value-func":P[2],"value-paren":P[0],"value-number":P[0],"value-operator":P[0],"value-word":P[0],"value-colon":P[0],"value-comma":P[0],"value-string":P[0],"value-atword":P[0],"value-unicode-range":P[0],"value-unknown":P[0]},Xf=Gf(Kf),Qf=Xf;function Yf(e,t){let n=0;for(let r=0;r<e.line-1;++r)n=t.indexOf(`
|
|
66
|
-
`,n)+1;return n+e.column}var $o=Yf;function pn(e){return(t,n,r)=>{let u=!!r?.backwards;if(n===!1)return!1;let{length:s}=t,i=n;for(;i>=0&&i<s;){let l=t.charAt(i);if(e instanceof RegExp){if(!e.test(l))return i}else if(!e.includes(l))return i;u?i--:i++}return i===-1||i===s?i:!1}}var _o=pn(" "),Zf=pn(",; "),Io=pn(/[^\n\r]/u);function jo(e,t){let{value:n}=e;return n==="-"||n==="--"||n.charAt(0)!=="-"?t:t-(n.charAt(1)==="-"?2:1)}function No(e,t){if(typeof e.source?.start?.offset=="number")return e.source.start.offset;if(typeof e.sourceIndex=="number")return e.type==="value-word"?jo(e,e.sourceIndex):e.sourceIndex;if(e.source?.start)return $o(e.source.start,t);throw Object.assign(new Error("Can not locate node."),{node:e})}function hn(e,t){if(e.type==="css-comment"&&e.inline)return Io(t,e.source.startOffset);if(typeof e.source?.end?.offset=="number")return e.source.end.offset;if(e.source){if(e.source.end){let n=$o(e.source.end,t);return e.type==="value-word"?jo(e,n):n}if(nr(e.nodes))return hn(Re(0,e.nodes,-1),t)}return null}function Po(e,t){e.source&&(e.source.startOffset=No(e,t),e.source.endOffset=hn(e,t));for(let n in e){let r=e[n];n==="source"||!r||typeof r!="object"||(r.type==="value-root"||r.type==="value-unknown"?Lo(r,ep(e),r.text||r.value):Po(r,t))}}function Lo(e,t,n){e.source&&(e.source.startOffset=No(e,n)+t,e.source.endOffset=hn(e,n)+t);for(let r in e){let u=e[r];r==="source"||!u||typeof u!="object"||Lo(u,t,n)}}function ep(e){let t=e.source.startOffset;return typeof e.prop=="string"&&(t+=e.prop.length),e.type==="css-atrule"&&typeof e.name=="string"&&(t+=1+e.name.length+e.raws.afterName.match(/^\s*:?\s*/u)[0].length),e.type!=="css-atrule"&&typeof e.raws?.between=="string"&&(t+=e.raws.between.length),t}function tp(e){let t="initial",n="initial",r,u=!1,s=[];for(let i=0;i<e.length;i++){let l=e[i];switch(t){case"initial":if(l==="'"){t="single-quotes";continue}if(l==='"'){t="double-quotes";continue}if((l==="u"||l==="U")&&e.slice(i,i+4).toLowerCase()==="url("){t="url",i+=3;continue}if(l==="*"&&e[i-1]==="/"){t="comment-block";continue}if(l==="/"&&e[i-1]==="/"){t="comment-inline",r=i-1;continue}continue;case"single-quotes":if(l==="'"&&e[i-1]!=="\\"&&(t=n,n="initial"),l===`
|
|
67
|
-
`||l==="\r")return e;continue;case"double-quotes":if(l==='"'&&e[i-1]!=="\\"&&(t=n,n="initial"),l===`
|
|
68
|
-
`||l==="\r")return e;continue;case"url":if(l===")"&&(t="initial"),l===`
|
|
69
|
-
`||l==="\r")return e;if(l==="'"){t="single-quotes",n="url";continue}if(l==='"'){t="double-quotes",n="url";continue}continue;case"comment-block":l==="/"&&e[i-1]==="*"&&(t="initial");continue;case"comment-inline":(l==='"'||l==="'"||l==="*")&&(u=!0),(l===`
|
|
70
|
-
`||l==="\r")&&(u&&s.push([r,i]),t="initial",u=!1);continue}}for(let[i,l]of s)e=e.slice(0,i)+V(0,e.slice(i,l),/["'*]/gu," ")+e.slice(l);return e}var Q=e=>e.source?.startOffset,Y=e=>e.source?.endOffset,rp=/\*\/$/,np=/^\/\*\*?/,Mo=/^\s*(\/\*\*?(.|\r?\n)*?\*\/)/,sp=/(^|\s+)\/\/([^\n\r]*)/g,Vn=/^(\r?\n)+/,op=/(?:^|\r?\n) *(@[^\n\r]*?) *\r?\n *(?![^\n\r@]*\/\/[^]*)([^\s@][^\n\r@]+?) *\r?\n/g,Un=/(?:^|\r?\n) *@(\S+) *([^\n\r]*)/g,up=/(\r?\n|^) *\* ?/g,Ro=[];function ip(e){let t=e.match(Mo);return t?t[0].trimStart():""}function ap(e){let t=e.match(Mo)?.[0];return t==null?e:e.slice(t.length)}function lp(e){e=V(0,e.replace(np,"").replace(rp,""),up,"$1");let t="";for(;t!==e;)t=e,e=V(0,e,op,`
|
|
71
|
-
$1 $2
|
|
72
|
-
`);e=e.replace(Vn,"").trimEnd();let n=Object.create(null),r=V(0,e,Un,"").replace(Vn,"").trimEnd(),u;for(;u=Un.exec(e);){let s=V(0,u[2],sp,"");if(typeof n[u[1]]=="string"||Array.isArray(n[u[1]])){let i=n[u[1]];n[u[1]]=[...Ro,...Array.isArray(i)?i:[i],s]}else n[u[1]]=s}return{comments:r,pragmas:n}}function cp({comments:e="",pragmas:t={}}){let n=Object.keys(t),r=n.flatMap(s=>Hn(s,t[s])).map(s=>` * ${s}
|
|
73
|
-
`).join("");if(!e){if(n.length===0)return"";if(n.length===1&&!Array.isArray(t[n[0]])){let s=t[n[0]];return`/** ${Hn(n[0],s)[0]} */`}}let u=e.split(`
|
|
74
|
-
`).map(s=>` * ${s}`).join(`
|
|
75
|
-
`)+`
|
|
76
|
-
`;return`/**
|
|
77
|
-
`+(e?u:"")+(e&&n.length>0?` *
|
|
78
|
-
`:"")+r+" */"}function Hn(e,t){return[...Ro,...Array.isArray(t)?t:[t]].map(n=>`@${e} ${n}`.trim())}var fp=["noformat","noprettier"],pp=["format","prettier"],hp="format";function dp(e){if(!e.startsWith("#!"))return"";let t=e.indexOf(`
|
|
79
|
-
`);return t===-1?e:e.slice(0,t)}var Dp=dp;function dn(e){let t=Dp(e);t&&(e=e.slice(t.length+1));let n=ip(e),{pragmas:r,comments:u}=lp(n);return{shebang:t,text:e,pragmas:r,comments:u}}function mp(e){let{pragmas:t}=dn(e);return pp.some(n=>Object.prototype.hasOwnProperty.call(t,n))}function gp(e){let{pragmas:t}=dn(e);return fp.some(n=>Object.prototype.hasOwnProperty.call(t,n))}function yp(e){let{shebang:t,text:n,pragmas:r,comments:u}=dn(e),s=ap(n),i=cp({pragmas:{[hp]:"",...r},comments:u.trimStart()});return(t?`${t}
|
|
80
|
-
`:"")+i+(s.startsWith(`
|
|
81
|
-
`)?`
|
|
82
|
-
`:`
|
|
83
|
-
|
|
84
|
-
`)+s}var vp=e=>mp(sr(e).content),Fp=e=>gp(sr(e).content),wp=e=>{let{frontMatter:t,content:n}=sr(e);return(t?t.raw+`
|
|
85
|
-
|
|
86
|
-
`:"")+yp(n)},bp=new Set(["red","green","blue","alpha","a","rgb","hue","h","saturation","s","lightness","l","whiteness","w","blackness","b","tint","shade","blend","blenda","contrast","hsl","hsla","hwb","hwba"]);function xp(e){return e.findAncestor(t=>t.type==="css-decl")?.prop?.toLowerCase()}var Cp=new Set(["initial","inherit","unset","revert"]);function kp(e){return Cp.has(e.toLowerCase())}function Ep(e,t){return e.findAncestor(n=>n.type==="css-atrule")?.name?.toLowerCase().endsWith("keyframes")&&["from","to"].includes(t.toLowerCase())}function lt(e){return e.includes("$")||e.includes("@")||e.includes("#")||e.startsWith("%")||e.startsWith("--")||e.startsWith(":--")||e.includes("(")&&e.includes(")")?e:e.toLowerCase()}function Rt(e,t){return e.findAncestor(n=>n.type==="value-func")?.value?.toLowerCase()===t}function Ap(e){return e.hasAncestor(t=>{if(t.type!=="css-rule")return!1;let n=t.raws?.selector;return n&&(n.startsWith(":import")||n.startsWith(":export"))})}function gt(e,t){let n=Array.isArray(t)?t:[t],r=e.findAncestor(u=>u.type==="css-atrule");return r&&n.includes(r.name.toLowerCase())}function Sp(e){let{node:t}=e;return t.groups[0]?.value==="url"&&t.groups.length===2&&e.findAncestor(n=>n.type==="css-atrule")?.name==="import"}function Op(e){return e.type==="value-func"&&e.value.toLowerCase()==="url"}function Bp(e){return e.type==="value-func"&&e.value.toLowerCase()==="var"}function Tp(e){let{selector:t}=e;return t?typeof t=="string"&&/^@.+:.*$/u.test(t)||t.value&&/^@.+:.*$/u.test(t.value):!1}function $p(e){return e.type==="value-word"&&["from","through","end"].includes(e.value)}function _p(e){return e.type==="value-word"&&["and","or","not"].includes(e.value)}function Ip(e){return e.type==="value-word"&&e.value==="in"}function Cr(e){return e.type==="value-operator"&&e.value==="*"}function Xe(e){return e?.type==="value-operator"&&e.value==="/"}function Se(e){return e.type==="value-operator"&&e.value==="+"}function Qe(e){return e.type==="value-operator"&&e.value==="-"}function jp(e){return e.type==="value-operator"&&e.value==="%"}function dr(e){return Cr(e)||Xe(e)||Se(e)||Qe(e)||jp(e)}function Np(e){return e.type==="value-word"&&["==","!="].includes(e.value)}function Pp(e){return e.type==="value-word"&&["<",">","<=",">="].includes(e.value)}function kr(e,t){return t.parser==="scss"&&e.type==="css-atrule"&&["if","else","for","each","while"].includes(e.name)}function Gn(e){return e.raws?.params&&/^\(\s*\)$/u.test(e.raws.params)}function Dr(e){return e.name.startsWith("prettier-placeholder")}function Lp(e){return e.prop.startsWith("@prettier-placeholder")}function Mp(e,t){return e.value==="$$"&&e.type==="value-func"&&t?.type==="value-word"&&!t.raws.before}function Rp(e){return e.value?.type==="value-root"&&e.value.group?.type==="value-value"&&e.prop.toLowerCase()==="composes"}function Wp(e){return e.value?.group?.group?.type==="value-paren_group"&&e.value.group.group.open!==null&&e.value.group.group.close!==null}function Ae(e){return e?.raws?.before===""}function Dn(e){return e.type==="value-comma_group"&&e.groups?.[1]?.type==="value-colon"}function mr(e){return e.type==="value-paren_group"&&e.groups?.[0]&&Dn(e.groups[0])}function Wo(e,t){if(t.parser!=="scss")return!1;let{node:n}=e;if(n.groups.length===0)return!1;let r=e.grandparent;return!mr(n)&&!(r&&mr(r))?!1:!!(e.findAncestor(u=>u.type==="css-decl")?.prop?.startsWith("$")||mr(r)||r.type==="value-func")}function _t(e){return e.type==="value-comment"&&e.inline}function gr(e){return e.type==="value-word"&&e.value==="#"}function Kn(e){return e.type==="value-word"&&e.value==="{"}function yr(e){return e.type==="value-word"&&e.value==="}"}function It(e){return["value-word","value-atword"].includes(e.type)}function Er(e){return e?.type==="value-colon"}function zp(e,t){if(!Dn(t))return!1;let{groups:n}=t,r=n.indexOf(e);return r===-1?!1:Er(n[r+1])}function qp(e){return e.value&&["not","and","or"].includes(e.value.toLowerCase())}function Jp(e){return e.type!=="value-func"?!1:bp.has(e.value.toLowerCase())}function ct(e){return/\/\//u.test(e.split(/[\n\r]/u).pop())}function jt(e){return e?.type==="value-atword"&&e.value.startsWith("prettier-placeholder-")}function Vp(e,t){if(e.open?.value!=="("||e.close?.value!==")"||e.groups.some(n=>n.type!=="value-comma_group"))return!1;if(t.type==="value-comma_group"){let n=t.groups.indexOf(e)-1,r=t.groups[n];if(r?.type==="value-word"&&r.value==="with")return!0}return!1}function Nt(e){return e.type==="value-paren_group"&&e.open?.value==="("&&e.close?.value===")"}function Up(e,t,n){let{node:r}=e,u=e.parent,s=e.grandparent,i=xp(e),l=i&&u.type==="value-value"&&(i==="grid"||i.startsWith("grid-template")),f=e.findAncestor(y=>y.type==="css-atrule"),d=f&&kr(f,t),a=r.groups.some(y=>_t(y)),o=e.map(n,"groups"),p=[""],c=Rt(e,"url"),D=!1,h=!1;for(let y=0;y<r.groups.length;++y){let g=r.groups[y-1],m=r.groups[y],F=r.groups[y+1],b=r.groups[y+2];if(_t(m)&&!F){p.push([p.pop(),Ef([" ",o[y]])]);continue}if(p.push([p.pop(),o[y]]),c){(F&&Se(F)||Se(m))&&p.push([p.pop()," "]);continue}if(gt(e,"forward")&&m.type==="value-word"&&m.value&&g!==void 0&&g.type==="value-word"&&g.value==="as"&&F.type==="value-operator"&&F.value==="*"||gt(e,"utility")&&m.type==="value-word"&&F&&F.type==="value-operator"&&F.value==="*"||!F||m.type==="value-word"&&jt(F)&&Y(m)===Q(F))continue;if(m.type==="value-string"&&m.quoted){let k=m.value.lastIndexOf("#{"),O=m.value.lastIndexOf("}");k!==-1&&O!==-1?D=k>O:k!==-1?D=!0:O!==-1&&(D=!1)}if(D||Er(m)||Er(F)||m.type==="value-atword"&&(m.value===""||m.value.endsWith("["))||F.type==="value-word"&&F.value.startsWith("]")||m.value==="~"||t.parser==="less"&&(F?.type==="value-word"&&F.value==="["||m.type==="value-word"&&m.value==="["&&(F?.type==="value-atword"||F?.type==="value-word")||m.type==="value-word"&&m.value==="]["&&F?.type==="value-word")||m.type!=="value-string"&&m.value&&m.value.includes("\\")&&F&&F.type!=="value-comment"||g?.value&&g.value.indexOf("\\")===g.value.length-1&&m.type==="value-operator"&&m.value==="/"||m.value==="\\"||Mp(m,F)||gr(m)||Kn(m)||yr(F)||Kn(F)&&Ae(F)||yr(m)&&Ae(F)||m.value==="--"&&gr(F))continue;let v=dr(m),w=dr(F);if((v&&gr(F)||w&&yr(m))&&Ae(F)||!g&&Xe(m)||Rt(e,"calc")&&(Se(m)||Se(F)||Qe(m)||Qe(F))&&Ae(F))continue;let x=(Se(m)||Qe(m))&&y===0&&(F.type==="value-number"||F.isHex)&&s&&Jp(s)&&!Ae(F);if(t.parser==="scss"&&v&&m.value==="-"&&F.type==="value-func"&&Y(m)!==Q(F)){p.push([p.pop()," "]);continue}let C=b?.type==="value-func"||b&&It(b)||m.type==="value-func"||It(m),B=F.type==="value-func"||It(F)||g?.type==="value-func"||g&&It(g);if(!(!(Cr(F)||Cr(m))&&!Rt(e,"calc")&&!x&&(Xe(F)&&!C||Xe(m)&&!B||Se(F)&&!C||Se(m)&&!B||Qe(F)||Qe(m))&&(Ae(F)||v&&(!g||g&&dr(g))))&&!((t.parser==="scss"||t.parser==="less")&&v&&m.value==="-"&&Nt(F)&&Y(m)===Q(F.open)&&F.open.value==="(")){if(_t(m)){if(u.type==="value-paren_group"){p.push(yt(U),"");continue}p.push(U,"");continue}if(d&&(Np(F)||Pp(F)||_p(F)||Ip(m)||$p(m))){p.push([p.pop()," "]);continue}if(f&&f.name.toLowerCase()==="namespace"){p.push([p.pop()," "]);continue}if(l){m.source&&F.source&&m.source.start.line!==F.source.start.line?(p.push(U,""),h=!0):p.push([p.pop()," "]);continue}if(!(i&&(i==="font"||i.startsWith("--"))&&(Xe(F)&&Ae(F)&&Xn(m)||Xe(m)&&Ae(m)&&Xn(g)))){if(w){p.push([p.pop()," "]);continue}if(F?.value!=="..."&&!(jt(m)&&jt(F)&&Y(m)===Q(F))){if(jt(m)&&Nt(F)&&Y(m)===Q(F.open)){p.push(oe,"");continue}if(m.value==="with"&&Nt(F)){p=[[Mt(p)," "]];continue}if(!(m.value?.endsWith("#")&&F.value==="{"&&Nt(F.group))&&!(_t(F)&&!b)){if(!f&&m.type==="value-comment"&&!m.inline&&r.groups.slice(0,y).every(k=>k.type==="value-comment")){p.push(yt(K),"");continue}p.push(K,"")}}}}}return a&&p.push([p.pop(),fn]),h&&p.unshift("",U),d?ue(te(p)):Sp(e)?ue(Mt(p)):ue(te(Mt(p)))}function Xn(e){if(e?.type==="value-number")return!0;if(e?.type!=="value-func")return!1;let t=e.value.toLowerCase();return t==="var"||t==="calc"||t==="min"||t==="max"||t==="clamp"||t.startsWith("--")}var Hp=Up;function Gp(e){return e.length===1?e:e.toLowerCase().replace(/^([+-]?[\d.]+e)(?:\+|(-))?0*(?=\d)/u,"$1$2").replace(/^([+-]?[\d.]+)e[+-]?0+$/u,"$1").replace(/^([+-])?\./u,"$10.").replace(/(\.\d+?)0+(?=e|$)/u,"$1").replace(/\.(?=e|$)/u,"")}var Kp=Gp,Ar=new Map([["em","em"],["rem","rem"],["ex","ex"],["rex","rex"],["cap","cap"],["rcap","rcap"],["ch","ch"],["rch","rch"],["ic","ic"],["ric","ric"],["lh","lh"],["rlh","rlh"],["vw","vw"],["svw","svw"],["lvw","lvw"],["dvw","dvw"],["vh","vh"],["svh","svh"],["lvh","lvh"],["dvh","dvh"],["vi","vi"],["svi","svi"],["lvi","lvi"],["dvi","dvi"],["vb","vb"],["svb","svb"],["lvb","lvb"],["dvb","dvb"],["vmin","vmin"],["svmin","svmin"],["lvmin","lvmin"],["dvmin","dvmin"],["vmax","vmax"],["svmax","svmax"],["lvmax","lvmax"],["dvmax","dvmax"],["cm","cm"],["mm","mm"],["q","Q"],["in","in"],["pt","pt"],["pc","pc"],["px","px"],["deg","deg"],["grad","grad"],["rad","rad"],["turn","turn"],["s","s"],["ms","ms"],["hz","Hz"],["khz","kHz"],["dpi","dpi"],["dpcm","dpcm"],["dppx","dppx"],["x","x"],["cqw","cqw"],["cqh","cqh"],["cqi","cqi"],["cqb","cqb"],["cqmin","cqmin"],["cqmax","cqmax"],["fr","fr"]]);function zo(e){let t=e.toLowerCase();return Ar.has(t)?Ar.get(t):e}var qo=/(["'])(?:(?!\1)[^\\]|\\.)*\1/gsu,Xp=/(?:\d*\.\d+|\d+\.?)(?:e[+-]?\d+)?/giu,Qp=/[a-z]+/giu,Yp=/[$@]?[_a-z\u0080-\uFFFF][\w\u0080-\uFFFF-]*/giu,Zp=new RegExp(qo.source+`|(${Yp.source})?(${Xp.source})(${Qp.source})?`,"giu");function le(e,t){return V(0,e,qo,n=>So(n,t))}function eh(e,t){let n=t.singleQuote?"'":'"',r="",u=e.match(/^(?<value>.+?)\s+(?<flag>[a-zA-Z])$/u);return u&&({value:e,flag:r}=u.groups),(e.includes('"')||e.includes("'")?e:n+e+n)+(r?` ${r}`:"")}function Ke(e){return V(0,e,Zp,(t,n,r,u,s)=>!r&&u&&(s??(s=""),s=s.toLowerCase(),!s||s==="n"||Ar.has(s))?Jo(u)+(s?zo(s):""):t)}function Jo(e){return Kp(e).replace(/\.0(?=$|e)/u,"")}function th(e){return e.trailingComma==="es5"||e.trailingComma==="all"}var Qn=e=>e===`
|
|
87
|
-
`||e==="\r"||e==="\u2028"||e==="\u2029";function rh(e,t,n){let r=!!n?.backwards;if(t===!1)return!1;let u=e.charAt(t);if(r){if(e.charAt(t-1)==="\r"&&u===`
|
|
88
|
-
`)return t-2;if(Qn(u))return t-1}else{if(u==="\r"&&e.charAt(t+1)===`
|
|
89
|
-
`)return t+2;if(Qn(u))return t+1}return t}var Vo=rh;function nh(e,t,n={}){let r=_o(e,n.backwards?t-1:t,n),u=Vo(e,r,n);return r!==u}var Uo=nh;function sh(e,t){if(t===!1)return!1;if(e.charAt(t)==="/"&&e.charAt(t+1)==="*"){for(let n=t+2;n<e.length;++n)if(e.charAt(n)==="*"&&e.charAt(n+1)==="/")return n+2}return t}var oh=sh;function uh(e,t){return t===!1?!1:e.charAt(t)==="/"&&e.charAt(t+1)==="/"?Io(e,t):t}var ih=uh;function ah(e,t){let n=null,r=t;for(;r!==n;)n=r,r=Zf(e,r),r=oh(e,r),r=_o(e,r);return r=ih(e,r),r=Vo(e,r),r!==!1&&Uo(e,r)}var Ho=ah;function lh({node:e,parent:t},n){return!!(e.source&&n.originalText.slice(Q(e),Q(t.close)).trimEnd().endsWith(","))}function ch(e,t){return Bp(e.grandparent)&&lh(e,t)?",":e.node.type!=="value-comment"&&!(e.node.type==="value-comma_group"&&e.node.groups.every(n=>n.type==="value-comment"))&&th(t)&&e.callParent(()=>Wo(e,t))?ko(","):""}function fh(e,t,n){let{node:r,parent:u}=e,s=e.map(({node:c})=>typeof c=="string"?c:n(),"groups");if(u&&Op(u)&&(r.groups.length===1||r.groups.length>0&&r.groups[0].type==="value-comma_group"&&r.groups[0].groups.length>0&&r.groups[0].groups[0].type==="value-word"&&r.groups[0].groups[0].value.startsWith("data:")))return[r.open?n("open"):"",Oe(",",s),r.close?n("close"):""];if(!r.open){let c=Go(e),D=hh(Oe(",",s),2),h=Oe(c?U:K,D);return te(c?[U,h]:ue([ph(e)?oe:"",Mt(h)]))}let i=e.map(({node:c,isLast:D,index:h})=>{let y=s[h];Dn(c)&&c.type==="value-comma_group"&&c.groups&&c.groups[0].type!=="value-paren_group"&&c.groups[2]?.type==="value-paren_group"&&Dt(y)===er&&Dt(y.contents)===Zt&&Dt(y.contents.contents)===tr&&(y=ue(yt(y)));let g=[y,D?ch(e,t):","];if(!D&&c.type==="value-comma_group"&&nr(c.groups)){let m=Re(0,c.groups,-1);!m.source&&m.close&&(m=m.close),m.source&&Ho(t.originalText,Y(m))&&g.push(U)}return g},"groups"),l=zp(r,u),f=Vp(r,u),d=Wo(e,t),a=f||d&&!l,o=f||l,p=ue([r.open?n("open"):"",te([oe,Oe(K,i)]),oe,r.close?n("close"):""],{shouldBreak:a});return o?yt(p):p}function Go(e){return e.match(t=>t.type==="value-paren_group"&&!t.open&&t.groups.some(n=>n.type==="value-comma_group"),(t,n)=>n==="group"&&t.type==="value-value",(t,n)=>n==="group"&&t.type==="value-root",(t,n)=>n==="value"&&(t.type==="css-decl"&&!t.prop.startsWith("--")||t.type==="css-atrule"&&t.variable))}function ph(e){return e.match(t=>t.type==="value-paren_group"&&!t.open,(t,n)=>n==="group"&&t.type==="value-value",(t,n)=>n==="group"&&t.type==="value-root",(t,n)=>n==="value"&&t.type==="css-decl")}function hh(e,t){let n=[];for(let r=0;r<e.length;r+=t)n.push(e.slice(r,r+t));return n}function dh(e,t,n){let r=[];return e.each(()=>{let{node:u,previous:s}=e;if(s?.type==="css-comment"&&s.text.trim()==="prettier-ignore"?r.push(t.originalText.slice(Q(u),Y(u))):r.push(n()),e.isLast)return;let{next:i}=e;i.type==="css-comment"&&!Uo(t.originalText,Q(i),{backwards:!0})&&!xr(u)||i.type==="css-atrule"&&i.name==="else"&&u.type!=="css-comment"?r.push(" "):(r.push(t.__isHTMLStyleAttribute?K:U),Ho(t.originalText,Y(u))&&!xr(u)&&r.push(U))},"nodes"),r}var ft=dh;function Dh(e,t,n){let{node:r}=e;switch(r.type){case"css-root":{let u=ft(e,t,n),s=r.raws.after.trim();return s.startsWith(";")&&(s=s.slice(1).trim()),[r.frontMatter?[n("frontMatter"),U,r.nodes.length>0?U:""]:"",u,s?` ${s}`:"",r.nodes.length>0?U:""]}case"css-comment":{let u=r.inline||r.raws.inline,s=t.originalText.slice(Q(r),Y(r));return u?s.trimEnd():s}case"css-rule":return[n("selector"),r.important?" !important":"",r.nodes?[r.selector?.type==="selector-unknown"&&ct(r.selector.value)?K:r.selector?" ":"","{",r.nodes.length>0?te([U,ft(e,t,n)]):"",U,"}",Tp(r)?";":""]:";"];case"css-decl":{let u=e.parent,{between:s}=r.raws,i=s.trim(),l=i===":",f=typeof r.value=="string"&&/^ *$/u.test(r.value),d=typeof r.value=="string"?r.value:n("value");return d=Rp(r)?bf(d):d,!l&&ct(i)&&!e.call(()=>Go(e),"value","group","group")&&(d=te([U,yt(d)])),[V(0,r.raws.before,/[\s;]/gu,""),u.type==="css-atrule"&&u.variable||Ap(e)?r.prop:lt(r.prop),i.startsWith("//")?" ":"",i,r.extend||f?"":" ",t.parser==="less"&&r.extend&&r.selector?["extend(",n("selector"),")"]:"",d,r.raws.important?r.raws.important.replace(/\s*!\s*important/iu," !important"):r.important?" !important":"",r.raws.scssDefault?r.raws.scssDefault.replace(/\s*!default/iu," !default"):r.scssDefault?" !default":"",r.raws.scssGlobal?r.raws.scssGlobal.replace(/\s*!global/iu," !global"):r.scssGlobal?" !global":"",r.nodes?[" {",te([oe,ft(e,t,n)]),oe,"}"]:Lp(r)&&!u.raws.semicolon&&t.originalText[Y(r)-1]!==";"?"":t.__isHTMLStyleAttribute&&e.isLast?ko(";"):";"]}case"css-atrule":{let u=e.parent,s=Dr(r)&&!u.raws.semicolon&&t.originalText[Y(r)-1]!==";";if(t.parser==="less"){if(r.mixin)return[n("selector"),r.important?" !important":"",s?"":";"];if(r.function)return[r.name,typeof r.params=="string"?r.params:n("params"),s?"":";"];if(r.variable)return["@",r.name,": ",r.value?n("value"):"",r.raws.between.trim()?r.raws.between.trim()+" ":"",r.nodes?["{",te([r.nodes.length>0?oe:"",ft(e,t,n)]),oe,"}"]:"",s?"":";"]}let i=r.name==="import"&&r.params?.type==="value-unknown"&&r.params.value.endsWith(";");return["@",Gn(r)||r.name.endsWith(":")||Dr(r)?r.name:lt(r.name),r.params?[Gn(r)?"":Dr(r)?r.raws.afterName===""?"":r.name.endsWith(":")?" ":/^\s*\n\s*\n/u.test(r.raws.afterName)?[U,U]:/^\s*\n/u.test(r.raws.afterName)?U:" ":" ",typeof r.params=="string"?r.params:n("params")]:"",r.selector?te([" ",n("selector")]):"",r.value?ue([" ",n("value"),kr(r,t)?Wp(r)?" ":K:""]):r.name==="else"?" ":"",r.nodes?[kr(r,t)?"":r.selector&&!r.selector.nodes&&typeof r.selector.value=="string"&&ct(r.selector.value)||!r.selector&&typeof r.params=="string"&&ct(r.params)?K:" ","{",te([r.nodes.length>0?oe:"",ft(e,t,n)]),oe,"}"]:s||i?"":";"]}case"media-query-list":{let u=[];return e.each(({node:s})=>{s.type==="media-query"&&s.value===""||u.push(n())},"nodes"),ue(te(Oe(K,u)))}case"media-query":return[Oe(" ",e.map(n,"nodes")),e.isLast?"":","];case"media-type":return Ke(le(r.value,t));case"media-feature-expression":return r.nodes?["(",...e.map(n,"nodes"),")"]:r.value;case"media-feature":return lt(le(V(0,r.value,/ +/gu," "),t));case"media-colon":return[r.value," "];case"media-value":return Ke(le(r.value,t));case"media-keyword":return le(r.value,t);case"media-url":return le(V(0,V(0,r.value,/^url\(\s+/giu,"url("),/\s+\)$/gu,")"),t);case"media-unknown":return r.value;case"selector-root":return ue([gt(e,"custom-selector")?[e.findAncestor(u=>u.type==="css-atrule").customSelector,K]:"",Oe([",",gt(e,["extend","custom-selector","nest"])?K:U],e.map(n,"nodes"))]);case"selector-selector":{let u=r.nodes.length>2;return ue((u?te:s=>s)(e.map(n,"nodes")))}case"selector-comment":return r.value;case"selector-string":return le(r.value,t);case"selector-tag":return[r.namespace?[r.namespace===!0?"":r.namespace.trim(),"|"]:"",e.previous?.type==="selector-nesting"?r.value:Ke(Ep(e,r.value)?r.value.toLowerCase():r.value)];case"selector-id":return["#",r.value];case"selector-class":return[".",Ke(le(r.value,t))];case"selector-attribute":return["[",r.namespace?[r.namespace===!0?"":r.namespace.trim(),"|"]:"",r.attribute.trim(),r.operator??"",r.value?eh(le(r.value.trim(),t),t):"",r.insensitive?" i":"","]"];case"selector-combinator":{if(r.value==="+"||r.value===">"||r.value==="~"||r.value===">>>"){let i=e.parent;return[i.type==="selector-selector"&&i.nodes[0]===r?"":K,r.value,e.isLast?"":" "]}let u=r.value.trim().startsWith("(")?K:"",s=Ke(le(r.value.trim(),t))||K;return[u,s]}case"selector-universal":return[r.namespace?[r.namespace===!0?"":r.namespace.trim(),"|"]:"",r.value];case"selector-pseudo":return[lt(r.value),nr(r.nodes)?ue(["(",te([oe,Oe([",",K],e.map(n,"nodes"))]),oe,")"]):""];case"selector-nesting":return r.value;case"selector-unknown":{if(e.findAncestor(i=>i.type==="css-rule")?.isSCSSNesterProperty)return Ke(le(lt(r.value),t));let u=e.parent;if(u.raws?.selector){let i=Q(u),l=i+u.raws.selector.length;return t.originalText.slice(i,l).trim()}let s=e.grandparent;if(u.type==="value-paren_group"&&s?.type==="value-func"&&s.value==="selector"){let i=Y(u.open)+1,l=Q(u.close),f=t.originalText.slice(i,l).trim();return ct(f)?[fn,f]:f}return r.value}case"value-value":case"value-root":return n("group");case"value-comment":return t.originalText.slice(Q(r),Y(r));case"value-comma_group":return Hp(e,t,n);case"value-paren_group":return fh(e,t,n);case"value-func":return[r.value,gt(e,"supports")&&qp(r)?" ":"",n("group")];case"value-paren":return r.value;case"value-number":return[Jo(r.value),zo(r.unit)];case"value-operator":return r.value;case"value-word":return r.isColor&&r.isHex||kp(r.value)?r.value.toLowerCase():r.value;case"value-colon":{let{previous:u}=e;return ue([r.value,typeof u?.value=="string"&&u.value.endsWith("\\")||Rt(e,"url")?"":K])}case"value-string":return So(r.raws.quote+r.value+r.raws.quote,t);case"value-atword":return["@",r.value];case"value-unicode-range":return r.value;case"value-unknown":return r.value;default:throw new Pf(r,"PostCSS")}}var mh={features:{experimental_frontMatterSupport:{massageAstNode:!0,embed:!0,print:!0}},print:Dh,embed:Jf,insertPragma:wp,massageAstNode:qf,getVisitorKeys:Qf},gh=mh,yh=[{name:"CSS",type:"markup",aceMode:"css",extensions:[".css",".wxss"],tmScope:"source.css",codemirrorMode:"css",codemirrorMimeType:"text/css",parsers:["css"],vscodeLanguageIds:["css"],linguistLanguageId:50},{name:"PostCSS",type:"markup",aceMode:"text",extensions:[".pcss",".postcss"],tmScope:"source.postcss",group:"CSS",parsers:["css"],vscodeLanguageIds:["postcss"],linguistLanguageId:262764437},{name:"Less",type:"markup",aceMode:"less",extensions:[".less"],tmScope:"source.css.less",aliases:["less-css"],codemirrorMode:"css",codemirrorMimeType:"text/x-less",parsers:["less"],vscodeLanguageIds:["less"],linguistLanguageId:198},{name:"SCSS",type:"markup",aceMode:"scss",extensions:[".scss"],tmScope:"source.css.scss",codemirrorMode:"css",codemirrorMimeType:"text/x-scss",parsers:["scss"],vscodeLanguageIds:["scss"],linguistLanguageId:329}],vh={singleQuote:{category:"Common",type:"boolean",default:!1,description:"Use single quotes instead of double quotes."}},Fh={singleQuote:vh.singleQuote},wh=Fh,Ko={};Zs(Ko,{css:()=>Zh,less:()=>ed,scss:()=>td});var bh=rt(Yt()),xh=rt(yc()),Ch=rt(kc());function kh(e,t){let n=new SyntaxError(e+" ("+t.loc.start.line+":"+t.loc.start.column+")");return Object.assign(n,t)}var Eh=kh;function Ah(e){return e!==null&&typeof e=="object"}var or=Ah,Sh=rt(Ac());function Et(e,t,n){if(or(e)){delete e.parent;for(let r in e)Et(e[r],t,n),r==="type"&&typeof e[r]=="string"&&!e[r].startsWith(t)&&(!n||!n.test(e[r]))&&(e[r]=t+e[r])}return e}function Xo(e){if(or(e)){delete e.parent;for(let t in e)Xo(e[t]);!Array.isArray(e)&&e.value&&!e.type&&(e.type="unknown")}return e}var Oh=Sh.default.default;function Bh(e){let t;try{t=Oh(e)}catch{return{type:"selector-unknown",value:e}}return Et(Xo(t),"media-")}var Th=Bh,$h=rt(qc());function _h(e){if(/\/[/*]/u.test(V(0,e,/"[^"]+"|'[^']+'/gu,"")))return{type:"selector-unknown",value:e.trim()};let t;try{new $h.default(n=>{t=n}).process(e)}catch{return{type:"selector-unknown",value:e}}return Et(t,"selector-")}var Ne=_h,Ih=rt(uf()),jh=e=>{for(;e.parent;)e=e.parent;return e},Qo=jh;function Nh(e){return Qo(e).text.slice(e.group.open.sourceIndex+1,e.group.close.sourceIndex).trim()}var Ph=Nh;function Lh(e){if(nr(e)){for(let t=e.length-1;t>0;t--)if(e[t].type==="word"&&e[t].value==="{"&&e[t-1].type==="word"&&e[t-1].value.endsWith("#"))return!0}return!1}var Mh=Lh;function Rh(e){return e.some(t=>t.type==="string"||t.type==="func"&&!t.value.endsWith("\\"))}var Wh=Rh;function zh(e,t){return!!(t.parser==="scss"&&e?.type==="word"&&e.value.startsWith("$"))}var qh=zh,Yn=e=>e.type==="paren"&&e.value===")";function Jh(e,t){let{nodes:n}=e,r={open:null,close:null,groups:[],type:"paren_group"},u=[r],s=r,i={groups:[],type:"comma_group"},l=[i];for(let f=0;f<n.length;++f){let d=n[f];if(t.parser==="scss"&&d.type==="number"&&d.unit===".."&&d.value.endsWith(".")&&(d.value=d.value.slice(0,-1),d.unit="..."),d.type==="func"&&d.value==="selector"&&(d.group.groups=[Ne(Qo(e).text.slice(d.group.open.sourceIndex+1,d.group.close.sourceIndex))]),d.type==="func"&&d.value==="url"){let a=d.group?.groups??[],o=[];for(let p=0;p<a.length;p++){let c=a[p];c.type==="comma_group"?o=[...o,...c.groups]:o.push(c)}(Mh(o)||!Wh(o)&&!qh(o[0],t))&&(d.group.groups=[Ph(d)])}if(d.type==="paren"&&d.value==="(")r={open:d,close:null,groups:[],type:"paren_group"},u.push(r),i={groups:[],type:"comma_group"},l.push(i);else if(Yn(d)){if(i.groups.length>0&&r.groups.push(i),r.close=d,l.length===1)throw new Error("Unbalanced parenthesis");l.pop(),i=Re(0,l,-1),i.groups.push(r),u.pop(),r=Re(0,u,-1)}else if(d.type==="comma"){if(f===n.length-3&&n[f+1].type==="comment"&&Yn(n[f+2]))continue;r.groups.push(i),i={groups:[],type:"comma_group"},l[l.length-1]=i}else i.groups.push(d)}return i.groups.length>0&&r.groups.push(i),s}function Sr(e){return e.type==="paren_group"&&!e.open&&!e.close&&e.groups.length===1||e.type==="comma_group"&&e.groups.length===1?Sr(e.groups[0]):e.type==="paren_group"||e.type==="comma_group"?{...e,groups:e.groups.map(Sr)}:e}function Yo(e,t){if(or(e))for(let n in e)n!=="parent"&&(Yo(e[n],t),n==="nodes"&&(e.group=Sr(Jh(e,t)),delete e[n]));return e}function Vh(e,t){if(t.parser==="less"&&e.startsWith("~`"))return{type:"value-unknown",value:e};let n=null;try{n=new Ih.default(e,{loose:!0}).parse()}catch{return{type:"value-unknown",value:e}}n.text=e;let r=Yo(n,t);return Et(r,"value-",/^selector-/u)}var Ie=Vh,Uh=new Set(["import","use","forward"]);function Hh(e){return Uh.has(e)}var Gh=Hh;function Kh(e,t){return t.parser!=="scss"||!e.selector?!1:e.selector.replace(/\/\*.*?\*\//u,"").replace(/\/\/.*\n/u,"").trim().endsWith(":")}var Xh=Kh,Qh=/(\s*)(!default).*$/u,Yh=/(\s*)(!global).*$/u;function Zo(e,t){if(or(e)){delete e.parent;for(let s in e)Zo(e[s],t);if(!e.type)return e;if(e.raws??(e.raws={}),e.type==="css-decl"&&typeof e.prop=="string"&&e.prop.startsWith("--")&&typeof e.value=="string"&&e.value.startsWith("{")){let s;if(e.value.trimEnd().endsWith("}")){let i=t.originalText.slice(0,e.source.start.offset),l="a".repeat(e.prop.length)+t.originalText.slice(e.source.start.offset+e.prop.length,e.source.end.offset),f=V(0,i,/[^\n]/gu," ")+l,d;t.parser==="scss"?d=ru:t.parser==="less"?d=tu:d=eu;let a;try{a=d(f,{...t})}catch{}a?.nodes?.length===1&&a.nodes[0].type==="css-rule"&&(s=a.nodes[0].nodes)}return s?e.value={type:"css-rule",nodes:s}:e.value={type:"value-unknown",value:e.raws.value.raw},e}let n="";typeof e.selector=="string"&&(n=e.raws.selector?e.raws.selector.scss??e.raws.selector.raw:e.selector,e.raws.between&&e.raws.between.trim().length>0&&(n+=e.raws.between),e.raws.selector=n);let r="";typeof e.value=="string"&&(r=e.raws.value?e.raws.value.scss??e.raws.value.raw:e.value,e.raws.value=r.trim());let u="";if(typeof e.params=="string"&&(u=e.raws.params?e.raws.params.scss??e.raws.params.raw:e.params,e.raws.afterName&&e.raws.afterName.trim().length>0&&(u=e.raws.afterName+u),e.raws.between&&e.raws.between.trim().length>0&&(u=u+e.raws.between),u=u.trim(),e.raws.params=u),n.trim().length>0)return n.startsWith("@")&&n.endsWith(":")?e:e.mixin?(e.selector=Ie(n,t),e):(Xh(e,t)&&(e.isSCSSNesterProperty=!0),e.selector=Ne(n),e);if(r.trim().length>0){let s=r.match(Qh);s&&(r=r.slice(0,s.index),e.scssDefault=!0,s[0].trim()!=="!default"&&(e.raws.scssDefault=s[0]));let i=r.match(Yh);if(i&&(r=r.slice(0,i.index),e.scssGlobal=!0,i[0].trim()!=="!global"&&(e.raws.scssGlobal=i[0])),r.startsWith("progid:"))return{type:"value-unknown",value:r};e.value=Ie(r,t)}if(t.parser==="less"&&e.type==="css-decl"&&r.startsWith("extend(")&&(e.extend||(e.extend=e.raws.between===":"),e.extend&&!e.selector&&(delete e.value,e.selector=Ne(r.slice(7,-1)))),e.type==="css-atrule"){if(t.parser==="less"){if(e.mixin){let s=e.raws.identifier+e.name+e.raws.afterName+e.raws.params;return e.selector=Ne(s),delete e.params,e}if(e.function)return e}if(t.parser==="css"&&e.name==="custom-selector"){let s=e.params.match(/:--\S+\s+/u)[0].trim();return e.customSelector=s,e.selector=Ne(e.params.slice(s.length).trim()),delete e.params,e}if(t.parser==="less"){if(e.name.includes(":")){e.variable=!0;let s=e.name.split(":");e.name=s[0];let i=s.slice(1).join(":");e.params&&(i+=e.params),e.value=Ie(i,t)}if(!["page","nest","keyframes"].includes(e.name)&&e.params?.[0]===":"){e.variable=!0;let s=e.params.slice(1);s&&(e.value=Ie(s,t)),e.raws.afterName+=":"}if(e.variable)return delete e.params,e.value||delete e.value,e}}if(e.type==="css-atrule"&&u.length>0){let{name:s}=e,i=e.name.toLowerCase();return s==="warn"||s==="error"?(e.params={type:"media-unknown",value:u},e):s==="extend"||s==="nest"?(e.selector=Ne(u),delete e.params,e):s==="at-root"?(/^\(\s*(?:without|with)\s*:.+\)$/su.test(u)?e.params=Ie(u,t):(e.selector=Ne(u),delete e.params),e):Gh(i)?(e.import=!0,delete e.filename,e.params=Ie(u,t),e):["namespace","supports","if","else","for","each","while","debug","mixin","include","function","return","define-mixin","add-mixin"].includes(s)?(u=u.replace(/(\$\S+?)(\s+)?\.{3}/u,"$1...$2"),u=u.replace(/^(?!if)([^"'\s(]+)(\s+)\(/u,"$1($2"),e.value=Ie(u,t),delete e.params,e):["media","custom-media"].includes(i)?u.includes("#{")?{type:"media-unknown",value:u}:(e.params=Th(u),e):(e.params=u,e)}}return e}function mn(e,t,n){let{frontMatter:r,content:u}=sr(t),s;try{s=e(u,{map:!1})}catch(i){let{name:l,reason:f,line:d,column:a}=i;throw typeof d!="number"?i:Eh(`${l}: ${f}`,{loc:{start:{line:d,column:a}},cause:i})}return n.originalText=t,s=Zo(Et(s,"css-"),n),Po(s,t),r&&(s.frontMatter={...r,type:"front-matter",source:{startOffset:r.start.index,endOffset:r.end.index}}),s}function eu(e,t={}){return mn(bh.default.default,e,t)}function tu(e,t={}){return mn(n=>xh.default.parse(tp(n)),e,t)}function ru(e,t={}){return mn(Ch.default,e,t)}var gn={astFormat:"postcss",hasPragma:vp,hasIgnorePragma:Fp,locStart:Q,locEnd:Y},Zh={...gn,parse:eu},ed={...gn,parse:tu},td={...gn,parse:ru},rd={postcss:gh};export{pu as H,af as _};
|