@shopify/cli
Version:
A CLI tool to build for the Shopify platform
48 lines (46 loc) • 153 kB
JavaScript
import{b as ns,g as Gt}from"./chunk-VPRTJUIN.js";function dn(e){return this[e<0?this.length+e:e]}function vn(e){if(typeof e=="string")return gr;if(Array.isArray(e))return wr;if(!e)return;let{type:s}=e;if(_r.has(s))return s}function wn(e){let s=e===null?"null":typeof e;if(s!=="string"&&s!=="object")return`Unexpected doc '${s}',
Expected it to be 'string' or 'object'.`;if(Me(e))throw new Error("doc is valid.");let i=Object.prototype.toString.call(e);if(i!=="[object Object]")return`Unexpected doc '${i}'.`;let r=gn([..._r].map(a=>`'${a}'`));return`Unexpected doc.type '${e.type}'.
Expected it to be ${r}.`}function kn(e,s){if(typeof e=="string")return s(e);let i=new Map;return r(e);function r(o){if(i.has(o))return i.get(o);let u=a(o);return i.set(o,u),u}function a(o){switch(Me(o)){case wr:return s(o.map(r));case ot:return s({...o,parts:o.parts.map(r)});case it:return s({...o,breakContents:r(o.breakContents),flatContents:r(o.flatContents)});case nt:{let{expandedStates:u,contents:p}=o;return u?(u=u.map(r),p=u[0]):p=r(p),s({...o,contents:p,expandedStates:u})}case Rt:case st:case kr:case Or:case Nt:return s({...o,contents:r(o.contents)});case gr:case br:case xr:case Tr:case _e:case Lt:return s(o);default:throw new xn(o)}}}function Tn(e){return e.type===_e&&!e.hard?e.soft?"":" ":e.type===it?e.flatContents:e}function On(e){return kn(e,Tn)}function Q(e){return de(e),{type:st,contents:e}}function Sn(e,s){return Cn(e),de(s),{type:Rt,contents:s,n:e}}function Ne(e){return Sn(-1,e)}function Ke(e){return _n(e),{type:ot,parts:e}}function Y(e,s={}){return de(e),Wt(s.expandedStates,!0),{type:nt,id:s.id,contents:e,break:!!s.shouldBreak,expandedStates:s.expandedStates}}function Cr(e,s="",i={}){return de(e),s!==""&&de(s),{type:it,breakContents:e,flatContents:s,groupId:i.groupId}}function ce(e,s){de(e),Wt(s);let i=[];for(let r=0;r<s.length;r++)r!==0&&i.push(e),i.push(s[r]);return i}function En(e){return de(e),{type:Nt,contents:e}}function jn(e){return Array.isArray(e)&&e.length>0}function Mn(e,s){let{preferred:i,alternate:r}=s===!0||s==="'"?In:Pn,{length:a}=e,o=0,u=0;for(let p=0;p<a;p++){let y=e.charCodeAt(p);y===i.codePoint?o++:y===r.codePoint&&u++}return(o>u?r:i).character}function Nn(e,s){let i=s==='"'?"'":'"',r=F(0,e,Rn,(a,o,u)=>o?o===i?i:a:u===s?"\\"+u:u);return s+r+s}function Wn(e,s){qe(/^(?<quote>["']).*\k<quote>$/su.test(e));let i=e.slice(1,-1),r=s.parser==="json"||s.parser==="jsonc"||s.parser==="json5"&&s.quoteProps==="preserve"&&!s.singleQuote?'"':s.__isInHtmlAttribute?"'":$n(i,s.singleQuote);return e.charAt(0)===r?e:Ln(i,r)}function qn(e){return!!e?.[jr]}function Dn(e){let s=e.slice(0,Ae);if(s!=="---"&&s!=="+++")return;let i=e.indexOf(`
`,Ae);if(i===-1)return;let r=e.slice(Ae,i).trim(),a=e.indexOf(`
${s}`,i),o=r;if(o||(o=s==="+++"?"toml":"yaml"),a===-1&&s==="---"&&o==="yaml"&&(a=e.indexOf(`
...`,i)),a===-1)return;let u=a+1+Ae,p=e.charAt(u+1);if(!/\s?/u.test(p))return;let y=e.slice(0,u),m;return{language:o,explicitLanguage:r||null,value:e.slice(i+1,a),startDelimiter:s,endDelimiter:y.slice(-Ae),raw:y,start:{line:1,column:0,index:0},end:{index:y.length,get line(){return m??(m=y.split(`
`)),m.length},get column(){return m??(m=y.split(`
`)),fe(0,m,-1).length}},[jr]:!0}}function Fn(e){let s=Dn(e);return s?{frontMatter:s,get content(){let{raw:i}=s;return F(0,i,/[^\n]/gu," ")+e.slice(i.length)}}:{content:e}}function Ir(e,s,i){if(e.type==="css-comment"&&i.type==="css-root"&&i.nodes.length>0&&((i.nodes[0]===e||vt(i.nodes[0])&&i.nodes[1]===e)&&(delete s.text,/^\*\s*@(?:format|prettier)\s*$/u.test(e.text))||i.type==="css-root"&&fe(0,i.nodes,-1)===e))return null;if(e.type==="value-root"&&delete s.text,(e.type==="media-query"||e.type==="media-query-list"||e.type==="media-feature-expression")&&delete s.value,e.type==="css-rule"&&delete s.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&&(s.value=Vn(e.value)),e.type==="selector-combinator"&&(s.value=F(0,s.value,/\s+/gu," ")),e.type==="media-feature"&&(s.value=F(0,s.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")&&(s.value=s.value.toLowerCase()),e.type==="css-decl"&&(s.prop=e.prop.toLowerCase()),(e.type==="css-atrule"||e.type==="css-import")&&(s.name=e.name.toLowerCase()),e.type==="value-number"&&(s.unit=e.unit.toLowerCase()),e.type==="value-unknown"&&(s.value=F(0,s.value,/;$/gu,"")),e.type==="selector-attribute"&&(s.attribute=e.attribute.trim(),e.namespace&&typeof e.namespace=="string"&&(s.namespace=e.namespace.trim()||!0),e.value)){let{value:r}=s;/\s[a-zA-Z]$/u.test(r)&&(s.__prettier_attribute_selector_flag=fe(0,r,-1),r=r.slice(0,-1)),r=r.trim(),r=r.replace(/^(?<quote>["'])(?<value>.*?)\k<quote>$/u,"$<value>"),s.value=r,delete s.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&&(s.value=F(0,s.value,/([\d+.e-]+)([a-z]*)/giu,(r,a,o)=>{let u=Number(a);return Number.isNaN(u)?r:u+o.toLowerCase()})),e.type==="selector-tag"){let r=s.value.toLowerCase();["from","to"].includes(r)&&(s.value=r)}if(e.type==="css-atrule"&&e.name.toLowerCase()==="supports"&&delete s.value,e.type==="selector-unknown"&&delete s.value,e.type==="value-comma_group"){let r=e.groups.findIndex(a=>a.type==="value-number"&&a.unit==="...");r!==-1&&(s.groups[r].unit="",s.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"}}}function Vn(e){return F(0,F(0,e,"'",'"'),/\\([^\da-f])/giu,"$1")}function Pr(){}function $e(e){if(Ee!==null&&typeof Ee.property){let s=Ee;return Ee=$e.prototype=null,s}return Ee=$e.prototype=e??Object.create(null),new $e}function Qn(e){return $e(e)}function Zn(e,s="type"){Qn(e);function i(r){let a=r[s],o=e[a];if(!Array.isArray(o))throw Object.assign(new Error(`Missing visitor keys for '${a}'.`),{node:r});return o}return i}function to(e,s){let i=0;for(let r=0;r<e.line-1;++r)i=s.indexOf(`
`,i)+1;return i+e.column}function lt(e){return(s,i,r)=>{let a=!!r?.backwards;if(i===!1)return!1;let{length:o}=s,u=i;for(;u>=0&&u<o;){let p=s.charAt(u);if(e instanceof RegExp){if(!e.test(p))return u}else if(!e.includes(p))return u;a?u--:u++}return u===-1||u===o?u:!1}}function Nr(e,s){let{value:i}=e;return i==="-"||i==="--"||i.charAt(0)!=="-"?s:s-(i.charAt(1)==="-"?2:1)}function Lr(e,s){if(typeof e.source?.start?.offset=="number")return e.source.start.offset;if(typeof e.sourceIndex=="number")return e.type==="value-word"?Nr(e,e.sourceIndex):e.sourceIndex;if(e.source?.start)return Mr(e.source.start,s);throw Object.assign(new Error("Can not locate node."),{node:e})}function Bt(e,s){if(e.type==="css-comment"&&e.inline)return Rr(s,e.source.startOffset);if(typeof e.source?.end?.offset=="number")return e.source.end.offset;if(e.source){if(e.source.end){let i=Mr(e.source.end,s);return e.type==="value-word"?Nr(e,i):i}if(at(e.nodes))return Bt(fe(0,e.nodes,-1),s)}return null}function Wr(e,s){e.source&&(e.source.startOffset=Lr(e,s),e.source.endOffset=Bt(e,s));for(let i in e){let r=e[i];i==="source"||!r||typeof r!="object"||(r.type==="value-root"||r.type==="value-unknown"?zr(r,so(e),r.text||r.value):Wr(r,s))}}function zr(e,s,i){e.source&&(e.source.startOffset=Lr(e,i)+s,e.source.endOffset=Bt(e,i)+s);for(let r in e){let a=e[r];r==="source"||!a||typeof a!="object"||zr(a,s,i)}}function so(e){let s=e.source.startOffset;return typeof e.prop=="string"&&(s+=e.prop.length),e.type==="css-atrule"&&typeof e.name=="string"&&(s+=1+e.name.length+e.raws.afterName.match(/^\s*:?\s*/u)[0].length),e.type!=="css-atrule"&&typeof e.raws?.between=="string"&&(s+=e.raws.between.length),s}function no(e){let s="initial",i="initial",r,a=!1,o=[];for(let u=0;u<e.length;u++){let p=e[u];switch(s){case"initial":if(p==="'"){s="single-quotes";continue}if(p==='"'){s="double-quotes";continue}if((p==="u"||p==="U")&&e.slice(u,u+4).toLowerCase()==="url("){s="url",u+=3;continue}if(p==="*"&&e[u-1]==="/"){s="comment-block";continue}if(p==="/"&&e[u-1]==="/"){s="comment-inline",r=u-1;continue}continue;case"single-quotes":if(p==="'"&&e[u-1]!=="\\"&&(s=i,i="initial"),p===`
`||p==="\r")return e;continue;case"double-quotes":if(p==='"'&&e[u-1]!=="\\"&&(s=i,i="initial"),p===`
`||p==="\r")return e;continue;case"url":if(p===")"&&(s="initial"),p===`
`||p==="\r")return e;if(p==="'"){s="single-quotes",i="url";continue}if(p==='"'){s="double-quotes",i="url";continue}continue;case"comment-block":p==="/"&&e[u-1]==="*"&&(s="initial");continue;case"comment-inline":(p==='"'||p==="'"||p==="*")&&(a=!0),(p===`
`||p==="\r")&&(a&&o.push([r,u]),s="initial",a=!1);continue}}for(let[u,p]of o)e=e.slice(0,u)+F(0,e.slice(u,p),/["'*]/gu," ")+e.slice(p);return e}function co(e){let s=e.match(Br);return s?s[0].trimStart():""}function po(e){let s=e.match(Br)?.[0];return s==null?e:e.slice(s.length)}function ho(e){e=F(0,e.replace(io,"").replace(oo,""),lo,"$1");let s="";for(;s!==e;)s=e,e=F(0,e,uo,`
$1 $2
`);e=e.replace(Ht,"").trimEnd();let i=Object.create(null),r=F(0,e,Jt,"").replace(Ht,"").trimEnd(),a;for(;a=Jt.exec(e);){let o=F(0,a[2],ao,"");if(typeof i[a[1]]=="string"||Array.isArray(i[a[1]])){let u=i[a[1]];i[a[1]]=[...qr,...Array.isArray(u)?u:[u],o]}else i[a[1]]=o}return{comments:r,pragmas:i}}function fo({comments:e="",pragmas:s={}}){let i=Object.keys(s),r=i.flatMap(o=>Qt(o,s[o])).map(o=>` * ${o}
`).join("");if(!e){if(i.length===0)return"";if(i.length===1&&!Array.isArray(s[i[0]])){let o=s[i[0]];return`/** ${Qt(i[0],o)[0]} */`}}let a=e.split(`
`).map(o=>` * ${o}`).join(`
`)+`
`;return`/**
`+(e?a:"")+(e&&i.length>0?` *
`:"")+r+" */"}function Qt(e,s){return[...qr,...Array.isArray(s)?s:[s]].map(i=>`@${e} ${i}`.trim())}function go(e){if(!e.startsWith("#!"))return"";let s=e.indexOf(`
`);return s===-1?e:e.slice(0,s)}function qt(e){let s=wo(e);s&&(e=e.slice(s.length+1));let i=co(e),{pragmas:r,comments:a}=ho(i);return{shebang:s,text:e,pragmas:r,comments:a}}function bo(e){let{pragmas:s}=qt(e);return yo.some(i=>Object.prototype.hasOwnProperty.call(s,i))}function xo(e){let{pragmas:s}=qt(e);return mo.some(i=>Object.prototype.hasOwnProperty.call(s,i))}function ko(e){let{shebang:s,text:i,pragmas:r,comments:a}=qt(e),o=po(i),u=fo({pragmas:{[vo]:"",...r},comments:a.trimStart()});return(s?`${s}
`:"")+u+(o.startsWith(`
`)?`
`:`
`)+o}function So(e){return e.findAncestor(s=>s.type==="css-decl")?.prop?.toLowerCase()}function Eo(e){return Ao.has(e.toLowerCase())}function jo(e,s){return e.findAncestor(i=>i.type==="css-atrule")?.name?.toLowerCase().endsWith("keyframes")&&["from","to"].includes(s.toLowerCase())}function je(e){return e.includes("$")||e.includes("@")||e.includes("#")||e.startsWith("%")||e.startsWith("--")||e.startsWith(":--")||e.includes("(")&&e.includes(")")?e:e.toLowerCase()}function Ye(e,s){return e.findAncestor(i=>i.type==="value-func")?.value?.toLowerCase()===s}function Io(e){return e.hasAncestor(s=>{if(s.type!=="css-rule")return!1;let i=s.raws?.selector;return i&&(i.startsWith(":import")||i.startsWith(":export"))})}function Re(e,s){let i=Array.isArray(s)?s:[s],r=e.findAncestor(a=>a.type==="css-atrule");return r&&i.includes(r.name.toLowerCase())}function Po(e){let{node:s}=e;return s.groups[0]?.value==="url"&&s.groups.length===2&&e.findAncestor(i=>i.type==="css-atrule")?.name==="import"}function Mo(e){return e.type==="value-func"&&e.value.toLowerCase()==="url"}function $o(e){return e.type==="value-func"&&e.value.toLowerCase()==="var"}function Ro(e){let{selector:s}=e;return s?typeof s=="string"&&/^@.+:.*$/u.test(s)||s.value&&/^@.+:.*$/u.test(s.value):!1}function No(e){return e.type==="value-word"&&["from","through","end"].includes(e.value)}function Lo(e){return e.type==="value-word"&&["and","or","not"].includes(e.value)}function Wo(e){return e.type==="value-word"&&e.value==="in"}function gt(e){return e.type==="value-operator"&&e.value==="*"}function xe(e){return e?.type==="value-operator"&&e.value==="/"}function le(e){return e.type==="value-operator"&&e.value==="+"}function ke(e){return e.type==="value-operator"&&e.value==="-"}function zo(e){return e.type==="value-operator"&&e.value==="%"}function ht(e){return gt(e)||xe(e)||le(e)||ke(e)||zo(e)}function Bo(e){return e.type==="value-word"&&["==","!="].includes(e.value)}function qo(e){return e.type==="value-word"&&["<",">","<=",">="].includes(e.value)}function wt(e,s){return s.parser==="scss"&&e.type==="css-atrule"&&["if","else","for","each","while"].includes(e.name)}function Zt(e){return e.raws?.params&&/^\(\s*\)$/u.test(e.raws.params)}function ft(e){return e.name.startsWith("prettier-placeholder")}function Do(e){return e.prop.startsWith("@prettier-placeholder")}function Fo(e,s){return e.value==="$$"&&e.type==="value-func"&&s?.type==="value-word"&&!s.raws.before}function Uo(e){return e.value?.type==="value-root"&&e.value.group?.type==="value-value"&&e.prop.toLowerCase()==="composes"}function Vo(e){return e.value?.group?.group?.type==="value-paren_group"&&e.value.group.group.open!==null&&e.value.group.group.close!==null}function ue(e){return e?.raws?.before===""}function Dt(e){return e.type==="value-comma_group"&&e.groups?.[1]?.type==="value-colon"}function dt(e){return e.type==="value-paren_group"&&e.groups?.[0]&&Dt(e.groups[0])}function Dr(e,s){if(s.parser!=="scss")return!1;let{node:i}=e;if(i.groups.length===0)return!1;let r=e.grandparent;return!dt(i)&&!(r&&dt(r))?!1:!!(e.findAncestor(a=>a.type==="css-decl")?.prop?.startsWith("$")||dt(r)||r.type==="value-func")}function He(e){return e.type==="value-comment"&&e.inline}function mt(e){return e.type==="value-word"&&e.value==="#"}function Kt(e){return e.type==="value-word"&&e.value==="{"}function yt(e){return e.type==="value-word"&&e.value==="}"}function Je(e){return["value-word","value-atword"].includes(e.type)}function bt(e){return e?.type==="value-colon"}function Go(e,s){if(!Dt(s))return!1;let{groups:i}=s,r=i.indexOf(e);return r===-1?!1:bt(i[r+1])}function Ho(e){return e.value&&["not","and","or"].includes(e.value.toLowerCase())}function Jo(e){return e.type!=="value-func"?!1:Co.has(e.value.toLowerCase())}function Ie(e){return/\/\//u.test(e.split(/[\n\r]/u).pop())}function Qe(e){return e?.type==="value-atword"&&e.value.startsWith("prettier-placeholder-")}function Qo(e,s){if(e.open?.value!=="("||e.close?.value!==")"||e.groups.some(i=>i.type!=="value-comma_group"))return!1;if(s.type==="value-comma_group"){let i=s.groups.indexOf(e)-1,r=s.groups[i];if(r?.type==="value-word"&&r.value==="with")return!0}return!1}function Ze(e){return e.type==="value-paren_group"&&e.open?.value==="("&&e.close?.value===")"}function Zo(e,s,i){let{node:r}=e,a=e.parent,o=e.grandparent,u=So(e),p=u&&a.type==="value-value"&&(u==="grid"||u.startsWith("grid-template")),y=e.findAncestor(g=>g.type==="css-atrule"),m=y&&wt(y,s),n=r.groups.some(g=>He(g)),t=e.map(i,"groups"),h=[""],c=Ye(e,"url"),d=!1,l=!1;for(let g=0;g<r.groups.length;++g){let v=r.groups[g-1],f=r.groups[g],w=r.groups[g+1],O=r.groups[g+2];if(He(f)&&!w){h.push([h.pop(),En([" ",t[g]])]);continue}if(h.push([h.pop(),t[g]]),c){(w&&le(w)||le(f))&&h.push([h.pop()," "]);continue}if(Re(e,"forward")&&f.type==="value-word"&&f.value&&v!==void 0&&v.type==="value-word"&&v.value==="as"&&w.type==="value-operator"&&w.value==="*"||Re(e,"utility")&&f.type==="value-word"&&w&&w.type==="value-operator"&&w.value==="*"||!w||f.type==="value-word"&&Qe(w)&&H(f)===G(w))continue;if(f.type==="value-string"&&f.quoted){let A=f.value.lastIndexOf("#{"),I=f.value.lastIndexOf("}");A!==-1&&I!==-1?d=A>I:A!==-1?d=!0:I!==-1&&(d=!1)}if(d||bt(f)||bt(w)||f.type==="value-atword"&&(f.value===""||f.value.endsWith("["))||w.type==="value-word"&&w.value.startsWith("]")||f.value==="~"||s.parser==="less"&&(w?.type==="value-word"&&w.value==="["||f.type==="value-word"&&f.value==="["&&(w?.type==="value-atword"||w?.type==="value-word")||f.type==="value-word"&&f.value==="]["&&w?.type==="value-word")||f.type!=="value-string"&&f.value&&f.value.includes("\\")&&w&&w.type!=="value-comment"||v?.value&&v.value.indexOf("\\")===v.value.length-1&&f.type==="value-operator"&&f.value==="/"||f.value==="\\"||Fo(f,w)||mt(f)||Kt(f)||yt(w)||Kt(w)&&ue(w)||yt(f)&&ue(w)||f.value==="--"&&mt(w))continue;let b=ht(f),T=ht(w);if((b&&mt(w)||T&&yt(f))&&ue(w)||!v&&xe(f)||Ye(e,"calc")&&(le(f)||le(w)||ke(f)||ke(w))&&ue(w))continue;let k=(le(f)||ke(f))&&g===0&&(w.type==="value-number"||w.isHex)&&o&&Jo(o)&&!ue(w);if(s.parser==="scss"&&b&&f.value==="-"&&w.type==="value-func"&&H(f)!==G(w)){h.push([h.pop()," "]);continue}let x=O?.type==="value-func"||O&&Je(O)||f.type==="value-func"||Je(f),C=w.type==="value-func"||Je(w)||v?.type==="value-func"||v&&Je(v);if(!(!(gt(w)||gt(f))&&!Ye(e,"calc")&&!k&&(xe(w)&&!x||xe(f)&&!C||le(w)&&!x||le(f)&&!C||ke(w)||ke(f))&&(ue(w)||b&&(!v||v&&ht(v))))&&!((s.parser==="scss"||s.parser==="less")&&b&&f.value==="-"&&Ze(w)&&H(f)===G(w.open)&&w.open.value==="(")){if(He(f)){if(a.type==="value-paren_group"){h.push(Ne(U),"");continue}h.push(U,"");continue}if(m&&(Bo(w)||qo(w)||Lo(w)||Wo(f)||No(f))){h.push([h.pop()," "]);continue}if(y&&y.name.toLowerCase()==="namespace"){h.push([h.pop()," "]);continue}if(p){f.source&&w.source&&f.source.start.line!==w.source.start.line?(h.push(U,""),l=!0):h.push([h.pop()," "]);continue}if(!(u&&(u==="font"||u.startsWith("--"))&&(xe(w)&&ue(w)&&Yt(f)||xe(f)&&ue(f)&&Yt(v)))){if(T){h.push([h.pop()," "]);continue}if(w?.value!=="..."&&!(Qe(f)&&Qe(w)&&H(f)===G(w))){if(Qe(f)&&Ze(w)&&H(f)===G(w.open)){h.push(K,"");continue}if(f.value==="with"&&Ze(w)){h=[[Ke(h)," "]];continue}if(!(f.value?.endsWith("#")&&w.value==="{"&&Ze(w.group))&&!(He(w)&&!O)){if(!y&&f.type==="value-comment"&&!f.inline&&r.groups.slice(0,g).every(A=>A.type==="value-comment")){h.push(Ne(V),"");continue}h.push(V,"")}}}}}return n&&h.push([h.pop(),zt]),l&&h.unshift("",U),m?Y(Q(h)):Po(e)?Y(Ke(h)):Y(Q(Ke(h)))}function Yt(e){if(e?.type==="value-number")return!0;if(e?.type!=="value-func")return!1;let s=e.value.toLowerCase();return s==="var"||s==="calc"||s==="min"||s==="max"||s==="clamp"||s.startsWith("--")}function Yo(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,"")}function Fr(e){let s=e.toLowerCase();return xt.has(s)?xt.get(s):e}function ee(e,s){return F(0,e,Ur,i=>Er(i,s))}function ni(e,s){let i=s.singleQuote?"'":'"',r="",a=e.match(/^(?<value>.+?)\s+(?<flag>[a-zA-Z])$/u);return a&&({value:e,flag:r}=a.groups),(e.includes('"')||e.includes("'")?e:i+e+i)+(r?` ${r}`:"")}function be(e){return F(0,e,si,(s,i,r,a,o)=>!r&&a&&(o??(o=""),o=o.toLowerCase(),!o||o==="n"||xt.has(o))?Vr(a)+(o?Fr(o):""):s)}function Vr(e){return Xo(e).replace(/\.0(?=$|e)/u,"")}function oi(e){return e.trailingComma==="es5"||e.trailingComma==="all"}function ii(e,s,i){let r=!!i?.backwards;if(s===!1)return!1;let a=e.charAt(s);if(r){if(e.charAt(s-1)==="\r"&&a===`
`)return s-2;if(Xt(a))return s-1}else{if(a==="\r"&&e.charAt(s+1)===`
`)return s+2;if(Xt(a))return s+1}return s}function ai(e,s,i={}){let r=$r(e,i.backwards?s-1:s,i),a=Gr(e,r,i);return r!==a}function ui(e,s){if(s===!1)return!1;if(e.charAt(s)==="/"&&e.charAt(s+1)==="*"){for(let i=s+2;i<e.length;++i)if(e.charAt(i)==="*"&&e.charAt(i+1)==="/")return i+2}return s}function ci(e,s){return s===!1?!1:e.charAt(s)==="/"&&e.charAt(s+1)==="/"?Rr(e,s):s}function hi(e,s){let i=null,r=s;for(;r!==i;)i=r,r=ro(e,r),r=li(e,r),r=$r(e,r);return r=pi(e,r),r=Gr(e,r),r!==!1&&Hr(e,r)}function fi({node:e,parent:s},i){return!!(e.source&&i.originalText.slice(G(e),G(s.close)).trimEnd().endsWith(","))}function di(e,s){return $o(e.grandparent)&&fi(e,s)?",":e.node.type!=="value-comment"&&!(e.node.type==="value-comma_group"&&e.node.groups.every(i=>i.type==="value-comment"))&&oi(s)&&e.callParent(()=>Dr(e,s))?Cr(","):""}function mi(e,s,i){let{node:r,parent:a}=e,o=e.map(({node:c})=>typeof c=="string"?c:i(),"groups");if(a&&Mo(a)&&(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?i("open"):"",ce(",",o),r.close?i("close"):""];if(!r.open){let c=Qr(e);Wt(o);let d=vi(ce(",",o),2),l=ce(c?U:V,d);return Q(c?[U,l]:Y([yi(e)?K:"",Ke(l)]))}let u=e.map(({node:c,isLast:d,index:l})=>{let g=o[l];Dt(c)&&c.type==="value-comma_group"&&c.groups&&c.groups[0].type!=="value-paren_group"&&c.groups[2]?.type==="value-paren_group"&&Me(g)===nt&&Me(g.contents)===st&&Me(g.contents.contents)===ot&&(g=Y(Ne(g)));let v=[g,d?di(e,s):","];if(!d&&c.type==="value-comma_group"&&at(c.groups)){let f=fe(0,c.groups,-1);!f.source&&f.close&&(f=f.close),f.source&&Jr(s.originalText,H(f))&&v.push(U)}return v},"groups"),p=Go(r,a),y=Qo(r,a),m=Dr(e,s),n=y||m&&!p,t=y||p,h=Y([r.open?i("open"):"",Q([K,ce(V,u)]),K,r.close?i("close"):""],{shouldBreak:n});return t?Ne(h):h}function Qr(e){return e.match(s=>s.type==="value-paren_group"&&!s.open&&s.groups.some(i=>i.type==="value-comma_group"),(s,i)=>i==="group"&&s.type==="value-value",(s,i)=>i==="group"&&s.type==="value-root",(s,i)=>i==="value"&&(s.type==="css-decl"&&!s.prop.startsWith("--")||s.type==="css-atrule"&&s.variable))}function yi(e){return e.match(s=>s.type==="value-paren_group"&&!s.open,(s,i)=>i==="group"&&s.type==="value-value",(s,i)=>i==="group"&&s.type==="value-root",(s,i)=>i==="value"&&s.type==="css-decl")}function vi(e,s){let i=[];for(let r=0;r<e.length;r+=s)i.push(e.slice(r,r+s));return i}function gi(e,s,i){let r=[];return e.each(()=>{let{node:a,previous:o}=e;if(o?.type==="css-comment"&&o.text.trim()==="prettier-ignore"?r.push(s.originalText.slice(G(a),H(a))):r.push(i()),e.isLast)return;let{next:u}=e;u.type==="css-comment"&&!Hr(s.originalText,G(u),{backwards:!0})&&!vt(a)||u.type==="css-atrule"&&u.name==="else"&&a.type!=="css-comment"?r.push(" "):(r.push(s.__isHTMLStyleAttribute?V:U),Jr(s.originalText,H(a))&&!vt(a)&&r.push(U))},"nodes"),r}function wi(e,s,i){let{node:r}=e;switch(r.type){case"css-root":{let a=Pe(e,s,i),o=r.raws.after.trim();return o.startsWith(";")&&(o=o.slice(1).trim()),[r.frontMatter?[i("frontMatter"),U,r.nodes.length>0?U:""]:"",a,o?` ${o}`:"",r.nodes.length>0?U:""]}case"css-comment":{let a=r.inline||r.raws.inline,o=s.originalText.slice(G(r),H(r));return a?o.trimEnd():o}case"css-rule":return[i("selector"),r.important?" !important":"",r.nodes?[r.selector?.type==="selector-unknown"&&Ie(r.selector.value)?V:r.selector?" ":"","{",r.nodes.length>0?Q([U,Pe(e,s,i)]):"",U,"}",Ro(r)?";":""]:";"];case"css-decl":{let a=e.parent,{between:o}=r.raws,u=o.trim(),p=u===":",y=typeof r.value=="string"&&/^ *$/u.test(r.value),m=typeof r.value=="string"?r.value:i("value");return m=Uo(r)?On(m):m,!p&&Ie(u)&&!e.call(()=>Qr(e),"value","group","group")&&(m=Q([U,Ne(m)])),[F(0,r.raws.before,/[\s;]/gu,""),a.type==="css-atrule"&&a.variable||Io(e)?r.prop:je(r.prop),u.startsWith("//")?" ":"",u,r.extend||y?"":" ",s.parser==="less"&&r.extend&&r.selector?["extend(",i("selector"),")"]:"",m,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?[" {",Q([K,Pe(e,s,i)]),K,"}"]:Do(r)&&!a.raws.semicolon&&s.originalText[H(r)-1]!==";"?"":s.__isHTMLStyleAttribute&&e.isLast?Cr(";"):";"]}case"css-atrule":{let a=e.parent,o=ft(r)&&!a.raws.semicolon&&s.originalText[H(r)-1]!==";";if(s.parser==="less"){if(r.mixin)return[i("selector"),r.important?" !important":"",o?"":";"];if(r.function)return[r.name,typeof r.params=="string"?r.params:i("params"),o?"":";"];if(r.variable)return["@",r.name,": ",r.value?i("value"):"",r.raws.between.trim()?r.raws.between.trim()+" ":"",r.nodes?["{",Q([r.nodes.length>0?K:"",Pe(e,s,i)]),K,"}"]:"",o?"":";"]}let u=r.name==="import"&&r.params?.type==="value-unknown"&&r.params.value.endsWith(";");return["@",Zt(r)||r.name.endsWith(":")||ft(r)?r.name:je(r.name),r.params?[Zt(r)?"":ft(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:i("params")]:"",r.selector?Q([" ",i("selector")]):"",r.value?Y([" ",i("value"),wt(r,s)?Vo(r)?" ":V:""]):r.name==="else"?" ":"",r.nodes?[wt(r,s)?"":r.selector&&!r.selector.nodes&&typeof r.selector.value=="string"&&Ie(r.selector.value)||!r.selector&&typeof r.params=="string"&&Ie(r.params)?V:" ","{",Q([r.nodes.length>0?K:"",Pe(e,s,i)]),K,"}"]:o||u?"":";"]}case"media-query-list":{let a=[];return e.each(({node:o})=>{o.type==="media-query"&&o.value===""||a.push(i())},"nodes"),Y(Q(ce(V,a)))}case"media-query":return[ce(" ",e.map(i,"nodes")),e.isLast?"":","];case"media-type":return be(ee(r.value,s));case"media-feature-expression":return r.nodes?["(",...e.map(i,"nodes"),")"]:r.value;case"media-feature":return je(ee(F(0,r.value,/ +/gu," "),s));case"media-colon":return[r.value," "];case"media-value":return be(ee(r.value,s));case"media-keyword":return ee(r.value,s);case"media-url":return ee(F(0,F(0,r.value,/^url\(\s+/giu,"url("),/\s+\)$/gu,")"),s);case"media-unknown":return r.value;case"selector-root":return Y([Re(e,"custom-selector")?[e.findAncestor(a=>a.type==="css-atrule").customSelector,V]:"",ce([",",Re(e,["extend","custom-selector","nest"])?V:U],e.map(i,"nodes"))]);case"selector-selector":{let a=r.nodes.length>2;return Y((a?Q:o=>o)(e.map(i,"nodes")))}case"selector-comment":return r.value;case"selector-string":return ee(r.value,s);case"selector-tag":return[r.namespace?[r.namespace===!0?"":r.namespace.trim(),"|"]:"",e.previous?.type==="selector-nesting"?r.value:be(jo(e,r.value)?r.value.toLowerCase():r.value)];case"selector-id":return["#",r.value];case"selector-class":return[".",be(ee(r.value,s))];case"selector-attribute":return["[",r.namespace?[r.namespace===!0?"":r.namespace.trim(),"|"]:"",r.attribute.trim(),r.operator??"",r.value?ni(ee(r.value.trim(),s),s):"",r.insensitive?" i":"","]"];case"selector-combinator":{if(r.value==="+"||r.value===">"||r.value==="~"||r.value===">>>"){let u=e.parent;return[u.type==="selector-selector"&&u.nodes[0]===r?"":V,r.value,e.isLast?"":" "]}let a=r.value.trim().startsWith("(")?V:"",o=be(ee(r.value.trim(),s))||V;return[a,o]}case"selector-universal":return[r.namespace?[r.namespace===!0?"":r.namespace.trim(),"|"]:"",r.value];case"selector-pseudo":return[je(r.value),at(r.nodes)?Y(["(",Q([K,ce([",",V],e.map(i,"nodes"))]),K,")"]):""];case"selector-nesting":return r.value;case"selector-unknown":{if(e.findAncestor(u=>u.type==="css-rule")?.isSCSSNesterProperty)return be(ee(je(r.value),s));let a=e.parent;if(a.raws?.selector){let u=G(a),p=u+a.raws.selector.length;return s.originalText.slice(u,p).trim()}let o=e.grandparent;if(a.type==="value-paren_group"&&o?.type==="value-func"&&o.value==="selector"){let u=H(a.open)+1,p=G(a.close),y=s.originalText.slice(u,p).trim();return Ie(y)?[zt,y]:y}return r.value}case"value-value":case"value-root":return i("group");case"value-comment":return s.originalText.slice(G(r),H(r));case"value-comma_group":return Ko(e,s,i);case"value-paren_group":return mi(e,s,i);case"value-func":return[r.value,Re(e,"supports")&&Ho(r)?" ":"",i("group")];case"value-paren":return r.value;case"value-number":return[Vr(r.value),Fr(r.unit)];case"value-operator":return r.value;case"value-word":return r.isColor&&r.isHex||Eo(r.value)?r.value.toLowerCase():r.value;case"value-colon":{let{previous:a}=e;return Y([r.value,typeof a?.value=="string"&&a.value.endsWith("\\")||Ye(e,"url")?"":V])}case"value-string":return Er(r.raws.quote+r.value+r.raws.quote,s);case"value-atword":return["@",r.value];case"value-unicode-range":return r.value;case"value-unknown":return r.value;default:throw new Bn(r,"PostCSS")}}function Ei(e,s){let i=new SyntaxError(e+" ("+s.loc.start.line+":"+s.loc.start.column+")");return Object.assign(i,s)}function Ii(e){return e!==null&&typeof e=="object"}function De(e,s,i){if(ct(e)){delete e.parent;for(let r in e)De(e[r],s,i),r==="type"&&typeof e[r]=="string"&&!e[r].startsWith(s)&&(!i||!i.test(e[r]))&&(e[r]=s+e[r])}return e}function Kr(e){if(ct(e)){delete e.parent;for(let s in e)Kr(e[s]);!Array.isArray(e)&&e.value&&!e.type&&(e.type="unknown")}return e}function $i(e){let s;try{s=Mi(e)}catch{return{type:"selector-unknown",value:e}}return De(Kr(s),"media-")}function Li(e){if(/\/[/*]/u.test(F(0,e,/"[^"]+"|'[^']+'/gu,"")))return{type:"selector-unknown",value:e.trim()};let s;try{new Ni.default(i=>{s=i}).process(e)}catch{return{type:"selector-unknown",value:e}}return De(s,"selector-")}function Bi(e){return Yr(e).text.slice(e.group.open.sourceIndex+1,e.group.close.sourceIndex).trim()}function Di(e){if(at(e)){for(let s=e.length-1;s>0;s--)if(e[s].type==="word"&&e[s].value==="{"&&e[s-1].type==="word"&&e[s-1].value.endsWith("#"))return!0}return!1}function Ui(e){return e.some(s=>s.type==="string"||s.type==="func"&&!s.value.endsWith("\\"))}function Gi(e,s){return!!(s.parser==="scss"&&e?.type==="word"&&e.value.startsWith("$"))}function Ji(e,s){let{nodes:i}=e,r={open:null,close:null,groups:[],type:"paren_group"},a=[r],o=r,u={groups:[],type:"comma_group"},p=[u];for(let y=0;y<i.length;++y){let m=i[y];if(s.parser==="scss"&&m.type==="number"&&m.unit===".."&&m.value.endsWith(".")&&(m.value=m.value.slice(0,-1),m.unit="..."),m.type==="func"&&m.value==="selector"&&(m.group.groups=[he(Yr(e).text.slice(m.group.open.sourceIndex+1,m.group.close.sourceIndex))]),m.type==="func"&&m.value==="url"){let n=m.group?.groups??[],t=[];for(let h=0;h<n.length;h++){let c=n[h];c.type==="comma_group"?t=[...t,...c.groups]:t.push(c)}(Fi(t)||!Vi(t)&&!Hi(t[0],s))&&(m.group.groups=[qi(m)])}if(m.type==="paren"&&m.value==="(")r={open:m,close:null,groups:[],type:"paren_group"},a.push(r),u={groups:[],type:"comma_group"},p.push(u);else if(er(m)){if(u.groups.length>0&&r.groups.push(u),r.close=m,p.length===1)throw new Error("Unbalanced parenthesis");p.pop(),u=fe(0,p,-1),u.groups.push(r),a.pop(),r=fe(0,a,-1)}else if(m.type==="comma"){if(y===i.length-3&&i[y+1].type==="comment"&&er(i[y+2]))continue;r.groups.push(u),u={groups:[],type:"comma_group"},p[p.length-1]=u}else u.groups.push(m)}return u.groups.length>0&&r.groups.push(u),o}function kt(e){return e.type==="paren_group"&&!e.open&&!e.close&&e.groups.length===1||e.type==="comma_group"&&e.groups.length===1?kt(e.groups[0]):e.type==="paren_group"||e.type==="comma_group"?{...e,groups:e.groups.map(kt)}:e}function Xr(e,s){if(ct(e))for(let i in e)i!=="parent"&&(Xr(e[i],s),i==="nodes"&&(e.group=kt(Ji(e,s)),delete e[i]));return e}function Qi(e,s){if(s.parser==="less"&&e.startsWith("~`"))return{type:"value-unknown",value:e};let i=null;try{i=new Wi.default(e,{loose:!0}).parse()}catch{return{type:"value-unknown",value:e}}i.text=e;let r=Xr(i,s);return De(r,"value-",/^selector-/u)}function Ki(e){return Zi.has(e)}function Xi(e,s){return s.parser!=="scss"||!e.selector?!1:e.selector.replace(/\/\*.*?\*\//u,"").replace(/\/\/.*\n/u,"").trim().endsWith(":")}function es(e,s){if(ct(e)){delete e.parent;for(let o in e)es(e[o],s);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 o;if(e.value.trimEnd().endsWith("}")){let u=s.originalText.slice(0,e.source.start.offset),p="a".repeat(e.prop.length)+s.originalText.slice(e.source.start.offset+e.prop.length,e.source.end.offset),y=F(0,u,/[^\n]/gu," ")+p,m;s.parser==="scss"?m=ss:s.parser==="less"?m=rs:m=ts;let n;try{n=m(y,{...s})}catch{}n?.nodes?.length===1&&n.nodes[0].type==="css-rule"&&(o=n.nodes[0].nodes)}return o?e.value={type:"css-rule",nodes:o}:e.value={type:"value-unknown",value:e.raws.value.raw},e}let i="";typeof e.selector=="string"&&(i=e.raws.selector?e.raws.selector.scss??e.raws.selector.raw:e.selector,e.raws.between&&e.raws.between.trim().length>0&&(i+=e.raws.between),e.raws.selector=i);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 a="";if(typeof e.params=="string"&&(a=e.raws.params?e.raws.params.scss??e.raws.params.raw:e.params,e.raws.afterName&&e.raws.afterName.trim().length>0&&(a=e.raws.afterName+a),e.raws.between&&e.raws.between.trim().length>0&&(a=a+e.raws.between),a=a.trim(),e.raws.params=a),i.trim().length>0)return i.startsWith("@")&&i.endsWith(":")?e:e.mixin?(e.selector=pe(i,s),e):(ea(e,s)&&(e.isSCSSNesterProperty=!0),e.selector=he(i),e);if(r.trim().length>0){let o=r.match(ta);o&&(r=r.slice(0,o.index),e.scssDefault=!0,o[0].trim()!=="!default"&&(e.raws.scssDefault=o[0]));let u=r.match(ra);if(u&&(r=r.slice(0,u.index),e.scssGlobal=!0,u[0].trim()!=="!global"&&(e.raws.scssGlobal=u[0])),r.startsWith("progid:"))return{type:"value-unknown",value:r};e.value=pe(r,s)}if(s.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=he(r.slice(7,-1)))),e.type==="css-atrule"){if(s.parser==="less"){if(e.mixin){let o=e.raws.identifier+e.name+e.raws.afterName+e.raws.params;return e.selector=he(o),delete e.params,e}if(e.function)return e}if(s.parser==="css"&&e.name==="custom-selector"){let o=e.params.match(/:--\S+\s+/u)[0].trim();return e.customSelector=o,e.selector=he(e.params.slice(o.length).trim()),delete e.params,e}if(s.parser==="less"){if(e.name.includes(":")){e.variable=!0;let o=e.name.split(":");e.name=o[0];let u=o.slice(1).join(":");e.params&&(u+=e.params),e.value=pe(u,s)}if(!["page","nest","keyframes"].includes(e.name)&&e.params?.[0]===":"){e.variable=!0;let o=e.params.slice(1);o&&(e.value=pe(o,s)),e.raws.afterName+=":"}if(e.variable)return delete e.params,e.value||delete e.value,e}}if(e.type==="css-atrule"&&a.length>0){let{name:o}=e,u=e.name.toLowerCase();return o==="warn"||o==="error"?(e.params={type:"media-unknown",value:a},e):o==="extend"||o==="nest"?(e.selector=he(a),delete e.params,e):o==="at-root"?(/^\(\s*(?:without|with)\s*:.+\)$/su.test(a)?e.params=pe(a,s):(e.selector=he(a),delete e.params),e):Yi(u)?(e.import=!0,delete e.filename,e.params=pe(a,s),e):["namespace","supports","if","else","for","each","while","debug","mixin","include","function","return","define-mixin","add-mixin"].includes(o)?(a=a.replace(/(\$\S+?)(\s+)?\.{3}/u,"$1...$2"),a=a.replace(/^(?!if)([^"'\s(]+)(\s+)\(/u,"$1($2"),e.value=pe(a,s),delete e.params,e):["media","custom-media"].includes(u)?a.includes("#{")?{type:"media-unknown",value:a}:(e.params=Ri(a),e):(e.params=a,e)}}return e}function Ft(e,s,i){let{frontMatter:r,content:a}=ut(s),o;try{o=e(a,{map:!1})}catch(u){let{name:p,reason:y,line:m,column:n}=u;throw typeof m!="number"?u:ji(`${p}: ${y}`,{loc:{start:{line:m,column:n}},cause:u})}return i.originalText=s,o=es(De(o,"css-"),i),Wr(o,s),r&&(o.frontMatter={...r,type:"front-matter",source:{startOffset:r.start.index,endOffset:r.end.index}}),o}function ts(e,s={}){return Ft(Ci.default.default,e,s)}function rs(e,s={}){return Ft(i=>Si.default.parse(no(i)),e,s)}function ss(e,s={}){return Ft(Ai.default,e,s)}var os,Tt,is,as,us,ls,E,tr,cs,Te,ps,rr,Ot,_t,Xe,Ct,et,Le,tt,me,hs,fs,or,We,St,ze,ir,At,Et,jt,rt,ds,ms,ys,vs,gs,ws,bs,xs,It,ks,ar,ur,Pt,lr,cr,Ts,Os,Mt,_s,Cs,Ss,As,hr,fr,Es,js,dr,mr,yr,Oe,J,$t,Is,Ps,Be,Ms,$s,Rs,Ns,Ls,Ws,zs,Bs,qs,Ds,Fs,Us,Vs,Gs,te,Z,Hs,Js,Qs,Zs,Ks,Ys,Xs,en,tn,rn,sn,nn,on,an,un,ln,cn,pn,vr,hn,fn,F,mn,fe,yn,qe,gr,wr,br,st,Rt,xr,nt,ot,it,kr,Nt,Tr,_e,Or,Lt,_r,Me,gn,bn,xn,de,Wt,_n,Cn,zt,V,K,An,U,at,Sr,Ar,In,Pn,$n,Rn,Ln,Er,zn,Bn,jr,vt,Ae,ut,Un,Gn,Hn,Ee,Jn,Kn,L,Yn,Xn,eo,Mr,ua,$r,ro,Rr,G,H,oo,io,Br,ao,Ht,uo,Jt,lo,qr,mo,yo,vo,wo,To,Oo,_o,Co,Ao,Ko,Xo,xt,Ur,ei,ti,ri,si,Xt,Gr,Hr,li,pi,Jr,Pe,bi,xi,ki,Ti,Oi,_i,Zr,Ci,Si,Ai,ji,ct,Pi,Mi,Ri,Ni,he,Wi,zi,Yr,qi,Fi,Vi,Hi,er,pe,Zi,Yi,ea,ta,ra,Ut,sa,na,oa,ia,aa=ns(()=>{Gt();os=Object.create,Tt=Object.defineProperty,is=Object.getOwnPropertyDescriptor,as=Object.getOwnPropertyNames,us=Object.getPrototypeOf,ls=Object.prototype.hasOwnProperty,E=(e,s)=>()=>(s||e((s={exports:{}}).exports,s),s.exports),tr=(e,s)=>{for(var i in s)Tt(e,i,{get:s[i],enumerable:!0})},cs=(e,s,i,r)=>{if(s&&typeof s=="object"||typeof s=="function")for(let a of as(s))!ls.call(e,a)&&a!==i&&Tt(e,a,{get:()=>s[a],enumerable:!(r=is(s,a))||r.enumerable});return e},Te=(e,s,i)=>(i=e!=null?os(us(e)):{},cs(s||!e||!e.__esModule?Tt(i,"default",{value:e,enumerable:!0}):i,e)),ps=E((e,s)=>{var i=String,r=function(){return{isColorSupported:!1,reset:i,bold:i,dim:i,italic:i,underline:i,inverse:i,hidden:i,strikethrough:i,black:i,red:i,green:i,yellow:i,blue:i,magenta:i,cyan:i,white:i,gray:i,bgBlack:i,bgRed:i,bgGreen:i,bgYellow:i,bgBlue:i,bgMagenta:i,bgCyan:i,bgWhite:i,blackBright:i,redBright:i,greenBright:i,yellowBright:i,blueBright:i,magentaBright:i,cyanBright:i,whiteBright:i,bgBlackBright:i,bgRedBright:i,bgGreenBright:i,bgYellowBright:i,bgBlueBright:i,bgMagentaBright:i,bgCyanBright:i,bgWhiteBright:i}};s.exports=r(),s.exports.createColors=r}),rr=E(()=>{}),Ot=E((e,s)=>{"use strict";var i=ps(),r=rr(),a=class sr extends Error{constructor(u,p,y,m,n,t){super(u),this.name="CssSyntaxError",this.reason=u,n&&(this.file=n),m&&(this.source=m),t&&(this.plugin=t),typeof p<"u"&&typeof y<"u"&&(typeof p=="number"?(this.line=p,this.column=y):(this.line=p.line,this.column=p.column,this.endLine=y.line,this.endColumn=y.column)),this.setMessage(),Error.captureStackTrace&&Error.captureStackTrace(this,sr)}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(u){if(!this.source)return"";let p=this.source;u==null&&(u=i.isColorSupported);let y=l=>l,m=l=>l,n=l=>l;if(u){let{bold:l,gray:g,red:v}=i.createColors(!0);m=f=>l(v(f)),y=f=>g(f),r&&(n=f=>r(f))}let t=p.split(/\r?\n/),h=Math.max(this.line-3,0),c=Math.min(this.line+2,t.length),d=String(c).length;return t.slice(h,c).map((l,g)=>{let v=h+1+g,f=" "+(" "+v).slice(-d)+" | ";if(v===this.line){if(l.length>160){let O=20,b=Math.max(0,this.column-O),T=Math.max(this.column+O,this.endColumn+O),k=l.slice(b,T),x=y(f.replace(/\d/g," "))+l.slice(0,Math.min(this.column-1,O-1)).replace(/[^\t]/g," ");return m(">")+y(f)+n(k)+`
`+x+m("^")}let w=y(f.replace(/\d/g," "))+l.slice(0,this.column-1).replace(/[^\t]/g," ");return m(">")+y(f)+n(l)+`
`+w+m("^")}return" "+y(f)+n(l)}).join(`
`)}toString(){let u=this.showSourceCode();return u&&(u=`
`+u+`
`),this.name+": "+this.message+u}};s.exports=a,a.default=a}),_t=E((e,s)=>{"use strict";var i={after:`
`,beforeClose:`
`,beforeComment:`
`,beforeDecl:`
`,beforeOpen:" ",beforeRule:`
`,colon:": ",commentLeft:" ",commentRight:" ",emptyBody:"",indent:" ",semicolon:!1};function r(o){return o[0].toUpperCase()+o.slice(1)}var a=class{constructor(o){this.builder=o}atrule(o,u){let p="@"+o.name,y=o.params?this.rawValue(o,"params"):"";if(typeof o.raws.afterName<"u"?p+=o.raws.afterName:y&&(p+=" "),o.nodes)this.block(o,p+y);else{let m=(o.raws.between||"")+(u?";":"");this.builder(p+y+m,o)}}beforeAfter(o,u){let p;o.type==="decl"?p=this.raw(o,null,"beforeDecl"):o.type==="comment"?p=this.raw(o,null,"beforeComment"):u==="before"?p=this.raw(o,null,"beforeRule"):p=this.raw(o,null,"beforeClose");let y=o.parent,m=0;for(;y&&y.type!=="root";)m+=1,y=y.parent;if(p.includes(`
`)){let n=this.raw(o,null,"indent");if(n.length)for(let t=0;t<m;t++)p+=n}return p}block(o,u){let p=this.raw(o,"between","beforeOpen");this.builder(u+p+"{",o,"start");let y;o.nodes&&o.nodes.length?(this.body(o),y=this.raw(o,"after")):y=this.raw(o,"after","emptyBody"),y&&this.builder(y),this.builder("}",o,"end")}body(o){let u=o.nodes.length-1;for(;u>0&&o.nodes[u].type==="comment";)u-=1;let p=this.raw(o,"semicolon");for(let y=0;y<o.nodes.length;y++){let m=o.nodes[y],n=this.raw(m,"before");n&&this.builder(n),this.stringify(m,u!==y||p)}}comment(o){let u=this.raw(o,"left","commentLeft"),p=this.raw(o,"right","commentRight");this.builder("/*"+u+o.text+p+"*/",o)}decl(o,u){let p=this.raw(o,"between","colon"),y=o.prop+p+this.rawValue(o,"value");o.important&&(y+=o.raws.important||" !important"),u&&(y+=";"),this.builder(y,o)}document(o){this.body(o)}raw(o,u,p){let y;if(p||(p=u),u&&(y=o.raws[u],typeof y<"u"))return y;let m=o.parent;if(p==="before"&&(!m||m.type==="root"&&m.first===o||m&&m.type==="document"))return"";if(!m)return i[p];let n=o.root();if(n.rawCache||(n.rawCache={}),typeof n.rawCache[p]<"u")return n.rawCache[p];if(p==="before"||p==="after")return this.beforeAfter(o,p);{let t="raw"+r(p);this[t]?y=this[t](n,o):n.walk(h=>{if(y=h.raws[u],typeof y<"u")return!1})}return typeof y>"u"&&(y=i[p]),n.rawCache[p]=y,y}rawBeforeClose(o){let u;return o.walk(p=>{if(p.nodes&&p.nodes.length>0&&typeof p.raws.after<"u")return u=p.raws.after,u.includes(`
`)&&(u=u.replace(/[^\n]+$/,"")),!1}),u&&(u=u.replace(/\S/g,"")),u}rawBeforeComment(o,u){let p;return o.walkComments(y=>{if(typeof y.raws.before<"u")return p=y.raws.before,p.includes(`
`)&&(p=p.replace(/[^\n]+$/,"")),!1}),typeof p>"u"?p=this.raw(u,null,"beforeDecl"):p&&(p=p.replace(/\S/g,"")),p}rawBeforeDecl(o,u){let p;return o.walkDecls(y=>{if(typeof y.raws.before<"u")return p=y.raws.before,p.includes(`
`)&&(p=p.replace(/[^\n]+$/,"")),!1}),typeof p>"u"?p=this.raw(u,null,"beforeRule"):p&&(p=p.replace(/\S/g,"")),p}rawBeforeOpen(o){let u;return o.walk(p=>{if(p.type!=="decl"&&(u=p.raws.between,typeof u<"u"))return!1}),u}rawBeforeRule(o){let u;return o.walk(p=>{if(p.nodes&&(p.parent!==o||o.first!==p)&&typeof p.raws.before<"u")return u=p.raws.before,u.includes(`
`)&&(u=u.replace(/[^\n]+$/,"")),!1}),u&&(u=u.replace(/\S/g,"")),u}rawColon(o){let u;return o.walkDecls(p=>{if(typeof p.raws.between<"u")return u=p.raws.between.replace(/[^\s:]/g,""),!1}),u}rawEmptyBody(o){let u;return o.walk(p=>{if(p.nodes&&p.nodes.length===0&&(u=p.raws.after,typeof u<"u"))return!1}),u}rawIndent(o){if(o.raws.indent)return o.raws.indent;let u;return o.walk(p=>{let y=p.parent;if(y&&y!==o&&y.parent&&y.parent===o&&typeof p.raws.before<"u"){let m=p.raws.before.split(`
`);return u=m[m.length-1],u=u.replace(/\S/g,""),!1}}),u}rawSemicolon(o){let u;return o.walk(p=>{if(p.nodes&&p.nodes.length&&p.last.type==="decl"&&(u=p.raws.semicolon,typeof u<"u"))return!1}),u}rawValue(o,u){let p=o[u],y=o.raws[u];return y&&y.value===p?y.raw:p}root(o){this.body(o),o.raws.after&&this.builder(o.raws.after)}rule(o){this.block(o,this.rawValue(o,"selector")),o.raws.ownSemicolon&&this.builder(o.raws.ownSemicolon,o,"end")}stringify(o,u){if(!this[o.type])throw new Error("Unknown AST node type "+o.type+". Maybe you need to change PostCSS stringifier.");this[o.type](o,u)}};s.exports=a,a.default=a}),Xe=E((e,s)=>{"use strict";var i=_t();function r(a,o){new i(o).stringify(a)}s.exports=r,r.default=r}),Ct=E((e,s)=>{"use strict";s.exports.isClean=Symbol("isClean"),s.exports.my=Symbol("my")}),et=E((e,s)=>{"use strict";var i=Ot(),r=_t(),a=Xe(),{isClean:o,my:u}=Ct();function p(n,t){let h=new n.constructor;for(let c in n){if(!Object.prototype.hasOwnProperty.call(n,c)||c==="proxyCache")continue;let d=n[c],l=typeof d;c==="parent"&&l==="object"?t&&(h[c]=t):c==="source"?h[c]=d:Array.isArray(d)?h[c]=d.map(g=>p(g,h)):(l==="object"&&d!==null&&(d=p(d)),h[c]=d)}return h}function y(n,t){if(t&&typeof t.offset<"u")return t.offset;let h=1,c=1,d=0;for(let l=0;l<n.length;l++){if(c===t.line&&h===t.column){d=l;break}n[l]===`
`?(h=1,c+=1):h+=1}return d}var m=class{get proxyOf(){return this}constructor(n={}){this.raws={},this[o]=!1,this[u]=!0;for(let t in n)if(t==="nodes"){this.nodes=[];for(let h of n[t])typeof h.clone=="function"?this.append(h.clone()):this.append(h)}else this[t]=n[t]}addToError(n){if(n.postcssNode=this,n.stack&&this.source&&/\n\s{4}at /.test(n.stack)){let t=this.source;n.stack=n.stack.replace(/\n\s{4}at /,`$&${t.input.from}:${t.start.line}:${t.start.column}$&`)}return n}after(n){return this.parent.insertAfter(this,n),this}assign(n={}){for(let t in n)this[t]=n[t];return this}before(n){return this.parent.insertBefore(this,n),this}cleanRaws(n){delete this.raws.before,delete this.raws.after,n||delete this.raws.between}clone(n={}){let t=p(this);for(let h in n)t[h]=n[h];return t}cloneAfter(n={}){let t=this.clone(n);return this.parent.insertAfter(this,t),t}cloneBefore(n={}){let t=this.clone(n);return this.parent.insertBefore(this,t),t}error(n,t={}){if(this.source){let{end:h,start:c}=this.rangeBy(t);return this.source.input.error(n,{column:c.column,line:c.line},{column:h.column,line:h.line},t)}return new i(n)}getProxyProcessor(){return{get(n,t){return t==="proxyOf"?n:t==="root"?()=>n.root().toProxy():n[t]},set(n,t,h){return n[t]===h||(n[t]=h,(t==="prop"||t==="value"||t==="name"||t==="params"||t==="important"||t==="text")&&n.markDirty()),!0}}}markClean(){this[o]=!0}markDirty(){if(this[o]){this[o]=!1;let n=this;for(;n=n.parent;)n[o]=!1}}next(){if(!this.parent)return;let n=this.parent.index(this);return this.parent.nodes[n+1]}positionBy(n={}){let t=this.source.start;if(n.index)t=this.positionInside(n.index);else if(n.word){let h="document"in this.source.input?this.source.input.document:this.source.input.css,c=h.slice(y(h,this.source.start),y(h,this.source.end)).indexOf(n.word);c!==-1&&(t=this.positionInside(c))}return t}positionInside(n){let t=this.source.start.column,h=this.source.start.line,c="document"in this.source.input?this.source.input.document:this.source.input.css,d=y(c,this.source.start),l=d+n;for(let g=d;g<l;g++)c[g]===`
`?(t=1,h+=1):t+=1;return{column:t,line:h,offset:l}}prev(){if(!this.parent)return;let n=this.parent.index(this);return this.parent.nodes[n-1]}rangeBy(n={}){let t="document"in this.source.input?this.source.input.document:this.source.input.css,h={column:this.source.start.column,line:this.source.start.line,offset:y(t,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:y(t,this.source.end)+1}:{column:h.column+1,line:h.line,offset:h.offset+1};if(n.word){let d=t.slice(y(t,this.source.start),y(t,this.source.end)).indexOf(n.word);d!==-1&&(h=this.positionInside(d),c=this.positionInside(d+n.word.length))}else n.start?h={column:n.start.column,line:n.start.line,offset:y(t,n.start)}:n.index&&(h=this.positionInside(n.index)),n.end?c={column:n.end.column,line:n.end.line,offset:y(t,n.end)}:typeof n.endIndex=="number"?c=this.positionInside(n.endIndex):n.index&&(c=this.positionInside(n.index+1));return(c.line<h.line||c.line===h.line&&c.column<=h.column)&&(c={column:h.column+1,line:h.line,offset:h.offset+1}),{end:c,start:h}}raw(n,t){return new r().raw(this,n,t)}remove(){return this.parent&&this.parent.removeChild(this),this.parent=void 0,this}replaceWith(...n){if(this.parent){let t=this,h=!1;for(let c of n)c===this?h=!0:h?(this.parent.insertAfter(t,c),t=c):this.parent.insertBefore(t,c);h||this.remove()}return this}root(){let n=this;for(;n.parent&&n.parent.type!=="document";)n=n.parent;return n}toJSON(n,t){let h={},c=t==null;t=t||new Map;let d=0;for(let l in this){if(!Object.prototype.hasOwnProperty.call(this,l)||l==="parent"||l==="proxyCache")continue;let g=this[l];if(Array.isArray(g))h[l]=g.map(v=>typeof v=="object"&&v.toJSON?v.toJSON(null,t):v);else if(typeof g=="object"&&g.toJSON)h[l]=g.toJSON(null,t);else if(l==="source"){if(g==null)continue;let v=t.get(g.input);v==null&&(v=d,t.set(g.input,d),d++),h[l]={end:g.end,inputId:v,start:g.start}}else h[l]=g}return c&&(h.inputs=[...t.keys()].map(l=>l.toJSON())),h}toProxy(){return this.proxyCache||(this.proxyCache=new Proxy(this,this.getProxyProcessor())),this.proxyCache}toString(n=a){n.stringify&&(n=n.stringify);let t="";return n(this,h=>{t+=h}),t}warn(n,t,h={}){let c={node:this};for(let d in h)c[d]=h[d];return n.warn(t,c)}};s.exports=m,m.default=m}),Le=E((e,s)=>{"use strict";var i=et(),r=class extends i{constructor(a){super(a),this.type="comment"}};s.exports=r,r.default=r}),tt=E((e,s)=>{"use strict";var i=et(),r=class extends i{get variable(){return this.prop.startsWith("--")||this.prop[0]==="$"}constructor(a){a&&typeof a.value<"u"&&typeof a.value!="string"&&(a={...a,value:String(a.value)}),super(a),this.type="decl"}};s.exports=r,r.default=r}),me=E((e,s)=>{"use strict";var i=Le(),r=tt(),a=et(),{isClean:o,my:u}=Ct(),p,y,m,n;function t(d){return d.map(l=>(l.nodes&&(l.nodes=t(l.nodes)),delete l.source,l))}function h(d){if(d[o]=!1,d.proxyOf.nodes)for(let l of d.proxyOf.nodes)h(l)}var c=class nr extends a{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(...l){for(let g of l){let v=this.normalize(g,this.last);for(let f of v)this.proxyOf.nodes.push(f)}return this.markDirty(),this}cleanRaws(l){if(super.cleanRaws(l),this.nodes)for(let g of this.nodes)g.cleanRaws(l)}each(l){if(!this.proxyOf.nodes)return;let g=this.getIterator(),v,f;for(;this.indexes[g]<this.proxyOf.nodes.length&&(v=this.indexes[g],f=l(this.proxyOf.nodes[v],v),f!==!1);)this.indexes[g]+=1;return delete this.indexes[g],f}every(l){return this.nodes.every(l)}getIterator(){this.lastEach||(this.lastEach=0),this.indexes||(this.indexes={}),this.lastEach+=1;let l=this.lastEach;return this.indexes[l]=0,l}getProxyProcessor(){return{get(l,g){return g==="proxyOf"?l:l[g]?g==="each"||typeof g=="string"&&g.startsWith("walk")?(...v)=>l[g](...v.map(f=>typeof f=="function"?(w,O)=>f(w.toProxy(),O):f)):g==="every"||g==="some"?v=>l[g]((f,...w)=>v(f.toProxy(),...w)):g==="root"?()=>l.root().toProxy