@cas-smartdesign/image-tools 3.0.2 → 3.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/dist/docs/0_css-background.js +1 -0
- package/dist/docs/1_img-src.js +1 -0
- package/dist/docs/2_directive.js +5 -0
- package/dist/docs/doc.css +1 -1
- package/dist/docs/doc.mjs +78 -43
- package/dist/docs/image-tools.mjs +3 -1
- package/dist/image-tools-with-externals.js +21 -1
- package/dist/image-tools-with-externals.js.map +4 -4
- package/dist/image-tools.d.ts +18 -1
- package/dist/image-tools.mjs +41 -12
- package/dist/image-tools.mjs.map +1 -1
- package/npm-third-party-licenses.json +56 -46
- package/package.json +6 -3
- package/dist/docs/css-background.js +0 -1
- package/dist/docs/img-src.js +0 -1
package/dist/docs/doc.mjs
CHANGED
|
@@ -1,11 +1,10 @@
|
|
|
1
|
-
|
|
1
|
+
const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["./0_css-background.js","./image-tools.mjs","./1_img-src.js","./2_directive.js"])))=>i.map(i=>d[i]);
|
|
2
|
+
(function(){const g=document.createElement("link").relList;if(g&&g.supports&&g.supports("modulepreload"))return;for(const n of document.querySelectorAll('link[rel="modulepreload"]'))f(n);new MutationObserver(n=>{for(const h of n)if(h.type==="childList")for(const s of h.addedNodes)s.tagName==="LINK"&&s.rel==="modulepreload"&&f(s)}).observe(document,{childList:!0,subtree:!0});function b(n){const h={};return n.integrity&&(h.integrity=n.integrity),n.referrerPolicy&&(h.referrerPolicy=n.referrerPolicy),n.crossOrigin==="use-credentials"?h.credentials="include":n.crossOrigin==="anonymous"?h.credentials="omit":h.credentials="same-origin",h}function f(n){if(n.ep)return;n.ep=!0;const h=b(n);fetch(n.href,h)}})();const Tn="modulepreload",Ln=function(a,g){return new URL(a,g).href},or={},Lt=function(g,b,f){let n=Promise.resolve();if(b&&b.length>0){let c=function(e){return Promise.all(e.map(i=>Promise.resolve(i).then(t=>({status:"fulfilled",value:t}),t=>({status:"rejected",reason:t}))))};const s=document.getElementsByTagName("link"),p=document.querySelector("meta[property=csp-nonce]"),x=p?.nonce||p?.getAttribute("nonce");n=c(b.map(e=>{if(e=Ln(e,f),e in or)return;or[e]=!0;const i=e.endsWith(".css"),t=i?'[rel="stylesheet"]':"";if(!!f)for(let u=s.length-1;u>=0;u--){const d=s[u];if(d.href===e&&(!i||d.rel==="stylesheet"))return}else if(document.querySelector(`link[href="${e}"]${t}`))return;const l=document.createElement("link");if(l.rel=i?"stylesheet":Tn,i||(l.as="script"),l.crossOrigin="",l.href=e,x&&l.setAttribute("nonce",x),document.head.appendChild(l),i)return new Promise((u,d)=>{l.addEventListener("load",u),l.addEventListener("error",()=>d(new Error(`Unable to preload CSS for ${e}`)))})}))}function h(s){const p=new Event("vite:preloadError",{cancelable:!0});if(p.payload=s,window.dispatchEvent(p),!p.defaultPrevented)throw s}return n.then(s=>{for(const p of s||[])p.status==="rejected"&&h(p.reason);return g().catch(h)})},jn=`<div id="css-example">
|
|
2
3
|
<div class="image-container"></div>
|
|
3
4
|
<button id="refresh">Refresh images</button>
|
|
4
5
|
</div>
|
|
5
|
-
`,
|
|
6
|
-
|
|
7
|
-
(some of them may not load on purpose)</p>
|
|
8
|
-
`,bn=`.image-container {
|
|
6
|
+
`,Bn=`<h3 id="using-css-background">Using CSS background</h3>
|
|
7
|
+
`,jt=`.image-container {
|
|
9
8
|
max-width: 512px;
|
|
10
9
|
}
|
|
11
10
|
|
|
@@ -15,7 +14,7 @@
|
|
|
15
14
|
display: inline-block;
|
|
16
15
|
background-size: cover;
|
|
17
16
|
}
|
|
18
|
-
`,
|
|
17
|
+
`,zn=`import ImageTools from "@cas-smartdesign/image-tools";
|
|
19
18
|
|
|
20
19
|
const placeHolderImage = "./placeholder.svg";
|
|
21
20
|
const container = document.querySelector("#css-example");
|
|
@@ -24,7 +23,7 @@ const updateImage = (element: HTMLElement) => {
|
|
|
24
23
|
element.classList.add("image");
|
|
25
24
|
if (Math.random() > 0.3) {
|
|
26
25
|
const cacheBuster = Math.floor(Math.random() * 2000);
|
|
27
|
-
ImageTools.showImage(element, \`https://
|
|
26
|
+
ImageTools.showImage(element, \`https://picsum.photos/500?\${cacheBuster}\`, placeHolderImage);
|
|
28
27
|
} else {
|
|
29
28
|
ImageTools.showImage(element, \`http://wrong-url\`, placeHolderImage);
|
|
30
29
|
}
|
|
@@ -43,14 +42,12 @@ refreshButton.onclick = () => {
|
|
|
43
42
|
updateImage(imageElement);
|
|
44
43
|
});
|
|
45
44
|
};
|
|
46
|
-
`,
|
|
45
|
+
`,Dn={mainContent:jn,description:Bn,css:jt,initializer:{content:zn,type:"typescript",initialize:()=>Lt(()=>import("./0_css-background.js"),__vite__mapDeps([0,1]),import.meta.url)}},Un=Object.freeze(Object.defineProperty({__proto__:null,default:Dn},Symbol.toStringTag,{value:"Module"})),$n=`<div id="img-example">
|
|
47
46
|
<div class="image-container"></div>
|
|
48
47
|
<button id="refresh">Refresh images</button>
|
|
49
48
|
</div>
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
(some of them may not load on purpose)</p>
|
|
53
|
-
`,jr=`import ImageTools from "@cas-smartdesign/image-tools";
|
|
49
|
+
`,qn=`<h3 id="using-img-elements-with-src-attribute">Using IMG elements with SRC attribute</h3>
|
|
50
|
+
`,Fn=`import ImageTools from "@cas-smartdesign/image-tools";
|
|
54
51
|
|
|
55
52
|
const placeHolderImage = "./placeholder.svg";
|
|
56
53
|
const container = document.querySelector("#img-example");
|
|
@@ -59,7 +56,7 @@ const updateImage = (element: HTMLElement) => {
|
|
|
59
56
|
element.classList.add("image");
|
|
60
57
|
if (Math.random() > 0.3) {
|
|
61
58
|
const cacheBuster = Math.floor(Math.random() * 2000);
|
|
62
|
-
ImageTools.showImage(element, \`https://
|
|
59
|
+
ImageTools.showImage(element, \`https://picsum.photos/500?\${cacheBuster}\`, placeHolderImage);
|
|
63
60
|
} else {
|
|
64
61
|
ImageTools.showImage(element, \`http://wrong-url\`, placeHolderImage);
|
|
65
62
|
}
|
|
@@ -78,35 +75,79 @@ refreshButton.onclick = () => {
|
|
|
78
75
|
updateImage(imageElement);
|
|
79
76
|
});
|
|
80
77
|
};
|
|
81
|
-
`,
|
|
82
|
-
|
|
83
|
-
|
|
78
|
+
`,Hn={mainContent:$n,description:qn,css:jt,initializer:{content:Fn,type:"typescript",initialize:()=>Lt(()=>import("./1_img-src.js"),__vite__mapDeps([2,1]),import.meta.url)}},Wn=Object.freeze(Object.defineProperty({__proto__:null,default:Hn},Symbol.toStringTag,{value:"Module"})),Gn=`<div id="lit-example">
|
|
79
|
+
<div class="image-container"></div>
|
|
80
|
+
<button id="refresh">Refresh images</button>
|
|
81
|
+
</div>
|
|
82
|
+
`,Zn=`<h3 id="using-as-a-lit-directive">Using as a lit directive</h3>
|
|
83
|
+
`,Jn=`import { placeholderDirective as placeholder } from "@cas-smartdesign/image-tools";
|
|
84
|
+
import { html, render } from "lit-html";
|
|
85
|
+
import { map } from "lit-html/directives/map.js";
|
|
86
|
+
import { range } from "lit-html/directives/range.js";
|
|
87
|
+
|
|
88
|
+
const placeHolderImage = "./placeholder.svg";
|
|
89
|
+
const container = document.querySelector("#lit-example");
|
|
90
|
+
const imageContainer = container.querySelector(".image-container") as HTMLElement;
|
|
91
|
+
|
|
92
|
+
const getImageUrl = () => {
|
|
93
|
+
if (Math.random() > 0.3) {
|
|
94
|
+
const cacheBuster = Math.floor(Math.random() * 2000);
|
|
95
|
+
return \`https://picsum.photos/500?\${cacheBuster}\`;
|
|
96
|
+
} else {
|
|
97
|
+
return \`http://wrong-url\`;
|
|
98
|
+
}
|
|
99
|
+
};
|
|
100
|
+
|
|
101
|
+
const renderImages = () => {
|
|
102
|
+
render(
|
|
103
|
+
html\`\${map(
|
|
104
|
+
range(8),
|
|
105
|
+
() =>
|
|
106
|
+
html\`<img class="image" src=\${placeholder(getImageUrl(), placeHolderImage)} />
|
|
107
|
+
<div
|
|
108
|
+
class="image"
|
|
109
|
+
style="background-image:\${placeholder(getImageUrl(), placeHolderImage)};margin-right: 4px"
|
|
110
|
+
></div>\`,
|
|
111
|
+
)}\`,
|
|
112
|
+
imageContainer,
|
|
113
|
+
);
|
|
114
|
+
};
|
|
115
|
+
renderImages();
|
|
116
|
+
|
|
117
|
+
const refreshButton = container.querySelector("#refresh") as HTMLButtonElement;
|
|
118
|
+
refreshButton.onclick = renderImages;
|
|
119
|
+
`,Kn={mainContent:Gn,description:Zn,css:jt,initializer:{content:Jn,type:"typescript",initialize:()=>Lt(()=>import("./2_directive.js"),__vite__mapDeps([3,1]),import.meta.url)}},Vn=Object.freeze(Object.defineProperty({__proto__:null,default:Kn},Symbol.toStringTag,{value:"Module"}));function Br(a){return a&&a.__esModule&&Object.prototype.hasOwnProperty.call(a,"default")?a.default:a}function Xn(a){if(Object.prototype.hasOwnProperty.call(a,"__esModule"))return a;var g=a.default;if(typeof g=="function"){var b=function f(){var n=!1;try{n=this instanceof f}catch{}return n?Reflect.construct(g,arguments,this.constructor):g.apply(this,arguments)};b.prototype=g.prototype}else b={};return Object.defineProperty(b,"__esModule",{value:!0}),Object.keys(a).forEach(function(f){var n=Object.getOwnPropertyDescriptor(a,f);Object.defineProperty(b,f,n.get?n:{enumerable:!0,get:function(){return a[f]}})}),b}var $e={exports:{}},ar;function Qn(){if(ar)return $e.exports;ar=1;var a=String,g=function(){return{isColorSupported:!1,reset:a,bold:a,dim:a,italic:a,underline:a,inverse:a,hidden:a,strikethrough:a,black:a,red:a,green:a,yellow:a,blue:a,magenta:a,cyan:a,white:a,gray:a,bgBlack:a,bgRed:a,bgGreen:a,bgYellow:a,bgBlue:a,bgMagenta:a,bgCyan:a,bgWhite:a,blackBright:a,redBright:a,greenBright:a,yellowBright:a,blueBright:a,magentaBright:a,cyanBright:a,whiteBright:a,bgBlackBright:a,bgRedBright:a,bgGreenBright:a,bgYellowBright:a,bgBlueBright:a,bgMagentaBright:a,bgCyanBright:a,bgWhiteBright:a}};return $e.exports=g(),$e.exports.createColors=g,$e.exports}const Yn={},ei=Object.freeze(Object.defineProperty({__proto__:null,default:Yn},Symbol.toStringTag,{value:"Module"})),le=Xn(ei);var at,lr;function Bt(){if(lr)return at;lr=1;let a=Qn(),g=le;class b extends Error{constructor(n,h,s,p,x,c){super(n),this.name="CssSyntaxError",this.reason=n,x&&(this.file=x),p&&(this.source=p),c&&(this.plugin=c),typeof h<"u"&&typeof s<"u"&&(typeof h=="number"?(this.line=h,this.column=s):(this.line=h.line,this.column=h.column,this.endLine=s.line,this.endColumn=s.column)),this.setMessage(),Error.captureStackTrace&&Error.captureStackTrace(this,b)}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(n){if(!this.source)return"";let h=this.source;n==null&&(n=a.isColorSupported);let s=r=>r,p=r=>r,x=r=>r;if(n){let{bold:r,gray:l,red:u}=a.createColors(!0);p=d=>r(u(d)),s=d=>l(d),g&&(x=d=>g(d))}let c=h.split(/\r?\n/),e=Math.max(this.line-3,0),i=Math.min(this.line+2,c.length),t=String(i).length;return c.slice(e,i).map((r,l)=>{let u=e+1+l,d=" "+(" "+u).slice(-t)+" | ";if(u===this.line){if(r.length>160){let S=20,w=Math.max(0,this.column-S),y=Math.max(this.column+S,this.endColumn+S),m=r.slice(w,y),k=s(d.replace(/\d/g," "))+r.slice(0,Math.min(this.column-1,S-1)).replace(/[^\t]/g," ");return p(">")+s(d)+x(m)+`
|
|
120
|
+
`+k+p("^")}let E=s(d.replace(/\d/g," "))+r.slice(0,this.column-1).replace(/[^\t]/g," ");return p(">")+s(d)+x(r)+`
|
|
121
|
+
`+E+p("^")}return" "+s(d)+x(r)}).join(`
|
|
122
|
+
`)}toString(){let n=this.showSourceCode();return n&&(n=`
|
|
84
123
|
|
|
85
|
-
`+
|
|
86
|
-
`),this.name+": "+this.message+
|
|
124
|
+
`+n+`
|
|
125
|
+
`),this.name+": "+this.message+n}}return at=b,b.default=b,at}var lt,cr;function zr(){if(cr)return lt;cr=1;const a={after:`
|
|
87
126
|
`,beforeClose:`
|
|
88
127
|
`,beforeComment:`
|
|
89
128
|
`,beforeDecl:`
|
|
90
129
|
`,beforeOpen:" ",beforeRule:`
|
|
91
|
-
`,colon:": ",commentLeft:" ",commentRight:" ",emptyBody:"",indent:" ",semicolon:!1};function
|
|
92
|
-
`)){let
|
|
93
|
-
`)&&(
|
|
94
|
-
`)&&(
|
|
95
|
-
`)&&(
|
|
96
|
-
`)&&(
|
|
97
|
-
`);return
|
|
98
|
-
`?(
|
|
99
|
-
`);n=new Array(o.length);let s=0;for(let a=0,l=o.length;a<l;a++)n[a]=s,s+=o[a].length+1;this[ot]=n}t=n[n.length-1];let i=0;if(e>=t)i=n.length-1;else{let o=n.length-2,s;for(;i<o;)if(s=i+(o-i>>1),e<n[s])o=s-1;else if(e>=n[s+1])i=s+1;else{i=s;break}}return{col:e-n[i]+1,line:i+1}}mapResolve(e){return/^\w+:\/\//.test(e)?e:bt(this.map.consumer().sourceRoot||this.map.root||".",e)}origin(e,t,n,i){if(!this.map)return!1;let o=this.map.consumer(),s=o.originalPositionFor({column:t,line:e});if(!s.source)return!1;let a;typeof n=="number"&&(a=o.originalPositionFor({column:i,line:n}));let l;mt(s.source)?l=ke(s.source):l=new URL(s.source,this.map.consumer().sourceRoot||ke(this.map.mapFile));let c={column:s.column,endColumn:a&&a.column,endLine:a&&a.line,line:s.line,url:l.toString()};if(l.protocol==="file:")if(Vt)c.file=Vt(l);else throw new Error("file: protocol is not available in this PostCSS build");let h=o.sourceContentFor(s.source);return h&&(c.source=h),c}toJSON(){let e={};for(let t of["hasBOM","css","file","id"])this[t]!=null&&(e[t]=this[t]);return this.map&&(e.map={...this.map},e.map.consumerCache&&(e.map.consumerCache=void 0)),e}get from(){return this.file||this.id}};var qe=Be;Be.default=Be;st&&st.registerInput&&st.registerInput(Be);let{SourceMapConsumer:Sn,SourceMapGenerator:$e}=j,{dirname:je,relative:_n,resolve:On,sep:kn}=j,{pathToFileURL:Qt}=j,ui=qe,hi=!!(Sn&&$e),fi=!!(je&&On&&_n&&kn),di=class{constructor(e,t,n,i){this.stringify=e,this.mapOpts=n.map||{},this.root=t,this.opts=n,this.css=i,this.usesFileUrls=!this.mapOpts.from&&this.mapOpts.absolute,this.memoizedFileURLs=new Map,this.memoizedPaths=new Map,this.memoizedURLs=new Map}addAnnotation(){let e;this.isInline()?e="data:application/json;base64,"+this.toBase64(this.map.toString()):typeof this.mapOpts.annotation=="string"?e=this.mapOpts.annotation:typeof this.mapOpts.annotation=="function"?e=this.mapOpts.annotation(this.opts.to,this.root):e=this.outputFile()+".map";let t=`
|
|
130
|
+
`,colon:": ",commentLeft:" ",commentRight:" ",emptyBody:"",indent:" ",semicolon:!1};function g(f){return f[0].toUpperCase()+f.slice(1)}class b{constructor(n){this.builder=n}atrule(n,h){let s="@"+n.name,p=n.params?this.rawValue(n,"params"):"";if(typeof n.raws.afterName<"u"?s+=n.raws.afterName:p&&(s+=" "),n.nodes)this.block(n,s+p);else{let x=(n.raws.between||"")+(h?";":"");this.builder(s+p+x,n)}}beforeAfter(n,h){let s;n.type==="decl"?s=this.raw(n,null,"beforeDecl"):n.type==="comment"?s=this.raw(n,null,"beforeComment"):h==="before"?s=this.raw(n,null,"beforeRule"):s=this.raw(n,null,"beforeClose");let p=n.parent,x=0;for(;p&&p.type!=="root";)x+=1,p=p.parent;if(s.includes(`
|
|
131
|
+
`)){let c=this.raw(n,null,"indent");if(c.length)for(let e=0;e<x;e++)s+=c}return s}block(n,h){let s=this.raw(n,"between","beforeOpen");this.builder(h+s+"{",n,"start");let p;n.nodes&&n.nodes.length?(this.body(n),p=this.raw(n,"after")):p=this.raw(n,"after","emptyBody"),p&&this.builder(p),this.builder("}",n,"end")}body(n){let h=n.nodes.length-1;for(;h>0&&n.nodes[h].type==="comment";)h-=1;let s=this.raw(n,"semicolon");for(let p=0;p<n.nodes.length;p++){let x=n.nodes[p],c=this.raw(x,"before");c&&this.builder(c),this.stringify(x,h!==p||s)}}comment(n){let h=this.raw(n,"left","commentLeft"),s=this.raw(n,"right","commentRight");this.builder("/*"+h+n.text+s+"*/",n)}decl(n,h){let s=this.raw(n,"between","colon"),p=n.prop+s+this.rawValue(n,"value");n.important&&(p+=n.raws.important||" !important"),h&&(p+=";"),this.builder(p,n)}document(n){this.body(n)}raw(n,h,s){let p;if(s||(s=h),h&&(p=n.raws[h],typeof p<"u"))return p;let x=n.parent;if(s==="before"&&(!x||x.type==="root"&&x.first===n||x&&x.type==="document"))return"";if(!x)return a[s];let c=n.root();if(c.rawCache||(c.rawCache={}),typeof c.rawCache[s]<"u")return c.rawCache[s];if(s==="before"||s==="after")return this.beforeAfter(n,s);{let e="raw"+g(s);this[e]?p=this[e](c,n):c.walk(i=>{if(p=i.raws[h],typeof p<"u")return!1})}return typeof p>"u"&&(p=a[s]),c.rawCache[s]=p,p}rawBeforeClose(n){let h;return n.walk(s=>{if(s.nodes&&s.nodes.length>0&&typeof s.raws.after<"u")return h=s.raws.after,h.includes(`
|
|
132
|
+
`)&&(h=h.replace(/[^\n]+$/,"")),!1}),h&&(h=h.replace(/\S/g,"")),h}rawBeforeComment(n,h){let s;return n.walkComments(p=>{if(typeof p.raws.before<"u")return s=p.raws.before,s.includes(`
|
|
133
|
+
`)&&(s=s.replace(/[^\n]+$/,"")),!1}),typeof s>"u"?s=this.raw(h,null,"beforeDecl"):s&&(s=s.replace(/\S/g,"")),s}rawBeforeDecl(n,h){let s;return n.walkDecls(p=>{if(typeof p.raws.before<"u")return s=p.raws.before,s.includes(`
|
|
134
|
+
`)&&(s=s.replace(/[^\n]+$/,"")),!1}),typeof s>"u"?s=this.raw(h,null,"beforeRule"):s&&(s=s.replace(/\S/g,"")),s}rawBeforeOpen(n){let h;return n.walk(s=>{if(s.type!=="decl"&&(h=s.raws.between,typeof h<"u"))return!1}),h}rawBeforeRule(n){let h;return n.walk(s=>{if(s.nodes&&(s.parent!==n||n.first!==s)&&typeof s.raws.before<"u")return h=s.raws.before,h.includes(`
|
|
135
|
+
`)&&(h=h.replace(/[^\n]+$/,"")),!1}),h&&(h=h.replace(/\S/g,"")),h}rawColon(n){let h;return n.walkDecls(s=>{if(typeof s.raws.between<"u")return h=s.raws.between.replace(/[^\s:]/g,""),!1}),h}rawEmptyBody(n){let h;return n.walk(s=>{if(s.nodes&&s.nodes.length===0&&(h=s.raws.after,typeof h<"u"))return!1}),h}rawIndent(n){if(n.raws.indent)return n.raws.indent;let h;return n.walk(s=>{let p=s.parent;if(p&&p!==n&&p.parent&&p.parent===n&&typeof s.raws.before<"u"){let x=s.raws.before.split(`
|
|
136
|
+
`);return h=x[x.length-1],h=h.replace(/\S/g,""),!1}}),h}rawSemicolon(n){let h;return n.walk(s=>{if(s.nodes&&s.nodes.length&&s.last.type==="decl"&&(h=s.raws.semicolon,typeof h<"u"))return!1}),h}rawValue(n,h){let s=n[h],p=n.raws[h];return p&&p.value===s?p.raw:s}root(n){this.body(n),n.raws.after&&this.builder(n.raws.after)}rule(n){this.block(n,this.rawValue(n,"selector")),n.raws.ownSemicolon&&this.builder(n.raws.ownSemicolon,n,"end")}stringify(n,h){if(!this[n.type])throw new Error("Unknown AST node type "+n.type+". Maybe you need to change PostCSS stringifier.");this[n.type](n,h)}}return lt=b,b.default=b,lt}var ct,ur;function We(){if(ur)return ct;ur=1;let a=zr();function g(b,f){new a(f).stringify(b)}return ct=g,g.default=g,ct}var qe={},hr;function zt(){return hr||(hr=1,qe.isClean=Symbol("isClean"),qe.my=Symbol("my")),qe}var ut,fr;function Ge(){if(fr)return ut;fr=1;let a=Bt(),g=zr(),b=We(),{isClean:f,my:n}=zt();function h(x,c){let e=new x.constructor;for(let i in x){if(!Object.prototype.hasOwnProperty.call(x,i)||i==="proxyCache")continue;let t=x[i],r=typeof t;i==="parent"&&r==="object"?c&&(e[i]=c):i==="source"?e[i]=t:Array.isArray(t)?e[i]=t.map(l=>h(l,e)):(r==="object"&&t!==null&&(t=h(t)),e[i]=t)}return e}function s(x,c){if(c&&typeof c.offset<"u")return c.offset;let e=1,i=1,t=0;for(let r=0;r<x.length;r++){if(i===c.line&&e===c.column){t=r;break}x[r]===`
|
|
137
|
+
`?(e=1,i+=1):e+=1}return t}class p{get proxyOf(){return this}constructor(c={}){this.raws={},this[f]=!1,this[n]=!0;for(let e in c)if(e==="nodes"){this.nodes=[];for(let i of c[e])typeof i.clone=="function"?this.append(i.clone()):this.append(i)}else this[e]=c[e]}addToError(c){if(c.postcssNode=this,c.stack&&this.source&&/\n\s{4}at /.test(c.stack)){let e=this.source;c.stack=c.stack.replace(/\n\s{4}at /,`$&${e.input.from}:${e.start.line}:${e.start.column}$&`)}return c}after(c){return this.parent.insertAfter(this,c),this}assign(c={}){for(let e in c)this[e]=c[e];return this}before(c){return this.parent.insertBefore(this,c),this}cleanRaws(c){delete this.raws.before,delete this.raws.after,c||delete this.raws.between}clone(c={}){let e=h(this);for(let i in c)e[i]=c[i];return e}cloneAfter(c={}){let e=this.clone(c);return this.parent.insertAfter(this,e),e}cloneBefore(c={}){let e=this.clone(c);return this.parent.insertBefore(this,e),e}error(c,e={}){if(this.source){let{end:i,start:t}=this.rangeBy(e);return this.source.input.error(c,{column:t.column,line:t.line},{column:i.column,line:i.line},e)}return new a(c)}getProxyProcessor(){return{get(c,e){return e==="proxyOf"?c:e==="root"?()=>c.root().toProxy():c[e]},set(c,e,i){return c[e]===i||(c[e]=i,(e==="prop"||e==="value"||e==="name"||e==="params"||e==="important"||e==="text")&&c.markDirty()),!0}}}markClean(){this[f]=!0}markDirty(){if(this[f]){this[f]=!1;let c=this;for(;c=c.parent;)c[f]=!1}}next(){if(!this.parent)return;let c=this.parent.index(this);return this.parent.nodes[c+1]}positionBy(c={}){let e=this.source.start;if(c.index)e=this.positionInside(c.index);else if(c.word){let i="document"in this.source.input?this.source.input.document:this.source.input.css,r=i.slice(s(i,this.source.start),s(i,this.source.end)).indexOf(c.word);r!==-1&&(e=this.positionInside(r))}return e}positionInside(c){let e=this.source.start.column,i=this.source.start.line,t="document"in this.source.input?this.source.input.document:this.source.input.css,r=s(t,this.source.start),l=r+c;for(let u=r;u<l;u++)t[u]===`
|
|
138
|
+
`?(e=1,i+=1):e+=1;return{column:e,line:i,offset:l}}prev(){if(!this.parent)return;let c=this.parent.index(this);return this.parent.nodes[c-1]}rangeBy(c={}){let e="document"in this.source.input?this.source.input.document:this.source.input.css,i={column:this.source.start.column,line:this.source.start.line,offset:s(e,this.source.start)},t=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:s(e,this.source.end)+1}:{column:i.column+1,line:i.line,offset:i.offset+1};if(c.word){let l=e.slice(s(e,this.source.start),s(e,this.source.end)).indexOf(c.word);l!==-1&&(i=this.positionInside(l),t=this.positionInside(l+c.word.length))}else c.start?i={column:c.start.column,line:c.start.line,offset:s(e,c.start)}:c.index&&(i=this.positionInside(c.index)),c.end?t={column:c.end.column,line:c.end.line,offset:s(e,c.end)}:typeof c.endIndex=="number"?t=this.positionInside(c.endIndex):c.index&&(t=this.positionInside(c.index+1));return(t.line<i.line||t.line===i.line&&t.column<=i.column)&&(t={column:i.column+1,line:i.line,offset:i.offset+1}),{end:t,start:i}}raw(c,e){return new g().raw(this,c,e)}remove(){return this.parent&&this.parent.removeChild(this),this.parent=void 0,this}replaceWith(...c){if(this.parent){let e=this,i=!1;for(let t of c)t===this?i=!0:i?(this.parent.insertAfter(e,t),e=t):this.parent.insertBefore(e,t);i||this.remove()}return this}root(){let c=this;for(;c.parent&&c.parent.type!=="document";)c=c.parent;return c}toJSON(c,e){let i={},t=e==null;e=e||new Map;let r=0;for(let l in this){if(!Object.prototype.hasOwnProperty.call(this,l)||l==="parent"||l==="proxyCache")continue;let u=this[l];if(Array.isArray(u))i[l]=u.map(d=>typeof d=="object"&&d.toJSON?d.toJSON(null,e):d);else if(typeof u=="object"&&u.toJSON)i[l]=u.toJSON(null,e);else if(l==="source"){if(u==null)continue;let d=e.get(u.input);d==null&&(d=r,e.set(u.input,r),r++),i[l]={end:u.end,inputId:d,start:u.start}}else i[l]=u}return t&&(i.inputs=[...e.keys()].map(l=>l.toJSON())),i}toProxy(){return this.proxyCache||(this.proxyCache=new Proxy(this,this.getProxyProcessor())),this.proxyCache}toString(c=b){c.stringify&&(c=c.stringify);let e="";return c(this,i=>{e+=i}),e}warn(c,e,i={}){let t={node:this};for(let r in i)t[r]=i[r];return c.warn(e,t)}}return ut=p,p.default=p,ut}var ht,dr;function Ze(){if(dr)return ht;dr=1;let a=Ge();class g extends a{constructor(f){super(f),this.type="comment"}}return ht=g,g.default=g,ht}var ft,pr;function Je(){if(pr)return ft;pr=1;let a=Ge();class g extends a{get variable(){return this.prop.startsWith("--")||this.prop[0]==="$"}constructor(f){f&&typeof f.value<"u"&&typeof f.value!="string"&&(f={...f,value:String(f.value)}),super(f),this.type="decl"}}return ft=g,g.default=g,ft}var dt,gr;function ve(){if(gr)return dt;gr=1;let a=Ze(),g=Je(),b=Ge(),{isClean:f,my:n}=zt(),h,s,p,x;function c(t){return t.map(r=>(r.nodes&&(r.nodes=c(r.nodes)),delete r.source,r))}function e(t){if(t[f]=!1,t.proxyOf.nodes)for(let r of t.proxyOf.nodes)e(r)}class i extends b{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(...r){for(let l of r){let u=this.normalize(l,this.last);for(let d of u)this.proxyOf.nodes.push(d)}return this.markDirty(),this}cleanRaws(r){if(super.cleanRaws(r),this.nodes)for(let l of this.nodes)l.cleanRaws(r)}each(r){if(!this.proxyOf.nodes)return;let l=this.getIterator(),u,d;for(;this.indexes[l]<this.proxyOf.nodes.length&&(u=this.indexes[l],d=r(this.proxyOf.nodes[u],u),d!==!1);)this.indexes[l]+=1;return delete this.indexes[l],d}every(r){return this.nodes.every(r)}getIterator(){this.lastEach||(this.lastEach=0),this.indexes||(this.indexes={}),this.lastEach+=1;let r=this.lastEach;return this.indexes[r]=0,r}getProxyProcessor(){return{get(r,l){return l==="proxyOf"?r:r[l]?l==="each"||typeof l=="string"&&l.startsWith("walk")?(...u)=>r[l](...u.map(d=>typeof d=="function"?(E,S)=>d(E.toProxy(),S):d)):l==="every"||l==="some"?u=>r[l]((d,...E)=>u(d.toProxy(),...E)):l==="root"?()=>r.root().toProxy():l==="nodes"?r.nodes.map(u=>u.toProxy()):l==="first"||l==="last"?r[l].toProxy():r[l]:r[l]},set(r,l,u){return r[l]===u||(r[l]=u,(l==="name"||l==="params"||l==="selector")&&r.markDirty()),!0}}}index(r){return typeof r=="number"?r:(r.proxyOf&&(r=r.proxyOf),this.proxyOf.nodes.indexOf(r))}insertAfter(r,l){let u=this.index(r),d=this.normalize(l,this.proxyOf.nodes[u]).reverse();u=this.index(r);for(let S of d)this.proxyOf.nodes.splice(u+1,0,S);let E;for(let S in this.indexes)E=this.indexes[S],u<E&&(this.indexes[S]=E+d.length);return this.markDirty(),this}insertBefore(r,l){let u=this.index(r),d=u===0?"prepend":!1,E=this.normalize(l,this.proxyOf.nodes[u],d).reverse();u=this.index(r);for(let w of E)this.proxyOf.nodes.splice(u,0,w);let S;for(let w in this.indexes)S=this.indexes[w],u<=S&&(this.indexes[w]=S+E.length);return this.markDirty(),this}normalize(r,l){if(typeof r=="string")r=c(s(r).nodes);else if(typeof r>"u")r=[];else if(Array.isArray(r)){r=r.slice(0);for(let d of r)d.parent&&d.parent.removeChild(d,"ignore")}else if(r.type==="root"&&this.type!=="document"){r=r.nodes.slice(0);for(let d of r)d.parent&&d.parent.removeChild(d,"ignore")}else if(r.type)r=[r];else if(r.prop){if(typeof r.value>"u")throw new Error("Value field is missed in node creation");typeof r.value!="string"&&(r.value=String(r.value)),r=[new g(r)]}else if(r.selector||r.selectors)r=[new x(r)];else if(r.name)r=[new h(r)];else if(r.text)r=[new a(r)];else throw new Error("Unknown node type in node creation");return r.map(d=>(d[n]||i.rebuild(d),d=d.proxyOf,d.parent&&d.parent.removeChild(d),d[f]&&e(d),d.raws||(d.raws={}),typeof d.raws.before>"u"&&l&&typeof l.raws.before<"u"&&(d.raws.before=l.raws.before.replace(/\S/g,"")),d.parent=this.proxyOf,d))}prepend(...r){r=r.reverse();for(let l of r){let u=this.normalize(l,this.first,"prepend").reverse();for(let d of u)this.proxyOf.nodes.unshift(d);for(let d in this.indexes)this.indexes[d]=this.indexes[d]+u.length}return this.markDirty(),this}push(r){return r.parent=this,this.proxyOf.nodes.push(r),this}removeAll(){for(let r of this.proxyOf.nodes)r.parent=void 0;return this.proxyOf.nodes=[],this.markDirty(),this}removeChild(r){r=this.index(r),this.proxyOf.nodes[r].parent=void 0,this.proxyOf.nodes.splice(r,1);let l;for(let u in this.indexes)l=this.indexes[u],l>=r&&(this.indexes[u]=l-1);return this.markDirty(),this}replaceValues(r,l,u){return u||(u=l,l={}),this.walkDecls(d=>{l.props&&!l.props.includes(d.prop)||l.fast&&!d.value.includes(l.fast)||(d.value=d.value.replace(r,u))}),this.markDirty(),this}some(r){return this.nodes.some(r)}walk(r){return this.each((l,u)=>{let d;try{d=r(l,u)}catch(E){throw l.addToError(E)}return d!==!1&&l.walk&&(d=l.walk(r)),d})}walkAtRules(r,l){return l?r instanceof RegExp?this.walk((u,d)=>{if(u.type==="atrule"&&r.test(u.name))return l(u,d)}):this.walk((u,d)=>{if(u.type==="atrule"&&u.name===r)return l(u,d)}):(l=r,this.walk((u,d)=>{if(u.type==="atrule")return l(u,d)}))}walkComments(r){return this.walk((l,u)=>{if(l.type==="comment")return r(l,u)})}walkDecls(r,l){return l?r instanceof RegExp?this.walk((u,d)=>{if(u.type==="decl"&&r.test(u.prop))return l(u,d)}):this.walk((u,d)=>{if(u.type==="decl"&&u.prop===r)return l(u,d)}):(l=r,this.walk((u,d)=>{if(u.type==="decl")return l(u,d)}))}walkRules(r,l){return l?r instanceof RegExp?this.walk((u,d)=>{if(u.type==="rule"&&r.test(u.selector))return l(u,d)}):this.walk((u,d)=>{if(u.type==="rule"&&u.selector===r)return l(u,d)}):(l=r,this.walk((u,d)=>{if(u.type==="rule")return l(u,d)}))}}return i.registerParse=t=>{s=t},i.registerRule=t=>{x=t},i.registerAtRule=t=>{h=t},i.registerRoot=t=>{p=t},dt=i,i.default=i,i.rebuild=t=>{t.type==="atrule"?Object.setPrototypeOf(t,h.prototype):t.type==="rule"?Object.setPrototypeOf(t,x.prototype):t.type==="decl"?Object.setPrototypeOf(t,g.prototype):t.type==="comment"?Object.setPrototypeOf(t,a.prototype):t.type==="root"&&Object.setPrototypeOf(t,p.prototype),t[n]=!0,t.nodes&&t.nodes.forEach(r=>{i.rebuild(r)})},dt}var pt,mr;function Dt(){if(mr)return pt;mr=1;let a=ve();class g extends a{constructor(f){super(f),this.type="atrule"}append(...f){return this.proxyOf.nodes||(this.nodes=[]),super.append(...f)}prepend(...f){return this.proxyOf.nodes||(this.nodes=[]),super.prepend(...f)}}return pt=g,g.default=g,a.registerAtRule(g),pt}var gt,br;function Ut(){if(br)return gt;br=1;let a=ve(),g,b;class f extends a{constructor(h){super({type:"document",...h}),this.nodes||(this.nodes=[])}toResult(h={}){return new g(new b,this,h).stringify()}}return f.registerLazyResult=n=>{g=n},f.registerProcessor=n=>{b=n},gt=f,f.default=f,gt}var mt,yr;function ti(){if(yr)return mt;yr=1;let a="useandom-26T198340PX75pxJACKVERYMINDBUSHWOLF_GQZbfghjklqvwyzrict";return mt={nanoid:(f=21)=>{let n="",h=f|0;for(;h--;)n+=a[Math.random()*64|0];return n},customAlphabet:(f,n=21)=>(h=n)=>{let s="",p=h|0;for(;p--;)s+=f[Math.random()*f.length|0];return s}},mt}var bt,wr;function Dr(){if(wr)return bt;wr=1;let{existsSync:a,readFileSync:g}=le,{dirname:b,join:f}=le,{SourceMapConsumer:n,SourceMapGenerator:h}=le;function s(x){return Buffer?Buffer.from(x,"base64").toString():window.atob(x)}class p{constructor(c,e){if(e.map===!1)return;this.loadAnnotation(c),this.inline=this.startWith(this.annotation,"data:");let i=e.map?e.map.prev:void 0,t=this.loadMap(e.from,i);!this.mapFile&&e.from&&(this.mapFile=e.from),this.mapFile&&(this.root=b(this.mapFile)),t&&(this.text=t)}consumer(){return this.consumerCache||(this.consumerCache=new n(this.text)),this.consumerCache}decodeInline(c){let e=/^data:application\/json;charset=utf-?8;base64,/,i=/^data:application\/json;base64,/,t=/^data:application\/json;charset=utf-?8,/,r=/^data:application\/json,/,l=c.match(t)||c.match(r);if(l)return decodeURIComponent(c.substr(l[0].length));let u=c.match(e)||c.match(i);if(u)return s(c.substr(u[0].length));let d=c.match(/data:application\/json;([^,]+),/)[1];throw new Error("Unsupported source map encoding "+d)}getAnnotationURL(c){return c.replace(/^\/\*\s*# sourceMappingURL=/,"").trim()}isMap(c){return typeof c!="object"?!1:typeof c.mappings=="string"||typeof c._mappings=="string"||Array.isArray(c.sections)}loadAnnotation(c){let e=c.match(/\/\*\s*# sourceMappingURL=/g);if(!e)return;let i=c.lastIndexOf(e.pop()),t=c.indexOf("*/",i);i>-1&&t>-1&&(this.annotation=this.getAnnotationURL(c.substring(i,t)))}loadFile(c){if(this.root=b(c),a(c))return this.mapFile=c,g(c,"utf-8").toString().trim()}loadMap(c,e){if(e===!1)return!1;if(e){if(typeof e=="string")return e;if(typeof e=="function"){let i=e(c);if(i){let t=this.loadFile(i);if(!t)throw new Error("Unable to load previous source map: "+i.toString());return t}}else{if(e instanceof n)return h.fromSourceMap(e).toString();if(e instanceof h)return e.toString();if(this.isMap(e))return JSON.stringify(e);throw new Error("Unsupported previous source map format: "+e.toString())}}else{if(this.inline)return this.decodeInline(this.annotation);if(this.annotation){let i=this.annotation;return c&&(i=f(b(c),i)),this.loadFile(i)}}}startWith(c,e){return c?c.substr(0,e.length)===e:!1}withContent(){return!!(this.consumer().sourcesContent&&this.consumer().sourcesContent.length>0)}}return bt=p,p.default=p,bt}var yt,xr;function Ke(){if(xr)return yt;xr=1;let{nanoid:a}=ti(),{isAbsolute:g,resolve:b}=le,{SourceMapConsumer:f,SourceMapGenerator:n}=le,{fileURLToPath:h,pathToFileURL:s}=le,p=Bt(),x=Dr(),c=le,e=Symbol("lineToIndexCache"),i=!!(f&&n),t=!!(b&&g);function r(u){if(u[e])return u[e];let d=u.css.split(`
|
|
139
|
+
`),E=new Array(d.length),S=0;for(let w=0,y=d.length;w<y;w++)E[w]=S,S+=d[w].length+1;return u[e]=E,E}class l{get from(){return this.file||this.id}constructor(d,E={}){if(d===null||typeof d>"u"||typeof d=="object"&&!d.toString)throw new Error(`PostCSS received ${d} instead of CSS string`);if(this.css=d.toString(),this.css[0]==="\uFEFF"||this.css[0]===""?(this.hasBOM=!0,this.css=this.css.slice(1)):this.hasBOM=!1,this.document=this.css,E.document&&(this.document=E.document.toString()),E.from&&(!t||/^\w+:\/\//.test(E.from)||g(E.from)?this.file=E.from:this.file=b(E.from)),t&&i){let S=new x(this.css,E);if(S.text){this.map=S;let w=S.consumer().file;!this.file&&w&&(this.file=this.mapResolve(w))}}this.file||(this.id="<input css "+a(6)+">"),this.map&&(this.map.file=this.from)}error(d,E,S,w={}){let y,m,k,C,L;if(E&&typeof E=="object"){let P=E,K=S;if(typeof P.offset=="number"){C=P.offset;let F=this.fromOffset(C);E=F.line,S=F.col}else E=P.line,S=P.column,C=this.fromLineAndColumn(E,S);if(typeof K.offset=="number"){k=K.offset;let F=this.fromOffset(k);m=F.line,y=F.col}else m=K.line,y=K.column,k=this.fromLineAndColumn(K.line,K.column)}else if(S)C=this.fromLineAndColumn(E,S);else{C=E;let P=this.fromOffset(C);E=P.line,S=P.col}let U=this.origin(E,S,m,y);return U?L=new p(d,U.endLine===void 0?U.line:{column:U.column,line:U.line},U.endLine===void 0?U.column:{column:U.endColumn,line:U.endLine},U.source,U.file,w.plugin):L=new p(d,m===void 0?E:{column:S,line:E},m===void 0?S:{column:y,line:m},this.css,this.file,w.plugin),L.input={column:S,endColumn:y,endLine:m,endOffset:k,line:E,offset:C,source:this.css},this.file&&(s&&(L.input.url=s(this.file).toString()),L.input.file=this.file),L}fromLineAndColumn(d,E){return r(this)[d-1]+E-1}fromOffset(d){let E=r(this),S=E[E.length-1],w=0;if(d>=S)w=E.length-1;else{let y=E.length-2,m;for(;w<y;)if(m=w+(y-w>>1),d<E[m])y=m-1;else if(d>=E[m+1])w=m+1;else{w=m;break}}return{col:d-E[w]+1,line:w+1}}mapResolve(d){return/^\w+:\/\//.test(d)?d:b(this.map.consumer().sourceRoot||this.map.root||".",d)}origin(d,E,S,w){if(!this.map)return!1;let y=this.map.consumer(),m=y.originalPositionFor({column:E,line:d});if(!m.source)return!1;let k;typeof S=="number"&&(k=y.originalPositionFor({column:w,line:S}));let C;g(m.source)?C=s(m.source):C=new URL(m.source,this.map.consumer().sourceRoot||s(this.map.mapFile));let L={column:m.column,endColumn:k&&k.column,endLine:k&&k.line,line:m.line,url:C.toString()};if(C.protocol==="file:")if(h)L.file=h(C);else throw new Error("file: protocol is not available in this PostCSS build");let U=y.sourceContentFor(m.source);return U&&(L.source=U),L}toJSON(){let d={};for(let E of["hasBOM","css","file","id"])this[E]!=null&&(d[E]=this[E]);return this.map&&(d.map={...this.map},d.map.consumerCache&&(d.map.consumerCache=void 0)),d}}return yt=l,l.default=l,c&&c.registerInput&&c.registerInput(l),yt}var wt,vr;function Pe(){if(vr)return wt;vr=1;let a=ve(),g,b;class f extends a{constructor(h){super(h),this.type="root",this.nodes||(this.nodes=[])}normalize(h,s,p){let x=super.normalize(h);if(s){if(p==="prepend")this.nodes.length>1?s.raws.before=this.nodes[1].raws.before:delete s.raws.before;else if(this.first!==s)for(let c of x)c.raws.before=s.raws.before}return x}removeChild(h,s){let p=this.index(h);return!s&&p===0&&this.nodes.length>1&&(this.nodes[1].raws.before=this.nodes[p].raws.before),super.removeChild(h)}toResult(h={}){return new g(new b,this,h).stringify()}}return f.registerLazyResult=n=>{g=n},f.registerProcessor=n=>{b=n},wt=f,f.default=f,a.registerRoot(f),wt}var xt,Er;function Ur(){if(Er)return xt;Er=1;let a={comma(g){return a.split(g,[","],!0)},space(g){let b=[" ",`
|
|
140
|
+
`," "];return a.split(g,b)},split(g,b,f){let n=[],h="",s=!1,p=0,x=!1,c="",e=!1;for(let i of g)e?e=!1:i==="\\"?e=!0:x?i===c&&(x=!1):i==='"'||i==="'"?(x=!0,c=i):i==="("?p+=1:i===")"?p>0&&(p-=1):p===0&&b.includes(i)&&(s=!0),s?(h!==""&&n.push(h.trim()),h="",s=!1):h+=i;return(f||h!=="")&&n.push(h.trim()),n}};return xt=a,a.default=a,xt}var vt,Sr;function $t(){if(Sr)return vt;Sr=1;let a=ve(),g=Ur();class b extends a{get selectors(){return g.comma(this.selector)}set selectors(n){let h=this.selector?this.selector.match(/,\s*/):null,s=h?h[0]:","+this.raw("between","beforeOpen");this.selector=n.join(s)}constructor(n){super(n),this.type="rule",this.nodes||(this.nodes=[])}}return vt=b,b.default=b,a.registerRule(b),vt}var Et,kr;function ri(){if(kr)return Et;kr=1;let a=Dt(),g=Ze(),b=Je(),f=Ke(),n=Dr(),h=Pe(),s=$t();function p(x,c){if(Array.isArray(x))return x.map(t=>p(t));let{inputs:e,...i}=x;if(e){c=[];for(let t of e){let r={...t,__proto__:f.prototype};r.map&&(r.map={...r.map,__proto__:n.prototype}),c.push(r)}}if(i.nodes&&(i.nodes=x.nodes.map(t=>p(t,c))),i.source){let{inputId:t,...r}=i.source;i.source=r,t!=null&&(i.source.input=c[t])}if(i.type==="root")return new h(i);if(i.type==="decl")return new b(i);if(i.type==="rule")return new s(i);if(i.type==="comment")return new g(i);if(i.type==="atrule")return new a(i);throw new Error("Unknown node type: "+x.type)}return Et=p,p.default=p,Et}var St,_r;function $r(){if(_r)return St;_r=1;let{dirname:a,relative:g,resolve:b,sep:f}=le,{SourceMapConsumer:n,SourceMapGenerator:h}=le,{pathToFileURL:s}=le,p=Ke(),x=!!(n&&h),c=!!(a&&b&&g&&f);class e{constructor(t,r,l,u){this.stringify=t,this.mapOpts=l.map||{},this.root=r,this.opts=l,this.css=u,this.originalCSS=u,this.usesFileUrls=!this.mapOpts.from&&this.mapOpts.absolute,this.memoizedFileURLs=new Map,this.memoizedPaths=new Map,this.memoizedURLs=new Map}addAnnotation(){let t;this.isInline()?t="data:application/json;base64,"+this.toBase64(this.map.toString()):typeof this.mapOpts.annotation=="string"?t=this.mapOpts.annotation:typeof this.mapOpts.annotation=="function"?t=this.mapOpts.annotation(this.opts.to,this.root):t=this.outputFile()+".map";let r=`
|
|
100
141
|
`;this.css.includes(`\r
|
|
101
|
-
`)&&(
|
|
102
|
-
`),this.css+=
|
|
103
|
-
`),t=a.length-s):t+=a.length,l&&c!=="start"){let h=l.parent||{raws:{}};(!(l.type==="decl"||l.type==="atrule"&&!l.nodes)||l!==h.last||h.raws.semicolon)&&(l.source&&l.source.end?(i.source=this.sourcePath(l),i.original.line=l.source.end.line,i.original.column=l.source.end.column-1,i.generated.line=e,i.generated.column=t-2,this.map.addMapping(i)):(i.source=n,i.original.line=1,i.original.column=0,i.generated.line=e,i.generated.column=t-1,this.map.addMapping(i)))}})}isAnnotation(){return this.isInline()?!0:typeof this.mapOpts.annotation<"u"?this.mapOpts.annotation:this.previous().length?this.previous().some(e=>e.annotation):!0}isInline(){if(typeof this.mapOpts.inline<"u")return this.mapOpts.inline;let e=this.mapOpts.annotation;return typeof e<"u"&&e!==!0?!1:this.previous().length?this.previous().some(t=>t.inline):!0}isMap(){return typeof this.opts.map<"u"?!!this.opts.map:this.previous().length>0}isSourcesContent(){return typeof this.mapOpts.sourcesContent<"u"?this.mapOpts.sourcesContent:this.previous().length?this.previous().some(e=>e.withContent()):!0}outputFile(){return this.opts.to?this.path(this.opts.to):this.opts.from?this.path(this.opts.from):"to.css"}path(e){if(this.mapOpts.absolute||e.charCodeAt(0)===60||/^\w+:\/\//.test(e))return e;let t=this.memoizedPaths.get(e);if(t)return t;let n=this.opts.to?je(this.opts.to):".";typeof this.mapOpts.annotation=="string"&&(n=je(On(n,this.mapOpts.annotation)));let i=_n(n,e);return this.memoizedPaths.set(e,i),i}previous(){if(!this.previousMaps)if(this.previousMaps=[],this.root)this.root.walk(e=>{if(e.source&&e.source.input.map){let t=e.source.input.map;this.previousMaps.includes(t)||this.previousMaps.push(t)}});else{let e=new ui(this.css,this.opts);e.map&&this.previousMaps.push(e.map)}return this.previousMaps}setSourcesContent(){let e={};if(this.root)this.root.walk(t=>{if(t.source){let n=t.source.input.from;if(n&&!e[n]){e[n]=!0;let i=this.usesFileUrls?this.toFileUrl(n):this.toUrl(this.path(n));this.map.setSourceContent(i,t.source.input.css)}}});else if(this.css){let t=this.opts.from?this.toUrl(this.path(this.opts.from)):"<no source>";this.map.setSourceContent(t,this.css)}}sourcePath(e){return this.mapOpts.from?this.toUrl(this.mapOpts.from):this.usesFileUrls?this.toFileUrl(e.source.input.from):this.toUrl(this.path(e.source.input.from))}toBase64(e){return Buffer?Buffer.from(e).toString("base64"):window.btoa(unescape(encodeURIComponent(e)))}toFileUrl(e){let t=this.memoizedFileURLs.get(e);if(t)return t;if(Qt){let n=Qt(e).toString();return this.memoizedFileURLs.set(e,n),n}else throw new Error("`map.absolute` option is not available in this PostCSS build")}toUrl(e){let t=this.memoizedURLs.get(e);if(t)return t;kn==="\\"&&(e=e.replace(/\\/g,"/"));let n=encodeURI(e).replace(/[#?]/g,encodeURIComponent);return this.memoizedURLs.set(e,n),n}};var Cn=di;let pi=Ge,yt=class extends pi{constructor(e){super(e),this.type="comment"}};var Ke=yt;yt.default=yt;let{isClean:An,my:Rn}=we,Nn=Ze,Mn=Ke,gi=Ge,In,kt,Ct,Pn;function Tn(r){return r.map(e=>(e.nodes&&(e.nodes=Tn(e.nodes)),delete e.source,e))}function Ln(r){if(r[An]=!1,r.proxyOf.nodes)for(let e of r.proxyOf.nodes)Ln(e)}let Z=class $n extends gi{append(...e){for(let t of e){let n=this.normalize(t,this.last);for(let i of n)this.proxyOf.nodes.push(i)}return this.markDirty(),this}cleanRaws(e){if(super.cleanRaws(e),this.nodes)for(let t of this.nodes)t.cleanRaws(e)}each(e){if(!this.proxyOf.nodes)return;let t=this.getIterator(),n,i;for(;this.indexes[t]<this.proxyOf.nodes.length&&(n=this.indexes[t],i=e(this.proxyOf.nodes[n],n),i!==!1);)this.indexes[t]+=1;return delete this.indexes[t],i}every(e){return this.nodes.every(e)}getIterator(){this.lastEach||(this.lastEach=0),this.indexes||(this.indexes={}),this.lastEach+=1;let e=this.lastEach;return this.indexes[e]=0,e}getProxyProcessor(){return{get(e,t){return t==="proxyOf"?e:e[t]?t==="each"||typeof t=="string"&&t.startsWith("walk")?(...n)=>e[t](...n.map(i=>typeof i=="function"?(o,s)=>i(o.toProxy(),s):i)):t==="every"||t==="some"?n=>e[t]((i,...o)=>n(i.toProxy(),...o)):t==="root"?()=>e.root().toProxy():t==="nodes"?e.nodes.map(n=>n.toProxy()):t==="first"||t==="last"?e[t].toProxy():e[t]:e[t]},set(e,t,n){return e[t]===n||(e[t]=n,(t==="name"||t==="params"||t==="selector")&&e.markDirty()),!0}}}index(e){return typeof e=="number"?e:(e.proxyOf&&(e=e.proxyOf),this.proxyOf.nodes.indexOf(e))}insertAfter(e,t){let n=this.index(e),i=this.normalize(t,this.proxyOf.nodes[n]).reverse();n=this.index(e);for(let s of i)this.proxyOf.nodes.splice(n+1,0,s);let o;for(let s in this.indexes)o=this.indexes[s],n<o&&(this.indexes[s]=o+i.length);return this.markDirty(),this}insertBefore(e,t){let n=this.index(e),i=n===0?"prepend":!1,o=this.normalize(t,this.proxyOf.nodes[n],i).reverse();n=this.index(e);for(let a of o)this.proxyOf.nodes.splice(n,0,a);let s;for(let a in this.indexes)s=this.indexes[a],n<=s&&(this.indexes[a]=s+o.length);return this.markDirty(),this}normalize(e,t){if(typeof e=="string")e=Tn(In(e).nodes);else if(Array.isArray(e)){e=e.slice(0);for(let i of e)i.parent&&i.parent.removeChild(i,"ignore")}else if(e.type==="root"&&this.type!=="document"){e=e.nodes.slice(0);for(let i of e)i.parent&&i.parent.removeChild(i,"ignore")}else if(e.type)e=[e];else if(e.prop){if(typeof e.value>"u")throw new Error("Value field is missed in node creation");typeof e.value!="string"&&(e.value=String(e.value)),e=[new Nn(e)]}else if(e.selector)e=[new kt(e)];else if(e.name)e=[new Ct(e)];else if(e.text)e=[new Mn(e)];else throw new Error("Unknown node type in node creation");return e.map(i=>(i[Rn]||$n.rebuild(i),i=i.proxyOf,i.parent&&i.parent.removeChild(i),i[An]&&Ln(i),typeof i.raws.before>"u"&&t&&typeof t.raws.before<"u"&&(i.raws.before=t.raws.before.replace(/\S/g,"")),i.parent=this.proxyOf,i))}prepend(...e){e=e.reverse();for(let t of e){let n=this.normalize(t,this.first,"prepend").reverse();for(let i of n)this.proxyOf.nodes.unshift(i);for(let i in this.indexes)this.indexes[i]=this.indexes[i]+n.length}return this.markDirty(),this}push(e){return e.parent=this,this.proxyOf.nodes.push(e),this}removeAll(){for(let e of this.proxyOf.nodes)e.parent=void 0;return this.proxyOf.nodes=[],this.markDirty(),this}removeChild(e){e=this.index(e),this.proxyOf.nodes[e].parent=void 0,this.proxyOf.nodes.splice(e,1);let t;for(let n in this.indexes)t=this.indexes[n],t>=e&&(this.indexes[n]=t-1);return this.markDirty(),this}replaceValues(e,t,n){return n||(n=t,t={}),this.walkDecls(i=>{t.props&&!t.props.includes(i.prop)||t.fast&&!i.value.includes(t.fast)||(i.value=i.value.replace(e,n))}),this.markDirty(),this}some(e){return this.nodes.some(e)}walk(e){return this.each((t,n)=>{let i;try{i=e(t,n)}catch(o){throw t.addToError(o)}return i!==!1&&t.walk&&(i=t.walk(e)),i})}walkAtRules(e,t){return t?e instanceof RegExp?this.walk((n,i)=>{if(n.type==="atrule"&&e.test(n.name))return t(n,i)}):this.walk((n,i)=>{if(n.type==="atrule"&&n.name===e)return t(n,i)}):(t=e,this.walk((n,i)=>{if(n.type==="atrule")return t(n,i)}))}walkComments(e){return this.walk((t,n)=>{if(t.type==="comment")return e(t,n)})}walkDecls(e,t){return t?e instanceof RegExp?this.walk((n,i)=>{if(n.type==="decl"&&e.test(n.prop))return t(n,i)}):this.walk((n,i)=>{if(n.type==="decl"&&n.prop===e)return t(n,i)}):(t=e,this.walk((n,i)=>{if(n.type==="decl")return t(n,i)}))}walkRules(e,t){return t?e instanceof RegExp?this.walk((n,i)=>{if(n.type==="rule"&&e.test(n.selector))return t(n,i)}):this.walk((n,i)=>{if(n.type==="rule"&&n.selector===e)return t(n,i)}):(t=e,this.walk((n,i)=>{if(n.type==="rule")return t(n,i)}))}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]}};Z.registerParse=r=>{In=r};Z.registerRule=r=>{kt=r};Z.registerAtRule=r=>{Ct=r};Z.registerRoot=r=>{Pn=r};var ee=Z;Z.default=Z;Z.rebuild=r=>{r.type==="atrule"?Object.setPrototypeOf(r,Ct.prototype):r.type==="rule"?Object.setPrototypeOf(r,kt.prototype):r.type==="decl"?Object.setPrototypeOf(r,Nn.prototype):r.type==="comment"?Object.setPrototypeOf(r,Mn.prototype):r.type==="root"&&Object.setPrototypeOf(r,Pn.prototype),r[Rn]=!0,r.nodes&&r.nodes.forEach(e=>{Z.rebuild(e)})};let mi=ee,jn,Bn,de=class extends mi{constructor(e){super({type:"document",...e}),this.nodes||(this.nodes=[])}toResult(e={}){return new jn(new Bn,this,e).stringify()}};de.registerLazyResult=r=>{jn=r};de.registerProcessor=r=>{Bn=r};var At=de;de.default=de;let wt=class{constructor(e,t={}){if(this.type="warning",this.text=e,t.node&&t.node.source){let n=t.node.rangeBy(t);this.line=n.start.line,this.column=n.start.column,this.endLine=n.end.line,this.endColumn=n.end.column}for(let n in t)this[n]=t[n]}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}};var zn=wt;wt.default=wt;let bi=zn,xt=class{constructor(e,t,n){this.processor=e,this.messages=[],this.root=t,this.opts=n,this.css=void 0,this.map=void 0}toString(){return this.css}warn(e,t={}){t.plugin||this.lastPlugin&&this.lastPlugin.postcssPlugin&&(t.plugin=this.lastPlugin.postcssPlugin);let n=new bi(e,t);return this.messages.push(n),n}warnings(){return this.messages.filter(e=>e.type==="warning")}get content(){return this.css}};var Rt=xt;xt.default=xt;const at=39,Yt=34,Ce=92,en=47,Ae=10,ce=32,Re=12,Ne=9,Me=13,yi=91,wi=93,xi=40,vi=41,Ei=123,Si=125,_i=59,Oi=42,ki=58,Ci=64,Ie=/[\t\n\f\r "#'()/;[\\\]{}]/g,Pe=/[\t\n\f\r !"#'():;@[\\\]{}]|\/(?=\*)/g,Ai=/.[\r\n"'(/\\]/,tn=/[\da-f]/i;var Ri=function(e,t={}){let n=e.css.valueOf(),i=t.ignoreErrors,o,s,a,l,c,h,b,g,C,R,L=n.length,m=0,F=[],H=[];function V(){return m}function $(B){throw e.error("Unclosed "+B,m)}function W(){return H.length===0&&m>=L}function le(B){if(H.length)return H.pop();if(m>=L)return;let I=B?B.ignoreUnclosed:!1;switch(o=n.charCodeAt(m),o){case Ae:case ce:case Ne:case Me:case Re:{s=m;do s+=1,o=n.charCodeAt(s);while(o===ce||o===Ae||o===Ne||o===Me||o===Re);R=["space",n.slice(m,s)],m=s-1;break}case yi:case wi:case Ei:case Si:case ki:case _i:case vi:{let J=String.fromCharCode(o);R=[J,J,m];break}case xi:{if(g=F.length?F.pop()[1]:"",C=n.charCodeAt(m+1),g==="url"&&C!==at&&C!==Yt&&C!==ce&&C!==Ae&&C!==Ne&&C!==Re&&C!==Me){s=m;do{if(h=!1,s=n.indexOf(")",s+1),s===-1)if(i||I){s=m;break}else $("bracket");for(b=s;n.charCodeAt(b-1)===Ce;)b-=1,h=!h}while(h);R=["brackets",n.slice(m,s+1),m,s],m=s}else s=n.indexOf(")",m+1),l=n.slice(m,s+1),s===-1||Ai.test(l)?R=["(","(",m]:(R=["brackets",l,m,s],m=s);break}case at:case Yt:{a=o===at?"'":'"',s=m;do{if(h=!1,s=n.indexOf(a,s+1),s===-1)if(i||I){s=m+1;break}else $("string");for(b=s;n.charCodeAt(b-1)===Ce;)b-=1,h=!h}while(h);R=["string",n.slice(m,s+1),m,s],m=s;break}case Ci:{Ie.lastIndex=m+1,Ie.test(n),Ie.lastIndex===0?s=n.length-1:s=Ie.lastIndex-2,R=["at-word",n.slice(m,s+1),m,s],m=s;break}case Ce:{for(s=m,c=!0;n.charCodeAt(s+1)===Ce;)s+=1,c=!c;if(o=n.charCodeAt(s+1),c&&o!==en&&o!==ce&&o!==Ae&&o!==Ne&&o!==Me&&o!==Re&&(s+=1,tn.test(n.charAt(s)))){for(;tn.test(n.charAt(s+1));)s+=1;n.charCodeAt(s+1)===ce&&(s+=1)}R=["word",n.slice(m,s+1),m,s],m=s;break}default:{o===en&&n.charCodeAt(m+1)===Oi?(s=n.indexOf("*/",m+2)+1,s===0&&(i||I?s=n.length:$("comment")),R=["comment",n.slice(m,s+1),m,s],m=s):(Pe.lastIndex=m+1,Pe.test(n),Pe.lastIndex===0?s=n.length-1:s=Pe.lastIndex-2,R=["word",n.slice(m,s+1),m,s],F.push(R),m=s);break}}return m++,R}function ne(B){H.push(B)}return{back:ne,endOfFile:W,nextToken:le,position:V}};let Un=ee,ze=class extends Un{constructor(e){super(e),this.type="atrule"}append(...e){return this.proxyOf.nodes||(this.nodes=[]),super.append(...e)}prepend(...e){return this.proxyOf.nodes||(this.nodes=[]),super.prepend(...e)}};var Nt=ze;ze.default=ze;Un.registerAtRule(ze);let Dn=ee,Fn,Hn,ie=class extends Dn{constructor(e){super(e),this.type="root",this.nodes||(this.nodes=[])}normalize(e,t,n){let i=super.normalize(e);if(t){if(n==="prepend")this.nodes.length>1?t.raws.before=this.nodes[1].raws.before:delete t.raws.before;else if(this.first!==t)for(let o of i)o.raws.before=t.raws.before}return i}removeChild(e,t){let n=this.index(e);return!t&&n===0&&this.nodes.length>1&&(this.nodes[1].raws.before=this.nodes[n].raws.before),super.removeChild(e)}toResult(e={}){return new Fn(new Hn,this,e).stringify()}};ie.registerLazyResult=r=>{Fn=r};ie.registerProcessor=r=>{Hn=r};var xe=ie;ie.default=ie;Dn.registerRoot(ie);let pe={comma(r){return pe.split(r,[","],!0)},space(r){let e=[" ",`
|
|
104
|
-
`," "];return pe.split(r,e)},split(r,e,t){let n=[],i="",o=!1,s=0,a=!1,l="",c=!1;for(let h of r)c?c=!1:h==="\\"?c=!0:a?h===l&&(a=!1):h==='"'||h==="'"?(a=!0,l=h):h==="("?s+=1:h===")"?s>0&&(s-=1):s===0&&e.includes(h)&&(o=!0),o?(i!==""&&n.push(i.trim()),i="",o=!1):i+=h;return(t||i!=="")&&n.push(i.trim()),n}};var Wn=pe;pe.default=pe;let Gn=ee,Ni=Wn,Ue=class extends Gn{constructor(e){super(e),this.type="rule",this.nodes||(this.nodes=[])}get selectors(){return Ni.comma(this.selector)}set selectors(e){let t=this.selector?this.selector.match(/,\s*/):null,n=t?t[0]:","+this.raw("between","beforeOpen");this.selector=e.join(n)}};var Mt=Ue;Ue.default=Ue;Gn.registerRule(Ue);let Mi=Ze,Ii=Ri,Pi=Ke,Ti=Nt,Li=xe,nn=Mt;const rn={empty:!0,space:!0};function $i(r){for(let e=r.length-1;e>=0;e--){let t=r[e],n=t[3]||t[2];if(n)return n}}let ji=class{constructor(e){this.input=e,this.root=new Li,this.current=this.root,this.spaces="",this.semicolon=!1,this.customProperty=!1,this.createTokenizer(),this.root.source={input:e,start:{column:1,line:1,offset:0}}}atrule(e){let t=new Ti;t.name=e[1].slice(1),t.name===""&&this.unnamedAtrule(t,e),this.init(t,e[2]);let n,i,o,s=!1,a=!1,l=[],c=[];for(;!this.tokenizer.endOfFile();){if(e=this.tokenizer.nextToken(),n=e[0],n==="("||n==="["?c.push(n==="("?")":"]"):n==="{"&&c.length>0?c.push("}"):n===c[c.length-1]&&c.pop(),c.length===0)if(n===";"){t.source.end=this.getPosition(e[2]),t.source.end.offset++,this.semicolon=!0;break}else if(n==="{"){a=!0;break}else if(n==="}"){if(l.length>0){for(o=l.length-1,i=l[o];i&&i[0]==="space";)i=l[--o];i&&(t.source.end=this.getPosition(i[3]||i[2]),t.source.end.offset++)}this.end(e);break}else l.push(e);else l.push(e);if(this.tokenizer.endOfFile()){s=!0;break}}t.raws.between=this.spacesAndCommentsFromEnd(l),l.length?(t.raws.afterName=this.spacesAndCommentsFromStart(l),this.raw(t,"params",l),s&&(e=l[l.length-1],t.source.end=this.getPosition(e[3]||e[2]),t.source.end.offset++,this.spaces=t.raws.between,t.raws.between="")):(t.raws.afterName="",t.params=""),a&&(t.nodes=[],this.current=t)}checkMissedSemicolon(e){let t=this.colon(e);if(t===!1)return;let n=0,i;for(let o=t-1;o>=0&&(i=e[o],!(i[0]!=="space"&&(n+=1,n===2)));o--);throw this.input.error("Missed semicolon",i[0]==="word"?i[3]+1:i[2])}colon(e){let t=0,n,i,o;for(let[s,a]of e.entries()){if(n=a,i=n[0],i==="("&&(t+=1),i===")"&&(t-=1),t===0&&i===":")if(!o)this.doubleColon(n);else{if(o[0]==="word"&&o[1]==="progid")continue;return s}o=n}return!1}comment(e){let t=new Pi;this.init(t,e[2]),t.source.end=this.getPosition(e[3]||e[2]),t.source.end.offset++;let n=e[1].slice(2,-2);if(/^\s*$/.test(n))t.text="",t.raws.left=n,t.raws.right="";else{let i=n.match(/^(\s*)([^]*\S)(\s*)$/);t.text=i[2],t.raws.left=i[1],t.raws.right=i[3]}}createTokenizer(){this.tokenizer=Ii(this.input)}decl(e,t){let n=new Mi;this.init(n,e[0][2]);let i=e[e.length-1];for(i[0]===";"&&(this.semicolon=!0,e.pop()),n.source.end=this.getPosition(i[3]||i[2]||$i(e)),n.source.end.offset++;e[0][0]!=="word";)e.length===1&&this.unknownWord(e),n.raws.before+=e.shift()[1];for(n.source.start=this.getPosition(e[0][2]),n.prop="";e.length;){let c=e[0][0];if(c===":"||c==="space"||c==="comment")break;n.prop+=e.shift()[1]}n.raws.between="";let o;for(;e.length;)if(o=e.shift(),o[0]===":"){n.raws.between+=o[1];break}else o[0]==="word"&&/\w/.test(o[1])&&this.unknownWord([o]),n.raws.between+=o[1];(n.prop[0]==="_"||n.prop[0]==="*")&&(n.raws.before+=n.prop[0],n.prop=n.prop.slice(1));let s=[],a;for(;e.length&&(a=e[0][0],!(a!=="space"&&a!=="comment"));)s.push(e.shift());this.precheckMissedSemicolon(e);for(let c=e.length-1;c>=0;c--){if(o=e[c],o[1].toLowerCase()==="!important"){n.important=!0;let h=this.stringFrom(e,c);h=this.spacesFromEnd(e)+h,h!==" !important"&&(n.raws.important=h);break}else if(o[1].toLowerCase()==="important"){let h=e.slice(0),b="";for(let g=c;g>0;g--){let C=h[g][0];if(b.trim().indexOf("!")===0&&C!=="space")break;b=h.pop()[1]+b}b.trim().indexOf("!")===0&&(n.important=!0,n.raws.important=b,e=h)}if(o[0]!=="space"&&o[0]!=="comment")break}e.some(c=>c[0]!=="space"&&c[0]!=="comment")&&(n.raws.between+=s.map(c=>c[1]).join(""),s=[]),this.raw(n,"value",s.concat(e),t),n.value.includes(":")&&!t&&this.checkMissedSemicolon(e)}doubleColon(e){throw this.input.error("Double colon",{offset:e[2]},{offset:e[2]+e[1].length})}emptyRule(e){let t=new nn;this.init(t,e[2]),t.selector="",t.raws.between="",this.current=t}end(e){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(e[2]),this.current.source.end.offset++,this.current=this.current.parent):this.unexpectedClose(e)}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(e){if(this.spaces+=e[1],this.current.nodes){let t=this.current.nodes[this.current.nodes.length-1];t&&t.type==="rule"&&!t.raws.ownSemicolon&&(t.raws.ownSemicolon=this.spaces,this.spaces="")}}getPosition(e){let t=this.input.fromOffset(e);return{column:t.col,line:t.line,offset:e}}init(e,t){this.current.push(e),e.source={input:this.input,start:this.getPosition(t)},e.raws.before=this.spaces,this.spaces="",e.type!=="comment"&&(this.semicolon=!1)}other(e){let t=!1,n=null,i=!1,o=null,s=[],a=e[1].startsWith("--"),l=[],c=e;for(;c;){if(n=c[0],l.push(c),n==="("||n==="[")o||(o=c),s.push(n==="("?")":"]");else if(a&&i&&n==="{")o||(o=c),s.push("}");else if(s.length===0)if(n===";")if(i){this.decl(l,a);return}else break;else if(n==="{"){this.rule(l);return}else if(n==="}"){this.tokenizer.back(l.pop()),t=!0;break}else n===":"&&(i=!0);else n===s[s.length-1]&&(s.pop(),s.length===0&&(o=null));c=this.tokenizer.nextToken()}if(this.tokenizer.endOfFile()&&(t=!0),s.length>0&&this.unclosedBracket(o),t&&i){if(!a)for(;l.length&&(c=l[l.length-1][0],!(c!=="space"&&c!=="comment"));)this.tokenizer.back(l.pop());this.decl(l,a)}else this.unknownWord(l)}parse(){let e;for(;!this.tokenizer.endOfFile();)switch(e=this.tokenizer.nextToken(),e[0]){case"space":this.spaces+=e[1];break;case";":this.freeSemicolon(e);break;case"}":this.end(e);break;case"comment":this.comment(e);break;case"at-word":this.atrule(e);break;case"{":this.emptyRule(e);break;default:this.other(e);break}this.endFile()}precheckMissedSemicolon(){}raw(e,t,n,i){let o,s,a=n.length,l="",c=!0,h,b;for(let g=0;g<a;g+=1)o=n[g],s=o[0],s==="space"&&g===a-1&&!i?c=!1:s==="comment"?(b=n[g-1]?n[g-1][0]:"empty",h=n[g+1]?n[g+1][0]:"empty",!rn[b]&&!rn[h]?l.slice(-1)===","?c=!1:l+=o[1]:c=!1):l+=o[1];if(!c){let g=n.reduce((C,R)=>C+R[1],"");e.raws[t]={raw:g,value:l}}e[t]=l}rule(e){e.pop();let t=new nn;this.init(t,e[0][2]),t.raws.between=this.spacesAndCommentsFromEnd(e),this.raw(t,"selector",e),this.current=t}spacesAndCommentsFromEnd(e){let t,n="";for(;e.length&&(t=e[e.length-1][0],!(t!=="space"&&t!=="comment"));)n=e.pop()[1]+n;return n}spacesAndCommentsFromStart(e){let t,n="";for(;e.length&&(t=e[0][0],!(t!=="space"&&t!=="comment"));)n+=e.shift()[1];return n}spacesFromEnd(e){let t,n="";for(;e.length&&(t=e[e.length-1][0],t==="space");)n=e.pop()[1]+n;return n}stringFrom(e,t){let n="";for(let i=t;i<e.length;i++)n+=e[i][1];return e.splice(t,e.length-t),n}unclosedBlock(){let e=this.current.source.start;throw this.input.error("Unclosed block",e.line,e.column)}unclosedBracket(e){throw this.input.error("Unclosed bracket",{offset:e[2]},{offset:e[2]+1})}unexpectedClose(e){throw this.input.error("Unexpected }",{offset:e[2]},{offset:e[2]+1})}unknownWord(e){throw this.input.error("Unknown word",{offset:e[0][2]},{offset:e[0][2]+e[0][1].length})}unnamedAtrule(e,t){throw this.input.error("At-rule without name",{offset:t[2]},{offset:t[2]+t[1].length})}};var Bi=ji;let zi=ee,Ui=Bi,Di=qe;function De(r,e){let t=new Di(r,e),n=new Ui(t);try{n.parse()}catch(i){throw i}return n.root}var It=De;De.default=De;zi.registerParse(De);let{isClean:D,my:Fi}=we,Hi=Cn,Wi=We,Gi=ee,Zi=At,sn=Rt,qi=It,Ki=xe;const Vi={atrule:"AtRule",comment:"Comment",decl:"Declaration",document:"Document",root:"Root",rule:"Rule"},Ji={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},Xi={Once:!0,postcssPlugin:!0,prepare:!0},se=0;function ue(r){return typeof r=="object"&&typeof r.then=="function"}function Zn(r){let e=!1,t=Vi[r.type];return r.type==="decl"?e=r.prop.toLowerCase():r.type==="atrule"&&(e=r.name.toLowerCase()),e&&r.append?[t,t+"-"+e,se,t+"Exit",t+"Exit-"+e]:e?[t,t+"-"+e,t+"Exit",t+"Exit-"+e]:r.append?[t,se,t+"Exit"]:[t,t+"Exit"]}function on(r){let e;return r.type==="document"?e=["Document",se,"DocumentExit"]:r.type==="root"?e=["Root",se,"RootExit"]:e=Zn(r),{eventIndex:0,events:e,iterator:0,node:r,visitorIndex:0,visitors:[]}}function vt(r){return r[D]=!1,r.nodes&&r.nodes.forEach(e=>vt(e)),r}let Et={},oe=class qn{constructor(e,t,n){this.stringified=!1,this.processed=!1;let i;if(typeof t=="object"&&t!==null&&(t.type==="root"||t.type==="document"))i=vt(t);else if(t instanceof qn||t instanceof sn)i=vt(t.root),t.map&&(typeof n.map>"u"&&(n.map={}),n.map.inline||(n.map.inline=!1),n.map.prev=t.map);else{let o=qi;n.syntax&&(o=n.syntax.parse),n.parser&&(o=n.parser),o.parse&&(o=o.parse);try{i=o(t,n)}catch(s){this.processed=!0,this.error=s}i&&!i[Fi]&&Gi.rebuild(i)}this.result=new sn(e,i,n),this.helpers={...Et,postcss:Et,result:this.result},this.plugins=this.processor.plugins.map(o=>typeof o=="object"&&o.prepare?{...o,...o.prepare(this.result)}:o)}async(){return this.error?Promise.reject(this.error):this.processed?Promise.resolve(this.result):(this.processing||(this.processing=this.runAsync()),this.processing)}catch(e){return this.async().catch(e)}finally(e){return this.async().then(e,e)}getAsyncError(){throw new Error("Use process(css).then(cb) to work with async plugins")}handleError(e,t){let n=this.result.lastPlugin;try{t&&t.addToError(e),this.error=e,e.name==="CssSyntaxError"&&!e.plugin?(e.plugin=n.postcssPlugin,e.setMessage()):n.postcssVersion}catch(i){console&&console.error&&console.error(i)}return e}prepareVisitors(){this.listeners={};let e=(t,n,i)=>{this.listeners[n]||(this.listeners[n]=[]),this.listeners[n].push([t,i])};for(let t of this.plugins)if(typeof t=="object")for(let n in t){if(!Ji[n]&&/^[A-Z]/.test(n))throw new Error(`Unknown event ${n} in ${t.postcssPlugin}. Try to update PostCSS (${this.processor.version} now).`);if(!Xi[n])if(typeof t[n]=="object")for(let i in t[n])i==="*"?e(t,n,t[n][i]):e(t,n+"-"+i.toLowerCase(),t[n][i]);else typeof t[n]=="function"&&e(t,n,t[n])}this.hasListener=Object.keys(this.listeners).length>0}async runAsync(){this.plugin=0;for(let e=0;e<this.plugins.length;e++){let t=this.plugins[e],n=this.runOnRoot(t);if(ue(n))try{await n}catch(i){throw this.handleError(i)}}if(this.prepareVisitors(),this.hasListener){let e=this.result.root;for(;!e[D];){e[D]=!0;let t=[on(e)];for(;t.length>0;){let n=this.visitTick(t);if(ue(n))try{await n}catch(i){let o=t[t.length-1].node;throw this.handleError(i,o)}}}if(this.listeners.OnceExit)for(let[t,n]of this.listeners.OnceExit){this.result.lastPlugin=t;try{if(e.type==="document"){let i=e.nodes.map(o=>n(o,this.helpers));await Promise.all(i)}else await n(e,this.helpers)}catch(i){throw this.handleError(i)}}}return this.processed=!0,this.stringify()}runOnRoot(e){this.result.lastPlugin=e;try{if(typeof e=="object"&&e.Once){if(this.result.root.type==="document"){let t=this.result.root.nodes.map(n=>e.Once(n,this.helpers));return ue(t[0])?Promise.all(t):t}return e.Once(this.result.root,this.helpers)}else if(typeof e=="function")return e(this.result.root,this.result)}catch(t){throw this.handleError(t)}}stringify(){if(this.error)throw this.error;if(this.stringified)return this.result;this.stringified=!0,this.sync();let e=this.result.opts,t=Wi;e.syntax&&(t=e.syntax.stringify),e.stringifier&&(t=e.stringifier),t.stringify&&(t=t.stringify);let i=new Hi(t,this.result.root,this.result.opts).generate();return this.result.css=i[0],this.result.map=i[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 e of this.plugins){let t=this.runOnRoot(e);if(ue(t))throw this.getAsyncError()}if(this.prepareVisitors(),this.hasListener){let e=this.result.root;for(;!e[D];)e[D]=!0,this.walkSync(e);if(this.listeners.OnceExit)if(e.type==="document")for(let t of e.nodes)this.visitSync(this.listeners.OnceExit,t);else this.visitSync(this.listeners.OnceExit,e)}return this.result}then(e,t){return this.async().then(e,t)}toString(){return this.css}visitSync(e,t){for(let[n,i]of e){this.result.lastPlugin=n;let o;try{o=i(t,this.helpers)}catch(s){throw this.handleError(s,t.proxyOf)}if(t.type!=="root"&&t.type!=="document"&&!t.parent)return!0;if(ue(o))throw this.getAsyncError()}}visitTick(e){let t=e[e.length-1],{node:n,visitors:i}=t;if(n.type!=="root"&&n.type!=="document"&&!n.parent){e.pop();return}if(i.length>0&&t.visitorIndex<i.length){let[s,a]=i[t.visitorIndex];t.visitorIndex+=1,t.visitorIndex===i.length&&(t.visitors=[],t.visitorIndex=0),this.result.lastPlugin=s;try{return a(n.toProxy(),this.helpers)}catch(l){throw this.handleError(l,n)}}if(t.iterator!==0){let s=t.iterator,a;for(;a=n.nodes[n.indexes[s]];)if(n.indexes[s]+=1,!a[D]){a[D]=!0,e.push(on(a));return}t.iterator=0,delete n.indexes[s]}let o=t.events;for(;t.eventIndex<o.length;){let s=o[t.eventIndex];if(t.eventIndex+=1,s===se){n.nodes&&n.nodes.length&&(n[D]=!0,t.iterator=n.getIterator());return}else if(this.listeners[s]){t.visitors=this.listeners[s];return}}e.pop()}walkSync(e){e[D]=!0;let t=Zn(e);for(let n of t)if(n===se)e.nodes&&e.each(i=>{i[D]||this.walkSync(i)});else{let i=this.listeners[n];if(i&&this.visitSync(i,e.toProxy()))return}}warnings(){return this.sync().warnings()}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"}};oe.registerPostcss=r=>{Et=r};var Kn=oe;oe.default=oe;Ki.registerLazyResult(oe);Zi.registerLazyResult(oe);let Qi=Cn,Yi=We,es=It;const ts=Rt;let St=class{constructor(e,t,n){t=t.toString(),this.stringified=!1,this._processor=e,this._css=t,this._opts=n,this._map=void 0;let i,o=Yi;this.result=new ts(this._processor,i,this._opts),this.result.css=t;let s=this;Object.defineProperty(this.result,"root",{get(){return s.root}});let a=new Qi(o,i,this._opts,t);if(a.isMap()){let[l,c]=a.generate();l&&(this.result.css=l),c&&(this.result.map=c)}}async(){return this.error?Promise.reject(this.error):Promise.resolve(this.result)}catch(e){return this.async().catch(e)}finally(e){return this.async().then(e,e)}sync(){if(this.error)throw this.error;return this.result}then(e,t){return this.async().then(e,t)}toString(){return this._css}warnings(){return[]}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 e,t=es;try{e=t(this._css,this._opts)}catch(n){this.error=n}if(this.error)throw this.error;return this._root=e,e}get[Symbol.toStringTag](){return"NoWorkResult"}};var ns=St;St.default=St;let rs=ns,is=Kn,ss=At,os=xe,ge=class{constructor(e=[]){this.version="8.4.32",this.plugins=this.normalize(e)}normalize(e){let t=[];for(let n of e)if(n.postcss===!0?n=n():n.postcss&&(n=n.postcss),typeof n=="object"&&Array.isArray(n.plugins))t=t.concat(n.plugins);else if(typeof n=="object"&&n.postcssPlugin)t.push(n);else if(typeof n=="function")t.push(n);else if(!(typeof n=="object"&&(n.parse||n.stringify)))throw new Error(n+" is not a PostCSS plugin");return t}process(e,t={}){return this.plugins.length===0&&typeof t.parser>"u"&&typeof t.stringifier>"u"&&typeof t.syntax>"u"?new rs(this,e,t):new is(this,e,t)}use(e){return this.plugins=this.plugins.concat(this.normalize([e])),this}};var as=ge;ge.default=ge;os.registerProcessor(ge);ss.registerProcessor(ge);let ls=Ze,cs=En,us=Ke,hs=Nt,fs=qe,ds=xe,ps=Mt;function me(r,e){if(Array.isArray(r))return r.map(i=>me(i));let{inputs:t,...n}=r;if(t){e=[];for(let i of t){let o={...i,__proto__:fs.prototype};o.map&&(o.map={...o.map,__proto__:cs.prototype}),e.push(o)}}if(n.nodes&&(n.nodes=r.nodes.map(i=>me(i,e))),n.source){let{inputId:i,...o}=n.source;n.source=o,i!=null&&(n.source.input=e[i])}if(n.type==="root")return new ds(n);if(n.type==="decl")return new ls(n);if(n.type==="rule")return new ps(n);if(n.type==="comment")return new us(n);if(n.type==="atrule")return new hs(n);throw new Error("Unknown node type: "+r.type)}var gs=me;me.default=me;var an={};let ms=Ot,Vn=Ze,bs=Kn,ys=ee,Pt=as,ws=We,xs=gs,Jn=At,vs=zn,Xn=Ke,Qn=Nt,Es=Rt,Ss=qe,_s=It,Os=Wn,Yn=Mt,er=xe,ks=Ge;function E(...r){return r.length===1&&Array.isArray(r[0])&&(r=r[0]),new Pt(r)}E.plugin=function(e,t){let n=!1;function i(...s){console&&console.warn&&!n&&(n=!0,console.warn(e+`: postcss.plugin was deprecated. Migration guide:
|
|
105
|
-
https://evilmartians.com/chronicles/postcss-8-plugin-migration`),an.LANG&&an.LANG.startsWith("cn")&&console.warn(e+`: 里面 postcss.plugin 被弃用. 迁移指南:
|
|
106
|
-
https://www.w3ctech.com/topic/2226`));let a=t(...s);return a.postcssPlugin=e,a.postcssVersion=new Pt().version,a}let o;return Object.defineProperty(i,"postcss",{get(){return o||(o=i()),o}}),i.process=function(s,a,l){return E([i(l)]).process(s,a)},i};E.stringify=ws;E.parse=_s;E.fromJSON=xs;E.list=Os;E.comment=r=>new Xn(r);E.atRule=r=>new Qn(r);E.decl=r=>new Vn(r);E.rule=r=>new Yn(r);E.root=r=>new er(r);E.document=r=>new Jn(r);E.CssSyntaxError=ms;E.Declaration=Vn;E.Container=ys;E.Processor=Pt;E.Document=Jn;E.Comment=Xn;E.Warning=vs;E.AtRule=Qn;E.Result=Es;E.Input=Ss;E.Rule=Yn;E.Root=er;E.Node=ks;bs.registerPostcss(E);var Cs=E;E.default=E;const k=yn(Cs);k.stringify;k.fromJSON;k.plugin;k.parse;k.list;k.document;k.comment;k.atRule;k.rule;k.decl;k.root;k.CssSyntaxError;k.Declaration;k.Container;k.Processor;k.Document;k.Comment;k.Warning;k.AtRule;k.Result;k.Input;k.Rule;k.Root;k.Node;var As=function(e){const t=e.prefix,n=/\s+$/.test(t)?t:`${t} `,i=e.ignoreFiles?[].concat(e.ignoreFiles):[],o=e.includeFiles?[].concat(e.includeFiles):[];return function(s){i.length&&s.source.input.file&&ln(s.source.input.file,i)||o.length&&s.source.input.file&&!ln(s.source.input.file,o)||s.walkRules(a=>{const l=["keyframes","-webkit-keyframes","-moz-keyframes","-o-keyframes"];a.parent&&l.includes(a.parent.name)||(a.selectors=a.selectors.map(c=>e.exclude&&Rs(c,e.exclude)?c:e.transform?e.transform(t,c,n+c,s.source.input.file,a):n+c))})}};function ln(r,e){return e.some(t=>t instanceof RegExp?t.test(r):r.includes(t))}function Rs(r,e){return e.some(t=>t instanceof RegExp?t.test(r):r===t)}const Ns=yn(As),Ms="code{white-space:pre}.example{display:flex;flex-wrap:wrap;flex-direction:row;align-items:center;gap:16px}.example>*{flex:1 1 500px}.example .tab-control{overflow:hidden}.example div[role=tab]{cursor:pointer;padding:8px 16px;display:inline-block;font-size:16px;border-bottom:2px solid transparent;background-clip:padding-box;-webkit-user-select:none;user-select:none}.example div[role=tab]:hover{background-color:#1467ba14}.example div[role=tab][selected]{background-color:#1467ba21;border-bottom:2px solid #1467ba}.tab-content{margin:16px 0}.tab-content>pre{padding-top:0}.tab-content.code{max-height:500px;overflow:auto}.tab-content.code pre{margin:0}",Is="pre code.hljs{display:block;overflow-x:auto;padding:1em}code.hljs{padding:3px 5px}.hljs{color:#24292e;background:#fff}.hljs-doctag,.hljs-keyword,.hljs-meta .hljs-keyword,.hljs-template-tag,.hljs-template-variable,.hljs-type,.hljs-variable.language_{color:#d73a49}.hljs-title,.hljs-title.class_,.hljs-title.class_.inherited__,.hljs-title.function_{color:#6f42c1}.hljs-attr,.hljs-attribute,.hljs-literal,.hljs-meta,.hljs-number,.hljs-operator,.hljs-variable,.hljs-selector-attr,.hljs-selector-class,.hljs-selector-id{color:#005cc5}.hljs-regexp,.hljs-string,.hljs-meta .hljs-string{color:#032f62}.hljs-built_in,.hljs-symbol{color:#e36209}.hljs-comment,.hljs-code,.hljs-formula{color:#6a737d}.hljs-name,.hljs-quote,.hljs-selector-tag,.hljs-selector-pseudo{color:#22863a}.hljs-subst{color:#24292e}.hljs-section{color:#005cc5;font-weight:700}.hljs-bullet{color:#735c0f}.hljs-emphasis{color:#24292e;font-style:italic}.hljs-strong{color:#24292e;font-weight:700}.hljs-addition{color:#22863a;background-color:#f0fff4}.hljs-deletion{color:#b31d28;background-color:#ffeef0}";function Ps(r){return r&&r.__esModule&&Object.prototype.hasOwnProperty.call(r,"default")?r.default:r}function tr(r){return r instanceof Map?r.clear=r.delete=r.set=function(){throw new Error("map is read-only")}:r instanceof Set&&(r.add=r.clear=r.delete=function(){throw new Error("set is read-only")}),Object.freeze(r),Object.getOwnPropertyNames(r).forEach(e=>{const t=r[e],n=typeof t;(n==="object"||n==="function")&&!Object.isFrozen(t)&&tr(t)}),r}class cn{constructor(e){e.data===void 0&&(e.data={}),this.data=e.data,this.isMatchIgnored=!1}ignoreMatch(){this.isMatchIgnored=!0}}function nr(r){return r.replace(/&/g,"&").replace(/</g,"<").replace(/>/g,">").replace(/"/g,""").replace(/'/g,"'")}function K(r,...e){const t=Object.create(null);for(const n in r)t[n]=r[n];return e.forEach(function(n){for(const i in n)t[i]=n[i]}),t}const Ts="</span>",un=r=>!!r.scope,Ls=(r,{prefix:e})=>{if(r.startsWith("language:"))return r.replace("language:","language-");if(r.includes(".")){const t=r.split(".");return[`${e}${t.shift()}`,...t.map((n,i)=>`${n}${"_".repeat(i+1)}`)].join(" ")}return`${e}${r}`};class $s{constructor(e,t){this.buffer="",this.classPrefix=t.classPrefix,e.walk(this)}addText(e){this.buffer+=nr(e)}openNode(e){if(!un(e))return;const t=Ls(e.scope,{prefix:this.classPrefix});this.span(t)}closeNode(e){un(e)&&(this.buffer+=Ts)}value(){return this.buffer}span(e){this.buffer+=`<span class="${e}">`}}const hn=(r={})=>{const e={children:[]};return Object.assign(e,r),e};class Tt{constructor(){this.rootNode=hn(),this.stack=[this.rootNode]}get top(){return this.stack[this.stack.length-1]}get root(){return this.rootNode}add(e){this.top.children.push(e)}openNode(e){const t=hn({scope:e});this.add(t),this.stack.push(t)}closeNode(){if(this.stack.length>1)return this.stack.pop()}closeAllNodes(){for(;this.closeNode(););}toJSON(){return JSON.stringify(this.rootNode,null,4)}walk(e){return this.constructor._walk(e,this.rootNode)}static _walk(e,t){return typeof t=="string"?e.addText(t):t.children&&(e.openNode(t),t.children.forEach(n=>this._walk(e,n)),e.closeNode(t)),e}static _collapse(e){typeof e!="string"&&e.children&&(e.children.every(t=>typeof t=="string")?e.children=[e.children.join("")]:e.children.forEach(t=>{Tt._collapse(t)}))}}class js extends Tt{constructor(e){super(),this.options=e}addText(e){e!==""&&this.add(e)}startScope(e){this.openNode(e)}endScope(){this.closeNode()}__addSublanguage(e,t){const n=e.root;t&&(n.scope=`language:${t}`),this.add(n)}toHTML(){return new $s(this,this.options).value()}finalize(){return this.closeAllNodes(),!0}}function be(r){return r?typeof r=="string"?r:r.source:null}function rr(r){return te("(?=",r,")")}function Bs(r){return te("(?:",r,")*")}function zs(r){return te("(?:",r,")?")}function te(...r){return r.map(e=>be(e)).join("")}function Us(r){const e=r[r.length-1];return typeof e=="object"&&e.constructor===Object?(r.splice(r.length-1,1),e):{}}function Lt(...r){return"("+(Us(r).capture?"":"?:")+r.map(e=>be(e)).join("|")+")"}function ir(r){return new RegExp(r.toString()+"|").exec("").length-1}function Ds(r,e){const t=r&&r.exec(e);return t&&t.index===0}const Fs=/\[(?:[^\\\]]|\\.)*\]|\(\??|\\([1-9][0-9]*)|\\./;function $t(r,{joinWith:e}){let t=0;return r.map(n=>{t+=1;const i=t;let o=be(n),s="";for(;o.length>0;){const a=Fs.exec(o);if(!a){s+=o;break}s+=o.substring(0,a.index),o=o.substring(a.index+a[0].length),a[0][0]==="\\"&&a[1]?s+="\\"+String(Number(a[1])+i):(s+=a[0],a[0]==="("&&t++)}return s}).map(n=>`(${n})`).join(e)}const Hs=/\b\B/,sr="[a-zA-Z]\\w*",jt="[a-zA-Z_]\\w*",or="\\b\\d+(\\.\\d+)?",ar="(-?)(\\b0[xX][a-fA-F0-9]+|(\\b\\d+(\\.\\d*)?|\\.\\d+)([eE][-+]?\\d+)?)",lr="\\b(0b[01]+)",Ws="!|!=|!==|%|%=|&|&&|&=|\\*|\\*=|\\+|\\+=|,|-|-=|/=|/|:|;|<<|<<=|<=|<|===|==|=|>>>=|>>=|>=|>>>|>>|>|\\?|\\[|\\{|\\(|\\^|\\^=|\\||\\|=|\\|\\||~",Gs=(r={})=>{const e=/^#![ ]*\//;return r.binary&&(r.begin=te(e,/.*\b/,r.binary,/\b.*/)),K({scope:"meta",begin:e,end:/$/,relevance:0,"on:begin":(t,n)=>{t.index!==0&&n.ignoreMatch()}},r)},ye={begin:"\\\\[\\s\\S]",relevance:0},Zs={scope:"string",begin:"'",end:"'",illegal:"\\n",contains:[ye]},qs={scope:"string",begin:'"',end:'"',illegal:"\\n",contains:[ye]},Ks={begin:/\b(a|an|the|are|I'm|isn't|don't|doesn't|won't|but|just|should|pretty|simply|enough|gonna|going|wtf|so|such|will|you|your|they|like|more)\b/},Ve=function(r,e,t={}){const n=K({scope:"comment",begin:r,end:e,contains:[]},t);n.contains.push({scope:"doctag",begin:"[ ]*(?=(TODO|FIXME|NOTE|BUG|OPTIMIZE|HACK|XXX):)",end:/(TODO|FIXME|NOTE|BUG|OPTIMIZE|HACK|XXX):/,excludeBegin:!0,relevance:0});const i=Lt("I","a","is","so","us","to","at","if","in","it","on",/[A-Za-z]+['](d|ve|re|ll|t|s|n)/,/[A-Za-z]+[-][a-z]+/,/[A-Za-z][a-z]{2,}/);return n.contains.push({begin:te(/[ ]+/,"(",i,/[.]?[:]?([.][ ]|[ ])/,"){3}")}),n},Vs=Ve("//","$"),Js=Ve("/\\*","\\*/"),Xs=Ve("#","$"),Qs={scope:"number",begin:or,relevance:0},Ys={scope:"number",begin:ar,relevance:0},eo={scope:"number",begin:lr,relevance:0},to={scope:"regexp",begin:/\/(?=[^/\n]*\/)/,end:/\/[gimuy]*/,contains:[ye,{begin:/\[/,end:/\]/,relevance:0,contains:[ye]}]},no={scope:"title",begin:sr,relevance:0},ro={scope:"title",begin:jt,relevance:0},io={begin:"\\.\\s*"+jt,relevance:0},so=function(r){return Object.assign(r,{"on:begin":(e,t)=>{t.data._beginMatch=e[1]},"on:end":(e,t)=>{t.data._beginMatch!==e[1]&&t.ignoreMatch()}})};var Te=Object.freeze({__proto__:null,APOS_STRING_MODE:Zs,BACKSLASH_ESCAPE:ye,BINARY_NUMBER_MODE:eo,BINARY_NUMBER_RE:lr,COMMENT:Ve,C_BLOCK_COMMENT_MODE:Js,C_LINE_COMMENT_MODE:Vs,C_NUMBER_MODE:Ys,C_NUMBER_RE:ar,END_SAME_AS_BEGIN:so,HASH_COMMENT_MODE:Xs,IDENT_RE:sr,MATCH_NOTHING_RE:Hs,METHOD_GUARD:io,NUMBER_MODE:Qs,NUMBER_RE:or,PHRASAL_WORDS_MODE:Ks,QUOTE_STRING_MODE:qs,REGEXP_MODE:to,RE_STARTERS_RE:Ws,SHEBANG:Gs,TITLE_MODE:no,UNDERSCORE_IDENT_RE:jt,UNDERSCORE_TITLE_MODE:ro});function oo(r,e){r.input[r.index-1]==="."&&e.ignoreMatch()}function ao(r,e){r.className!==void 0&&(r.scope=r.className,delete r.className)}function lo(r,e){e&&r.beginKeywords&&(r.begin="\\b("+r.beginKeywords.split(" ").join("|")+")(?!\\.)(?=\\b|\\s)",r.__beforeBegin=oo,r.keywords=r.keywords||r.beginKeywords,delete r.beginKeywords,r.relevance===void 0&&(r.relevance=0))}function co(r,e){Array.isArray(r.illegal)&&(r.illegal=Lt(...r.illegal))}function uo(r,e){if(r.match){if(r.begin||r.end)throw new Error("begin & end are not supported with match");r.begin=r.match,delete r.match}}function ho(r,e){r.relevance===void 0&&(r.relevance=1)}const fo=(r,e)=>{if(!r.beforeMatch)return;if(r.starts)throw new Error("beforeMatch cannot be used with starts");const t=Object.assign({},r);Object.keys(r).forEach(n=>{delete r[n]}),r.keywords=t.keywords,r.begin=te(t.beforeMatch,rr(t.begin)),r.starts={relevance:0,contains:[Object.assign(t,{endsParent:!0})]},r.relevance=0,delete t.beforeMatch},po=["of","and","for","in","not","or","if","then","parent","list","value"],go="keyword";function cr(r,e,t=go){const n=Object.create(null);return typeof r=="string"?i(t,r.split(" ")):Array.isArray(r)?i(t,r):Object.keys(r).forEach(function(o){Object.assign(n,cr(r[o],e,o))}),n;function i(o,s){e&&(s=s.map(a=>a.toLowerCase())),s.forEach(function(a){const l=a.split("|");n[l[0]]=[o,mo(l[0],l[1])]})}}function mo(r,e){return e?Number(e):bo(r)?0:1}function bo(r){return po.includes(r.toLowerCase())}const fn={},Y=r=>{console.error(r)},dn=(r,...e)=>{console.log(`WARN: ${r}`,...e)},re=(r,e)=>{fn[`${r}/${e}`]||(console.log(`Deprecated as of ${r}. ${e}`),fn[`${r}/${e}`]=!0)},Fe=new Error;function ur(r,e,{key:t}){let n=0;const i=r[t],o={},s={};for(let a=1;a<=e.length;a++)s[a+n]=i[a],o[a+n]=!0,n+=ir(e[a-1]);r[t]=s,r[t]._emit=o,r[t]._multi=!0}function yo(r){if(Array.isArray(r.begin)){if(r.skip||r.excludeBegin||r.returnBegin)throw Y("skip, excludeBegin, returnBegin not compatible with beginScope: {}"),Fe;if(typeof r.beginScope!="object"||r.beginScope===null)throw Y("beginScope must be object"),Fe;ur(r,r.begin,{key:"beginScope"}),r.begin=$t(r.begin,{joinWith:""})}}function wo(r){if(Array.isArray(r.end)){if(r.skip||r.excludeEnd||r.returnEnd)throw Y("skip, excludeEnd, returnEnd not compatible with endScope: {}"),Fe;if(typeof r.endScope!="object"||r.endScope===null)throw Y("endScope must be object"),Fe;ur(r,r.end,{key:"endScope"}),r.end=$t(r.end,{joinWith:""})}}function xo(r){r.scope&&typeof r.scope=="object"&&r.scope!==null&&(r.beginScope=r.scope,delete r.scope)}function vo(r){xo(r),typeof r.beginScope=="string"&&(r.beginScope={_wrap:r.beginScope}),typeof r.endScope=="string"&&(r.endScope={_wrap:r.endScope}),yo(r),wo(r)}function Eo(r){function e(s,a){return new RegExp(be(s),"m"+(r.case_insensitive?"i":"")+(r.unicodeRegex?"u":"")+(a?"g":""))}class t{constructor(){this.matchIndexes={},this.regexes=[],this.matchAt=1,this.position=0}addRule(a,l){l.position=this.position++,this.matchIndexes[this.matchAt]=l,this.regexes.push([l,a]),this.matchAt+=ir(a)+1}compile(){this.regexes.length===0&&(this.exec=()=>null);const a=this.regexes.map(l=>l[1]);this.matcherRe=e($t(a,{joinWith:"|"}),!0),this.lastIndex=0}exec(a){this.matcherRe.lastIndex=this.lastIndex;const l=this.matcherRe.exec(a);if(!l)return null;const c=l.findIndex((b,g)=>g>0&&b!==void 0),h=this.matchIndexes[c];return l.splice(0,c),Object.assign(l,h)}}class n{constructor(){this.rules=[],this.multiRegexes=[],this.count=0,this.lastIndex=0,this.regexIndex=0}getMatcher(a){if(this.multiRegexes[a])return this.multiRegexes[a];const l=new t;return this.rules.slice(a).forEach(([c,h])=>l.addRule(c,h)),l.compile(),this.multiRegexes[a]=l,l}resumingScanAtSamePosition(){return this.regexIndex!==0}considerAll(){this.regexIndex=0}addRule(a,l){this.rules.push([a,l]),l.type==="begin"&&this.count++}exec(a){const l=this.getMatcher(this.regexIndex);l.lastIndex=this.lastIndex;let c=l.exec(a);if(this.resumingScanAtSamePosition()&&!(c&&c.index===this.lastIndex)){const h=this.getMatcher(0);h.lastIndex=this.lastIndex+1,c=h.exec(a)}return c&&(this.regexIndex+=c.position+1,this.regexIndex===this.count&&this.considerAll()),c}}function i(s){const a=new n;return s.contains.forEach(l=>a.addRule(l.begin,{rule:l,type:"begin"})),s.terminatorEnd&&a.addRule(s.terminatorEnd,{type:"end"}),s.illegal&&a.addRule(s.illegal,{type:"illegal"}),a}function o(s,a){const l=s;if(s.isCompiled)return l;[ao,uo,vo,fo].forEach(h=>h(s,a)),r.compilerExtensions.forEach(h=>h(s,a)),s.__beforeBegin=null,[lo,co,ho].forEach(h=>h(s,a)),s.isCompiled=!0;let c=null;return typeof s.keywords=="object"&&s.keywords.$pattern&&(s.keywords=Object.assign({},s.keywords),c=s.keywords.$pattern,delete s.keywords.$pattern),c=c||/\w+/,s.keywords&&(s.keywords=cr(s.keywords,r.case_insensitive)),l.keywordPatternRe=e(c,!0),a&&(s.begin||(s.begin=/\B|\b/),l.beginRe=e(l.begin),!s.end&&!s.endsWithParent&&(s.end=/\B|\b/),s.end&&(l.endRe=e(l.end)),l.terminatorEnd=be(l.end)||"",s.endsWithParent&&a.terminatorEnd&&(l.terminatorEnd+=(s.end?"|":"")+a.terminatorEnd)),s.illegal&&(l.illegalRe=e(s.illegal)),s.contains||(s.contains=[]),s.contains=[].concat(...s.contains.map(function(h){return So(h==="self"?s:h)})),s.contains.forEach(function(h){o(h,l)}),s.starts&&o(s.starts,a),l.matcher=i(l),l}if(r.compilerExtensions||(r.compilerExtensions=[]),r.contains&&r.contains.includes("self"))throw new Error("ERR: contains `self` is not supported at the top-level of a language. See documentation.");return r.classNameAliases=K(r.classNameAliases||{}),o(r)}function hr(r){return r?r.endsWithParent||hr(r.starts):!1}function So(r){return r.variants&&!r.cachedVariants&&(r.cachedVariants=r.variants.map(function(e){return K(r,{variants:null},e)})),r.cachedVariants?r.cachedVariants:hr(r)?K(r,{starts:r.starts?K(r.starts):null}):Object.isFrozen(r)?K(r):r}var _o="11.9.0";class Oo extends Error{constructor(e,t){super(e),this.name="HTMLInjectionError",this.html=t}}const lt=nr,pn=K,gn=Symbol("nomatch"),ko=7,fr=function(r){const e=Object.create(null),t=Object.create(null),n=[];let i=!0;const o="Could not find the language '{}', did you forget to load/include a language module?",s={disableAutodetect:!0,name:"Plain text",contains:[]};let a={ignoreUnescapedHTML:!1,throwUnescapedHTML:!1,noHighlightRe:/^(no-?highlight)$/i,languageDetectRe:/\blang(?:uage)?-([\w-]+)\b/i,classPrefix:"hljs-",cssSelector:"pre code",languages:null,__emitter:js};function l(u){return a.noHighlightRe.test(u)}function c(u){let d=u.className+" ";d+=u.parentNode?u.parentNode.className:"";const w=a.languageDetectRe.exec(d);if(w){const v=I(w[1]);return v||(dn(o.replace("{}",w[1])),dn("Falling back to no-highlight mode for this block.",u)),v?w[1]:"no-highlight"}return d.split(/\s+/).find(v=>l(v)||I(v))}function h(u,d,w){let v="",A="";typeof d=="object"?(v=u,w=d.ignoreIllegals,A=d.language):(re("10.7.0","highlight(lang, code, ...args) has been deprecated."),re("10.7.0",`Please use highlight(code, options) instead.
|
|
107
|
-
https://github.com/highlightjs/highlight.js/issues/2277`),A=u,v=d),w===void 0&&(w=!0);const P={code:v,language:A};X("before:highlight",P);const q=P.result?P.result:b(P.language,P.code,w);return q.code=P.code,X("after:highlight",q),q}function b(u,d,w,v){const A=Object.create(null);function P(f,p){return f.keywords[p]}function q(){if(!y.keywords){N.addText(_);return}let f=0;y.keywordPatternRe.lastIndex=0;let p=y.keywordPatternRe.exec(_),x="";for(;p;){x+=_.substring(f,p.index);const S=U.case_insensitive?p[0].toLowerCase():p[0],M=P(y,S);if(M){const[G,kr]=M;if(N.addText(x),x="",A[S]=(A[S]||0)+1,A[S]<=ko&&(_e+=kr),G.startsWith("_"))x+=p[0];else{const Cr=U.classNameAliases[G]||G;z(p[0],Cr)}}else x+=p[0];f=y.keywordPatternRe.lastIndex,p=y.keywordPatternRe.exec(_)}x+=_.substring(f),N.addText(x)}function Ee(){if(_==="")return;let f=null;if(typeof y.subLanguage=="string"){if(!e[y.subLanguage]){N.addText(_);return}f=b(y.subLanguage,_,!0,Ft[y.subLanguage]),Ft[y.subLanguage]=f._top}else f=C(_,y.subLanguage.length?y.subLanguage:null);y.relevance>0&&(_e+=f.relevance),N.__addSublanguage(f._emitter,f.language)}function T(){y.subLanguage!=null?Ee():q(),_=""}function z(f,p){f!==""&&(N.startScope(p),N.addText(f),N.endScope())}function Bt(f,p){let x=1;const S=p.length-1;for(;x<=S;){if(!f._emit[x]){x++;continue}const M=U.classNameAliases[f[x]]||f[x],G=p[x];M?z(G,M):(_=G,q(),_=""),x++}}function zt(f,p){return f.scope&&typeof f.scope=="string"&&N.openNode(U.classNameAliases[f.scope]||f.scope),f.beginScope&&(f.beginScope._wrap?(z(_,U.classNameAliases[f.beginScope._wrap]||f.beginScope._wrap),_=""):f.beginScope._multi&&(Bt(f.beginScope,p),_="")),y=Object.create(f,{parent:{value:y}}),y}function Ut(f,p,x){let S=Ds(f.endRe,x);if(S){if(f["on:end"]){const M=new cn(f);f["on:end"](p,M),M.isMatchIgnored&&(S=!1)}if(S){for(;f.endsParent&&f.parent;)f=f.parent;return f}}if(f.endsWithParent)return Ut(f.parent,p,x)}function vr(f){return y.matcher.regexIndex===0?(_+=f[0],1):(rt=!0,0)}function Er(f){const p=f[0],x=f.rule,S=new cn(x),M=[x.__beforeBegin,x["on:begin"]];for(const G of M)if(G&&(G(f,S),S.isMatchIgnored))return vr(p);return x.skip?_+=p:(x.excludeBegin&&(_+=p),T(),!x.returnBegin&&!x.excludeBegin&&(_=p)),zt(x,f),x.returnBegin?0:p.length}function Sr(f){const p=f[0],x=d.substring(f.index),S=Ut(y,f,x);if(!S)return gn;const M=y;y.endScope&&y.endScope._wrap?(T(),z(p,y.endScope._wrap)):y.endScope&&y.endScope._multi?(T(),Bt(y.endScope,f)):M.skip?_+=p:(M.returnEnd||M.excludeEnd||(_+=p),T(),M.excludeEnd&&(_=p));do y.scope&&N.closeNode(),!y.skip&&!y.subLanguage&&(_e+=y.relevance),y=y.parent;while(y!==S.parent);return S.starts&&zt(S.starts,f),M.returnEnd?0:p.length}function _r(){const f=[];for(let p=y;p!==U;p=p.parent)p.scope&&f.unshift(p.scope);f.forEach(p=>N.openNode(p))}let Se={};function Dt(f,p){const x=p&&p[0];if(_+=f,x==null)return T(),0;if(Se.type==="begin"&&p.type==="end"&&Se.index===p.index&&x===""){if(_+=d.slice(p.index,p.index+1),!i){const S=new Error(`0 width match regex (${u})`);throw S.languageName=u,S.badRule=Se.rule,S}return 1}if(Se=p,p.type==="begin")return Er(p);if(p.type==="illegal"&&!w){const S=new Error('Illegal lexeme "'+x+'" for mode "'+(y.scope||"<unnamed>")+'"');throw S.mode=y,S}else if(p.type==="end"){const S=Sr(p);if(S!==gn)return S}if(p.type==="illegal"&&x==="")return 1;if(nt>1e5&&nt>p.index*3)throw new Error("potential infinite loop, way more iterations than matches");return _+=x,x.length}const U=I(u);if(!U)throw Y(o.replace("{}",u)),new Error('Unknown language: "'+u+'"');const Or=Eo(U);let tt="",y=v||Or;const Ft={},N=new a.__emitter(a);_r();let _="",_e=0,Q=0,nt=0,rt=!1;try{if(U.__emitTokens)U.__emitTokens(d,N);else{for(y.matcher.considerAll();;){nt++,rt?rt=!1:y.matcher.considerAll(),y.matcher.lastIndex=Q;const f=y.matcher.exec(d);if(!f)break;const p=d.substring(Q,f.index),x=Dt(p,f);Q=f.index+x}Dt(d.substring(Q))}return N.finalize(),tt=N.toHTML(),{language:u,value:tt,relevance:_e,illegal:!1,_emitter:N,_top:y}}catch(f){if(f.message&&f.message.includes("Illegal"))return{language:u,value:lt(d),illegal:!0,relevance:0,_illegalBy:{message:f.message,index:Q,context:d.slice(Q-100,Q+100),mode:f.mode,resultSoFar:tt},_emitter:N};if(i)return{language:u,value:lt(d),illegal:!1,relevance:0,errorRaised:f,_emitter:N,_top:y};throw f}}function g(u){const d={value:lt(u),illegal:!1,relevance:0,_top:s,_emitter:new a.__emitter(a)};return d._emitter.addText(u),d}function C(u,d){d=d||a.languages||Object.keys(e);const w=g(u),v=d.filter(I).filter(ve).map(T=>b(T,u,!1));v.unshift(w);const A=v.sort((T,z)=>{if(T.relevance!==z.relevance)return z.relevance-T.relevance;if(T.language&&z.language){if(I(T.language).supersetOf===z.language)return 1;if(I(z.language).supersetOf===T.language)return-1}return 0}),[P,q]=A,Ee=P;return Ee.secondBest=q,Ee}function R(u,d,w){const v=d&&t[d]||w;u.classList.add("hljs"),u.classList.add(`language-${v}`)}function L(u){let d=null;const w=c(u);if(l(w))return;if(X("before:highlightElement",{el:u,language:w}),u.dataset.highlighted){console.log("Element previously highlighted. To highlight again, first unset `dataset.highlighted`.",u);return}if(u.children.length>0&&(a.ignoreUnescapedHTML||(console.warn("One of your code blocks includes unescaped HTML. This is a potentially serious security risk."),console.warn("https://github.com/highlightjs/highlight.js/wiki/security"),console.warn("The element with unescaped HTML:"),console.warn(u)),a.throwUnescapedHTML))throw new Oo("One of your code blocks includes unescaped HTML.",u.innerHTML);d=u;const v=d.textContent,A=w?h(v,{language:w,ignoreIllegals:!0}):C(v);u.innerHTML=A.value,u.dataset.highlighted="yes",R(u,w,A.language),u.result={language:A.language,re:A.relevance,relevance:A.relevance},A.secondBest&&(u.secondBest={language:A.secondBest.language,relevance:A.secondBest.relevance}),X("after:highlightElement",{el:u,result:A,text:v})}function m(u){a=pn(a,u)}const F=()=>{$(),re("10.6.0","initHighlighting() deprecated. Use highlightAll() now.")};function H(){$(),re("10.6.0","initHighlightingOnLoad() deprecated. Use highlightAll() now.")}let V=!1;function $(){if(document.readyState==="loading"){V=!0;return}document.querySelectorAll(a.cssSelector).forEach(L)}function W(){V&&$()}typeof window<"u"&&window.addEventListener&&window.addEventListener("DOMContentLoaded",W,!1);function le(u,d){let w=null;try{w=d(r)}catch(v){if(Y("Language definition for '{}' could not be registered.".replace("{}",u)),i)Y(v);else throw v;w=s}w.name||(w.name=u),e[u]=w,w.rawDefinition=d.bind(null,r),w.aliases&&J(w.aliases,{languageName:u})}function ne(u){delete e[u];for(const d of Object.keys(t))t[d]===u&&delete t[d]}function B(){return Object.keys(e)}function I(u){return u=(u||"").toLowerCase(),e[u]||e[t[u]]}function J(u,{languageName:d}){typeof u=="string"&&(u=[u]),u.forEach(w=>{t[w.toLowerCase()]=d})}function ve(u){const d=I(u);return d&&!d.disableAutodetect}function Xe(u){u["before:highlightBlock"]&&!u["before:highlightElement"]&&(u["before:highlightElement"]=d=>{u["before:highlightBlock"](Object.assign({block:d.el},d))}),u["after:highlightBlock"]&&!u["after:highlightElement"]&&(u["after:highlightElement"]=d=>{u["after:highlightBlock"](Object.assign({block:d.el},d))})}function Qe(u){Xe(u),n.push(u)}function Ye(u){const d=n.indexOf(u);d!==-1&&n.splice(d,1)}function X(u,d){const w=u;n.forEach(function(v){v[w]&&v[w](d)})}function et(u){return re("10.7.0","highlightBlock will be removed entirely in v12.0"),re("10.7.0","Please use highlightElement now."),L(u)}Object.assign(r,{highlight:h,highlightAuto:C,highlightAll:$,highlightElement:L,highlightBlock:et,configure:m,initHighlighting:F,initHighlightingOnLoad:H,registerLanguage:le,unregisterLanguage:ne,listLanguages:B,getLanguage:I,registerAliases:J,autoDetection:ve,inherit:pn,addPlugin:Qe,removePlugin:Ye}),r.debugMode=function(){i=!1},r.safeMode=function(){i=!0},r.versionString=_o,r.regex={concat:te,lookahead:rr,either:Lt,optional:zs,anyNumberOfTimes:Bs};for(const u in Te)typeof Te[u]=="object"&&tr(Te[u]);return Object.assign(r,Te),r},ae=fr({});ae.newInstance=()=>fr({});var Co=ae;ae.HighlightJS=ae;ae.default=ae;const Je=Ps(Co),He="[A-Za-z$_][0-9A-Za-z$_]*",dr=["as","in","of","if","for","while","finally","var","new","function","do","return","void","else","break","catch","instanceof","with","throw","case","default","try","switch","continue","typeof","delete","let","yield","const","class","debugger","async","await","static","import","from","export","extends"],pr=["true","false","null","undefined","NaN","Infinity"],gr=["Object","Function","Boolean","Symbol","Math","Date","Number","BigInt","String","RegExp","Array","Float32Array","Float64Array","Int8Array","Uint8Array","Uint8ClampedArray","Int16Array","Int32Array","Uint16Array","Uint32Array","BigInt64Array","BigUint64Array","Set","Map","WeakSet","WeakMap","ArrayBuffer","SharedArrayBuffer","Atomics","DataView","JSON","Promise","Generator","GeneratorFunction","AsyncFunction","Reflect","Proxy","Intl","WebAssembly"],mr=["Error","EvalError","InternalError","RangeError","ReferenceError","SyntaxError","TypeError","URIError"],br=["setInterval","setTimeout","clearInterval","clearTimeout","require","exports","eval","isFinite","isNaN","parseFloat","parseInt","decodeURI","decodeURIComponent","encodeURI","encodeURIComponent","escape","unescape"],yr=["arguments","this","super","console","window","document","localStorage","sessionStorage","module","global"],wr=[].concat(br,gr,mr);function Ao(r){const e=r.regex,t=(u,{after:d})=>{const w="</"+u[0].slice(1);return u.input.indexOf(w,d)!==-1},n=He,i={begin:"<>",end:"</>"},o=/<[A-Za-z0-9\\._:-]+\s*\/>/,s={begin:/<[A-Za-z0-9\\._:-]+/,end:/\/[A-Za-z0-9\\._:-]+>|\/>/,isTrulyOpeningTag:(u,d)=>{const w=u[0].length+u.index,v=u.input[w];if(v==="<"||v===","){d.ignoreMatch();return}v===">"&&(t(u,{after:w})||d.ignoreMatch());let A;const P=u.input.substring(w);if(A=P.match(/^\s*=/)){d.ignoreMatch();return}if((A=P.match(/^\s+extends\s+/))&&A.index===0){d.ignoreMatch();return}}},a={$pattern:He,keyword:dr,literal:pr,built_in:wr,"variable.language":yr},l="[0-9](_?[0-9])*",c=`\\.(${l})`,h="0|[1-9](_?[0-9])*|0[0-7]*[89][0-9]*",b={className:"number",variants:[{begin:`(\\b(${h})((${c})|\\.)?|(${c}))[eE][+-]?(${l})\\b`},{begin:`\\b(${h})\\b((${c})\\b|\\.)?|(${c})\\b`},{begin:"\\b(0|[1-9](_?[0-9])*)n\\b"},{begin:"\\b0[xX][0-9a-fA-F](_?[0-9a-fA-F])*n?\\b"},{begin:"\\b0[bB][0-1](_?[0-1])*n?\\b"},{begin:"\\b0[oO][0-7](_?[0-7])*n?\\b"},{begin:"\\b0[0-7]+n?\\b"}],relevance:0},g={className:"subst",begin:"\\$\\{",end:"\\}",keywords:a,contains:[]},C={begin:"html`",end:"",starts:{end:"`",returnEnd:!1,contains:[r.BACKSLASH_ESCAPE,g],subLanguage:"xml"}},R={begin:"css`",end:"",starts:{end:"`",returnEnd:!1,contains:[r.BACKSLASH_ESCAPE,g],subLanguage:"css"}},L={begin:"gql`",end:"",starts:{end:"`",returnEnd:!1,contains:[r.BACKSLASH_ESCAPE,g],subLanguage:"graphql"}},m={className:"string",begin:"`",end:"`",contains:[r.BACKSLASH_ESCAPE,g]},F={className:"comment",variants:[r.COMMENT(/\/\*\*(?!\/)/,"\\*/",{relevance:0,contains:[{begin:"(?=@[A-Za-z]+)",relevance:0,contains:[{className:"doctag",begin:"@[A-Za-z]+"},{className:"type",begin:"\\{",end:"\\}",excludeEnd:!0,excludeBegin:!0,relevance:0},{className:"variable",begin:n+"(?=\\s*(-)|$)",endsParent:!0,relevance:0},{begin:/(?=[^\n])\s/,relevance:0}]}]}),r.C_BLOCK_COMMENT_MODE,r.C_LINE_COMMENT_MODE]},H=[r.APOS_STRING_MODE,r.QUOTE_STRING_MODE,C,R,L,m,{match:/\$\d+/},b];g.contains=H.concat({begin:/\{/,end:/\}/,keywords:a,contains:["self"].concat(H)});const V=[].concat(F,g.contains),$=V.concat([{begin:/\(/,end:/\)/,keywords:a,contains:["self"].concat(V)}]),W={className:"params",begin:/\(/,end:/\)/,excludeBegin:!0,excludeEnd:!0,keywords:a,contains:$},le={variants:[{match:[/class/,/\s+/,n,/\s+/,/extends/,/\s+/,e.concat(n,"(",e.concat(/\./,n),")*")],scope:{1:"keyword",3:"title.class",5:"keyword",7:"title.class.inherited"}},{match:[/class/,/\s+/,n],scope:{1:"keyword",3:"title.class"}}]},ne={relevance:0,match:e.either(/\bJSON/,/\b[A-Z][a-z]+([A-Z][a-z]*|\d)*/,/\b[A-Z]{2,}([A-Z][a-z]+|\d)+([A-Z][a-z]*)*/,/\b[A-Z]{2,}[a-z]+([A-Z][a-z]+|\d)*([A-Z][a-z]*)*/),className:"title.class",keywords:{_:[...gr,...mr]}},B={label:"use_strict",className:"meta",relevance:10,begin:/^\s*['"]use (strict|asm)['"]/},I={variants:[{match:[/function/,/\s+/,n,/(?=\s*\()/]},{match:[/function/,/\s*(?=\()/]}],className:{1:"keyword",3:"title.function"},label:"func.def",contains:[W],illegal:/%/},J={relevance:0,match:/\b[A-Z][A-Z_0-9]+\b/,className:"variable.constant"};function ve(u){return e.concat("(?!",u.join("|"),")")}const Xe={match:e.concat(/\b/,ve([...br,"super","import"]),n,e.lookahead(/\(/)),className:"title.function",relevance:0},Qe={begin:e.concat(/\./,e.lookahead(e.concat(n,/(?![0-9A-Za-z$_(])/))),end:n,excludeBegin:!0,keywords:"prototype",className:"property",relevance:0},Ye={match:[/get|set/,/\s+/,n,/(?=\()/],className:{1:"keyword",3:"title.function"},contains:[{begin:/\(\)/},W]},X="(\\([^()]*(\\([^()]*(\\([^()]*\\)[^()]*)*\\)[^()]*)*\\)|"+r.UNDERSCORE_IDENT_RE+")\\s*=>",et={match:[/const|var|let/,/\s+/,n,/\s*/,/=\s*/,/(async\s*)?/,e.lookahead(X)],keywords:"async",className:{1:"keyword",3:"title.function"},contains:[W]};return{name:"JavaScript",aliases:["js","jsx","mjs","cjs"],keywords:a,exports:{PARAMS_CONTAINS:$,CLASS_REFERENCE:ne},illegal:/#(?![$_A-z])/,contains:[r.SHEBANG({label:"shebang",binary:"node",relevance:5}),B,r.APOS_STRING_MODE,r.QUOTE_STRING_MODE,C,R,L,m,F,{match:/\$\d+/},b,ne,{className:"attr",begin:n+e.lookahead(":"),relevance:0},et,{begin:"("+r.RE_STARTERS_RE+"|\\b(case|return|throw)\\b)\\s*",keywords:"return throw case",relevance:0,contains:[F,r.REGEXP_MODE,{className:"function",begin:X,returnBegin:!0,end:"\\s*=>",contains:[{className:"params",variants:[{begin:r.UNDERSCORE_IDENT_RE,relevance:0},{className:null,begin:/\(\s*\)/,skip:!0},{begin:/\(/,end:/\)/,excludeBegin:!0,excludeEnd:!0,keywords:a,contains:$}]}]},{begin:/,/,relevance:0},{match:/\s+/,relevance:0},{variants:[{begin:i.begin,end:i.end},{match:o},{begin:s.begin,"on:begin":s.isTrulyOpeningTag,end:s.end}],subLanguage:"xml",contains:[{begin:s.begin,end:s.end,skip:!0,contains:["self"]}]}]},I,{beginKeywords:"while if switch catch for"},{begin:"\\b(?!function)"+r.UNDERSCORE_IDENT_RE+"\\([^()]*(\\([^()]*(\\([^()]*\\)[^()]*)*\\)[^()]*)*\\)\\s*\\{",returnBegin:!0,label:"func.def",contains:[W,r.inherit(r.TITLE_MODE,{begin:n,className:"title.function"})]},{match:/\.\.\./,relevance:0},Qe,{match:"\\$"+n,relevance:0},{match:[/\bconstructor(?=\s*\()/],className:{1:"title.function"},contains:[W]},Xe,J,le,Ye,{match:/\$[(.]/}]}}function Ro(r){const e=Ao(r),t=He,n=["any","void","number","boolean","string","object","never","symbol","bigint","unknown"],i={beginKeywords:"namespace",end:/\{/,excludeEnd:!0,contains:[e.exports.CLASS_REFERENCE]},o={beginKeywords:"interface",end:/\{/,excludeEnd:!0,keywords:{keyword:"interface extends",built_in:n},contains:[e.exports.CLASS_REFERENCE]},s={className:"meta",relevance:10,begin:/^\s*['"]use strict['"]/},a=["type","namespace","interface","public","private","protected","implements","declare","abstract","readonly","enum","override"],l={$pattern:He,keyword:dr.concat(a),literal:pr,built_in:wr.concat(n),"variable.language":yr},c={className:"meta",begin:"@"+t},h=(g,C,R)=>{const L=g.contains.findIndex(m=>m.label===C);if(L===-1)throw new Error("can not find mode to replace");g.contains.splice(L,1,R)};Object.assign(e.keywords,l),e.exports.PARAMS_CONTAINS.push(c),e.contains=e.contains.concat([c,i,o]),h(e,"shebang",r.SHEBANG()),h(e,"use_strict",s);const b=e.contains.find(g=>g.label==="func.def");return b.relevance=0,Object.assign(e,{name:"TypeScript",aliases:["ts","tsx","mts","cts"]}),e}function No(r){const e=r.regex,t=e.concat(/[\p{L}_]/u,e.optional(/[\p{L}0-9_.-]*:/u),/[\p{L}0-9_.-]*/u),n=/[\p{L}0-9._:-]+/u,i={className:"symbol",begin:/&[a-z]+;|&#[0-9]+;|&#x[a-f0-9]+;/},o={begin:/\s/,contains:[{className:"keyword",begin:/#?[a-z_][a-z1-9_-]+/,illegal:/\n/}]},s=r.inherit(o,{begin:/\(/,end:/\)/}),a=r.inherit(r.APOS_STRING_MODE,{className:"string"}),l=r.inherit(r.QUOTE_STRING_MODE,{className:"string"}),c={endsWithParent:!0,illegal:/</,relevance:0,contains:[{className:"attr",begin:n,relevance:0},{begin:/=\s*/,relevance:0,contains:[{className:"string",endsParent:!0,variants:[{begin:/"/,end:/"/,contains:[i]},{begin:/'/,end:/'/,contains:[i]},{begin:/[^\s"'=<>`]+/}]}]}]};return{name:"HTML, XML",aliases:["html","xhtml","rss","atom","xjb","xsd","xsl","plist","wsf","svg"],case_insensitive:!0,unicodeRegex:!0,contains:[{className:"meta",begin:/<![a-z]/,end:/>/,relevance:10,contains:[o,l,a,s,{begin:/\[/,end:/\]/,contains:[{className:"meta",begin:/<![a-z]/,end:/>/,contains:[o,s,l,a]}]}]},r.COMMENT(/<!--/,/-->/,{relevance:10}),{begin:/<!\[CDATA\[/,end:/\]\]>/,relevance:10},i,{className:"meta",end:/\?>/,variants:[{begin:/<\?xml/,relevance:10,contains:[l]},{begin:/<\?[a-z][a-z0-9]+/}]},{className:"tag",begin:/<style(?=\s|>)/,end:/>/,keywords:{name:"style"},contains:[c],starts:{end:/<\/style>/,returnEnd:!0,subLanguage:["css","xml"]}},{className:"tag",begin:/<script(?=\s|>)/,end:/>/,keywords:{name:"script"},contains:[c],starts:{end:/<\/script>/,returnEnd:!0,subLanguage:["javascript","handlebars","xml"]}},{className:"tag",begin:/<>|<\/>/},{className:"tag",begin:e.concat(/</,e.lookahead(e.concat(t,e.either(/\/>/,/>/,/\s/)))),end:/\/?>/,contains:[{className:"name",begin:t,relevance:0,starts:c}]},{className:"tag",begin:e.concat(/<\//,e.lookahead(e.concat(t,/>/))),contains:[{className:"name",begin:t,relevance:0},{begin:/>/,relevance:0,endsParent:!0}]}]}}const Mo=r=>({IMPORTANT:{scope:"meta",begin:"!important"},BLOCK_COMMENT:r.C_BLOCK_COMMENT_MODE,HEXCOLOR:{scope:"number",begin:/#(([0-9a-fA-F]{3,4})|(([0-9a-fA-F]{2}){3,4}))\b/},FUNCTION_DISPATCH:{className:"built_in",begin:/[\w-]+(?=\()/},ATTRIBUTE_SELECTOR_MODE:{scope:"selector-attr",begin:/\[/,end:/\]/,illegal:"$",contains:[r.APOS_STRING_MODE,r.QUOTE_STRING_MODE]},CSS_NUMBER_MODE:{scope:"number",begin:r.NUMBER_RE+"(%|em|ex|ch|rem|vw|vh|vmin|vmax|cm|mm|in|pt|pc|px|deg|grad|rad|turn|s|ms|Hz|kHz|dpi|dpcm|dppx)?",relevance:0},CSS_VARIABLE:{className:"attr",begin:/--[A-Za-z_][A-Za-z0-9_-]*/}}),Io=["a","abbr","address","article","aside","audio","b","blockquote","body","button","canvas","caption","cite","code","dd","del","details","dfn","div","dl","dt","em","fieldset","figcaption","figure","footer","form","h1","h2","h3","h4","h5","h6","header","hgroup","html","i","iframe","img","input","ins","kbd","label","legend","li","main","mark","menu","nav","object","ol","p","q","quote","samp","section","span","strong","summary","sup","table","tbody","td","textarea","tfoot","th","thead","time","tr","ul","var","video"],Po=["any-hover","any-pointer","aspect-ratio","color","color-gamut","color-index","device-aspect-ratio","device-height","device-width","display-mode","forced-colors","grid","height","hover","inverted-colors","monochrome","orientation","overflow-block","overflow-inline","pointer","prefers-color-scheme","prefers-contrast","prefers-reduced-motion","prefers-reduced-transparency","resolution","scan","scripting","update","width","min-width","max-width","min-height","max-height"],To=["active","any-link","blank","checked","current","default","defined","dir","disabled","drop","empty","enabled","first","first-child","first-of-type","fullscreen","future","focus","focus-visible","focus-within","has","host","host-context","hover","indeterminate","in-range","invalid","is","lang","last-child","last-of-type","left","link","local-link","not","nth-child","nth-col","nth-last-child","nth-last-col","nth-last-of-type","nth-of-type","only-child","only-of-type","optional","out-of-range","past","placeholder-shown","read-only","read-write","required","right","root","scope","target","target-within","user-invalid","valid","visited","where"],Lo=["after","backdrop","before","cue","cue-region","first-letter","first-line","grammar-error","marker","part","placeholder","selection","slotted","spelling-error"],$o=["align-content","align-items","align-self","all","animation","animation-delay","animation-direction","animation-duration","animation-fill-mode","animation-iteration-count","animation-name","animation-play-state","animation-timing-function","backface-visibility","background","background-attachment","background-blend-mode","background-clip","background-color","background-image","background-origin","background-position","background-repeat","background-size","block-size","border","border-block","border-block-color","border-block-end","border-block-end-color","border-block-end-style","border-block-end-width","border-block-start","border-block-start-color","border-block-start-style","border-block-start-width","border-block-style","border-block-width","border-bottom","border-bottom-color","border-bottom-left-radius","border-bottom-right-radius","border-bottom-style","border-bottom-width","border-collapse","border-color","border-image","border-image-outset","border-image-repeat","border-image-slice","border-image-source","border-image-width","border-inline","border-inline-color","border-inline-end","border-inline-end-color","border-inline-end-style","border-inline-end-width","border-inline-start","border-inline-start-color","border-inline-start-style","border-inline-start-width","border-inline-style","border-inline-width","border-left","border-left-color","border-left-style","border-left-width","border-radius","border-right","border-right-color","border-right-style","border-right-width","border-spacing","border-style","border-top","border-top-color","border-top-left-radius","border-top-right-radius","border-top-style","border-top-width","border-width","bottom","box-decoration-break","box-shadow","box-sizing","break-after","break-before","break-inside","caption-side","caret-color","clear","clip","clip-path","clip-rule","color","column-count","column-fill","column-gap","column-rule","column-rule-color","column-rule-style","column-rule-width","column-span","column-width","columns","contain","content","content-visibility","counter-increment","counter-reset","cue","cue-after","cue-before","cursor","direction","display","empty-cells","filter","flex","flex-basis","flex-direction","flex-flow","flex-grow","flex-shrink","flex-wrap","float","flow","font","font-display","font-family","font-feature-settings","font-kerning","font-language-override","font-size","font-size-adjust","font-smoothing","font-stretch","font-style","font-synthesis","font-variant","font-variant-caps","font-variant-east-asian","font-variant-ligatures","font-variant-numeric","font-variant-position","font-variation-settings","font-weight","gap","glyph-orientation-vertical","grid","grid-area","grid-auto-columns","grid-auto-flow","grid-auto-rows","grid-column","grid-column-end","grid-column-start","grid-gap","grid-row","grid-row-end","grid-row-start","grid-template","grid-template-areas","grid-template-columns","grid-template-rows","hanging-punctuation","height","hyphens","icon","image-orientation","image-rendering","image-resolution","ime-mode","inline-size","isolation","justify-content","left","letter-spacing","line-break","line-height","list-style","list-style-image","list-style-position","list-style-type","margin","margin-block","margin-block-end","margin-block-start","margin-bottom","margin-inline","margin-inline-end","margin-inline-start","margin-left","margin-right","margin-top","marks","mask","mask-border","mask-border-mode","mask-border-outset","mask-border-repeat","mask-border-slice","mask-border-source","mask-border-width","mask-clip","mask-composite","mask-image","mask-mode","mask-origin","mask-position","mask-repeat","mask-size","mask-type","max-block-size","max-height","max-inline-size","max-width","min-block-size","min-height","min-inline-size","min-width","mix-blend-mode","nav-down","nav-index","nav-left","nav-right","nav-up","none","normal","object-fit","object-position","opacity","order","orphans","outline","outline-color","outline-offset","outline-style","outline-width","overflow","overflow-wrap","overflow-x","overflow-y","padding","padding-block","padding-block-end","padding-block-start","padding-bottom","padding-inline","padding-inline-end","padding-inline-start","padding-left","padding-right","padding-top","page-break-after","page-break-before","page-break-inside","pause","pause-after","pause-before","perspective","perspective-origin","pointer-events","position","quotes","resize","rest","rest-after","rest-before","right","row-gap","scroll-margin","scroll-margin-block","scroll-margin-block-end","scroll-margin-block-start","scroll-margin-bottom","scroll-margin-inline","scroll-margin-inline-end","scroll-margin-inline-start","scroll-margin-left","scroll-margin-right","scroll-margin-top","scroll-padding","scroll-padding-block","scroll-padding-block-end","scroll-padding-block-start","scroll-padding-bottom","scroll-padding-inline","scroll-padding-inline-end","scroll-padding-inline-start","scroll-padding-left","scroll-padding-right","scroll-padding-top","scroll-snap-align","scroll-snap-stop","scroll-snap-type","scrollbar-color","scrollbar-gutter","scrollbar-width","shape-image-threshold","shape-margin","shape-outside","speak","speak-as","src","tab-size","table-layout","text-align","text-align-all","text-align-last","text-combine-upright","text-decoration","text-decoration-color","text-decoration-line","text-decoration-style","text-emphasis","text-emphasis-color","text-emphasis-position","text-emphasis-style","text-indent","text-justify","text-orientation","text-overflow","text-rendering","text-shadow","text-transform","text-underline-position","top","transform","transform-box","transform-origin","transform-style","transition","transition-delay","transition-duration","transition-property","transition-timing-function","unicode-bidi","vertical-align","visibility","voice-balance","voice-duration","voice-family","voice-pitch","voice-range","voice-rate","voice-stress","voice-volume","white-space","widows","width","will-change","word-break","word-spacing","word-wrap","writing-mode","z-index"].reverse();function jo(r){const e=r.regex,t=Mo(r),n={begin:/-(webkit|moz|ms|o)-(?=[a-z])/},i="and or not only",o=/@-?\w[\w]*(-\w+)*/,s="[a-zA-Z-][a-zA-Z0-9_-]*",a=[r.APOS_STRING_MODE,r.QUOTE_STRING_MODE];return{name:"CSS",case_insensitive:!0,illegal:/[=|'\$]/,keywords:{keyframePosition:"from to"},classNameAliases:{keyframePosition:"selector-tag"},contains:[t.BLOCK_COMMENT,n,t.CSS_NUMBER_MODE,{className:"selector-id",begin:/#[A-Za-z0-9_-]+/,relevance:0},{className:"selector-class",begin:"\\."+s,relevance:0},t.ATTRIBUTE_SELECTOR_MODE,{className:"selector-pseudo",variants:[{begin:":("+To.join("|")+")"},{begin:":(:)?("+Lo.join("|")+")"}]},t.CSS_VARIABLE,{className:"attribute",begin:"\\b("+$o.join("|")+")\\b"},{begin:/:/,end:/[;}{]/,contains:[t.BLOCK_COMMENT,t.HEXCOLOR,t.IMPORTANT,t.CSS_NUMBER_MODE,...a,{begin:/(url|data-uri)\(/,end:/\)/,relevance:0,keywords:{built_in:"url data-uri"},contains:[...a,{className:"string",begin:/[^)]/,endsWithParent:!0,excludeEnd:!0}]},t.FUNCTION_DISPATCH]},{begin:e.lookahead(/@/),end:"[{;]",relevance:0,illegal:/:/,contains:[{className:"keyword",begin:o},{begin:/\s/,endsWithParent:!0,excludeEnd:!0,relevance:0,keywords:{$pattern:/[a-z-]+/,keyword:i,attribute:Po.join(" ")},contains:[{begin:/[a-z-]+(?=:)/,className:"attribute"},...a,t.CSS_NUMBER_MODE]}]},{className:"selector-tag",begin:"\\b("+Io.join("|")+")\\b"}]}}const xr=document.createElement("style");xr.innerText=[Ms,Is].join(`
|
|
108
|
-
`);document.head.appendChild(
|
|
109
|
-
`).trim();return
|
|
142
|
+
`)&&(r=`\r
|
|
143
|
+
`),this.css+=r+"/*# sourceMappingURL="+t+" */"}applyPrevMaps(){for(let t of this.previous()){let r=this.toUrl(this.path(t.file)),l=t.root||a(t.file),u;this.mapOpts.sourcesContent===!1?(u=new n(t.text),u.sourcesContent&&(u.sourcesContent=null)):u=t.consumer(),this.map.applySourceMap(u,r,this.toUrl(this.path(l)))}}clearAnnotation(){if(this.mapOpts.annotation!==!1)if(this.root){let t;for(let r=this.root.nodes.length-1;r>=0;r--)t=this.root.nodes[r],t.type==="comment"&&t.text.startsWith("# sourceMappingURL=")&&this.root.removeChild(r)}else this.css&&(this.css=this.css.replace(/\n*\/\*#[\S\s]*?\*\/$/gm,""))}generate(){if(this.clearAnnotation(),c&&x&&this.isMap())return this.generateMap();{let t="";return this.stringify(this.root,r=>{t+=r}),[t]}}generateMap(){if(this.root)this.generateString();else if(this.previous().length===1){let t=this.previous()[0].consumer();t.file=this.outputFile(),this.map=h.fromSourceMap(t,{ignoreInvalidMapping:!0})}else this.map=new h({file:this.outputFile(),ignoreInvalidMapping:!0}),this.map.addMapping({generated:{column:0,line:1},original:{column:0,line:1},source:this.opts.from?this.toUrl(this.path(this.opts.from)):"<no source>"});return this.isSourcesContent()&&this.setSourcesContent(),this.root&&this.previous().length>0&&this.applyPrevMaps(),this.isAnnotation()&&this.addAnnotation(),this.isInline()?[this.css]:[this.css,this.map]}generateString(){this.css="",this.map=new h({file:this.outputFile(),ignoreInvalidMapping:!0});let t=1,r=1,l="<no source>",u={generated:{column:0,line:0},original:{column:0,line:0},source:""},d,E;this.stringify(this.root,(S,w,y)=>{if(this.css+=S,w&&y!=="end"&&(u.generated.line=t,u.generated.column=r-1,w.source&&w.source.start?(u.source=this.sourcePath(w),u.original.line=w.source.start.line,u.original.column=w.source.start.column-1,this.map.addMapping(u)):(u.source=l,u.original.line=1,u.original.column=0,this.map.addMapping(u))),E=S.match(/\n/g),E?(t+=E.length,d=S.lastIndexOf(`
|
|
144
|
+
`),r=S.length-d):r+=S.length,w&&y!=="start"){let m=w.parent||{raws:{}};(!(w.type==="decl"||w.type==="atrule"&&!w.nodes)||w!==m.last||m.raws.semicolon)&&(w.source&&w.source.end?(u.source=this.sourcePath(w),u.original.line=w.source.end.line,u.original.column=w.source.end.column-1,u.generated.line=t,u.generated.column=r-2,this.map.addMapping(u)):(u.source=l,u.original.line=1,u.original.column=0,u.generated.line=t,u.generated.column=r-1,this.map.addMapping(u)))}})}isAnnotation(){return this.isInline()?!0:typeof this.mapOpts.annotation<"u"?this.mapOpts.annotation:this.previous().length?this.previous().some(t=>t.annotation):!0}isInline(){if(typeof this.mapOpts.inline<"u")return this.mapOpts.inline;let t=this.mapOpts.annotation;return typeof t<"u"&&t!==!0?!1:this.previous().length?this.previous().some(r=>r.inline):!0}isMap(){return typeof this.opts.map<"u"?!!this.opts.map:this.previous().length>0}isSourcesContent(){return typeof this.mapOpts.sourcesContent<"u"?this.mapOpts.sourcesContent:this.previous().length?this.previous().some(t=>t.withContent()):!0}outputFile(){return this.opts.to?this.path(this.opts.to):this.opts.from?this.path(this.opts.from):"to.css"}path(t){if(this.mapOpts.absolute||t.charCodeAt(0)===60||/^\w+:\/\//.test(t))return t;let r=this.memoizedPaths.get(t);if(r)return r;let l=this.opts.to?a(this.opts.to):".";typeof this.mapOpts.annotation=="string"&&(l=a(b(l,this.mapOpts.annotation)));let u=g(l,t);return this.memoizedPaths.set(t,u),u}previous(){if(!this.previousMaps)if(this.previousMaps=[],this.root)this.root.walk(t=>{if(t.source&&t.source.input.map){let r=t.source.input.map;this.previousMaps.includes(r)||this.previousMaps.push(r)}});else{let t=new p(this.originalCSS,this.opts);t.map&&this.previousMaps.push(t.map)}return this.previousMaps}setSourcesContent(){let t={};if(this.root)this.root.walk(r=>{if(r.source){let l=r.source.input.from;if(l&&!t[l]){t[l]=!0;let u=this.usesFileUrls?this.toFileUrl(l):this.toUrl(this.path(l));this.map.setSourceContent(u,r.source.input.css)}}});else if(this.css){let r=this.opts.from?this.toUrl(this.path(this.opts.from)):"<no source>";this.map.setSourceContent(r,this.css)}}sourcePath(t){return this.mapOpts.from?this.toUrl(this.mapOpts.from):this.usesFileUrls?this.toFileUrl(t.source.input.from):this.toUrl(this.path(t.source.input.from))}toBase64(t){return Buffer?Buffer.from(t).toString("base64"):window.btoa(unescape(encodeURIComponent(t)))}toFileUrl(t){let r=this.memoizedFileURLs.get(t);if(r)return r;if(s){let l=s(t).toString();return this.memoizedFileURLs.set(t,l),l}else throw new Error("`map.absolute` option is not available in this PostCSS build")}toUrl(t){let r=this.memoizedURLs.get(t);if(r)return r;f==="\\"&&(t=t.replace(/\\/g,"/"));let l=encodeURI(t).replace(/[#?]/g,encodeURIComponent);return this.memoizedURLs.set(t,l),l}}return St=e,St}var kt,Or;function ni(){if(Or)return kt;Or=1;const a=39,g=34,b=92,f=47,n=10,h=32,s=12,p=9,x=13,c=91,e=93,i=40,t=41,r=123,l=125,u=59,d=42,E=58,S=64,w=/[\t\n\f\r "#'()/;[\\\]{}]/g,y=/[\t\n\f\r !"#'():;@[\\\]{}]|\/(?=\*)/g,m=/.[\r\n"'(/\\]/,k=/[\da-f]/i;return kt=function(L,U={}){let P=L.css.valueOf(),K=U.ignoreErrors,F,be,ae,M,Ee,W,Q,ie,se,de,ye=P.length,B=0,Re=[],Se=[];function Xe(){return B}function Ce(pe){throw L.error("Unclosed "+pe,B)}function Qe(){return Se.length===0&&B>=ye}function ke(pe){if(Se.length)return Se.pop();if(B>=ye)return;let Ae=pe?pe.ignoreUnclosed:!1;switch(F=P.charCodeAt(B),F){case n:case h:case p:case x:case s:{M=B;do M+=1,F=P.charCodeAt(M);while(F===h||F===n||F===p||F===x||F===s);W=["space",P.slice(B,M)],B=M-1;break}case c:case e:case r:case l:case E:case u:case t:{let Te=String.fromCharCode(F);W=[Te,Te,B];break}case i:{if(de=Re.length?Re.pop()[1]:"",se=P.charCodeAt(B+1),de==="url"&&se!==a&&se!==g&&se!==h&&se!==n&&se!==p&&se!==s&&se!==x){M=B;do{if(Q=!1,M=P.indexOf(")",M+1),M===-1)if(K||Ae){M=B;break}else Ce("bracket");for(ie=M;P.charCodeAt(ie-1)===b;)ie-=1,Q=!Q}while(Q);W=["brackets",P.slice(B,M+1),B,M],B=M}else M=P.indexOf(")",B+1),be=P.slice(B,M+1),M===-1||m.test(be)?W=["(","(",B]:(W=["brackets",be,B,M],B=M);break}case a:case g:{Ee=F===a?"'":'"',M=B;do{if(Q=!1,M=P.indexOf(Ee,M+1),M===-1)if(K||Ae){M=B+1;break}else Ce("string");for(ie=M;P.charCodeAt(ie-1)===b;)ie-=1,Q=!Q}while(Q);W=["string",P.slice(B,M+1),B,M],B=M;break}case S:{w.lastIndex=B+1,w.test(P),w.lastIndex===0?M=P.length-1:M=w.lastIndex-2,W=["at-word",P.slice(B,M+1),B,M],B=M;break}case b:{for(M=B,ae=!0;P.charCodeAt(M+1)===b;)M+=1,ae=!ae;if(F=P.charCodeAt(M+1),ae&&F!==f&&F!==h&&F!==n&&F!==p&&F!==x&&F!==s&&(M+=1,k.test(P.charAt(M)))){for(;k.test(P.charAt(M+1));)M+=1;P.charCodeAt(M+1)===h&&(M+=1)}W=["word",P.slice(B,M+1),B,M],B=M;break}default:{F===f&&P.charCodeAt(B+1)===d?(M=P.indexOf("*/",B+2)+1,M===0&&(K||Ae?M=P.length:Ce("comment")),W=["comment",P.slice(B,M+1),B,M],B=M):(y.lastIndex=B+1,y.test(P),y.lastIndex===0?M=P.length-1:M=y.lastIndex-2,W=["word",P.slice(B,M+1),B,M],Re.push(W),B=M);break}}return B++,W}function Ye(pe){Se.push(pe)}return{back:Ye,endOfFile:Qe,nextToken:ke,position:Xe}},kt}var _t,Rr;function ii(){if(Rr)return _t;Rr=1;let a=Dt(),g=Ze(),b=Je(),f=Pe(),n=$t(),h=ni();const s={empty:!0,space:!0};function p(c){for(let e=c.length-1;e>=0;e--){let i=c[e],t=i[3]||i[2];if(t)return t}}class x{constructor(e){this.input=e,this.root=new f,this.current=this.root,this.spaces="",this.semicolon=!1,this.createTokenizer(),this.root.source={input:e,start:{column:1,line:1,offset:0}}}atrule(e){let i=new a;i.name=e[1].slice(1),i.name===""&&this.unnamedAtrule(i,e),this.init(i,e[2]);let t,r,l,u=!1,d=!1,E=[],S=[];for(;!this.tokenizer.endOfFile();){if(e=this.tokenizer.nextToken(),t=e[0],t==="("||t==="["?S.push(t==="("?")":"]"):t==="{"&&S.length>0?S.push("}"):t===S[S.length-1]&&S.pop(),S.length===0)if(t===";"){i.source.end=this.getPosition(e[2]),i.source.end.offset++,this.semicolon=!0;break}else if(t==="{"){d=!0;break}else if(t==="}"){if(E.length>0){for(l=E.length-1,r=E[l];r&&r[0]==="space";)r=E[--l];r&&(i.source.end=this.getPosition(r[3]||r[2]),i.source.end.offset++)}this.end(e);break}else E.push(e);else E.push(e);if(this.tokenizer.endOfFile()){u=!0;break}}i.raws.between=this.spacesAndCommentsFromEnd(E),E.length?(i.raws.afterName=this.spacesAndCommentsFromStart(E),this.raw(i,"params",E),u&&(e=E[E.length-1],i.source.end=this.getPosition(e[3]||e[2]),i.source.end.offset++,this.spaces=i.raws.between,i.raws.between="")):(i.raws.afterName="",i.params=""),d&&(i.nodes=[],this.current=i)}checkMissedSemicolon(e){let i=this.colon(e);if(i===!1)return;let t=0,r;for(let l=i-1;l>=0&&(r=e[l],!(r[0]!=="space"&&(t+=1,t===2)));l--);throw this.input.error("Missed semicolon",r[0]==="word"?r[3]+1:r[2])}colon(e){let i=0,t,r,l;for(let[u,d]of e.entries()){if(r=d,l=r[0],l==="("&&(i+=1),l===")"&&(i-=1),i===0&&l===":")if(!t)this.doubleColon(r);else{if(t[0]==="word"&&t[1]==="progid")continue;return u}t=r}return!1}comment(e){let i=new g;this.init(i,e[2]),i.source.end=this.getPosition(e[3]||e[2]),i.source.end.offset++;let t=e[1].slice(2,-2);if(/^\s*$/.test(t))i.text="",i.raws.left=t,i.raws.right="";else{let r=t.match(/^(\s*)([^]*\S)(\s*)$/);i.text=r[2],i.raws.left=r[1],i.raws.right=r[3]}}createTokenizer(){this.tokenizer=h(this.input)}decl(e,i){let t=new b;this.init(t,e[0][2]);let r=e[e.length-1];for(r[0]===";"&&(this.semicolon=!0,e.pop()),t.source.end=this.getPosition(r[3]||r[2]||p(e)),t.source.end.offset++;e[0][0]!=="word";)e.length===1&&this.unknownWord(e),t.raws.before+=e.shift()[1];for(t.source.start=this.getPosition(e[0][2]),t.prop="";e.length;){let S=e[0][0];if(S===":"||S==="space"||S==="comment")break;t.prop+=e.shift()[1]}t.raws.between="";let l;for(;e.length;)if(l=e.shift(),l[0]===":"){t.raws.between+=l[1];break}else l[0]==="word"&&/\w/.test(l[1])&&this.unknownWord([l]),t.raws.between+=l[1];(t.prop[0]==="_"||t.prop[0]==="*")&&(t.raws.before+=t.prop[0],t.prop=t.prop.slice(1));let u=[],d;for(;e.length&&(d=e[0][0],!(d!=="space"&&d!=="comment"));)u.push(e.shift());this.precheckMissedSemicolon(e);for(let S=e.length-1;S>=0;S--){if(l=e[S],l[1].toLowerCase()==="!important"){t.important=!0;let w=this.stringFrom(e,S);w=this.spacesFromEnd(e)+w,w!==" !important"&&(t.raws.important=w);break}else if(l[1].toLowerCase()==="important"){let w=e.slice(0),y="";for(let m=S;m>0;m--){let k=w[m][0];if(y.trim().startsWith("!")&&k!=="space")break;y=w.pop()[1]+y}y.trim().startsWith("!")&&(t.important=!0,t.raws.important=y,e=w)}if(l[0]!=="space"&&l[0]!=="comment")break}e.some(S=>S[0]!=="space"&&S[0]!=="comment")&&(t.raws.between+=u.map(S=>S[1]).join(""),u=[]),this.raw(t,"value",u.concat(e),i),t.value.includes(":")&&!i&&this.checkMissedSemicolon(e)}doubleColon(e){throw this.input.error("Double colon",{offset:e[2]},{offset:e[2]+e[1].length})}emptyRule(e){let i=new n;this.init(i,e[2]),i.selector="",i.raws.between="",this.current=i}end(e){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(e[2]),this.current.source.end.offset++,this.current=this.current.parent):this.unexpectedClose(e)}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(e){if(this.spaces+=e[1],this.current.nodes){let i=this.current.nodes[this.current.nodes.length-1];i&&i.type==="rule"&&!i.raws.ownSemicolon&&(i.raws.ownSemicolon=this.spaces,this.spaces="",i.source.end=this.getPosition(e[2]),i.source.end.offset+=i.raws.ownSemicolon.length)}}getPosition(e){let i=this.input.fromOffset(e);return{column:i.col,line:i.line,offset:e}}init(e,i){this.current.push(e),e.source={input:this.input,start:this.getPosition(i)},e.raws.before=this.spaces,this.spaces="",e.type!=="comment"&&(this.semicolon=!1)}other(e){let i=!1,t=null,r=!1,l=null,u=[],d=e[1].startsWith("--"),E=[],S=e;for(;S;){if(t=S[0],E.push(S),t==="("||t==="[")l||(l=S),u.push(t==="("?")":"]");else if(d&&r&&t==="{")l||(l=S),u.push("}");else if(u.length===0)if(t===";")if(r){this.decl(E,d);return}else break;else if(t==="{"){this.rule(E);return}else if(t==="}"){this.tokenizer.back(E.pop()),i=!0;break}else t===":"&&(r=!0);else t===u[u.length-1]&&(u.pop(),u.length===0&&(l=null));S=this.tokenizer.nextToken()}if(this.tokenizer.endOfFile()&&(i=!0),u.length>0&&this.unclosedBracket(l),i&&r){if(!d)for(;E.length&&(S=E[E.length-1][0],!(S!=="space"&&S!=="comment"));)this.tokenizer.back(E.pop());this.decl(E,d)}else this.unknownWord(E)}parse(){let e;for(;!this.tokenizer.endOfFile();)switch(e=this.tokenizer.nextToken(),e[0]){case"space":this.spaces+=e[1];break;case";":this.freeSemicolon(e);break;case"}":this.end(e);break;case"comment":this.comment(e);break;case"at-word":this.atrule(e);break;case"{":this.emptyRule(e);break;default:this.other(e);break}this.endFile()}precheckMissedSemicolon(){}raw(e,i,t,r){let l,u,d=t.length,E="",S=!0,w,y;for(let m=0;m<d;m+=1)l=t[m],u=l[0],u==="space"&&m===d-1&&!r?S=!1:u==="comment"?(y=t[m-1]?t[m-1][0]:"empty",w=t[m+1]?t[m+1][0]:"empty",!s[y]&&!s[w]?E.slice(-1)===","?S=!1:E+=l[1]:S=!1):E+=l[1];if(!S){let m=t.reduce((k,C)=>k+C[1],"");e.raws[i]={raw:m,value:E}}e[i]=E}rule(e){e.pop();let i=new n;this.init(i,e[0][2]),i.raws.between=this.spacesAndCommentsFromEnd(e),this.raw(i,"selector",e),this.current=i}spacesAndCommentsFromEnd(e){let i,t="";for(;e.length&&(i=e[e.length-1][0],!(i!=="space"&&i!=="comment"));)t=e.pop()[1]+t;return t}spacesAndCommentsFromStart(e){let i,t="";for(;e.length&&(i=e[0][0],!(i!=="space"&&i!=="comment"));)t+=e.shift()[1];return t}spacesFromEnd(e){let i,t="";for(;e.length&&(i=e[e.length-1][0],i==="space");)t=e.pop()[1]+t;return t}stringFrom(e,i){let t="";for(let r=i;r<e.length;r++)t+=e[r][1];return e.splice(i,e.length-i),t}unclosedBlock(){let e=this.current.source.start;throw this.input.error("Unclosed block",e.line,e.column)}unclosedBracket(e){throw this.input.error("Unclosed bracket",{offset:e[2]},{offset:e[2]+1})}unexpectedClose(e){throw this.input.error("Unexpected }",{offset:e[2]},{offset:e[2]+1})}unknownWord(e){throw this.input.error("Unknown word "+e[0][1],{offset:e[0][2]},{offset:e[0][2]+e[0][1].length})}unnamedAtrule(e,i){throw this.input.error("At-rule without name",{offset:i[2]},{offset:i[2]+i[1].length})}}return _t=x,_t}var Ot,Cr;function qt(){if(Cr)return Ot;Cr=1;let a=ve(),g=Ke(),b=ii();function f(n,h){let s=new g(n,h),p=new b(s);try{p.parse()}catch(x){throw x}return p.root}return Ot=f,f.default=f,a.registerParse(f),Ot}var Rt,Ar;function qr(){if(Ar)return Rt;Ar=1;class a{constructor(b,f={}){if(this.type="warning",this.text=b,f.node&&f.node.source){let n=f.node.rangeBy(f);this.line=n.start.line,this.column=n.start.column,this.endLine=n.end.line,this.endColumn=n.end.column}for(let n in f)this[n]=f[n]}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}}return Rt=a,a.default=a,Rt}var Ct,Mr;function Ft(){if(Mr)return Ct;Mr=1;let a=qr();class g{get content(){return this.css}constructor(f,n,h){this.processor=f,this.messages=[],this.root=n,this.opts=h,this.css="",this.map=void 0}toString(){return this.css}warn(f,n={}){n.plugin||this.lastPlugin&&this.lastPlugin.postcssPlugin&&(n.plugin=this.lastPlugin.postcssPlugin);let h=new a(f,n);return this.messages.push(h),h}warnings(){return this.messages.filter(f=>f.type==="warning")}}return Ct=g,g.default=g,Ct}var At,Nr;function Fr(){if(Nr)return At;Nr=1;let a=ve(),g=Ut(),b=$r(),f=qt(),n=Ft(),h=Pe(),s=We(),{isClean:p,my:x}=zt();const c={atrule:"AtRule",comment:"Comment",decl:"Declaration",document:"Document",root:"Root",rule:"Rule"},e={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},i={Once:!0,postcssPlugin:!0,prepare:!0},t=0;function r(w){return typeof w=="object"&&typeof w.then=="function"}function l(w){let y=!1,m=c[w.type];return w.type==="decl"?y=w.prop.toLowerCase():w.type==="atrule"&&(y=w.name.toLowerCase()),y&&w.append?[m,m+"-"+y,t,m+"Exit",m+"Exit-"+y]:y?[m,m+"-"+y,m+"Exit",m+"Exit-"+y]:w.append?[m,t,m+"Exit"]:[m,m+"Exit"]}function u(w){let y;return w.type==="document"?y=["Document",t,"DocumentExit"]:w.type==="root"?y=["Root",t,"RootExit"]:y=l(w),{eventIndex:0,events:y,iterator:0,node:w,visitorIndex:0,visitors:[]}}function d(w){return w[p]=!1,w.nodes&&w.nodes.forEach(y=>d(y)),w}let E={};class S{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(y,m,k){this.stringified=!1,this.processed=!1;let C;if(typeof m=="object"&&m!==null&&(m.type==="root"||m.type==="document"))C=d(m);else if(m instanceof S||m instanceof n)C=d(m.root),m.map&&(typeof k.map>"u"&&(k.map={}),k.map.inline||(k.map.inline=!1),k.map.prev=m.map);else{let L=f;k.syntax&&(L=k.syntax.parse),k.parser&&(L=k.parser),L.parse&&(L=L.parse);try{C=L(m,k)}catch(U){this.processed=!0,this.error=U}C&&!C[x]&&a.rebuild(C)}this.result=new n(y,C,k),this.helpers={...E,postcss:E,result:this.result},this.plugins=this.processor.plugins.map(L=>typeof L=="object"&&L.prepare?{...L,...L.prepare(this.result)}:L)}async(){return this.error?Promise.reject(this.error):this.processed?Promise.resolve(this.result):(this.processing||(this.processing=this.runAsync()),this.processing)}catch(y){return this.async().catch(y)}finally(y){return this.async().then(y,y)}getAsyncError(){throw new Error("Use process(css).then(cb) to work with async plugins")}handleError(y,m){let k=this.result.lastPlugin;try{m&&m.addToError(y),this.error=y,y.name==="CssSyntaxError"&&!y.plugin?(y.plugin=k.postcssPlugin,y.setMessage()):k.postcssVersion}catch(C){console&&console.error&&console.error(C)}return y}prepareVisitors(){this.listeners={};let y=(m,k,C)=>{this.listeners[k]||(this.listeners[k]=[]),this.listeners[k].push([m,C])};for(let m of this.plugins)if(typeof m=="object")for(let k in m){if(!e[k]&&/^[A-Z]/.test(k))throw new Error(`Unknown event ${k} in ${m.postcssPlugin}. Try to update PostCSS (${this.processor.version} now).`);if(!i[k])if(typeof m[k]=="object")for(let C in m[k])C==="*"?y(m,k,m[k][C]):y(m,k+"-"+C.toLowerCase(),m[k][C]);else typeof m[k]=="function"&&y(m,k,m[k])}this.hasListener=Object.keys(this.listeners).length>0}async runAsync(){this.plugin=0;for(let y=0;y<this.plugins.length;y++){let m=this.plugins[y],k=this.runOnRoot(m);if(r(k))try{await k}catch(C){throw this.handleError(C)}}if(this.prepareVisitors(),this.hasListener){let y=this.result.root;for(;!y[p];){y[p]=!0;let m=[u(y)];for(;m.length>0;){let k=this.visitTick(m);if(r(k))try{await k}catch(C){let L=m[m.length-1].node;throw this.handleError(C,L)}}}if(this.listeners.OnceExit)for(let[m,k]of this.listeners.OnceExit){this.result.lastPlugin=m;try{if(y.type==="document"){let C=y.nodes.map(L=>k(L,this.helpers));await Promise.all(C)}else await k(y,this.helpers)}catch(C){throw this.handleError(C)}}}return this.processed=!0,this.stringify()}runOnRoot(y){this.result.lastPlugin=y;try{if(typeof y=="object"&&y.Once){if(this.result.root.type==="document"){let m=this.result.root.nodes.map(k=>y.Once(k,this.helpers));return r(m[0])?Promise.all(m):m}return y.Once(this.result.root,this.helpers)}else if(typeof y=="function")return y(this.result.root,this.result)}catch(m){throw this.handleError(m)}}stringify(){if(this.error)throw this.error;if(this.stringified)return this.result;this.stringified=!0,this.sync();let y=this.result.opts,m=s;y.syntax&&(m=y.syntax.stringify),y.stringifier&&(m=y.stringifier),m.stringify&&(m=m.stringify);let C=new b(m,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 y of this.plugins){let m=this.runOnRoot(y);if(r(m))throw this.getAsyncError()}if(this.prepareVisitors(),this.hasListener){let y=this.result.root;for(;!y[p];)y[p]=!0,this.walkSync(y);if(this.listeners.OnceExit)if(y.type==="document")for(let m of y.nodes)this.visitSync(this.listeners.OnceExit,m);else this.visitSync(this.listeners.OnceExit,y)}return this.result}then(y,m){return this.async().then(y,m)}toString(){return this.css}visitSync(y,m){for(let[k,C]of y){this.result.lastPlugin=k;let L;try{L=C(m,this.helpers)}catch(U){throw this.handleError(U,m.proxyOf)}if(m.type!=="root"&&m.type!=="document"&&!m.parent)return!0;if(r(L))throw this.getAsyncError()}}visitTick(y){let m=y[y.length-1],{node:k,visitors:C}=m;if(k.type!=="root"&&k.type!=="document"&&!k.parent){y.pop();return}if(C.length>0&&m.visitorIndex<C.length){let[U,P]=C[m.visitorIndex];m.visitorIndex+=1,m.visitorIndex===C.length&&(m.visitors=[],m.visitorIndex=0),this.result.lastPlugin=U;try{return P(k.toProxy(),this.helpers)}catch(K){throw this.handleError(K,k)}}if(m.iterator!==0){let U=m.iterator,P;for(;P=k.nodes[k.indexes[U]];)if(k.indexes[U]+=1,!P[p]){P[p]=!0,y.push(u(P));return}m.iterator=0,delete k.indexes[U]}let L=m.events;for(;m.eventIndex<L.length;){let U=L[m.eventIndex];if(m.eventIndex+=1,U===t){k.nodes&&k.nodes.length&&(k[p]=!0,m.iterator=k.getIterator());return}else if(this.listeners[U]){m.visitors=this.listeners[U];return}}y.pop()}walkSync(y){y[p]=!0;let m=l(y);for(let k of m)if(k===t)y.nodes&&y.each(C=>{C[p]||this.walkSync(C)});else{let C=this.listeners[k];if(C&&this.visitSync(C,y.toProxy()))return}}warnings(){return this.sync().warnings()}}return S.registerPostcss=w=>{E=w},At=S,S.default=S,h.registerLazyResult(S),g.registerLazyResult(S),At}var Mt,Ir;function si(){if(Ir)return Mt;Ir=1;let a=$r(),g=qt();const b=Ft();let f=We();class n{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 s,p=g;try{s=p(this._css,this._opts)}catch(x){this.error=x}if(this.error)throw this.error;return this._root=s,s}get[Symbol.toStringTag](){return"NoWorkResult"}constructor(s,p,x){p=p.toString(),this.stringified=!1,this._processor=s,this._css=p,this._opts=x,this._map=void 0;let c,e=f;this.result=new b(this._processor,c,this._opts),this.result.css=p;let i=this;Object.defineProperty(this.result,"root",{get(){return i.root}});let t=new a(e,c,this._opts,p);if(t.isMap()){let[r,l]=t.generate();r&&(this.result.css=r),l&&(this.result.map=l)}else t.clearAnnotation(),this.result.css=t.css}async(){return this.error?Promise.reject(this.error):Promise.resolve(this.result)}catch(s){return this.async().catch(s)}finally(s){return this.async().then(s,s)}sync(){if(this.error)throw this.error;return this.result}then(s,p){return this.async().then(s,p)}toString(){return this._css}warnings(){return[]}}return Mt=n,n.default=n,Mt}var Nt,Pr;function oi(){if(Pr)return Nt;Pr=1;let a=Ut(),g=Fr(),b=si(),f=Pe();class n{constructor(s=[]){this.version="8.5.6",this.plugins=this.normalize(s)}normalize(s){let p=[];for(let x of s)if(x.postcss===!0?x=x():x.postcss&&(x=x.postcss),typeof x=="object"&&Array.isArray(x.plugins))p=p.concat(x.plugins);else if(typeof x=="object"&&x.postcssPlugin)p.push(x);else if(typeof x=="function")p.push(x);else if(!(typeof x=="object"&&(x.parse||x.stringify)))throw new Error(x+" is not a PostCSS plugin");return p}process(s,p={}){return!this.plugins.length&&!p.parser&&!p.stringifier&&!p.syntax?new b(this,s,p):new g(this,s,p)}use(s){return this.plugins=this.plugins.concat(this.normalize([s])),this}}return Nt=n,n.default=n,f.registerProcessor(n),a.registerProcessor(n),Nt}var It,Tr;function ai(){if(Tr)return It;Tr=1;var a={};let g=Dt(),b=Ze(),f=ve(),n=Bt(),h=Je(),s=Ut(),p=ri(),x=Ke(),c=Fr(),e=Ur(),i=Ge(),t=qt(),r=oi(),l=Ft(),u=Pe(),d=$t(),E=We(),S=qr();function w(...y){return y.length===1&&Array.isArray(y[0])&&(y=y[0]),new r(y)}return w.plugin=function(m,k){let C=!1;function L(...P){console&&console.warn&&!C&&(C=!0,console.warn(m+`: postcss.plugin was deprecated. Migration guide:
|
|
145
|
+
https://evilmartians.com/chronicles/postcss-8-plugin-migration`),a.LANG&&a.LANG.startsWith("cn")&&console.warn(m+`: 里面 postcss.plugin 被弃用. 迁移指南:
|
|
146
|
+
https://www.w3ctech.com/topic/2226`));let K=k(...P);return K.postcssPlugin=m,K.postcssVersion=new r().version,K}let U;return Object.defineProperty(L,"postcss",{get(){return U||(U=L()),U}}),L.process=function(P,K,F){return w([L(F)]).process(P,K)},L},w.stringify=E,w.parse=t,w.fromJSON=p,w.list=e,w.comment=y=>new b(y),w.atRule=y=>new g(y),w.decl=y=>new h(y),w.rule=y=>new d(y),w.root=y=>new u(y),w.document=y=>new s(y),w.CssSyntaxError=n,w.Declaration=h,w.Container=f,w.Processor=r,w.Document=s,w.Comment=b,w.Warning=S,w.AtRule=g,w.Result=l,w.Input=x,w.Rule=d,w.Root=u,w.Node=i,c.registerPostcss(w),It=w,w.default=w,It}var li=ai();const J=Br(li);J.stringify;J.fromJSON;J.plugin;J.parse;J.list;J.document;J.comment;J.atRule;J.rule;J.decl;J.root;J.CssSyntaxError;J.Declaration;J.Container;J.Processor;J.Document;J.Comment;J.Warning;J.AtRule;J.Result;J.Input;J.Rule;J.Root;J.Node;var Pt,Lr;function ci(){if(Lr)return Pt;Lr=1;const a=(f={})=>{const n=f.prefix,h=/\s+$/.test(n)?n:`${n} `,s=f.ignoreFiles?[].concat(f.ignoreFiles):[],p=f.includeFiles?[].concat(f.includeFiles):[];return{postcssPlugin:"postcss-prefix-selector",prepare(x){const c=x.root,e=c.source.input.file;if(!(s.length&&e&&g(e,s))&&!(p.length&&e&&!g(e,p)))return{Rule(i,{result:t}){const r=["keyframes","-webkit-keyframes","-moz-keyframes","-o-keyframes","-ms-keyframes"];i.parent&&r.includes(i.parent.name)||(i.selectors=i.selectors.map(l=>f.exclude&&b(l,f.exclude)?l:f.transform?f.transform(n,l,h+l,c.source.input.file,i):[":root","body","html"].some(u=>l.startsWith(u))?f.skipGlobalSelectors?l:l.replace(/(html\s+body|:root\s+body|html|:root|body)/gm,n):h+l))}}}}};function g(f,n){return n.some(h=>h instanceof RegExp?h.test(f):f.includes(h))}function b(f,n){return n.some(h=>h instanceof RegExp?h.test(f):f===h)}return a.postcss=!0,Pt=a,Pt}var ui=ci();const hi=Br(ui),fi="code{white-space:pre}.example{display:flex;flex-wrap:wrap;flex-direction:row;align-items:center;gap:16px}.example>*{flex:1 1 500px}.example .tab-control{overflow:hidden}.example div[role=tab]{cursor:pointer;padding:8px 16px;display:inline-block;font-size:16px;border-bottom:2px solid transparent;background-clip:padding-box;-webkit-user-select:none;user-select:none}.example div[role=tab]:hover{background-color:#1467ba14}.example div[role=tab][selected]{background-color:#1467ba21;border-bottom:2px solid #1467ba}.tab-content{margin:16px 0}.tab-content>pre{padding-top:0}.tab-content.code{max-height:500px;overflow:auto}.tab-content.code pre{margin:0}",di="pre code.hljs{display:block;overflow-x:auto;padding:1em}code.hljs{padding:3px 5px}.hljs{color:#24292e;background:#fff}.hljs-doctag,.hljs-keyword,.hljs-meta .hljs-keyword,.hljs-template-tag,.hljs-template-variable,.hljs-type,.hljs-variable.language_{color:#d73a49}.hljs-title,.hljs-title.class_,.hljs-title.class_.inherited__,.hljs-title.function_{color:#6f42c1}.hljs-attr,.hljs-attribute,.hljs-literal,.hljs-meta,.hljs-number,.hljs-operator,.hljs-variable,.hljs-selector-attr,.hljs-selector-class,.hljs-selector-id{color:#005cc5}.hljs-regexp,.hljs-string,.hljs-meta .hljs-string{color:#032f62}.hljs-built_in,.hljs-symbol{color:#e36209}.hljs-comment,.hljs-code,.hljs-formula{color:#6a737d}.hljs-name,.hljs-quote,.hljs-selector-tag,.hljs-selector-pseudo{color:#22863a}.hljs-subst{color:#24292e}.hljs-section{color:#005cc5;font-weight:700}.hljs-bullet{color:#735c0f}.hljs-emphasis{color:#24292e;font-style:italic}.hljs-strong{color:#24292e;font-weight:700}.hljs-addition{color:#22863a;background-color:#f0fff4}.hljs-deletion{color:#b31d28;background-color:#ffeef0}";function pi(a){return a&&a.__esModule&&Object.prototype.hasOwnProperty.call(a,"default")?a.default:a}var Tt,jr;function gi(){if(jr)return Tt;jr=1;function a(o){return o instanceof Map?o.clear=o.delete=o.set=function(){throw new Error("map is read-only")}:o instanceof Set&&(o.add=o.clear=o.delete=function(){throw new Error("set is read-only")}),Object.freeze(o),Object.getOwnPropertyNames(o).forEach(v=>{const R=o[v],D=typeof R;(D==="object"||D==="function")&&!Object.isFrozen(R)&&a(R)}),o}class g{constructor(v){v.data===void 0&&(v.data={}),this.data=v.data,this.isMatchIgnored=!1}ignoreMatch(){this.isMatchIgnored=!0}}function b(o){return o.replace(/&/g,"&").replace(/</g,"<").replace(/>/g,">").replace(/"/g,""").replace(/'/g,"'")}function f(o,...v){const R=Object.create(null);for(const D in o)R[D]=o[D];return v.forEach(function(D){for(const V in D)R[V]=D[V]}),R}const n="</span>",h=o=>!!o.scope,s=(o,{prefix:v})=>{if(o.startsWith("language:"))return o.replace("language:","language-");if(o.includes(".")){const R=o.split(".");return[`${v}${R.shift()}`,...R.map((D,V)=>`${D}${"_".repeat(V+1)}`)].join(" ")}return`${v}${o}`};class p{constructor(v,R){this.buffer="",this.classPrefix=R.classPrefix,v.walk(this)}addText(v){this.buffer+=b(v)}openNode(v){if(!h(v))return;const R=s(v.scope,{prefix:this.classPrefix});this.span(R)}closeNode(v){h(v)&&(this.buffer+=n)}value(){return this.buffer}span(v){this.buffer+=`<span class="${v}">`}}const x=(o={})=>{const v={children:[]};return Object.assign(v,o),v};class c{constructor(){this.rootNode=x(),this.stack=[this.rootNode]}get top(){return this.stack[this.stack.length-1]}get root(){return this.rootNode}add(v){this.top.children.push(v)}openNode(v){const R=x({scope:v});this.add(R),this.stack.push(R)}closeNode(){if(this.stack.length>1)return this.stack.pop()}closeAllNodes(){for(;this.closeNode(););}toJSON(){return JSON.stringify(this.rootNode,null,4)}walk(v){return this.constructor._walk(v,this.rootNode)}static _walk(v,R){return typeof R=="string"?v.addText(R):R.children&&(v.openNode(R),R.children.forEach(D=>this._walk(v,D)),v.closeNode(R)),v}static _collapse(v){typeof v!="string"&&v.children&&(v.children.every(R=>typeof R=="string")?v.children=[v.children.join("")]:v.children.forEach(R=>{c._collapse(R)}))}}class e extends c{constructor(v){super(),this.options=v}addText(v){v!==""&&this.add(v)}startScope(v){this.openNode(v)}endScope(){this.closeNode()}__addSublanguage(v,R){const D=v.root;R&&(D.scope=`language:${R}`),this.add(D)}toHTML(){return new p(this,this.options).value()}finalize(){return this.closeAllNodes(),!0}}function i(o){return o?typeof o=="string"?o:o.source:null}function t(o){return u("(?=",o,")")}function r(o){return u("(?:",o,")*")}function l(o){return u("(?:",o,")?")}function u(...o){return o.map(v=>i(v)).join("")}function d(o){const v=o[o.length-1];return typeof v=="object"&&v.constructor===Object?(o.splice(o.length-1,1),v):{}}function E(...o){return"("+(d(o).capture?"":"?:")+o.map(v=>i(v)).join("|")+")"}function S(o){return new RegExp(o.toString()+"|").exec("").length-1}function w(o,v){const R=o&&o.exec(v);return R&&R.index===0}const y=/\[(?:[^\\\]]|\\.)*\]|\(\??|\\([1-9][0-9]*)|\\./;function m(o,{joinWith:v}){let R=0;return o.map(D=>{R+=1;const V=R;let X=i(D),N="";for(;X.length>0;){const A=y.exec(X);if(!A){N+=X;break}N+=X.substring(0,A.index),X=X.substring(A.index+A[0].length),A[0][0]==="\\"&&A[1]?N+="\\"+String(Number(A[1])+V):(N+=A[0],A[0]==="("&&R++)}return N}).map(D=>`(${D})`).join(v)}const k=/\b\B/,C="[a-zA-Z]\\w*",L="[a-zA-Z_]\\w*",U="\\b\\d+(\\.\\d+)?",P="(-?)(\\b0[xX][a-fA-F0-9]+|(\\b\\d+(\\.\\d*)?|\\.\\d+)([eE][-+]?\\d+)?)",K="\\b(0b[01]+)",F="!|!=|!==|%|%=|&|&&|&=|\\*|\\*=|\\+|\\+=|,|-|-=|/=|/|:|;|<<|<<=|<=|<|===|==|=|>>>=|>>=|>=|>>>|>>|>|\\?|\\[|\\{|\\(|\\^|\\^=|\\||\\|=|\\|\\||~",be=(o={})=>{const v=/^#![ ]*\//;return o.binary&&(o.begin=u(v,/.*\b/,o.binary,/\b.*/)),f({scope:"meta",begin:v,end:/$/,relevance:0,"on:begin":(R,D)=>{R.index!==0&&D.ignoreMatch()}},o)},ae={begin:"\\\\[\\s\\S]",relevance:0},M={scope:"string",begin:"'",end:"'",illegal:"\\n",contains:[ae]},Ee={scope:"string",begin:'"',end:'"',illegal:"\\n",contains:[ae]},W={begin:/\b(a|an|the|are|I'm|isn't|don't|doesn't|won't|but|just|should|pretty|simply|enough|gonna|going|wtf|so|such|will|you|your|they|like|more)\b/},Q=function(o,v,R={}){const D=f({scope:"comment",begin:o,end:v,contains:[]},R);D.contains.push({scope:"doctag",begin:"[ ]*(?=(TODO|FIXME|NOTE|BUG|OPTIMIZE|HACK|XXX):)",end:/(TODO|FIXME|NOTE|BUG|OPTIMIZE|HACK|XXX):/,excludeBegin:!0,relevance:0});const V=E("I","a","is","so","us","to","at","if","in","it","on",/[A-Za-z]+['](d|ve|re|ll|t|s|n)/,/[A-Za-z]+[-][a-z]+/,/[A-Za-z][a-z]{2,}/);return D.contains.push({begin:u(/[ ]+/,"(",V,/[.]?[:]?([.][ ]|[ ])/,"){3}")}),D},ie=Q("//","$"),se=Q("/\\*","\\*/"),de=Q("#","$"),ye={scope:"number",begin:U,relevance:0},B={scope:"number",begin:P,relevance:0},Re={scope:"number",begin:K,relevance:0},Se={scope:"regexp",begin:/\/(?=[^/\n]*\/)/,end:/\/[gimuy]*/,contains:[ae,{begin:/\[/,end:/\]/,relevance:0,contains:[ae]}]},Xe={scope:"title",begin:C,relevance:0},Ce={scope:"title",begin:L,relevance:0},Qe={begin:"\\.\\s*"+L,relevance:0};var ke=Object.freeze({__proto__:null,APOS_STRING_MODE:M,BACKSLASH_ESCAPE:ae,BINARY_NUMBER_MODE:Re,BINARY_NUMBER_RE:K,COMMENT:Q,C_BLOCK_COMMENT_MODE:se,C_LINE_COMMENT_MODE:ie,C_NUMBER_MODE:B,C_NUMBER_RE:P,END_SAME_AS_BEGIN:function(o){return Object.assign(o,{"on:begin":(v,R)=>{R.data._beginMatch=v[1]},"on:end":(v,R)=>{R.data._beginMatch!==v[1]&&R.ignoreMatch()}})},HASH_COMMENT_MODE:de,IDENT_RE:C,MATCH_NOTHING_RE:k,METHOD_GUARD:Qe,NUMBER_MODE:ye,NUMBER_RE:U,PHRASAL_WORDS_MODE:W,QUOTE_STRING_MODE:Ee,REGEXP_MODE:Se,RE_STARTERS_RE:F,SHEBANG:be,TITLE_MODE:Xe,UNDERSCORE_IDENT_RE:L,UNDERSCORE_TITLE_MODE:Ce});function Ye(o,v){o.input[o.index-1]==="."&&v.ignoreMatch()}function pe(o,v){o.className!==void 0&&(o.scope=o.className,delete o.className)}function Ae(o,v){v&&o.beginKeywords&&(o.begin="\\b("+o.beginKeywords.split(" ").join("|")+")(?!\\.)(?=\\b|\\s)",o.__beforeBegin=Ye,o.keywords=o.keywords||o.beginKeywords,delete o.beginKeywords,o.relevance===void 0&&(o.relevance=0))}function Te(o,v){Array.isArray(o.illegal)&&(o.illegal=E(...o.illegal))}function Yr(o,v){if(o.match){if(o.begin||o.end)throw new Error("begin & end are not supported with match");o.begin=o.match,delete o.match}}function en(o,v){o.relevance===void 0&&(o.relevance=1)}const tn=(o,v)=>{if(!o.beforeMatch)return;if(o.starts)throw new Error("beforeMatch cannot be used with starts");const R=Object.assign({},o);Object.keys(o).forEach(D=>{delete o[D]}),o.keywords=R.keywords,o.begin=u(R.beforeMatch,t(R.begin)),o.starts={relevance:0,contains:[Object.assign(R,{endsParent:!0})]},o.relevance=0,delete R.beforeMatch},rn=["of","and","for","in","not","or","if","then","parent","list","value"],nn="keyword";function Ht(o,v,R=nn){const D=Object.create(null);return typeof o=="string"?V(R,o.split(" ")):Array.isArray(o)?V(R,o):Object.keys(o).forEach(function(X){Object.assign(D,Ht(o[X],v,X))}),D;function V(X,N){v&&(N=N.map(A=>A.toLowerCase())),N.forEach(function(A){const j=A.split("|");D[j[0]]=[X,sn(j[0],j[1])]})}}function sn(o,v){return v?Number(v):on(o)?0:1}function on(o){return rn.includes(o.toLowerCase())}const Wt={},we=o=>{console.error(o)},Gt=(o,...v)=>{console.log(`WARN: ${o}`,...v)},_e=(o,v)=>{Wt[`${o}/${v}`]||(console.log(`Deprecated as of ${o}. ${v}`),Wt[`${o}/${v}`]=!0)},Le=new Error;function Zt(o,v,{key:R}){let D=0;const V=o[R],X={},N={};for(let A=1;A<=v.length;A++)N[A+D]=V[A],X[A+D]=!0,D+=S(v[A-1]);o[R]=N,o[R]._emit=X,o[R]._multi=!0}function an(o){if(Array.isArray(o.begin)){if(o.skip||o.excludeBegin||o.returnBegin)throw we("skip, excludeBegin, returnBegin not compatible with beginScope: {}"),Le;if(typeof o.beginScope!="object"||o.beginScope===null)throw we("beginScope must be object"),Le;Zt(o,o.begin,{key:"beginScope"}),o.begin=m(o.begin,{joinWith:""})}}function ln(o){if(Array.isArray(o.end)){if(o.skip||o.excludeEnd||o.returnEnd)throw we("skip, excludeEnd, returnEnd not compatible with endScope: {}"),Le;if(typeof o.endScope!="object"||o.endScope===null)throw we("endScope must be object"),Le;Zt(o,o.end,{key:"endScope"}),o.end=m(o.end,{joinWith:""})}}function cn(o){o.scope&&typeof o.scope=="object"&&o.scope!==null&&(o.beginScope=o.scope,delete o.scope)}function un(o){cn(o),typeof o.beginScope=="string"&&(o.beginScope={_wrap:o.beginScope}),typeof o.endScope=="string"&&(o.endScope={_wrap:o.endScope}),an(o),ln(o)}function hn(o){function v(N,A){return new RegExp(i(N),"m"+(o.case_insensitive?"i":"")+(o.unicodeRegex?"u":"")+(A?"g":""))}class R{constructor(){this.matchIndexes={},this.regexes=[],this.matchAt=1,this.position=0}addRule(A,j){j.position=this.position++,this.matchIndexes[this.matchAt]=j,this.regexes.push([j,A]),this.matchAt+=S(A)+1}compile(){this.regexes.length===0&&(this.exec=()=>null);const A=this.regexes.map(j=>j[1]);this.matcherRe=v(m(A,{joinWith:"|"}),!0),this.lastIndex=0}exec(A){this.matcherRe.lastIndex=this.lastIndex;const j=this.matcherRe.exec(A);if(!j)return null;const te=j.findIndex((Me,tt)=>tt>0&&Me!==void 0),Y=this.matchIndexes[te];return j.splice(0,te),Object.assign(j,Y)}}class D{constructor(){this.rules=[],this.multiRegexes=[],this.count=0,this.lastIndex=0,this.regexIndex=0}getMatcher(A){if(this.multiRegexes[A])return this.multiRegexes[A];const j=new R;return this.rules.slice(A).forEach(([te,Y])=>j.addRule(te,Y)),j.compile(),this.multiRegexes[A]=j,j}resumingScanAtSamePosition(){return this.regexIndex!==0}considerAll(){this.regexIndex=0}addRule(A,j){this.rules.push([A,j]),j.type==="begin"&&this.count++}exec(A){const j=this.getMatcher(this.regexIndex);j.lastIndex=this.lastIndex;let te=j.exec(A);if(this.resumingScanAtSamePosition()&&!(te&&te.index===this.lastIndex)){const Y=this.getMatcher(0);Y.lastIndex=this.lastIndex+1,te=Y.exec(A)}return te&&(this.regexIndex+=te.position+1,this.regexIndex===this.count&&this.considerAll()),te}}function V(N){const A=new D;return N.contains.forEach(j=>A.addRule(j.begin,{rule:j,type:"begin"})),N.terminatorEnd&&A.addRule(N.terminatorEnd,{type:"end"}),N.illegal&&A.addRule(N.illegal,{type:"illegal"}),A}function X(N,A){const j=N;if(N.isCompiled)return j;[pe,Yr,un,tn].forEach(Y=>Y(N,A)),o.compilerExtensions.forEach(Y=>Y(N,A)),N.__beforeBegin=null,[Ae,Te,en].forEach(Y=>Y(N,A)),N.isCompiled=!0;let te=null;return typeof N.keywords=="object"&&N.keywords.$pattern&&(N.keywords=Object.assign({},N.keywords),te=N.keywords.$pattern,delete N.keywords.$pattern),te=te||/\w+/,N.keywords&&(N.keywords=Ht(N.keywords,o.case_insensitive)),j.keywordPatternRe=v(te,!0),A&&(N.begin||(N.begin=/\B|\b/),j.beginRe=v(j.begin),!N.end&&!N.endsWithParent&&(N.end=/\B|\b/),N.end&&(j.endRe=v(j.end)),j.terminatorEnd=i(j.end)||"",N.endsWithParent&&A.terminatorEnd&&(j.terminatorEnd+=(N.end?"|":"")+A.terminatorEnd)),N.illegal&&(j.illegalRe=v(N.illegal)),N.contains||(N.contains=[]),N.contains=[].concat(...N.contains.map(function(Y){return fn(Y==="self"?N:Y)})),N.contains.forEach(function(Y){X(Y,j)}),N.starts&&X(N.starts,A),j.matcher=V(j),j}if(o.compilerExtensions||(o.compilerExtensions=[]),o.contains&&o.contains.includes("self"))throw new Error("ERR: contains `self` is not supported at the top-level of a language. See documentation.");return o.classNameAliases=f(o.classNameAliases||{}),X(o)}function Jt(o){return o?o.endsWithParent||Jt(o.starts):!1}function fn(o){return o.variants&&!o.cachedVariants&&(o.cachedVariants=o.variants.map(function(v){return f(o,{variants:null},v)})),o.cachedVariants?o.cachedVariants:Jt(o)?f(o,{starts:o.starts?f(o.starts):null}):Object.isFrozen(o)?f(o):o}var dn="11.11.1";class pn extends Error{constructor(v,R){super(v),this.name="HTMLInjectionError",this.html=R}}const et=b,Kt=f,Vt=Symbol("nomatch"),gn=7,Xt=function(o){const v=Object.create(null),R=Object.create(null),D=[];let V=!0;const X="Could not find the language '{}', did you forget to load/include a language module?",N={disableAutodetect:!0,name:"Plain text",contains:[]};let A={ignoreUnescapedHTML:!1,throwUnescapedHTML:!1,noHighlightRe:/^(no-?highlight)$/i,languageDetectRe:/\blang(?:uage)?-([\w-]+)\b/i,classPrefix:"hljs-",cssSelector:"pre code",languages:null,__emitter:e};function j(_){return A.noHighlightRe.test(_)}function te(_){let T=_.className+" ";T+=_.parentNode?_.parentNode.className:"";const q=A.languageDetectRe.exec(T);if(q){const G=ge(q[1]);return G||(Gt(X.replace("{}",q[1])),Gt("Falling back to no-highlight mode for this block.",_)),G?q[1]:"no-highlight"}return T.split(/\s+/).find(G=>j(G)||ge(G))}function Y(_,T,q){let G="",ee="";typeof T=="object"?(G=_,q=T.ignoreIllegals,ee=T.language):(_e("10.7.0","highlight(lang, code, ...args) has been deprecated."),_e("10.7.0",`Please use highlight(code, options) instead.
|
|
147
|
+
https://github.com/highlightjs/highlight.js/issues/2277`),ee=_,G=T),q===void 0&&(q=!0);const ce={code:G,language:ee};Be("before:highlight",ce);const me=ce.result?ce.result:Me(ce.language,ce.code,q);return me.code=ce.code,Be("after:highlight",me),me}function Me(_,T,q,G){const ee=Object.create(null);function ce(O,I){return O.keywords[I]}function me(){if(!z.keywords){re.addText(Z);return}let O=0;z.keywordPatternRe.lastIndex=0;let I=z.keywordPatternRe.exec(Z),$="";for(;I;){$+=Z.substring(O,I.index);const H=he.case_insensitive?I[0].toLowerCase():I[0],ne=ce(z,H);if(ne){const[fe,In]=ne;if(re.addText($),$="",ee[H]=(ee[H]||0)+1,ee[H]<=gn&&(Ue+=In),fe.startsWith("_"))$+=I[0];else{const Pn=he.classNameAliases[fe]||fe;ue(I[0],Pn)}}else $+=I[0];O=z.keywordPatternRe.lastIndex,I=z.keywordPatternRe.exec(Z)}$+=Z.substring(O),re.addText($)}function ze(){if(Z==="")return;let O=null;if(typeof z.subLanguage=="string"){if(!v[z.subLanguage]){re.addText(Z);return}O=Me(z.subLanguage,Z,!0,sr[z.subLanguage]),sr[z.subLanguage]=O._top}else O=rt(Z,z.subLanguage.length?z.subLanguage:null);z.relevance>0&&(Ue+=O.relevance),re.__addSublanguage(O._emitter,O.language)}function oe(){z.subLanguage!=null?ze():me(),Z=""}function ue(O,I){O!==""&&(re.startScope(I),re.addText(O),re.endScope())}function tr(O,I){let $=1;const H=I.length-1;for(;$<=H;){if(!O._emit[$]){$++;continue}const ne=he.classNameAliases[O[$]]||O[$],fe=I[$];ne?ue(fe,ne):(Z=fe,me(),Z=""),$++}}function rr(O,I){return O.scope&&typeof O.scope=="string"&&re.openNode(he.classNameAliases[O.scope]||O.scope),O.beginScope&&(O.beginScope._wrap?(ue(Z,he.classNameAliases[O.beginScope._wrap]||O.beginScope._wrap),Z=""):O.beginScope._multi&&(tr(O.beginScope,I),Z="")),z=Object.create(O,{parent:{value:z}}),z}function nr(O,I,$){let H=w(O.endRe,$);if(H){if(O["on:end"]){const ne=new g(O);O["on:end"](I,ne),ne.isMatchIgnored&&(H=!1)}if(H){for(;O.endsParent&&O.parent;)O=O.parent;return O}}if(O.endsWithParent)return nr(O.parent,I,$)}function Rn(O){return z.matcher.regexIndex===0?(Z+=O[0],1):(ot=!0,0)}function Cn(O){const I=O[0],$=O.rule,H=new g($),ne=[$.__beforeBegin,$["on:begin"]];for(const fe of ne)if(fe&&(fe(O,H),H.isMatchIgnored))return Rn(I);return $.skip?Z+=I:($.excludeBegin&&(Z+=I),oe(),!$.returnBegin&&!$.excludeBegin&&(Z=I)),rr($,O),$.returnBegin?0:I.length}function An(O){const I=O[0],$=T.substring(O.index),H=nr(z,O,$);if(!H)return Vt;const ne=z;z.endScope&&z.endScope._wrap?(oe(),ue(I,z.endScope._wrap)):z.endScope&&z.endScope._multi?(oe(),tr(z.endScope,O)):ne.skip?Z+=I:(ne.returnEnd||ne.excludeEnd||(Z+=I),oe(),ne.excludeEnd&&(Z=I));do z.scope&&re.closeNode(),!z.skip&&!z.subLanguage&&(Ue+=z.relevance),z=z.parent;while(z!==H.parent);return H.starts&&rr(H.starts,O),ne.returnEnd?0:I.length}function Mn(){const O=[];for(let I=z;I!==he;I=I.parent)I.scope&&O.unshift(I.scope);O.forEach(I=>re.openNode(I))}let De={};function ir(O,I){const $=I&&I[0];if(Z+=O,$==null)return oe(),0;if(De.type==="begin"&&I.type==="end"&&De.index===I.index&&$===""){if(Z+=T.slice(I.index,I.index+1),!V){const H=new Error(`0 width match regex (${_})`);throw H.languageName=_,H.badRule=De.rule,H}return 1}if(De=I,I.type==="begin")return Cn(I);if(I.type==="illegal"&&!q){const H=new Error('Illegal lexeme "'+$+'" for mode "'+(z.scope||"<unnamed>")+'"');throw H.mode=z,H}else if(I.type==="end"){const H=An(I);if(H!==Vt)return H}if(I.type==="illegal"&&$==="")return Z+=`
|
|
148
|
+
`,1;if(st>1e5&&st>I.index*3)throw new Error("potential infinite loop, way more iterations than matches");return Z+=$,$.length}const he=ge(_);if(!he)throw we(X.replace("{}",_)),new Error('Unknown language: "'+_+'"');const Nn=hn(he);let it="",z=G||Nn;const sr={},re=new A.__emitter(A);Mn();let Z="",Ue=0,xe=0,st=0,ot=!1;try{if(he.__emitTokens)he.__emitTokens(T,re);else{for(z.matcher.considerAll();;){st++,ot?ot=!1:z.matcher.considerAll(),z.matcher.lastIndex=xe;const O=z.matcher.exec(T);if(!O)break;const I=T.substring(xe,O.index),$=ir(I,O);xe=O.index+$}ir(T.substring(xe))}return re.finalize(),it=re.toHTML(),{language:_,value:it,relevance:Ue,illegal:!1,_emitter:re,_top:z}}catch(O){if(O.message&&O.message.includes("Illegal"))return{language:_,value:et(T),illegal:!0,relevance:0,_illegalBy:{message:O.message,index:xe,context:T.slice(xe-100,xe+100),mode:O.mode,resultSoFar:it},_emitter:re};if(V)return{language:_,value:et(T),illegal:!1,relevance:0,errorRaised:O,_emitter:re,_top:z};throw O}}function tt(_){const T={value:et(_),illegal:!1,relevance:0,_top:N,_emitter:new A.__emitter(A)};return T._emitter.addText(_),T}function rt(_,T){T=T||A.languages||Object.keys(v);const q=tt(_),G=T.filter(ge).filter(er).map(oe=>Me(oe,_,!1));G.unshift(q);const ee=G.sort((oe,ue)=>{if(oe.relevance!==ue.relevance)return ue.relevance-oe.relevance;if(oe.language&&ue.language){if(ge(oe.language).supersetOf===ue.language)return 1;if(ge(ue.language).supersetOf===oe.language)return-1}return 0}),[ce,me]=ee,ze=ce;return ze.secondBest=me,ze}function mn(_,T,q){const G=T&&R[T]||q;_.classList.add("hljs"),_.classList.add(`language-${G}`)}function nt(_){let T=null;const q=te(_);if(j(q))return;if(Be("before:highlightElement",{el:_,language:q}),_.dataset.highlighted){console.log("Element previously highlighted. To highlight again, first unset `dataset.highlighted`.",_);return}if(_.children.length>0&&(A.ignoreUnescapedHTML||(console.warn("One of your code blocks includes unescaped HTML. This is a potentially serious security risk."),console.warn("https://github.com/highlightjs/highlight.js/wiki/security"),console.warn("The element with unescaped HTML:"),console.warn(_)),A.throwUnescapedHTML))throw new pn("One of your code blocks includes unescaped HTML.",_.innerHTML);T=_;const G=T.textContent,ee=q?Y(G,{language:q,ignoreIllegals:!0}):rt(G);_.innerHTML=ee.value,_.dataset.highlighted="yes",mn(_,q,ee.language),_.result={language:ee.language,re:ee.relevance,relevance:ee.relevance},ee.secondBest&&(_.secondBest={language:ee.secondBest.language,relevance:ee.secondBest.relevance}),Be("after:highlightElement",{el:_,result:ee,text:G})}function bn(_){A=Kt(A,_)}const yn=()=>{je(),_e("10.6.0","initHighlighting() deprecated. Use highlightAll() now.")};function wn(){je(),_e("10.6.0","initHighlightingOnLoad() deprecated. Use highlightAll() now.")}let Qt=!1;function je(){function _(){je()}if(document.readyState==="loading"){Qt||window.addEventListener("DOMContentLoaded",_,!1),Qt=!0;return}document.querySelectorAll(A.cssSelector).forEach(nt)}function xn(_,T){let q=null;try{q=T(o)}catch(G){if(we("Language definition for '{}' could not be registered.".replace("{}",_)),V)we(G);else throw G;q=N}q.name||(q.name=_),v[_]=q,q.rawDefinition=T.bind(null,o),q.aliases&&Yt(q.aliases,{languageName:_})}function vn(_){delete v[_];for(const T of Object.keys(R))R[T]===_&&delete R[T]}function En(){return Object.keys(v)}function ge(_){return _=(_||"").toLowerCase(),v[_]||v[R[_]]}function Yt(_,{languageName:T}){typeof _=="string"&&(_=[_]),_.forEach(q=>{R[q.toLowerCase()]=T})}function er(_){const T=ge(_);return T&&!T.disableAutodetect}function Sn(_){_["before:highlightBlock"]&&!_["before:highlightElement"]&&(_["before:highlightElement"]=T=>{_["before:highlightBlock"](Object.assign({block:T.el},T))}),_["after:highlightBlock"]&&!_["after:highlightElement"]&&(_["after:highlightElement"]=T=>{_["after:highlightBlock"](Object.assign({block:T.el},T))})}function kn(_){Sn(_),D.push(_)}function _n(_){const T=D.indexOf(_);T!==-1&&D.splice(T,1)}function Be(_,T){const q=_;D.forEach(function(G){G[q]&&G[q](T)})}function On(_){return _e("10.7.0","highlightBlock will be removed entirely in v12.0"),_e("10.7.0","Please use highlightElement now."),nt(_)}Object.assign(o,{highlight:Y,highlightAuto:rt,highlightAll:je,highlightElement:nt,highlightBlock:On,configure:bn,initHighlighting:yn,initHighlightingOnLoad:wn,registerLanguage:xn,unregisterLanguage:vn,listLanguages:En,getLanguage:ge,registerAliases:Yt,autoDetection:er,inherit:Kt,addPlugin:kn,removePlugin:_n}),o.debugMode=function(){V=!1},o.safeMode=function(){V=!0},o.versionString=dn,o.regex={concat:u,lookahead:t,either:E,optional:l,anyNumberOfTimes:r};for(const _ in ke)typeof ke[_]=="object"&&a(ke[_]);return Object.assign(o,ke),o},Oe=Xt({});return Oe.newInstance=()=>Xt({}),Tt=Oe,Oe.HighlightJS=Oe,Oe.default=Oe,Tt}var mi=gi();const Ve=pi(mi),He="[A-Za-z$_][0-9A-Za-z$_]*",Hr=["as","in","of","if","for","while","finally","var","new","function","do","return","void","else","break","catch","instanceof","with","throw","case","default","try","switch","continue","typeof","delete","let","yield","const","class","debugger","async","await","static","import","from","export","extends","using"],Wr=["true","false","null","undefined","NaN","Infinity"],Gr=["Object","Function","Boolean","Symbol","Math","Date","Number","BigInt","String","RegExp","Array","Float32Array","Float64Array","Int8Array","Uint8Array","Uint8ClampedArray","Int16Array","Int32Array","Uint16Array","Uint32Array","BigInt64Array","BigUint64Array","Set","Map","WeakSet","WeakMap","ArrayBuffer","SharedArrayBuffer","Atomics","DataView","JSON","Promise","Generator","GeneratorFunction","AsyncFunction","Reflect","Proxy","Intl","WebAssembly"],Zr=["Error","EvalError","InternalError","RangeError","ReferenceError","SyntaxError","TypeError","URIError"],Jr=["setInterval","setTimeout","clearInterval","clearTimeout","require","exports","eval","isFinite","isNaN","parseFloat","parseInt","decodeURI","decodeURIComponent","encodeURI","encodeURIComponent","escape","unescape"],Kr=["arguments","this","super","console","window","document","localStorage","sessionStorage","module","global"],Vr=[].concat(Jr,Gr,Zr);function bi(a){const g=a.regex,b=(W,{after:Q})=>{const ie="</"+W[0].slice(1);return W.input.indexOf(ie,Q)!==-1},f=He,n={begin:"<>",end:"</>"},h=/<[A-Za-z0-9\\._:-]+\s*\/>/,s={begin:/<[A-Za-z0-9\\._:-]+/,end:/\/[A-Za-z0-9\\._:-]+>|\/>/,isTrulyOpeningTag:(W,Q)=>{const ie=W[0].length+W.index,se=W.input[ie];if(se==="<"||se===","){Q.ignoreMatch();return}se===">"&&(b(W,{after:ie})||Q.ignoreMatch());let de;const ye=W.input.substring(ie);if(de=ye.match(/^\s*=/)){Q.ignoreMatch();return}if((de=ye.match(/^\s+extends\s+/))&&de.index===0){Q.ignoreMatch();return}}},p={$pattern:He,keyword:Hr,literal:Wr,built_in:Vr,"variable.language":Kr},x="[0-9](_?[0-9])*",c=`\\.(${x})`,e="0|[1-9](_?[0-9])*|0[0-7]*[89][0-9]*",i={className:"number",variants:[{begin:`(\\b(${e})((${c})|\\.)?|(${c}))[eE][+-]?(${x})\\b`},{begin:`\\b(${e})\\b((${c})\\b|\\.)?|(${c})\\b`},{begin:"\\b(0|[1-9](_?[0-9])*)n\\b"},{begin:"\\b0[xX][0-9a-fA-F](_?[0-9a-fA-F])*n?\\b"},{begin:"\\b0[bB][0-1](_?[0-1])*n?\\b"},{begin:"\\b0[oO][0-7](_?[0-7])*n?\\b"},{begin:"\\b0[0-7]+n?\\b"}],relevance:0},t={className:"subst",begin:"\\$\\{",end:"\\}",keywords:p,contains:[]},r={begin:".?html`",end:"",starts:{end:"`",returnEnd:!1,contains:[a.BACKSLASH_ESCAPE,t],subLanguage:"xml"}},l={begin:".?css`",end:"",starts:{end:"`",returnEnd:!1,contains:[a.BACKSLASH_ESCAPE,t],subLanguage:"css"}},u={begin:".?gql`",end:"",starts:{end:"`",returnEnd:!1,contains:[a.BACKSLASH_ESCAPE,t],subLanguage:"graphql"}},d={className:"string",begin:"`",end:"`",contains:[a.BACKSLASH_ESCAPE,t]},E={className:"comment",variants:[a.COMMENT(/\/\*\*(?!\/)/,"\\*/",{relevance:0,contains:[{begin:"(?=@[A-Za-z]+)",relevance:0,contains:[{className:"doctag",begin:"@[A-Za-z]+"},{className:"type",begin:"\\{",end:"\\}",excludeEnd:!0,excludeBegin:!0,relevance:0},{className:"variable",begin:f+"(?=\\s*(-)|$)",endsParent:!0,relevance:0},{begin:/(?=[^\n])\s/,relevance:0}]}]}),a.C_BLOCK_COMMENT_MODE,a.C_LINE_COMMENT_MODE]},S=[a.APOS_STRING_MODE,a.QUOTE_STRING_MODE,r,l,u,d,{match:/\$\d+/},i];t.contains=S.concat({begin:/\{/,end:/\}/,keywords:p,contains:["self"].concat(S)});const w=[].concat(E,t.contains),y=w.concat([{begin:/(\s*)\(/,end:/\)/,keywords:p,contains:["self"].concat(w)}]),m={className:"params",begin:/(\s*)\(/,end:/\)/,excludeBegin:!0,excludeEnd:!0,keywords:p,contains:y},k={variants:[{match:[/class/,/\s+/,f,/\s+/,/extends/,/\s+/,g.concat(f,"(",g.concat(/\./,f),")*")],scope:{1:"keyword",3:"title.class",5:"keyword",7:"title.class.inherited"}},{match:[/class/,/\s+/,f],scope:{1:"keyword",3:"title.class"}}]},C={relevance:0,match:g.either(/\bJSON/,/\b[A-Z][a-z]+([A-Z][a-z]*|\d)*/,/\b[A-Z]{2,}([A-Z][a-z]+|\d)+([A-Z][a-z]*)*/,/\b[A-Z]{2,}[a-z]+([A-Z][a-z]+|\d)*([A-Z][a-z]*)*/),className:"title.class",keywords:{_:[...Gr,...Zr]}},L={label:"use_strict",className:"meta",relevance:10,begin:/^\s*['"]use (strict|asm)['"]/},U={variants:[{match:[/function/,/\s+/,f,/(?=\s*\()/]},{match:[/function/,/\s*(?=\()/]}],className:{1:"keyword",3:"title.function"},label:"func.def",contains:[m],illegal:/%/},P={relevance:0,match:/\b[A-Z][A-Z_0-9]+\b/,className:"variable.constant"};function K(W){return g.concat("(?!",W.join("|"),")")}const F={match:g.concat(/\b/,K([...Jr,"super","import"].map(W=>`${W}\\s*\\(`)),f,g.lookahead(/\s*\(/)),className:"title.function",relevance:0},be={begin:g.concat(/\./,g.lookahead(g.concat(f,/(?![0-9A-Za-z$_(])/))),end:f,excludeBegin:!0,keywords:"prototype",className:"property",relevance:0},ae={match:[/get|set/,/\s+/,f,/(?=\()/],className:{1:"keyword",3:"title.function"},contains:[{begin:/\(\)/},m]},M="(\\([^()]*(\\([^()]*(\\([^()]*\\)[^()]*)*\\)[^()]*)*\\)|"+a.UNDERSCORE_IDENT_RE+")\\s*=>",Ee={match:[/const|var|let/,/\s+/,f,/\s*/,/=\s*/,/(async\s*)?/,g.lookahead(M)],keywords:"async",className:{1:"keyword",3:"title.function"},contains:[m]};return{name:"JavaScript",aliases:["js","jsx","mjs","cjs"],keywords:p,exports:{PARAMS_CONTAINS:y,CLASS_REFERENCE:C},illegal:/#(?![$_A-z])/,contains:[a.SHEBANG({label:"shebang",binary:"node",relevance:5}),L,a.APOS_STRING_MODE,a.QUOTE_STRING_MODE,r,l,u,d,E,{match:/\$\d+/},i,C,{scope:"attr",match:f+g.lookahead(":"),relevance:0},Ee,{begin:"("+a.RE_STARTERS_RE+"|\\b(case|return|throw)\\b)\\s*",keywords:"return throw case",relevance:0,contains:[E,a.REGEXP_MODE,{className:"function",begin:M,returnBegin:!0,end:"\\s*=>",contains:[{className:"params",variants:[{begin:a.UNDERSCORE_IDENT_RE,relevance:0},{className:null,begin:/\(\s*\)/,skip:!0},{begin:/(\s*)\(/,end:/\)/,excludeBegin:!0,excludeEnd:!0,keywords:p,contains:y}]}]},{begin:/,/,relevance:0},{match:/\s+/,relevance:0},{variants:[{begin:n.begin,end:n.end},{match:h},{begin:s.begin,"on:begin":s.isTrulyOpeningTag,end:s.end}],subLanguage:"xml",contains:[{begin:s.begin,end:s.end,skip:!0,contains:["self"]}]}]},U,{beginKeywords:"while if switch catch for"},{begin:"\\b(?!function)"+a.UNDERSCORE_IDENT_RE+"\\([^()]*(\\([^()]*(\\([^()]*\\)[^()]*)*\\)[^()]*)*\\)\\s*\\{",returnBegin:!0,label:"func.def",contains:[m,a.inherit(a.TITLE_MODE,{begin:f,className:"title.function"})]},{match:/\.\.\./,relevance:0},be,{match:"\\$"+f,relevance:0},{match:[/\bconstructor(?=\s*\()/],className:{1:"title.function"},contains:[m]},F,P,k,ae,{match:/\$[(.]/}]}}function yi(a){const g=a.regex,b=bi(a),f=He,n=["any","void","number","boolean","string","object","never","symbol","bigint","unknown"],h={begin:[/namespace/,/\s+/,a.IDENT_RE],beginScope:{1:"keyword",3:"title.class"}},s={beginKeywords:"interface",end:/\{/,excludeEnd:!0,keywords:{keyword:"interface extends",built_in:n},contains:[b.exports.CLASS_REFERENCE]},p={className:"meta",relevance:10,begin:/^\s*['"]use strict['"]/},x=["type","interface","public","private","protected","implements","declare","abstract","readonly","enum","override","satisfies"],c={$pattern:He,keyword:Hr.concat(x),literal:Wr,built_in:Vr.concat(n),"variable.language":Kr},e={className:"meta",begin:"@"+f},i=(u,d,E)=>{const S=u.contains.findIndex(w=>w.label===d);if(S===-1)throw new Error("can not find mode to replace");u.contains.splice(S,1,E)};Object.assign(b.keywords,c),b.exports.PARAMS_CONTAINS.push(e);const t=b.contains.find(u=>u.scope==="attr"),r=Object.assign({},t,{match:g.concat(f,g.lookahead(/\s*\?:/))});b.exports.PARAMS_CONTAINS.push([b.exports.CLASS_REFERENCE,t,r]),b.contains=b.contains.concat([e,h,s,r]),i(b,"shebang",a.SHEBANG()),i(b,"use_strict",p);const l=b.contains.find(u=>u.label==="func.def");return l.relevance=0,Object.assign(b,{name:"TypeScript",aliases:["ts","tsx","mts","cts"]}),b}function wi(a){const g=a.regex,b=g.concat(/[\p{L}_]/u,g.optional(/[\p{L}0-9_.-]*:/u),/[\p{L}0-9_.-]*/u),f=/[\p{L}0-9._:-]+/u,n={className:"symbol",begin:/&[a-z]+;|&#[0-9]+;|&#x[a-f0-9]+;/},h={begin:/\s/,contains:[{className:"keyword",begin:/#?[a-z_][a-z1-9_-]+/,illegal:/\n/}]},s=a.inherit(h,{begin:/\(/,end:/\)/}),p=a.inherit(a.APOS_STRING_MODE,{className:"string"}),x=a.inherit(a.QUOTE_STRING_MODE,{className:"string"}),c={endsWithParent:!0,illegal:/</,relevance:0,contains:[{className:"attr",begin:f,relevance:0},{begin:/=\s*/,relevance:0,contains:[{className:"string",endsParent:!0,variants:[{begin:/"/,end:/"/,contains:[n]},{begin:/'/,end:/'/,contains:[n]},{begin:/[^\s"'=<>`]+/}]}]}]};return{name:"HTML, XML",aliases:["html","xhtml","rss","atom","xjb","xsd","xsl","plist","wsf","svg"],case_insensitive:!0,unicodeRegex:!0,contains:[{className:"meta",begin:/<![a-z]/,end:/>/,relevance:10,contains:[h,x,p,s,{begin:/\[/,end:/\]/,contains:[{className:"meta",begin:/<![a-z]/,end:/>/,contains:[h,s,x,p]}]}]},a.COMMENT(/<!--/,/-->/,{relevance:10}),{begin:/<!\[CDATA\[/,end:/\]\]>/,relevance:10},n,{className:"meta",end:/\?>/,variants:[{begin:/<\?xml/,relevance:10,contains:[x]},{begin:/<\?[a-z][a-z0-9]+/}]},{className:"tag",begin:/<style(?=\s|>)/,end:/>/,keywords:{name:"style"},contains:[c],starts:{end:/<\/style>/,returnEnd:!0,subLanguage:["css","xml"]}},{className:"tag",begin:/<script(?=\s|>)/,end:/>/,keywords:{name:"script"},contains:[c],starts:{end:/<\/script>/,returnEnd:!0,subLanguage:["javascript","handlebars","xml"]}},{className:"tag",begin:/<>|<\/>/},{className:"tag",begin:g.concat(/</,g.lookahead(g.concat(b,g.either(/\/>/,/>/,/\s/)))),end:/\/?>/,contains:[{className:"name",begin:b,relevance:0,starts:c}]},{className:"tag",begin:g.concat(/<\//,g.lookahead(g.concat(b,/>/))),contains:[{className:"name",begin:b,relevance:0},{begin:/>/,relevance:0,endsParent:!0}]}]}}const xi=a=>({IMPORTANT:{scope:"meta",begin:"!important"},BLOCK_COMMENT:a.C_BLOCK_COMMENT_MODE,HEXCOLOR:{scope:"number",begin:/#(([0-9a-fA-F]{3,4})|(([0-9a-fA-F]{2}){3,4}))\b/},FUNCTION_DISPATCH:{className:"built_in",begin:/[\w-]+(?=\()/},ATTRIBUTE_SELECTOR_MODE:{scope:"selector-attr",begin:/\[/,end:/\]/,illegal:"$",contains:[a.APOS_STRING_MODE,a.QUOTE_STRING_MODE]},CSS_NUMBER_MODE:{scope:"number",begin:a.NUMBER_RE+"(%|em|ex|ch|rem|vw|vh|vmin|vmax|cm|mm|in|pt|pc|px|deg|grad|rad|turn|s|ms|Hz|kHz|dpi|dpcm|dppx)?",relevance:0},CSS_VARIABLE:{className:"attr",begin:/--[A-Za-z_][A-Za-z0-9_-]*/}}),vi=["a","abbr","address","article","aside","audio","b","blockquote","body","button","canvas","caption","cite","code","dd","del","details","dfn","div","dl","dt","em","fieldset","figcaption","figure","footer","form","h1","h2","h3","h4","h5","h6","header","hgroup","html","i","iframe","img","input","ins","kbd","label","legend","li","main","mark","menu","nav","object","ol","optgroup","option","p","picture","q","quote","samp","section","select","source","span","strong","summary","sup","table","tbody","td","textarea","tfoot","th","thead","time","tr","ul","var","video"],Ei=["defs","g","marker","mask","pattern","svg","switch","symbol","feBlend","feColorMatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feFlood","feGaussianBlur","feImage","feMerge","feMorphology","feOffset","feSpecularLighting","feTile","feTurbulence","linearGradient","radialGradient","stop","circle","ellipse","image","line","path","polygon","polyline","rect","text","use","textPath","tspan","foreignObject","clipPath"],Si=[...vi,...Ei],ki=["any-hover","any-pointer","aspect-ratio","color","color-gamut","color-index","device-aspect-ratio","device-height","device-width","display-mode","forced-colors","grid","height","hover","inverted-colors","monochrome","orientation","overflow-block","overflow-inline","pointer","prefers-color-scheme","prefers-contrast","prefers-reduced-motion","prefers-reduced-transparency","resolution","scan","scripting","update","width","min-width","max-width","min-height","max-height"].sort().reverse(),_i=["active","any-link","blank","checked","current","default","defined","dir","disabled","drop","empty","enabled","first","first-child","first-of-type","fullscreen","future","focus","focus-visible","focus-within","has","host","host-context","hover","indeterminate","in-range","invalid","is","lang","last-child","last-of-type","left","link","local-link","not","nth-child","nth-col","nth-last-child","nth-last-col","nth-last-of-type","nth-of-type","only-child","only-of-type","optional","out-of-range","past","placeholder-shown","read-only","read-write","required","right","root","scope","target","target-within","user-invalid","valid","visited","where"].sort().reverse(),Oi=["after","backdrop","before","cue","cue-region","first-letter","first-line","grammar-error","marker","part","placeholder","selection","slotted","spelling-error"].sort().reverse(),Ri=["accent-color","align-content","align-items","align-self","alignment-baseline","all","anchor-name","animation","animation-composition","animation-delay","animation-direction","animation-duration","animation-fill-mode","animation-iteration-count","animation-name","animation-play-state","animation-range","animation-range-end","animation-range-start","animation-timeline","animation-timing-function","appearance","aspect-ratio","backdrop-filter","backface-visibility","background","background-attachment","background-blend-mode","background-clip","background-color","background-image","background-origin","background-position","background-position-x","background-position-y","background-repeat","background-size","baseline-shift","block-size","border","border-block","border-block-color","border-block-end","border-block-end-color","border-block-end-style","border-block-end-width","border-block-start","border-block-start-color","border-block-start-style","border-block-start-width","border-block-style","border-block-width","border-bottom","border-bottom-color","border-bottom-left-radius","border-bottom-right-radius","border-bottom-style","border-bottom-width","border-collapse","border-color","border-end-end-radius","border-end-start-radius","border-image","border-image-outset","border-image-repeat","border-image-slice","border-image-source","border-image-width","border-inline","border-inline-color","border-inline-end","border-inline-end-color","border-inline-end-style","border-inline-end-width","border-inline-start","border-inline-start-color","border-inline-start-style","border-inline-start-width","border-inline-style","border-inline-width","border-left","border-left-color","border-left-style","border-left-width","border-radius","border-right","border-right-color","border-right-style","border-right-width","border-spacing","border-start-end-radius","border-start-start-radius","border-style","border-top","border-top-color","border-top-left-radius","border-top-right-radius","border-top-style","border-top-width","border-width","bottom","box-align","box-decoration-break","box-direction","box-flex","box-flex-group","box-lines","box-ordinal-group","box-orient","box-pack","box-shadow","box-sizing","break-after","break-before","break-inside","caption-side","caret-color","clear","clip","clip-path","clip-rule","color","color-interpolation","color-interpolation-filters","color-profile","color-rendering","color-scheme","column-count","column-fill","column-gap","column-rule","column-rule-color","column-rule-style","column-rule-width","column-span","column-width","columns","contain","contain-intrinsic-block-size","contain-intrinsic-height","contain-intrinsic-inline-size","contain-intrinsic-size","contain-intrinsic-width","container","container-name","container-type","content","content-visibility","counter-increment","counter-reset","counter-set","cue","cue-after","cue-before","cursor","cx","cy","direction","display","dominant-baseline","empty-cells","enable-background","field-sizing","fill","fill-opacity","fill-rule","filter","flex","flex-basis","flex-direction","flex-flow","flex-grow","flex-shrink","flex-wrap","float","flood-color","flood-opacity","flow","font","font-display","font-family","font-feature-settings","font-kerning","font-language-override","font-optical-sizing","font-palette","font-size","font-size-adjust","font-smooth","font-smoothing","font-stretch","font-style","font-synthesis","font-synthesis-position","font-synthesis-small-caps","font-synthesis-style","font-synthesis-weight","font-variant","font-variant-alternates","font-variant-caps","font-variant-east-asian","font-variant-emoji","font-variant-ligatures","font-variant-numeric","font-variant-position","font-variation-settings","font-weight","forced-color-adjust","gap","glyph-orientation-horizontal","glyph-orientation-vertical","grid","grid-area","grid-auto-columns","grid-auto-flow","grid-auto-rows","grid-column","grid-column-end","grid-column-start","grid-gap","grid-row","grid-row-end","grid-row-start","grid-template","grid-template-areas","grid-template-columns","grid-template-rows","hanging-punctuation","height","hyphenate-character","hyphenate-limit-chars","hyphens","icon","image-orientation","image-rendering","image-resolution","ime-mode","initial-letter","initial-letter-align","inline-size","inset","inset-area","inset-block","inset-block-end","inset-block-start","inset-inline","inset-inline-end","inset-inline-start","isolation","justify-content","justify-items","justify-self","kerning","left","letter-spacing","lighting-color","line-break","line-height","line-height-step","list-style","list-style-image","list-style-position","list-style-type","margin","margin-block","margin-block-end","margin-block-start","margin-bottom","margin-inline","margin-inline-end","margin-inline-start","margin-left","margin-right","margin-top","margin-trim","marker","marker-end","marker-mid","marker-start","marks","mask","mask-border","mask-border-mode","mask-border-outset","mask-border-repeat","mask-border-slice","mask-border-source","mask-border-width","mask-clip","mask-composite","mask-image","mask-mode","mask-origin","mask-position","mask-repeat","mask-size","mask-type","masonry-auto-flow","math-depth","math-shift","math-style","max-block-size","max-height","max-inline-size","max-width","min-block-size","min-height","min-inline-size","min-width","mix-blend-mode","nav-down","nav-index","nav-left","nav-right","nav-up","none","normal","object-fit","object-position","offset","offset-anchor","offset-distance","offset-path","offset-position","offset-rotate","opacity","order","orphans","outline","outline-color","outline-offset","outline-style","outline-width","overflow","overflow-anchor","overflow-block","overflow-clip-margin","overflow-inline","overflow-wrap","overflow-x","overflow-y","overlay","overscroll-behavior","overscroll-behavior-block","overscroll-behavior-inline","overscroll-behavior-x","overscroll-behavior-y","padding","padding-block","padding-block-end","padding-block-start","padding-bottom","padding-inline","padding-inline-end","padding-inline-start","padding-left","padding-right","padding-top","page","page-break-after","page-break-before","page-break-inside","paint-order","pause","pause-after","pause-before","perspective","perspective-origin","place-content","place-items","place-self","pointer-events","position","position-anchor","position-visibility","print-color-adjust","quotes","r","resize","rest","rest-after","rest-before","right","rotate","row-gap","ruby-align","ruby-position","scale","scroll-behavior","scroll-margin","scroll-margin-block","scroll-margin-block-end","scroll-margin-block-start","scroll-margin-bottom","scroll-margin-inline","scroll-margin-inline-end","scroll-margin-inline-start","scroll-margin-left","scroll-margin-right","scroll-margin-top","scroll-padding","scroll-padding-block","scroll-padding-block-end","scroll-padding-block-start","scroll-padding-bottom","scroll-padding-inline","scroll-padding-inline-end","scroll-padding-inline-start","scroll-padding-left","scroll-padding-right","scroll-padding-top","scroll-snap-align","scroll-snap-stop","scroll-snap-type","scroll-timeline","scroll-timeline-axis","scroll-timeline-name","scrollbar-color","scrollbar-gutter","scrollbar-width","shape-image-threshold","shape-margin","shape-outside","shape-rendering","speak","speak-as","src","stop-color","stop-opacity","stroke","stroke-dasharray","stroke-dashoffset","stroke-linecap","stroke-linejoin","stroke-miterlimit","stroke-opacity","stroke-width","tab-size","table-layout","text-align","text-align-all","text-align-last","text-anchor","text-combine-upright","text-decoration","text-decoration-color","text-decoration-line","text-decoration-skip","text-decoration-skip-ink","text-decoration-style","text-decoration-thickness","text-emphasis","text-emphasis-color","text-emphasis-position","text-emphasis-style","text-indent","text-justify","text-orientation","text-overflow","text-rendering","text-shadow","text-size-adjust","text-transform","text-underline-offset","text-underline-position","text-wrap","text-wrap-mode","text-wrap-style","timeline-scope","top","touch-action","transform","transform-box","transform-origin","transform-style","transition","transition-behavior","transition-delay","transition-duration","transition-property","transition-timing-function","translate","unicode-bidi","user-modify","user-select","vector-effect","vertical-align","view-timeline","view-timeline-axis","view-timeline-inset","view-timeline-name","view-transition-name","visibility","voice-balance","voice-duration","voice-family","voice-pitch","voice-range","voice-rate","voice-stress","voice-volume","white-space","white-space-collapse","widows","width","will-change","word-break","word-spacing","word-wrap","writing-mode","x","y","z-index","zoom"].sort().reverse();function Ci(a){const g=a.regex,b=xi(a),f={begin:/-(webkit|moz|ms|o)-(?=[a-z])/},n="and or not only",h=/@-?\w[\w]*(-\w+)*/,s="[a-zA-Z-][a-zA-Z0-9_-]*",p=[a.APOS_STRING_MODE,a.QUOTE_STRING_MODE];return{name:"CSS",case_insensitive:!0,illegal:/[=|'\$]/,keywords:{keyframePosition:"from to"},classNameAliases:{keyframePosition:"selector-tag"},contains:[b.BLOCK_COMMENT,f,b.CSS_NUMBER_MODE,{className:"selector-id",begin:/#[A-Za-z0-9_-]+/,relevance:0},{className:"selector-class",begin:"\\."+s,relevance:0},b.ATTRIBUTE_SELECTOR_MODE,{className:"selector-pseudo",variants:[{begin:":("+_i.join("|")+")"},{begin:":(:)?("+Oi.join("|")+")"}]},b.CSS_VARIABLE,{className:"attribute",begin:"\\b("+Ri.join("|")+")\\b"},{begin:/:/,end:/[;}{]/,contains:[b.BLOCK_COMMENT,b.HEXCOLOR,b.IMPORTANT,b.CSS_NUMBER_MODE,...p,{begin:/(url|data-uri)\(/,end:/\)/,relevance:0,keywords:{built_in:"url data-uri"},contains:[...p,{className:"string",begin:/[^)]/,endsWithParent:!0,excludeEnd:!0}]},b.FUNCTION_DISPATCH]},{begin:g.lookahead(/@/),end:"[{;]",relevance:0,illegal:/:/,contains:[{className:"keyword",begin:h},{begin:/\s/,endsWithParent:!0,excludeEnd:!0,relevance:0,keywords:{$pattern:/[a-z-]+/,keyword:n,attribute:ki.join(" ")},contains:[{begin:/[a-z-]+(?=:)/,className:"attribute"},...p,b.CSS_NUMBER_MODE]}]},{className:"selector-tag",begin:"\\b("+Si.join("|")+")\\b"}]}}const Xr=document.createElement("style");Xr.innerText=[fi,di].join(`
|
|
149
|
+
`);document.head.appendChild(Xr);Ve.registerLanguage("typescript",yi);Ve.registerLanguage("html",wi);Ve.registerLanguage("css",Ci);function Ai(...a){const g=document.createElement("div"),b=document.createElement("div");b.classList.add("tab-control");const f=document.createElement("div");return a.forEach(n=>{g.appendChild(n),n.addEventListener("click",()=>{a.forEach(h=>h.removeAttribute("selected")),n.setAttribute("selected",""),f.innerHTML="",f.appendChild(n.content),f.className=n.className,f.classList.add("tab-content")})}),b.appendChild(g),b.appendChild(f),f.classList.add("tab-content"),a[0].setAttribute("selected",""),f.appendChild(a[0].content),b}function Ne(a,g){const b=document.createElement("div");return b.role="tab",b.tabIndex=0,b.innerText=a,b.content=g,g.tagName=="PRE"&&b.classList.add("code"),b}function Ie(a,g){const b=document.createElement(a);return typeof g=="string"?b.innerHTML=g:g.forEach(f=>{b.appendChild(f)}),b}async function Mi(a,g,b){const f=g.mainContent,n=Ie("div",f);n.id=`example-preview-${b}`;const h=typeof g.css=="string"?void 0:g.css?.label,s=typeof g.css=="string"?g.css:g.css?.content,p=Ai(Ne("Preview",n),Ne("HTML",Fe("html",f)),...s?[Ne(h??"CSS",Fe("css",s))]:[],...g.initializer&&g.initializer.content?[Ne(g.initializer.label??"TS",Fe("typescript",g.initializer.content))]:[],...(g.additionalSources||[]).map(c=>Ne(c.label,Fe(c.language,c.content))));g.description&&a.appendChild(Ie("div",g.description));const x=Ie("div",[p]);x.classList.add("example"),a.appendChild(x),s&&Ni(`#${n.id}`,s),g.initializer?.initialize&&await g.initializer.initialize(n)}function Fe(a,g){let b=g.split(/\r?\n/).map(f=>{const n=f.indexOf("///");if(n>-1){const h=f.substring(n+3).trimStart();return h?f.replace(/^(\s*)([^\s].*)$/,`$1${h}`):void 0}return f}).filter(f=>typeof f<"u").join(`
|
|
150
|
+
`).trim();return a&&a!="raw"&&(b=Ve.highlight(b,{language:a}).value),Ie("pre",[Ie("code",b)])}function Ni(a,g){const b=document.createElement("style");b.innerHTML=J().use(hi({prefix:a})).process(g).css,document.head.appendChild(b)}async function Ii(a,g=document.body){const b=Ti(g);let f=0;Object.keys(a).sort().forEach(async n=>{const h=document.createElement("div");h.className="example-container",b.appendChild(h);const s=a[n].default;Mi(h,s,f++)})}function Pi(a){const g=document.createElement("div");g.id="examples-container";const b=a.querySelector("#examples");return b?b.after(g):a.appendChild(g),g}function Ti(a){return a.children?Pi(a):a}const Li=`<h1 id="@cas-smartdesign/image-tools">@cas-smartdesign/image-tools</h1>
|
|
110
151
|
<p>A utility providing placeholder/fallback image loading.</p>
|
|
111
152
|
<h2 id="public-methods">Public methods</h2>
|
|
112
153
|
<ul>
|
|
@@ -122,10 +163,4 @@ If not specified, it is autodetected based on the element type.</li>
|
|
|
122
163
|
</ul>
|
|
123
164
|
</li>
|
|
124
165
|
</ul>
|
|
125
|
-
`,
|
|
126
|
-
function __vite__mapDeps(indexes) {
|
|
127
|
-
if (!__vite__mapDeps.viteFileDeps) {
|
|
128
|
-
__vite__mapDeps.viteFileDeps = ["./css-background.js","./image-tools.mjs","./img-src.js"]
|
|
129
|
-
}
|
|
130
|
-
return indexes.map((i) => __vite__mapDeps.viteFileDeps[i])
|
|
131
|
-
}
|
|
166
|
+
`,ji=document.querySelector("#markdown-container");ji.innerHTML=Li;const Qr=document.createElement("p");Qr.innerText="In the following examples the images are loaded from the same origin, which inevitably leads to a waterfall. (some of them may not load on purpose)";document.querySelector(".markdown-body").append(Qr);Ii(Object.assign({"./examples/0_css-background/index.ts":Un,"./examples/1_img-src/index.ts":Wn,"./examples/2_directive/index.ts":Vn}),document.querySelector(".markdown-body"));
|