@cas-smartdesign/message 4.0.2 → 4.1.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/doc.css +1 -1
- package/dist/docs/doc.mjs +33 -36
- package/dist/message-with-externals.js.map +2 -2
- package/dist/message.mjs.map +1 -1
- package/npm-third-party-licenses.json +51 -46
- package/package.json +4 -4
package/dist/docs/doc.mjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
(function(){const
|
|
1
|
+
(function(){const f=document.createElement("link").relList;if(f&&f.supports&&f.supports("modulepreload"))return;for(const n of document.querySelectorAll('link[rel="modulepreload"]'))d(n);new MutationObserver(n=>{for(const h of n)if(h.type==="childList")for(const o of h.addedNodes)o.tagName==="LINK"&&o.rel==="modulepreload"&&d(o)}).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 d(n){if(n.ep)return;n.ep=!0;const h=b(n);fetch(n.href,h)}})();const Tn=`<!-- Load message with all dependencies directly -->
|
|
2
2
|
<script src="./message-with-externals.js"><\/script>
|
|
3
3
|
|
|
4
4
|
<sd-message
|
|
@@ -13,10 +13,10 @@
|
|
|
13
13
|
</span>
|
|
14
14
|
<span slot="description"><i>lorem ipsum dolor sit amet</i></span>
|
|
15
15
|
</sd-message>
|
|
16
|
-
`,
|
|
17
|
-
`,
|
|
18
|
-
`,
|
|
19
|
-
`,
|
|
16
|
+
`,jn=`<h3 id="create-a-button-element-declaratively.">Create a button element declaratively.</h3>
|
|
17
|
+
`,zn={mainContent:Tn,description:jn},Bn=Object.freeze(Object.defineProperty({__proto__:null,default:zn},Symbol.toStringTag,{value:"Module"})),Dn="modulepreload",Un=function(s,f){return new URL(s,f).href},ar={},Fn=function(f,b,d){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 o=document.getElementsByTagName("link"),g=document.querySelector("meta[property=csp-nonce]"),v=g?.nonce||g?.getAttribute("nonce");n=c(b.map(e=>{if(e=Un(e,d),e in ar)return;ar[e]=!0;const i=e.endsWith(".css"),t=i?'[rel="stylesheet"]':"";if(!!d)for(let u=o.length-1;u>=0;u--){const p=o[u];if(p.href===e&&(!i||p.rel==="stylesheet"))return}else if(document.querySelector(`link[href="${e}"]${t}`))return;const l=document.createElement("link");if(l.rel=i?"stylesheet":Dn,i||(l.as="script"),l.crossOrigin="",l.href=e,v&&l.setAttribute("nonce",v),document.head.appendChild(l),i)return new Promise((u,p)=>{l.addEventListener("load",u),l.addEventListener("error",()=>p(new Error(`Unable to preload CSS for ${e}`)))})}))}function h(o){const g=new Event("vite:preloadError",{cancelable:!0});if(g.payload=o,window.dispatchEvent(g),!g.defaultPrevented)throw o}return n.then(o=>{for(const g of o||[])g.status==="rejected"&&h(g.reason);return f().catch(h)})},$n=`<div id="message-from-source-container"></div>
|
|
18
|
+
`,qn=`<h3 id="create-and-access-a-message-with-typescript-code.">Create and access a message with typescript code.</h3>
|
|
19
|
+
`,Wn=`import { Level, Message } from "@cas-smartdesign/message";
|
|
20
20
|
import "@cas-smartdesign/message";
|
|
21
21
|
|
|
22
22
|
const addMessage = (caption: string, level: Level, withButton: boolean, hiddenIcon: boolean) => {
|
|
@@ -70,7 +70,7 @@ const addExamples = () => {
|
|
|
70
70
|
};
|
|
71
71
|
|
|
72
72
|
addExamples();
|
|
73
|
-
`,
|
|
73
|
+
`,Hn={mainContent:$n,description:qn,initializer:{content:Wn,type:"typescript",initialize:()=>Fn(()=>import("./2_created_from_source.js"),[],import.meta.url)}},Gn=Object.freeze(Object.defineProperty({__proto__:null,default:Hn},Symbol.toStringTag,{value:"Module"})),Br=class He extends HTMLElement{memoizedTemplate(){const f=this.is();if(He.TEMPLATE_CACHE[f])return He.TEMPLATE_CACHE[f];const b=this.template();return window.ShadyCSS&&window.ShadyCSS.prepareTemplate(b,this.is()),He.TEMPLATE_CACHE[f]=b,b}connectedCallback(){const f=this.memoizedTemplate();window.ShadyCSS&&window.ShadyCSS.styleElement(this),this.shadowRoot||(this.attachShadow({mode:"open"}),this.shadowRoot.appendChild(document.importNode(f.content,!0)),requestAnimationFrame(()=>this.dispatchEvent(new CustomEvent("ready"))))}whenReady(f){this.shadowRoot?f():this.addEventListener("ready",()=>f())}};Br.TEMPLATE_CACHE={};let Zn=Br;const Jn=`<style>
|
|
74
74
|
:host {
|
|
75
75
|
display: flex;
|
|
76
76
|
flex-direction: row;
|
|
@@ -156,35 +156,38 @@ addExamples();
|
|
|
156
156
|
<slot name="footer"></slot>
|
|
157
157
|
</div>
|
|
158
158
|
</div>
|
|
159
|
-
`,
|
|
160
|
-
`+
|
|
161
|
-
|
|
159
|
+
`,Kn="data:image/svg+xml,%3csvg%20id='svg3363'%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%2032%2032'%20height='32'%20width='32'%3e%3cstyle%3e%20.st0{fill:%23cc0017}%20%3c/style%3e%3cg%20id='layer1'%20transform='translate(0%20-40)'%3e%3cpath%20class='st0'%20d='M16%2042.2c7.6%200%2013.8%206.2%2013.8%2013.8S23.6%2069.8%2016%2069.8%202.2%2063.6%202.2%2056%208.4%2042.2%2016%2042.2m0-1.2C7.7%2041%201%2047.7%201%2056s6.7%2015%2015%2015%2015-6.7%2015-15-6.7-15-15-15z'%20id='path3854'/%3e%3cpath%20id='rect3856'%20class='st0'%20d='M15%2048h2v12h-2z'/%3e%3cpath%20id='rect3860'%20class='st0'%20d='M15%2063h2v2h-2z'/%3e%3c/g%3e%3c/svg%3e",Vn="data:image/svg+xml,%3csvg%20id='svg3363'%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%2032%2032'%20height='32'%20width='32'%3e%3cstyle%3e%20.st0{fill:%23105295}%20%3c/style%3e%3cpath%20class='st0'%20d='M16%2029.8C8.4%2029.8%202.2%2023.6%202.2%2016S8.4%202.2%2016%202.2%2029.8%208.4%2029.8%2016%2023.6%2029.8%2016%2029.8m0%201.2c8.3%200%2015-6.7%2015-15S24.3%201%2016%201%201%207.7%201%2016s6.7%2015%2015%2015z'/%3e%3cpath%20id='rect3856'%20class='st0'%20d='M15%2012h2v12h-2z'/%3e%3cpath%20id='rect3860'%20class='st0'%20d='M15%207h2v2h-2z'/%3e%3c/svg%3e",Xn="data:image/svg+xml,%3csvg%20id='Ebene_1'%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%2032%2032'%20height='32'%20width='32'%3e%3cstyle%3e%20.st0{fill:%23bf8800}%20%3c/style%3e%3cpath%20class='st0'%20d='M16%201.8l13.8%2024.7v1.6H2.3v-1.6L16%201.8zm1-.8h-2L1%2025.8v3.8h30v-3.8L17%201z'/%3e%3cpath%20class='st0'%20d='M15%2010h2v10h-2zm0%2013h2v2h-2z'/%3e%3c/svg%3e",Qn="data:image/svg+xml,%3csvg%20width='32'%20height='32'%20viewBox='0%200%2032%2032'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cpath%20d='M16%2029.8C8.4%2029.8%202.2%2023.6%202.2%2016C2.2%208.4%208.4%202.2%2016%202.2C23.6%202.2%2029.8%208.4%2029.8%2016C29.8%2023.6%2023.6%2029.8%2016%2029.8ZM16%2031C24.3%2031%2031%2024.3%2031%2016C31%207.7%2024.3%201%2016%201C7.7%201%201%207.7%201%2016C1%2024.3%207.7%2031%2016%2031Z'%20fill='%2326A642'/%3e%3cpath%20fill-rule='evenodd'%20clip-rule='evenodd'%20d='M24.4134%2010.9512L13.6667%2022.4656L7.58667%2015.9512L9.04878%2014.5866L13.6667%2019.5344L22.9513%209.58661L24.4134%2010.9512Z'%20fill='%2326A642'/%3e%3c/svg%3e",Yn={error:Kn,info:Vn,warn:Xn,success:Qn},Ze=class Ze extends Zn{set caption(f){f?this.setAttribute("caption",f):this.removeAttribute("caption")}get caption(){return this.getAttribute("caption")}set description(f){f?this.setAttribute("description",f):this.removeAttribute("description")}get description(){return this.getAttribute("description")}get level(){return this.getAttribute("level")}set level(f){f?this.setAttribute("level",f):this.setAttribute("level","info")}get iconAlt(){return this.getAttribute("icon-alt")}set iconAlt(f){f?this.setAttribute("icon-alt",f):this.removeAttribute("icon-alt")}get hiddenIcon(){return this.hasAttribute("hidden-icon")&&this.getAttribute("hidden-icon")!=="false"}set hiddenIcon(f){f?this.setAttribute("hidden-icon",""):this.removeAttribute("hidden-icon")}static get observedAttributes(){return["level","caption","description","icon-alt"]}is(){return Ze.ID}template(){const f=document.createElement("template");return f.innerHTML=Jn,f}constructor(){super(),this.updateNoCaptionStyleName=this.updateNoCaptionStyleName.bind(this)}connectedCallback(){super.connectedCallback(),this.hasAttribute("level")||(this.level="info"),this.infoImage=this.shadowRoot.querySelector("img"),this.captionElement=this.shadowRoot.querySelector(".caption"),this.descriptionElement=this.shadowRoot.querySelector(".description"),this.captionSlot=this.shadowRoot.querySelector('slot[name="caption"]'),this.captionSlot.addEventListener("slotchange",this.updateNoCaptionStyleName),this.render()}disconnectedCallback(){this.captionSlot.removeEventListener("slotchange",this.updateNoCaptionStyleName)}attributeChangedCallback(){this.render()}render(){this.updateCaption(),this.updateDescription(),this.updateIcon()}getPathToIcon(f){return Yn[f]}updateCaption(){this.captionElement&&(this.caption?this.captionElement.innerText=this.caption:this.captionElement.innerText="",this.updateNoCaptionStyleName())}updateNoCaptionStyleName(){this.caption||this.captionSlot.assignedNodes().length>0?this.classList.remove("no-caption"):this.classList.add("no-caption")}updateDescription(){this.descriptionElement&&(this.description?this.descriptionElement.innerText=this.description:this.descriptionElement.innerText="")}updateIcon(){this.infoImage&&(this.infoImage.src=this.getPathToIcon(this.level)||"",this.infoImage.alt=this.iconAlt||"")}};Ze.ID="sd-message";let Pe=Ze;var ei=(s=>(s.ERROR="error",s.WARN="warn",s.INFO="info",s.SUCCESS="success",s))(ei||{});customElements.get(Pe.ID)||customElements.define(Pe.ID,Pe);function Dr(s){return s&&s.__esModule&&Object.prototype.hasOwnProperty.call(s,"default")?s.default:s}function ti(s){if(Object.prototype.hasOwnProperty.call(s,"__esModule"))return s;var f=s.default;if(typeof f=="function"){var b=function d(){var n=!1;try{n=this instanceof d}catch{}return n?Reflect.construct(f,arguments,this.constructor):f.apply(this,arguments)};b.prototype=f.prototype}else b={};return Object.defineProperty(b,"__esModule",{value:!0}),Object.keys(s).forEach(function(d){var n=Object.getOwnPropertyDescriptor(s,d);Object.defineProperty(b,d,n.get?n:{enumerable:!0,get:function(){return s[d]}})}),b}var $e={exports:{}},lr;function ri(){if(lr)return $e.exports;lr=1;var s=String,f=function(){return{isColorSupported:!1,reset:s,bold:s,dim:s,italic:s,underline:s,inverse:s,hidden:s,strikethrough:s,black:s,red:s,green:s,yellow:s,blue:s,magenta:s,cyan:s,white:s,gray:s,bgBlack:s,bgRed:s,bgGreen:s,bgYellow:s,bgBlue:s,bgMagenta:s,bgCyan:s,bgWhite:s,blackBright:s,redBright:s,greenBright:s,yellowBright:s,blueBright:s,magentaBright:s,cyanBright:s,whiteBright:s,bgBlackBright:s,bgRedBright:s,bgGreenBright:s,bgYellowBright:s,bgBlueBright:s,bgMagentaBright:s,bgCyanBright:s,bgWhiteBright:s}};return $e.exports=f(),$e.exports.createColors=f,$e.exports}const ni={},ii=Object.freeze(Object.defineProperty({__proto__:null,default:ni},Symbol.toStringTag,{value:"Module"})),le=ti(ii);var ut,cr;function Bt(){if(cr)return ut;cr=1;let s=ri(),f=le;class b extends Error{constructor(n,h,o,g,v,c){super(n),this.name="CssSyntaxError",this.reason=n,v&&(this.file=v),g&&(this.source=g),c&&(this.plugin=c),typeof h<"u"&&typeof o<"u"&&(typeof h=="number"?(this.line=h,this.column=o):(this.line=h.line,this.column=h.column,this.endLine=o.line,this.endColumn=o.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=s.isColorSupported);let o=r=>r,g=r=>r,v=r=>r;if(n){let{bold:r,gray:l,red:u}=s.createColors(!0);g=p=>r(u(p)),o=p=>l(p),f&&(v=p=>f(p))}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,p=" "+(" "+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=o(p.replace(/\d/g," "))+r.slice(0,Math.min(this.column-1,S-1)).replace(/[^\t]/g," ");return g(">")+o(p)+v(m)+`
|
|
160
|
+
`+k+g("^")}let E=o(p.replace(/\d/g," "))+r.slice(0,this.column-1).replace(/[^\t]/g," ");return g(">")+o(p)+v(r)+`
|
|
161
|
+
`+E+g("^")}return" "+o(p)+v(r)}).join(`
|
|
162
|
+
`)}toString(){let n=this.showSourceCode();return n&&(n=`
|
|
162
163
|
|
|
163
|
-
`+
|
|
164
|
-
`),this.name+": "+this.message+
|
|
164
|
+
`+n+`
|
|
165
|
+
`),this.name+": "+this.message+n}}return ut=b,b.default=b,ut}var ht,ur;function Ur(){if(ur)return ht;ur=1;const s={after:`
|
|
165
166
|
`,beforeClose:`
|
|
166
167
|
`,beforeComment:`
|
|
167
168
|
`,beforeDecl:`
|
|
168
169
|
`,beforeOpen:" ",beforeRule:`
|
|
169
|
-
`,colon:": ",commentLeft:" ",commentRight:" ",emptyBody:"",indent:" ",semicolon:!1};function
|
|
170
|
-
`)){let
|
|
171
|
-
`)&&(
|
|
172
|
-
`)&&(
|
|
173
|
-
`)&&(
|
|
174
|
-
`)&&(
|
|
175
|
-
`);return
|
|
176
|
-
`?(
|
|
177
|
-
`);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[ct]=n}t=n[n.length-1];let r=0;if(e>=t)r=n.length-1;else{let o=n.length-2,s;for(;r<o;)if(s=r+(o-r>>1),e<n[s])o=s-1;else if(e>=n[s+1])r=s+1;else{r=s;break}}return{col:e-n[r]+1,line:r+1}}mapResolve(e){return/^\w+:\/\//.test(e)?e:vt(this.map.consumer().sourceRoot||this.map.root||".",e)}origin(e,t,n,r){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:r,line:n}));let l;wt(s.source)?l=_e(s.source):l=new URL(s.source,this.map.consumer().sourceRoot||_e(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(Qt)c.file=Qt(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 Je=De;De.default=De;lt&<.registerInput&<.registerInput(De);let{SourceMapConsumer:On,SourceMapGenerator:ze}=$,{dirname:Be,relative:An,resolve:_n,sep:kn}=$,{pathToFileURL:tn}=$,vr=Je,xr=!!(On&&ze),Er=!!(Be&&_n&&An&&kn),Sr=class{constructor(e,t,n,r){this.stringify=e,this.mapOpts=n.map||{},this.root=t,this.opts=n,this.css=r,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=`
|
|
170
|
+
`,colon:": ",commentLeft:" ",commentRight:" ",emptyBody:"",indent:" ",semicolon:!1};function f(d){return d[0].toUpperCase()+d.slice(1)}class b{constructor(n){this.builder=n}atrule(n,h){let o="@"+n.name,g=n.params?this.rawValue(n,"params"):"";if(typeof n.raws.afterName<"u"?o+=n.raws.afterName:g&&(o+=" "),n.nodes)this.block(n,o+g);else{let v=(n.raws.between||"")+(h?";":"");this.builder(o+g+v,n)}}beforeAfter(n,h){let o;n.type==="decl"?o=this.raw(n,null,"beforeDecl"):n.type==="comment"?o=this.raw(n,null,"beforeComment"):h==="before"?o=this.raw(n,null,"beforeRule"):o=this.raw(n,null,"beforeClose");let g=n.parent,v=0;for(;g&&g.type!=="root";)v+=1,g=g.parent;if(o.includes(`
|
|
171
|
+
`)){let c=this.raw(n,null,"indent");if(c.length)for(let e=0;e<v;e++)o+=c}return o}block(n,h){let o=this.raw(n,"between","beforeOpen");this.builder(h+o+"{",n,"start");let g;n.nodes&&n.nodes.length?(this.body(n),g=this.raw(n,"after")):g=this.raw(n,"after","emptyBody"),g&&this.builder(g),this.builder("}",n,"end")}body(n){let h=n.nodes.length-1;for(;h>0&&n.nodes[h].type==="comment";)h-=1;let o=this.raw(n,"semicolon");for(let g=0;g<n.nodes.length;g++){let v=n.nodes[g],c=this.raw(v,"before");c&&this.builder(c),this.stringify(v,h!==g||o)}}comment(n){let h=this.raw(n,"left","commentLeft"),o=this.raw(n,"right","commentRight");this.builder("/*"+h+n.text+o+"*/",n)}decl(n,h){let o=this.raw(n,"between","colon"),g=n.prop+o+this.rawValue(n,"value");n.important&&(g+=n.raws.important||" !important"),h&&(g+=";"),this.builder(g,n)}document(n){this.body(n)}raw(n,h,o){let g;if(o||(o=h),h&&(g=n.raws[h],typeof g<"u"))return g;let v=n.parent;if(o==="before"&&(!v||v.type==="root"&&v.first===n||v&&v.type==="document"))return"";if(!v)return s[o];let c=n.root();if(c.rawCache||(c.rawCache={}),typeof c.rawCache[o]<"u")return c.rawCache[o];if(o==="before"||o==="after")return this.beforeAfter(n,o);{let e="raw"+f(o);this[e]?g=this[e](c,n):c.walk(i=>{if(g=i.raws[h],typeof g<"u")return!1})}return typeof g>"u"&&(g=s[o]),c.rawCache[o]=g,g}rawBeforeClose(n){let h;return n.walk(o=>{if(o.nodes&&o.nodes.length>0&&typeof o.raws.after<"u")return h=o.raws.after,h.includes(`
|
|
172
|
+
`)&&(h=h.replace(/[^\n]+$/,"")),!1}),h&&(h=h.replace(/\S/g,"")),h}rawBeforeComment(n,h){let o;return n.walkComments(g=>{if(typeof g.raws.before<"u")return o=g.raws.before,o.includes(`
|
|
173
|
+
`)&&(o=o.replace(/[^\n]+$/,"")),!1}),typeof o>"u"?o=this.raw(h,null,"beforeDecl"):o&&(o=o.replace(/\S/g,"")),o}rawBeforeDecl(n,h){let o;return n.walkDecls(g=>{if(typeof g.raws.before<"u")return o=g.raws.before,o.includes(`
|
|
174
|
+
`)&&(o=o.replace(/[^\n]+$/,"")),!1}),typeof o>"u"?o=this.raw(h,null,"beforeRule"):o&&(o=o.replace(/\S/g,"")),o}rawBeforeOpen(n){let h;return n.walk(o=>{if(o.type!=="decl"&&(h=o.raws.between,typeof h<"u"))return!1}),h}rawBeforeRule(n){let h;return n.walk(o=>{if(o.nodes&&(o.parent!==n||n.first!==o)&&typeof o.raws.before<"u")return h=o.raws.before,h.includes(`
|
|
175
|
+
`)&&(h=h.replace(/[^\n]+$/,"")),!1}),h&&(h=h.replace(/\S/g,"")),h}rawColon(n){let h;return n.walkDecls(o=>{if(typeof o.raws.between<"u")return h=o.raws.between.replace(/[^\s:]/g,""),!1}),h}rawEmptyBody(n){let h;return n.walk(o=>{if(o.nodes&&o.nodes.length===0&&(h=o.raws.after,typeof h<"u"))return!1}),h}rawIndent(n){if(n.raws.indent)return n.raws.indent;let h;return n.walk(o=>{let g=o.parent;if(g&&g!==n&&g.parent&&g.parent===n&&typeof o.raws.before<"u"){let v=o.raws.before.split(`
|
|
176
|
+
`);return h=v[v.length-1],h=h.replace(/\S/g,""),!1}}),h}rawSemicolon(n){let h;return n.walk(o=>{if(o.nodes&&o.nodes.length&&o.last.type==="decl"&&(h=o.raws.semicolon,typeof h<"u"))return!1}),h}rawValue(n,h){let o=n[h],g=n.raws[h];return g&&g.value===o?g.raw:o}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 ht=b,b.default=b,ht}var ft,hr;function Je(){if(hr)return ft;hr=1;let s=Ur();function f(b,d){new s(d).stringify(b)}return ft=f,f.default=f,ft}var qe={},fr;function Dt(){return fr||(fr=1,qe.isClean=Symbol("isClean"),qe.my=Symbol("my")),qe}var dt,dr;function Ke(){if(dr)return dt;dr=1;let s=Bt(),f=Ur(),b=Je(),{isClean:d,my:n}=Dt();function h(v,c){let e=new v.constructor;for(let i in v){if(!Object.prototype.hasOwnProperty.call(v,i)||i==="proxyCache")continue;let t=v[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 o(v,c){if(c&&typeof c.offset<"u")return c.offset;let e=1,i=1,t=0;for(let r=0;r<v.length;r++){if(i===c.line&&e===c.column){t=r;break}v[r]===`
|
|
177
|
+
`?(e=1,i+=1):e+=1}return t}class g{get proxyOf(){return this}constructor(c={}){this.raws={},this[d]=!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 s(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[d]=!0}markDirty(){if(this[d]){this[d]=!1;let c=this;for(;c=c.parent;)c[d]=!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(o(i,this.source.start),o(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=o(t,this.source.start),l=r+c;for(let u=r;u<l;u++)t[u]===`
|
|
178
|
+
`?(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:o(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:o(e,this.source.end)+1}:{column:i.column+1,line:i.line,offset:i.offset+1};if(c.word){let l=e.slice(o(e,this.source.start),o(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:o(e,c.start)}:c.index&&(i=this.positionInside(c.index)),c.end?t={column:c.end.column,line:c.end.line,offset:o(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 f().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(p=>typeof p=="object"&&p.toJSON?p.toJSON(null,e):p);else if(typeof u=="object"&&u.toJSON)i[l]=u.toJSON(null,e);else if(l==="source"){if(u==null)continue;let p=e.get(u.input);p==null&&(p=r,e.set(u.input,r),r++),i[l]={end:u.end,inputId:p,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 dt=g,g.default=g,dt}var pt,pr;function Ve(){if(pr)return pt;pr=1;let s=Ke();class f extends s{constructor(d){super(d),this.type="comment"}}return pt=f,f.default=f,pt}var gt,gr;function Xe(){if(gr)return gt;gr=1;let s=Ke();class f extends s{get variable(){return this.prop.startsWith("--")||this.prop[0]==="$"}constructor(d){d&&typeof d.value<"u"&&typeof d.value!="string"&&(d={...d,value:String(d.value)}),super(d),this.type="decl"}}return gt=f,f.default=f,gt}var mt,mr;function xe(){if(mr)return mt;mr=1;let s=Ve(),f=Xe(),b=Ke(),{isClean:d,my:n}=Dt(),h,o,g,v;function c(t){return t.map(r=>(r.nodes&&(r.nodes=c(r.nodes)),delete r.source,r))}function e(t){if(t[d]=!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 p of u)this.proxyOf.nodes.push(p)}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,p;for(;this.indexes[l]<this.proxyOf.nodes.length&&(u=this.indexes[l],p=r(this.proxyOf.nodes[u],u),p!==!1);)this.indexes[l]+=1;return delete this.indexes[l],p}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(p=>typeof p=="function"?(E,S)=>p(E.toProxy(),S):p)):l==="every"||l==="some"?u=>r[l]((p,...E)=>u(p.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),p=this.normalize(l,this.proxyOf.nodes[u]).reverse();u=this.index(r);for(let S of p)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+p.length);return this.markDirty(),this}insertBefore(r,l){let u=this.index(r),p=u===0?"prepend":!1,E=this.normalize(l,this.proxyOf.nodes[u],p).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(o(r).nodes);else if(typeof r>"u")r=[];else if(Array.isArray(r)){r=r.slice(0);for(let p of r)p.parent&&p.parent.removeChild(p,"ignore")}else if(r.type==="root"&&this.type!=="document"){r=r.nodes.slice(0);for(let p of r)p.parent&&p.parent.removeChild(p,"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 f(r)]}else if(r.selector||r.selectors)r=[new v(r)];else if(r.name)r=[new h(r)];else if(r.text)r=[new s(r)];else throw new Error("Unknown node type in node creation");return r.map(p=>(p[n]||i.rebuild(p),p=p.proxyOf,p.parent&&p.parent.removeChild(p),p[d]&&e(p),p.raws||(p.raws={}),typeof p.raws.before>"u"&&l&&typeof l.raws.before<"u"&&(p.raws.before=l.raws.before.replace(/\S/g,"")),p.parent=this.proxyOf,p))}prepend(...r){r=r.reverse();for(let l of r){let u=this.normalize(l,this.first,"prepend").reverse();for(let p of u)this.proxyOf.nodes.unshift(p);for(let p in this.indexes)this.indexes[p]=this.indexes[p]+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(p=>{l.props&&!l.props.includes(p.prop)||l.fast&&!p.value.includes(l.fast)||(p.value=p.value.replace(r,u))}),this.markDirty(),this}some(r){return this.nodes.some(r)}walk(r){return this.each((l,u)=>{let p;try{p=r(l,u)}catch(E){throw l.addToError(E)}return p!==!1&&l.walk&&(p=l.walk(r)),p})}walkAtRules(r,l){return l?r instanceof RegExp?this.walk((u,p)=>{if(u.type==="atrule"&&r.test(u.name))return l(u,p)}):this.walk((u,p)=>{if(u.type==="atrule"&&u.name===r)return l(u,p)}):(l=r,this.walk((u,p)=>{if(u.type==="atrule")return l(u,p)}))}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,p)=>{if(u.type==="decl"&&r.test(u.prop))return l(u,p)}):this.walk((u,p)=>{if(u.type==="decl"&&u.prop===r)return l(u,p)}):(l=r,this.walk((u,p)=>{if(u.type==="decl")return l(u,p)}))}walkRules(r,l){return l?r instanceof RegExp?this.walk((u,p)=>{if(u.type==="rule"&&r.test(u.selector))return l(u,p)}):this.walk((u,p)=>{if(u.type==="rule"&&u.selector===r)return l(u,p)}):(l=r,this.walk((u,p)=>{if(u.type==="rule")return l(u,p)}))}}return i.registerParse=t=>{o=t},i.registerRule=t=>{v=t},i.registerAtRule=t=>{h=t},i.registerRoot=t=>{g=t},mt=i,i.default=i,i.rebuild=t=>{t.type==="atrule"?Object.setPrototypeOf(t,h.prototype):t.type==="rule"?Object.setPrototypeOf(t,v.prototype):t.type==="decl"?Object.setPrototypeOf(t,f.prototype):t.type==="comment"?Object.setPrototypeOf(t,s.prototype):t.type==="root"&&Object.setPrototypeOf(t,g.prototype),t[n]=!0,t.nodes&&t.nodes.forEach(r=>{i.rebuild(r)})},mt}var bt,br;function Ut(){if(br)return bt;br=1;let s=xe();class f extends s{constructor(d){super(d),this.type="atrule"}append(...d){return this.proxyOf.nodes||(this.nodes=[]),super.append(...d)}prepend(...d){return this.proxyOf.nodes||(this.nodes=[]),super.prepend(...d)}}return bt=f,f.default=f,s.registerAtRule(f),bt}var yt,yr;function Ft(){if(yr)return yt;yr=1;let s=xe(),f,b;class d extends s{constructor(h){super({type:"document",...h}),this.nodes||(this.nodes=[])}toResult(h={}){return new f(new b,this,h).stringify()}}return d.registerLazyResult=n=>{f=n},d.registerProcessor=n=>{b=n},yt=d,d.default=d,yt}var wt,wr;function si(){if(wr)return wt;wr=1;let s="useandom-26T198340PX75pxJACKVERYMINDBUSHWOLF_GQZbfghjklqvwyzrict";return wt={nanoid:(d=21)=>{let n="",h=d|0;for(;h--;)n+=s[Math.random()*64|0];return n},customAlphabet:(d,n=21)=>(h=n)=>{let o="",g=h|0;for(;g--;)o+=d[Math.random()*d.length|0];return o}},wt}var vt,vr;function Fr(){if(vr)return vt;vr=1;let{existsSync:s,readFileSync:f}=le,{dirname:b,join:d}=le,{SourceMapConsumer:n,SourceMapGenerator:h}=le;function o(v){return Buffer?Buffer.from(v,"base64").toString():window.atob(v)}class g{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 o(c.substr(u[0].length));let p=c.match(/data:application\/json;([^,]+),/)[1];throw new Error("Unsupported source map encoding "+p)}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),s(c))return this.mapFile=c,f(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=d(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 vt=g,g.default=g,vt}var xt,xr;function Qe(){if(xr)return xt;xr=1;let{nanoid:s}=si(),{isAbsolute:f,resolve:b}=le,{SourceMapConsumer:d,SourceMapGenerator:n}=le,{fileURLToPath:h,pathToFileURL:o}=le,g=Bt(),v=Fr(),c=le,e=Symbol("lineToIndexCache"),i=!!(d&&n),t=!!(b&&f);function r(u){if(u[e])return u[e];let p=u.css.split(`
|
|
179
|
+
`),E=new Array(p.length),S=0;for(let w=0,y=p.length;w<y;w++)E[w]=S,S+=p[w].length+1;return u[e]=E,E}class l{get from(){return this.file||this.id}constructor(p,E={}){if(p===null||typeof p>"u"||typeof p=="object"&&!p.toString)throw new Error(`PostCSS received ${p} instead of CSS string`);if(this.css=p.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)||f(E.from)?this.file=E.from:this.file=b(E.from)),t&&i){let S=new v(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 "+s(6)+">"),this.map&&(this.map.file=this.from)}error(p,E,S,w={}){let y,m,k,A,T;if(E&&typeof E=="object"){let L=E,K=S;if(typeof L.offset=="number"){A=L.offset;let q=this.fromOffset(A);E=q.line,S=q.col}else E=L.line,S=L.column,A=this.fromLineAndColumn(E,S);if(typeof K.offset=="number"){k=K.offset;let q=this.fromOffset(k);m=q.line,y=q.col}else m=K.line,y=K.column,k=this.fromLineAndColumn(K.line,K.column)}else if(S)A=this.fromLineAndColumn(E,S);else{A=E;let L=this.fromOffset(A);E=L.line,S=L.col}let U=this.origin(E,S,m,y);return U?T=new g(p,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):T=new g(p,m===void 0?E:{column:S,line:E},m===void 0?S:{column:y,line:m},this.css,this.file,w.plugin),T.input={column:S,endColumn:y,endLine:m,endOffset:k,line:E,offset:A,source:this.css},this.file&&(o&&(T.input.url=o(this.file).toString()),T.input.file=this.file),T}fromLineAndColumn(p,E){return r(this)[p-1]+E-1}fromOffset(p){let E=r(this),S=E[E.length-1],w=0;if(p>=S)w=E.length-1;else{let y=E.length-2,m;for(;w<y;)if(m=w+(y-w>>1),p<E[m])y=m-1;else if(p>=E[m+1])w=m+1;else{w=m;break}}return{col:p-E[w]+1,line:w+1}}mapResolve(p){return/^\w+:\/\//.test(p)?p:b(this.map.consumer().sourceRoot||this.map.root||".",p)}origin(p,E,S,w){if(!this.map)return!1;let y=this.map.consumer(),m=y.originalPositionFor({column:E,line:p});if(!m.source)return!1;let k;typeof S=="number"&&(k=y.originalPositionFor({column:w,line:S}));let A;f(m.source)?A=o(m.source):A=new URL(m.source,this.map.consumer().sourceRoot||o(this.map.mapFile));let T={column:m.column,endColumn:k&&k.column,endLine:k&&k.line,line:m.line,url:A.toString()};if(A.protocol==="file:")if(h)T.file=h(A);else throw new Error("file: protocol is not available in this PostCSS build");let U=y.sourceContentFor(m.source);return U&&(T.source=U),T}toJSON(){let p={};for(let E of["hasBOM","css","file","id"])this[E]!=null&&(p[E]=this[E]);return this.map&&(p.map={...this.map},p.map.consumerCache&&(p.map.consumerCache=void 0)),p}}return xt=l,l.default=l,c&&c.registerInput&&c.registerInput(l),xt}var Et,Er;function Ie(){if(Er)return Et;Er=1;let s=xe(),f,b;class d extends s{constructor(h){super(h),this.type="root",this.nodes||(this.nodes=[])}normalize(h,o,g){let v=super.normalize(h);if(o){if(g==="prepend")this.nodes.length>1?o.raws.before=this.nodes[1].raws.before:delete o.raws.before;else if(this.first!==o)for(let c of v)c.raws.before=o.raws.before}return v}removeChild(h,o){let g=this.index(h);return!o&&g===0&&this.nodes.length>1&&(this.nodes[1].raws.before=this.nodes[g].raws.before),super.removeChild(h)}toResult(h={}){return new f(new b,this,h).stringify()}}return d.registerLazyResult=n=>{f=n},d.registerProcessor=n=>{b=n},Et=d,d.default=d,s.registerRoot(d),Et}var St,Sr;function $r(){if(Sr)return St;Sr=1;let s={comma(f){return s.split(f,[","],!0)},space(f){let b=[" ",`
|
|
180
|
+
`," "];return s.split(f,b)},split(f,b,d){let n=[],h="",o=!1,g=0,v=!1,c="",e=!1;for(let i of f)e?e=!1:i==="\\"?e=!0:v?i===c&&(v=!1):i==='"'||i==="'"?(v=!0,c=i):i==="("?g+=1:i===")"?g>0&&(g-=1):g===0&&b.includes(i)&&(o=!0),o?(h!==""&&n.push(h.trim()),h="",o=!1):h+=i;return(d||h!=="")&&n.push(h.trim()),n}};return St=s,s.default=s,St}var kt,kr;function $t(){if(kr)return kt;kr=1;let s=xe(),f=$r();class b extends s{get selectors(){return f.comma(this.selector)}set selectors(n){let h=this.selector?this.selector.match(/,\s*/):null,o=h?h[0]:","+this.raw("between","beforeOpen");this.selector=n.join(o)}constructor(n){super(n),this.type="rule",this.nodes||(this.nodes=[])}}return kt=b,b.default=b,s.registerRule(b),kt}var Ct,Cr;function oi(){if(Cr)return Ct;Cr=1;let s=Ut(),f=Ve(),b=Xe(),d=Qe(),n=Fr(),h=Ie(),o=$t();function g(v,c){if(Array.isArray(v))return v.map(t=>g(t));let{inputs:e,...i}=v;if(e){c=[];for(let t of e){let r={...t,__proto__:d.prototype};r.map&&(r.map={...r.map,__proto__:n.prototype}),c.push(r)}}if(i.nodes&&(i.nodes=v.nodes.map(t=>g(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 o(i);if(i.type==="comment")return new f(i);if(i.type==="atrule")return new s(i);throw new Error("Unknown node type: "+v.type)}return Ct=g,g.default=g,Ct}var Rt,Rr;function qr(){if(Rr)return Rt;Rr=1;let{dirname:s,relative:f,resolve:b,sep:d}=le,{SourceMapConsumer:n,SourceMapGenerator:h}=le,{pathToFileURL:o}=le,g=Qe(),v=!!(n&&h),c=!!(s&&b&&f&&d);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=`
|
|
178
181
|
`;this.css.includes(`\r
|
|
179
|
-
`)&&(
|
|
180
|
-
`),this.css+=
|
|
181
|
-
`),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?(r.source=this.sourcePath(l),r.original.line=l.source.end.line,r.original.column=l.source.end.column-1,r.generated.line=e,r.generated.column=t-2,this.map.addMapping(r)):(r.source=n,r.original.line=1,r.original.column=0,r.generated.line=e,r.generated.column=t-1,this.map.addMapping(r)))}})}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?Be(this.opts.to):".";typeof this.mapOpts.annotation=="string"&&(n=Be(_n(n,this.mapOpts.annotation)));let r=An(n,e);return this.memoizedPaths.set(e,r),r}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 vr(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 r=this.usesFileUrls?this.toFileUrl(n):this.toUrl(this.path(n));this.map.setSourceContent(r,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(tn){let n=tn(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 Rn=Sr;let Cr=Ke,xt=class extends Cr{constructor(e){super(e),this.type="comment"}};var Xe=xt;xt.default=xt;let{isClean:Nn,my:Mn}=ve,Ln=Ve,In=Xe,Or=Ke,Pn,Rt,Nt,Tn;function jn(i){return i.map(e=>(e.nodes&&(e.nodes=jn(e.nodes)),delete e.source,e))}function $n(i){if(i[Nn]=!1,i.proxyOf.nodes)for(let e of i.proxyOf.nodes)$n(e)}let Z=class zn extends Or{append(...e){for(let t of e){let n=this.normalize(t,this.last);for(let r of n)this.proxyOf.nodes.push(r)}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,r;for(;this.indexes[t]<this.proxyOf.nodes.length&&(n=this.indexes[t],r=e(this.proxyOf.nodes[n],n),r!==!1);)this.indexes[t]+=1;return delete this.indexes[t],r}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(r=>typeof r=="function"?(o,s)=>r(o.toProxy(),s):r)):t==="every"||t==="some"?n=>e[t]((r,...o)=>n(r.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),r=this.normalize(t,this.proxyOf.nodes[n]).reverse();n=this.index(e);for(let s of r)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+r.length);return this.markDirty(),this}insertBefore(e,t){let n=this.index(e),r=n===0?"prepend":!1,o=this.normalize(t,this.proxyOf.nodes[n],r).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=jn(Pn(e).nodes);else if(Array.isArray(e)){e=e.slice(0);for(let r of e)r.parent&&r.parent.removeChild(r,"ignore")}else if(e.type==="root"&&this.type!=="document"){e=e.nodes.slice(0);for(let r of e)r.parent&&r.parent.removeChild(r,"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 Ln(e)]}else if(e.selector)e=[new Rt(e)];else if(e.name)e=[new Nt(e)];else if(e.text)e=[new In(e)];else throw new Error("Unknown node type in node creation");return e.map(r=>(r[Mn]||zn.rebuild(r),r=r.proxyOf,r.parent&&r.parent.removeChild(r),r[Nn]&&$n(r),typeof r.raws.before>"u"&&t&&typeof t.raws.before<"u"&&(r.raws.before=t.raws.before.replace(/\S/g,"")),r.parent=this.proxyOf,r))}prepend(...e){e=e.reverse();for(let t of e){let n=this.normalize(t,this.first,"prepend").reverse();for(let r of n)this.proxyOf.nodes.unshift(r);for(let r in this.indexes)this.indexes[r]=this.indexes[r]+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(r=>{t.props&&!t.props.includes(r.prop)||t.fast&&!r.value.includes(t.fast)||(r.value=r.value.replace(e,n))}),this.markDirty(),this}some(e){return this.nodes.some(e)}walk(e){return this.each((t,n)=>{let r;try{r=e(t,n)}catch(o){throw t.addToError(o)}return r!==!1&&t.walk&&(r=t.walk(e)),r})}walkAtRules(e,t){return t?e instanceof RegExp?this.walk((n,r)=>{if(n.type==="atrule"&&e.test(n.name))return t(n,r)}):this.walk((n,r)=>{if(n.type==="atrule"&&n.name===e)return t(n,r)}):(t=e,this.walk((n,r)=>{if(n.type==="atrule")return t(n,r)}))}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,r)=>{if(n.type==="decl"&&e.test(n.prop))return t(n,r)}):this.walk((n,r)=>{if(n.type==="decl"&&n.prop===e)return t(n,r)}):(t=e,this.walk((n,r)=>{if(n.type==="decl")return t(n,r)}))}walkRules(e,t){return t?e instanceof RegExp?this.walk((n,r)=>{if(n.type==="rule"&&e.test(n.selector))return t(n,r)}):this.walk((n,r)=>{if(n.type==="rule"&&n.selector===e)return t(n,r)}):(t=e,this.walk((n,r)=>{if(n.type==="rule")return t(n,r)}))}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=i=>{Pn=i};Z.registerRule=i=>{Rt=i};Z.registerAtRule=i=>{Nt=i};Z.registerRoot=i=>{Tn=i};var ee=Z;Z.default=Z;Z.rebuild=i=>{i.type==="atrule"?Object.setPrototypeOf(i,Nt.prototype):i.type==="rule"?Object.setPrototypeOf(i,Rt.prototype):i.type==="decl"?Object.setPrototypeOf(i,Ln.prototype):i.type==="comment"?Object.setPrototypeOf(i,In.prototype):i.type==="root"&&Object.setPrototypeOf(i,Tn.prototype),i[Mn]=!0,i.nodes&&i.nodes.forEach(e=>{Z.rebuild(e)})};let Ar=ee,Bn,Dn,pe=class extends Ar{constructor(e){super({type:"document",...e}),this.nodes||(this.nodes=[])}toResult(e={}){return new Bn(new Dn,this,e).stringify()}};pe.registerLazyResult=i=>{Bn=i};pe.registerProcessor=i=>{Dn=i};var Mt=pe;pe.default=pe;let Et=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 Un=Et;Et.default=Et;let _r=Un,St=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 _r(e,t);return this.messages.push(n),n}warnings(){return this.messages.filter(e=>e.type==="warning")}get content(){return this.css}};var Lt=St;St.default=St;const ut=39,nn=34,ke=92,rn=47,Re=10,ce=32,Ne=12,Me=9,Le=13,kr=91,Rr=93,Nr=40,Mr=41,Lr=123,Ir=125,Pr=59,Tr=42,jr=58,$r=64,Ie=/[\t\n\f\r "#'()/;[\\\]{}]/g,Pe=/[\t\n\f\r !"#'():;@[\\\]{}]|\/(?=\*)/g,zr=/.[\r\n"'(/\\]/,sn=/[\da-f]/i;var Br=function(e,t={}){let n=e.css.valueOf(),r=t.ignoreErrors,o,s,a,l,c,h,b,g,_,R,T=n.length,m=0,F=[],H=[];function V(){return m}function j(z){throw e.error("Unclosed "+z,m)}function W(){return H.length===0&&m>=T}function le(z){if(H.length)return H.pop();if(m>=T)return;let L=z?z.ignoreUnclosed:!1;switch(o=n.charCodeAt(m),o){case Re:case ce:case Me:case Le:case Ne:{s=m;do s+=1,o=n.charCodeAt(s);while(o===ce||o===Re||o===Me||o===Le||o===Ne);R=["space",n.slice(m,s)],m=s-1;break}case kr:case Rr:case Lr:case Ir:case jr:case Pr:case Mr:{let J=String.fromCharCode(o);R=[J,J,m];break}case Nr:{if(g=F.length?F.pop()[1]:"",_=n.charCodeAt(m+1),g==="url"&&_!==ut&&_!==nn&&_!==ce&&_!==Re&&_!==Me&&_!==Ne&&_!==Le){s=m;do{if(h=!1,s=n.indexOf(")",s+1),s===-1)if(r||L){s=m;break}else j("bracket");for(b=s;n.charCodeAt(b-1)===ke;)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||zr.test(l)?R=["(","(",m]:(R=["brackets",l,m,s],m=s);break}case ut:case nn:{a=o===ut?"'":'"',s=m;do{if(h=!1,s=n.indexOf(a,s+1),s===-1)if(r||L){s=m+1;break}else j("string");for(b=s;n.charCodeAt(b-1)===ke;)b-=1,h=!h}while(h);R=["string",n.slice(m,s+1),m,s],m=s;break}case $r:{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 ke:{for(s=m,c=!0;n.charCodeAt(s+1)===ke;)s+=1,c=!c;if(o=n.charCodeAt(s+1),c&&o!==rn&&o!==ce&&o!==Re&&o!==Me&&o!==Le&&o!==Ne&&(s+=1,sn.test(n.charAt(s)))){for(;sn.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===rn&&n.charCodeAt(m+1)===Tr?(s=n.indexOf("*/",m+2)+1,s===0&&(r||L?s=n.length:j("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(z){H.push(z)}return{back:ne,endOfFile:W,nextToken:le,position:V}};let Fn=ee,Ue=class extends Fn{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 It=Ue;Ue.default=Ue;Fn.registerAtRule(Ue);let Hn=ee,Wn,Gn,re=class extends Hn{constructor(e){super(e),this.type="root",this.nodes||(this.nodes=[])}normalize(e,t,n){let r=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 r)o.raws.before=t.raws.before}return r}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 Wn(new Gn,this,e).stringify()}};re.registerLazyResult=i=>{Wn=i};re.registerProcessor=i=>{Gn=i};var xe=re;re.default=re;Hn.registerRoot(re);let ge={comma(i){return ge.split(i,[","],!0)},space(i){let e=[" ",`
|
|
182
|
-
`," "];return ge.split(i,e)},split(i,e,t){let n=[],r="",o=!1,s=0,a=!1,l="",c=!1;for(let h of i)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?(r!==""&&n.push(r.trim()),r="",o=!1):r+=h;return(t||r!=="")&&n.push(r.trim()),n}};var Zn=ge;ge.default=ge;let qn=ee,Dr=Zn,Fe=class extends qn{constructor(e){super(e),this.type="rule",this.nodes||(this.nodes=[])}get selectors(){return Dr.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 Pt=Fe;Fe.default=Fe;qn.registerRule(Fe);let Ur=Ve,Fr=Br,Hr=Xe,Wr=It,Gr=xe,on=Pt;const an={empty:!0,space:!0};function Zr(i){for(let e=i.length-1;e>=0;e--){let t=i[e],n=t[3]||t[2];if(n)return n}}let qr=class{constructor(e){this.input=e,this.root=new Gr,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 Wr;t.name=e[1].slice(1),t.name===""&&this.unnamedAtrule(t,e),this.init(t,e[2]);let n,r,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,r=l[o];r&&r[0]==="space";)r=l[--o];r&&(t.source.end=this.getPosition(r[3]||r[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,r;for(let o=t-1;o>=0&&(r=e[o],!(r[0]!=="space"&&(n+=1,n===2)));o--);throw this.input.error("Missed semicolon",r[0]==="word"?r[3]+1:r[2])}colon(e){let t=0,n,r,o;for(let[s,a]of e.entries()){if(n=a,r=n[0],r==="("&&(t+=1),r===")"&&(t-=1),t===0&&r===":")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 Hr;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 r=n.match(/^(\s*)([^]*\S)(\s*)$/);t.text=r[2],t.raws.left=r[1],t.raws.right=r[3]}}createTokenizer(){this.tokenizer=Fr(this.input)}decl(e,t){let n=new Ur;this.init(n,e[0][2]);let r=e[e.length-1];for(r[0]===";"&&(this.semicolon=!0,e.pop()),n.source.end=this.getPosition(r[3]||r[2]||Zr(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 _=h[g][0];if(b.trim().indexOf("!")===0&&_!=="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 on;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,r=!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&&r&&n==="{")o||(o=c),s.push("}");else if(s.length===0)if(n===";")if(r){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===":"&&(r=!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&&r){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,r){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&&!r?c=!1:s==="comment"?(b=n[g-1]?n[g-1][0]:"empty",h=n[g+1]?n[g+1][0]:"empty",!an[b]&&!an[h]?l.slice(-1)===","?c=!1:l+=o[1]:c=!1):l+=o[1];if(!c){let g=n.reduce((_,R)=>_+R[1],"");e.raws[t]={raw:g,value:l}}e[t]=l}rule(e){e.pop();let t=new on;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 r=t;r<e.length;r++)n+=e[r][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 Kr=qr;let Vr=ee,Jr=Kr,Xr=Je;function He(i,e){let t=new Xr(i,e),n=new Jr(t);try{n.parse()}catch(r){throw r}return n.root}var Tt=He;He.default=He;Vr.registerParse(He);let{isClean:U,my:Qr}=ve,Yr=Rn,es=qe,ts=ee,ns=Mt,ln=Lt,is=Tt,rs=xe;const ss={atrule:"AtRule",comment:"Comment",decl:"Declaration",document:"Document",root:"Root",rule:"Rule"},os={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},as={Once:!0,postcssPlugin:!0,prepare:!0},se=0;function ue(i){return typeof i=="object"&&typeof i.then=="function"}function Kn(i){let e=!1,t=ss[i.type];return i.type==="decl"?e=i.prop.toLowerCase():i.type==="atrule"&&(e=i.name.toLowerCase()),e&&i.append?[t,t+"-"+e,se,t+"Exit",t+"Exit-"+e]:e?[t,t+"-"+e,t+"Exit",t+"Exit-"+e]:i.append?[t,se,t+"Exit"]:[t,t+"Exit"]}function cn(i){let e;return i.type==="document"?e=["Document",se,"DocumentExit"]:i.type==="root"?e=["Root",se,"RootExit"]:e=Kn(i),{eventIndex:0,events:e,iterator:0,node:i,visitorIndex:0,visitors:[]}}function Ct(i){return i[U]=!1,i.nodes&&i.nodes.forEach(e=>Ct(e)),i}let Ot={},oe=class Vn{constructor(e,t,n){this.stringified=!1,this.processed=!1;let r;if(typeof t=="object"&&t!==null&&(t.type==="root"||t.type==="document"))r=Ct(t);else if(t instanceof Vn||t instanceof ln)r=Ct(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=is;n.syntax&&(o=n.syntax.parse),n.parser&&(o=n.parser),o.parse&&(o=o.parse);try{r=o(t,n)}catch(s){this.processed=!0,this.error=s}r&&!r[Qr]&&ts.rebuild(r)}this.result=new ln(e,r,n),this.helpers={...Ot,postcss:Ot,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(r){console&&console.error&&console.error(r)}return e}prepareVisitors(){this.listeners={};let e=(t,n,r)=>{this.listeners[n]||(this.listeners[n]=[]),this.listeners[n].push([t,r])};for(let t of this.plugins)if(typeof t=="object")for(let n in t){if(!os[n]&&/^[A-Z]/.test(n))throw new Error(`Unknown event ${n} in ${t.postcssPlugin}. Try to update PostCSS (${this.processor.version} now).`);if(!as[n])if(typeof t[n]=="object")for(let r in t[n])r==="*"?e(t,n,t[n][r]):e(t,n+"-"+r.toLowerCase(),t[n][r]);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(r){throw this.handleError(r)}}if(this.prepareVisitors(),this.hasListener){let e=this.result.root;for(;!e[U];){e[U]=!0;let t=[cn(e)];for(;t.length>0;){let n=this.visitTick(t);if(ue(n))try{await n}catch(r){let o=t[t.length-1].node;throw this.handleError(r,o)}}}if(this.listeners.OnceExit)for(let[t,n]of this.listeners.OnceExit){this.result.lastPlugin=t;try{if(e.type==="document"){let r=e.nodes.map(o=>n(o,this.helpers));await Promise.all(r)}else await n(e,this.helpers)}catch(r){throw this.handleError(r)}}}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=es;e.syntax&&(t=e.syntax.stringify),e.stringifier&&(t=e.stringifier),t.stringify&&(t=t.stringify);let r=new Yr(t,this.result.root,this.result.opts).generate();return this.result.css=r[0],this.result.map=r[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[U];)e[U]=!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,r]of e){this.result.lastPlugin=n;let o;try{o=r(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:r}=t;if(n.type!=="root"&&n.type!=="document"&&!n.parent){e.pop();return}if(r.length>0&&t.visitorIndex<r.length){let[s,a]=r[t.visitorIndex];t.visitorIndex+=1,t.visitorIndex===r.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[U]){a[U]=!0,e.push(cn(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[U]=!0,t.iterator=n.getIterator());return}else if(this.listeners[s]){t.visitors=this.listeners[s];return}}e.pop()}walkSync(e){e[U]=!0;let t=Kn(e);for(let n of t)if(n===se)e.nodes&&e.each(r=>{r[U]||this.walkSync(r)});else{let r=this.listeners[n];if(r&&this.visitSync(r,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=i=>{Ot=i};var Jn=oe;oe.default=oe;rs.registerLazyResult(oe);ns.registerLazyResult(oe);let ls=Rn,cs=qe,us=Tt;const hs=Lt;let At=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 r,o=cs;this.result=new hs(this._processor,r,this._opts),this.result.css=t;let s=this;Object.defineProperty(this.result,"root",{get(){return s.root}});let a=new ls(o,r,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=us;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 fs=At;At.default=At;let ds=fs,ps=Jn,gs=Mt,ms=xe,me=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 ds(this,e,t):new ps(this,e,t)}use(e){return this.plugins=this.plugins.concat(this.normalize([e])),this}};var bs=me;me.default=me;ms.registerProcessor(me);gs.registerProcessor(me);let ys=Ve,ws=Cn,vs=Xe,xs=It,Es=Je,Ss=xe,Cs=Pt;function be(i,e){if(Array.isArray(i))return i.map(r=>be(r));let{inputs:t,...n}=i;if(t){e=[];for(let r of t){let o={...r,__proto__:Es.prototype};o.map&&(o.map={...o.map,__proto__:ws.prototype}),e.push(o)}}if(n.nodes&&(n.nodes=i.nodes.map(r=>be(r,e))),n.source){let{inputId:r,...o}=n.source;n.source=o,r!=null&&(n.source.input=e[r])}if(n.type==="root")return new Ss(n);if(n.type==="decl")return new ys(n);if(n.type==="rule")return new Cs(n);if(n.type==="comment")return new vs(n);if(n.type==="atrule")return new xs(n);throw new Error("Unknown node type: "+i.type)}var Os=be;be.default=be;var un={};let As=kt,Xn=Ve,_s=Jn,ks=ee,jt=bs,Rs=qe,Ns=Os,Qn=Mt,Ms=Un,Yn=Xe,ei=It,Ls=Lt,Is=Je,Ps=Tt,Ts=Zn,ti=Pt,ni=xe,js=Ke;function E(...i){return i.length===1&&Array.isArray(i[0])&&(i=i[0]),new jt(i)}E.plugin=function(e,t){let n=!1;function r(...s){console&&console.warn&&!n&&(n=!0,console.warn(e+`: postcss.plugin was deprecated. Migration guide:
|
|
183
|
-
https://evilmartians.com/chronicles/postcss-8-plugin-migration`),un.LANG&&un.LANG.startsWith("cn")&&console.warn(e+`: 里面 postcss.plugin 被弃用. 迁移指南:
|
|
184
|
-
https://www.w3ctech.com/topic/2226`));let a=t(...s);return a.postcssPlugin=e,a.postcssVersion=new jt().version,a}let o;return Object.defineProperty(r,"postcss",{get(){return o||(o=r()),o}}),r.process=function(s,a,l){return E([r(l)]).process(s,a)},r};E.stringify=Rs;E.parse=Ps;E.fromJSON=Ns;E.list=Ts;E.comment=i=>new Yn(i);E.atRule=i=>new ei(i);E.decl=i=>new Xn(i);E.rule=i=>new ti(i);E.root=i=>new ni(i);E.document=i=>new Qn(i);E.CssSyntaxError=As;E.Declaration=Xn;E.Container=ks;E.Processor=jt;E.Document=Qn;E.Comment=Yn;E.Warning=Ms;E.AtRule=ei;E.Result=Ls;E.Input=Is;E.Rule=ti;E.Root=ni;E.Node=js;_s.registerPostcss(E);var $s=E;E.default=E;const A=vn($s);A.stringify;A.fromJSON;A.plugin;A.parse;A.list;A.document;A.comment;A.atRule;A.rule;A.decl;A.root;A.CssSyntaxError;A.Declaration;A.Container;A.Processor;A.Document;A.Comment;A.Warning;A.AtRule;A.Result;A.Input;A.Rule;A.Root;A.Node;var zs=function(e){const t=e.prefix,n=/\s+$/.test(t)?t:`${t} `,r=e.ignoreFiles?[].concat(e.ignoreFiles):[],o=e.includeFiles?[].concat(e.includeFiles):[];return function(s){r.length&&s.source.input.file&&hn(s.source.input.file,r)||o.length&&s.source.input.file&&!hn(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&&Bs(c,e.exclude)?c:e.transform?e.transform(t,c,n+c,s.source.input.file,a):n+c))})}};function hn(i,e){return e.some(t=>t instanceof RegExp?t.test(i):i.includes(t))}function Bs(i,e){return e.some(t=>t instanceof RegExp?t.test(i):i===t)}const Ds=vn(zs),Us="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}",Fs="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 Hs(i){return i&&i.__esModule&&Object.prototype.hasOwnProperty.call(i,"default")?i.default:i}function ii(i){return i instanceof Map?i.clear=i.delete=i.set=function(){throw new Error("map is read-only")}:i instanceof Set&&(i.add=i.clear=i.delete=function(){throw new Error("set is read-only")}),Object.freeze(i),Object.getOwnPropertyNames(i).forEach(e=>{const t=i[e],n=typeof t;(n==="object"||n==="function")&&!Object.isFrozen(t)&&ii(t)}),i}class fn{constructor(e){e.data===void 0&&(e.data={}),this.data=e.data,this.isMatchIgnored=!1}ignoreMatch(){this.isMatchIgnored=!0}}function ri(i){return i.replace(/&/g,"&").replace(/</g,"<").replace(/>/g,">").replace(/"/g,""").replace(/'/g,"'")}function K(i,...e){const t=Object.create(null);for(const n in i)t[n]=i[n];return e.forEach(function(n){for(const r in n)t[r]=n[r]}),t}const Ws="</span>",dn=i=>!!i.scope,Gs=(i,{prefix:e})=>{if(i.startsWith("language:"))return i.replace("language:","language-");if(i.includes(".")){const t=i.split(".");return[`${e}${t.shift()}`,...t.map((n,r)=>`${n}${"_".repeat(r+1)}`)].join(" ")}return`${e}${i}`};class Zs{constructor(e,t){this.buffer="",this.classPrefix=t.classPrefix,e.walk(this)}addText(e){this.buffer+=ri(e)}openNode(e){if(!dn(e))return;const t=Gs(e.scope,{prefix:this.classPrefix});this.span(t)}closeNode(e){dn(e)&&(this.buffer+=Ws)}value(){return this.buffer}span(e){this.buffer+=`<span class="${e}">`}}const pn=(i={})=>{const e={children:[]};return Object.assign(e,i),e};class $t{constructor(){this.rootNode=pn(),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=pn({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=>{$t._collapse(t)}))}}class qs extends $t{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 Zs(this,this.options).value()}finalize(){return this.closeAllNodes(),!0}}function ye(i){return i?typeof i=="string"?i:i.source:null}function si(i){return te("(?=",i,")")}function Ks(i){return te("(?:",i,")*")}function Vs(i){return te("(?:",i,")?")}function te(...i){return i.map(e=>ye(e)).join("")}function Js(i){const e=i[i.length-1];return typeof e=="object"&&e.constructor===Object?(i.splice(i.length-1,1),e):{}}function zt(...i){return"("+(Js(i).capture?"":"?:")+i.map(e=>ye(e)).join("|")+")"}function oi(i){return new RegExp(i.toString()+"|").exec("").length-1}function Xs(i,e){const t=i&&i.exec(e);return t&&t.index===0}const Qs=/\[(?:[^\\\]]|\\.)*\]|\(\??|\\([1-9][0-9]*)|\\./;function Bt(i,{joinWith:e}){let t=0;return i.map(n=>{t+=1;const r=t;let o=ye(n),s="";for(;o.length>0;){const a=Qs.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])+r):(s+=a[0],a[0]==="("&&t++)}return s}).map(n=>`(${n})`).join(e)}const Ys=/\b\B/,ai="[a-zA-Z]\\w*",Dt="[a-zA-Z_]\\w*",li="\\b\\d+(\\.\\d+)?",ci="(-?)(\\b0[xX][a-fA-F0-9]+|(\\b\\d+(\\.\\d*)?|\\.\\d+)([eE][-+]?\\d+)?)",ui="\\b(0b[01]+)",eo="!|!=|!==|%|%=|&|&&|&=|\\*|\\*=|\\+|\\+=|,|-|-=|/=|/|:|;|<<|<<=|<=|<|===|==|=|>>>=|>>=|>=|>>>|>>|>|\\?|\\[|\\{|\\(|\\^|\\^=|\\||\\|=|\\|\\||~",to=(i={})=>{const e=/^#![ ]*\//;return i.binary&&(i.begin=te(e,/.*\b/,i.binary,/\b.*/)),K({scope:"meta",begin:e,end:/$/,relevance:0,"on:begin":(t,n)=>{t.index!==0&&n.ignoreMatch()}},i)},we={begin:"\\\\[\\s\\S]",relevance:0},no={scope:"string",begin:"'",end:"'",illegal:"\\n",contains:[we]},io={scope:"string",begin:'"',end:'"',illegal:"\\n",contains:[we]},ro={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/},Qe=function(i,e,t={}){const n=K({scope:"comment",begin:i,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 r=zt("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(/[ ]+/,"(",r,/[.]?[:]?([.][ ]|[ ])/,"){3}")}),n},so=Qe("//","$"),oo=Qe("/\\*","\\*/"),ao=Qe("#","$"),lo={scope:"number",begin:li,relevance:0},co={scope:"number",begin:ci,relevance:0},uo={scope:"number",begin:ui,relevance:0},ho={scope:"regexp",begin:/\/(?=[^/\n]*\/)/,end:/\/[gimuy]*/,contains:[we,{begin:/\[/,end:/\]/,relevance:0,contains:[we]}]},fo={scope:"title",begin:ai,relevance:0},po={scope:"title",begin:Dt,relevance:0},go={begin:"\\.\\s*"+Dt,relevance:0},mo=function(i){return Object.assign(i,{"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:no,BACKSLASH_ESCAPE:we,BINARY_NUMBER_MODE:uo,BINARY_NUMBER_RE:ui,COMMENT:Qe,C_BLOCK_COMMENT_MODE:oo,C_LINE_COMMENT_MODE:so,C_NUMBER_MODE:co,C_NUMBER_RE:ci,END_SAME_AS_BEGIN:mo,HASH_COMMENT_MODE:ao,IDENT_RE:ai,MATCH_NOTHING_RE:Ys,METHOD_GUARD:go,NUMBER_MODE:lo,NUMBER_RE:li,PHRASAL_WORDS_MODE:ro,QUOTE_STRING_MODE:io,REGEXP_MODE:ho,RE_STARTERS_RE:eo,SHEBANG:to,TITLE_MODE:fo,UNDERSCORE_IDENT_RE:Dt,UNDERSCORE_TITLE_MODE:po});function bo(i,e){i.input[i.index-1]==="."&&e.ignoreMatch()}function yo(i,e){i.className!==void 0&&(i.scope=i.className,delete i.className)}function wo(i,e){e&&i.beginKeywords&&(i.begin="\\b("+i.beginKeywords.split(" ").join("|")+")(?!\\.)(?=\\b|\\s)",i.__beforeBegin=bo,i.keywords=i.keywords||i.beginKeywords,delete i.beginKeywords,i.relevance===void 0&&(i.relevance=0))}function vo(i,e){Array.isArray(i.illegal)&&(i.illegal=zt(...i.illegal))}function xo(i,e){if(i.match){if(i.begin||i.end)throw new Error("begin & end are not supported with match");i.begin=i.match,delete i.match}}function Eo(i,e){i.relevance===void 0&&(i.relevance=1)}const So=(i,e)=>{if(!i.beforeMatch)return;if(i.starts)throw new Error("beforeMatch cannot be used with starts");const t=Object.assign({},i);Object.keys(i).forEach(n=>{delete i[n]}),i.keywords=t.keywords,i.begin=te(t.beforeMatch,si(t.begin)),i.starts={relevance:0,contains:[Object.assign(t,{endsParent:!0})]},i.relevance=0,delete t.beforeMatch},Co=["of","and","for","in","not","or","if","then","parent","list","value"],Oo="keyword";function hi(i,e,t=Oo){const n=Object.create(null);return typeof i=="string"?r(t,i.split(" ")):Array.isArray(i)?r(t,i):Object.keys(i).forEach(function(o){Object.assign(n,hi(i[o],e,o))}),n;function r(o,s){e&&(s=s.map(a=>a.toLowerCase())),s.forEach(function(a){const l=a.split("|");n[l[0]]=[o,Ao(l[0],l[1])]})}}function Ao(i,e){return e?Number(e):_o(i)?0:1}function _o(i){return Co.includes(i.toLowerCase())}const gn={},Y=i=>{console.error(i)},mn=(i,...e)=>{console.log(`WARN: ${i}`,...e)},ie=(i,e)=>{gn[`${i}/${e}`]||(console.log(`Deprecated as of ${i}. ${e}`),gn[`${i}/${e}`]=!0)},We=new Error;function fi(i,e,{key:t}){let n=0;const r=i[t],o={},s={};for(let a=1;a<=e.length;a++)s[a+n]=r[a],o[a+n]=!0,n+=oi(e[a-1]);i[t]=s,i[t]._emit=o,i[t]._multi=!0}function ko(i){if(Array.isArray(i.begin)){if(i.skip||i.excludeBegin||i.returnBegin)throw Y("skip, excludeBegin, returnBegin not compatible with beginScope: {}"),We;if(typeof i.beginScope!="object"||i.beginScope===null)throw Y("beginScope must be object"),We;fi(i,i.begin,{key:"beginScope"}),i.begin=Bt(i.begin,{joinWith:""})}}function Ro(i){if(Array.isArray(i.end)){if(i.skip||i.excludeEnd||i.returnEnd)throw Y("skip, excludeEnd, returnEnd not compatible with endScope: {}"),We;if(typeof i.endScope!="object"||i.endScope===null)throw Y("endScope must be object"),We;fi(i,i.end,{key:"endScope"}),i.end=Bt(i.end,{joinWith:""})}}function No(i){i.scope&&typeof i.scope=="object"&&i.scope!==null&&(i.beginScope=i.scope,delete i.scope)}function Mo(i){No(i),typeof i.beginScope=="string"&&(i.beginScope={_wrap:i.beginScope}),typeof i.endScope=="string"&&(i.endScope={_wrap:i.endScope}),ko(i),Ro(i)}function Lo(i){function e(s,a){return new RegExp(ye(s),"m"+(i.case_insensitive?"i":"")+(i.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+=oi(a)+1}compile(){this.regexes.length===0&&(this.exec=()=>null);const a=this.regexes.map(l=>l[1]);this.matcherRe=e(Bt(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 r(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;[yo,xo,Mo,So].forEach(h=>h(s,a)),i.compilerExtensions.forEach(h=>h(s,a)),s.__beforeBegin=null,[wo,vo,Eo].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=hi(s.keywords,i.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=ye(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 Io(h==="self"?s:h)})),s.contains.forEach(function(h){o(h,l)}),s.starts&&o(s.starts,a),l.matcher=r(l),l}if(i.compilerExtensions||(i.compilerExtensions=[]),i.contains&&i.contains.includes("self"))throw new Error("ERR: contains `self` is not supported at the top-level of a language. See documentation.");return i.classNameAliases=K(i.classNameAliases||{}),o(i)}function di(i){return i?i.endsWithParent||di(i.starts):!1}function Io(i){return i.variants&&!i.cachedVariants&&(i.cachedVariants=i.variants.map(function(e){return K(i,{variants:null},e)})),i.cachedVariants?i.cachedVariants:di(i)?K(i,{starts:i.starts?K(i.starts):null}):Object.isFrozen(i)?K(i):i}var Po="11.9.0";class To extends Error{constructor(e,t){super(e),this.name="HTMLInjectionError",this.html=t}}const ht=ri,bn=K,yn=Symbol("nomatch"),jo=7,pi=function(i){const e=Object.create(null),t=Object.create(null),n=[];let r=!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:qs};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 x=L(w[1]);return x||(mn(o.replace("{}",w[1])),mn("Falling back to no-highlight mode for this block.",u)),x?w[1]:"no-highlight"}return d.split(/\s+/).find(x=>l(x)||L(x))}function h(u,d,w){let x="",k="";typeof d=="object"?(x=u,w=d.ignoreIllegals,k=d.language):(ie("10.7.0","highlight(lang, code, ...args) has been deprecated."),ie("10.7.0",`Please use highlight(code, options) instead.
|
|
185
|
-
https://github.com/highlightjs/highlight.js/issues/2277`),k=u,x=d),w===void 0&&(w=!0);const I={code:x,language:k};X("before:highlight",I);const q=I.result?I.result:b(I.language,I.code,w);return q.code=I.code,X("after:highlight",q),q}function b(u,d,w,x){const k=Object.create(null);function I(f,p){return f.keywords[p]}function q(){if(!y.keywords){N.addText(C);return}let f=0;y.keywordPatternRe.lastIndex=0;let p=y.keywordPatternRe.exec(C),v="";for(;p;){v+=C.substring(f,p.index);const S=D.case_insensitive?p[0].toLowerCase():p[0],M=I(y,S);if(M){const[G,ki]=M;if(N.addText(v),v="",k[S]=(k[S]||0)+1,k[S]<=jo&&(Oe+=ki),G.startsWith("_"))v+=p[0];else{const Ri=D.classNameAliases[G]||G;B(p[0],Ri)}}else v+=p[0];f=y.keywordPatternRe.lastIndex,p=y.keywordPatternRe.exec(C)}v+=C.substring(f),N.addText(v)}function Se(){if(C==="")return;let f=null;if(typeof y.subLanguage=="string"){if(!e[y.subLanguage]){N.addText(C);return}f=b(y.subLanguage,C,!0,Gt[y.subLanguage]),Gt[y.subLanguage]=f._top}else f=_(C,y.subLanguage.length?y.subLanguage:null);y.relevance>0&&(Oe+=f.relevance),N.__addSublanguage(f._emitter,f.language)}function P(){y.subLanguage!=null?Se():q(),C=""}function B(f,p){f!==""&&(N.startScope(p),N.addText(f),N.endScope())}function Ut(f,p){let v=1;const S=p.length-1;for(;v<=S;){if(!f._emit[v]){v++;continue}const M=D.classNameAliases[f[v]]||f[v],G=p[v];M?B(G,M):(C=G,q(),C=""),v++}}function Ft(f,p){return f.scope&&typeof f.scope=="string"&&N.openNode(D.classNameAliases[f.scope]||f.scope),f.beginScope&&(f.beginScope._wrap?(B(C,D.classNameAliases[f.beginScope._wrap]||f.beginScope._wrap),C=""):f.beginScope._multi&&(Ut(f.beginScope,p),C="")),y=Object.create(f,{parent:{value:y}}),y}function Ht(f,p,v){let S=Xs(f.endRe,v);if(S){if(f["on:end"]){const M=new fn(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 Ht(f.parent,p,v)}function Si(f){return y.matcher.regexIndex===0?(C+=f[0],1):(ot=!0,0)}function Ci(f){const p=f[0],v=f.rule,S=new fn(v),M=[v.__beforeBegin,v["on:begin"]];for(const G of M)if(G&&(G(f,S),S.isMatchIgnored))return Si(p);return v.skip?C+=p:(v.excludeBegin&&(C+=p),P(),!v.returnBegin&&!v.excludeBegin&&(C=p)),Ft(v,f),v.returnBegin?0:p.length}function Oi(f){const p=f[0],v=d.substring(f.index),S=Ht(y,f,v);if(!S)return yn;const M=y;y.endScope&&y.endScope._wrap?(P(),B(p,y.endScope._wrap)):y.endScope&&y.endScope._multi?(P(),Ut(y.endScope,f)):M.skip?C+=p:(M.returnEnd||M.excludeEnd||(C+=p),P(),M.excludeEnd&&(C=p));do y.scope&&N.closeNode(),!y.skip&&!y.subLanguage&&(Oe+=y.relevance),y=y.parent;while(y!==S.parent);return S.starts&&Ft(S.starts,f),M.returnEnd?0:p.length}function Ai(){const f=[];for(let p=y;p!==D;p=p.parent)p.scope&&f.unshift(p.scope);f.forEach(p=>N.openNode(p))}let Ce={};function Wt(f,p){const v=p&&p[0];if(C+=f,v==null)return P(),0;if(Ce.type==="begin"&&p.type==="end"&&Ce.index===p.index&&v===""){if(C+=d.slice(p.index,p.index+1),!r){const S=new Error(`0 width match regex (${u})`);throw S.languageName=u,S.badRule=Ce.rule,S}return 1}if(Ce=p,p.type==="begin")return Ci(p);if(p.type==="illegal"&&!w){const S=new Error('Illegal lexeme "'+v+'" for mode "'+(y.scope||"<unnamed>")+'"');throw S.mode=y,S}else if(p.type==="end"){const S=Oi(p);if(S!==yn)return S}if(p.type==="illegal"&&v==="")return 1;if(st>1e5&&st>p.index*3)throw new Error("potential infinite loop, way more iterations than matches");return C+=v,v.length}const D=L(u);if(!D)throw Y(o.replace("{}",u)),new Error('Unknown language: "'+u+'"');const _i=Lo(D);let rt="",y=x||_i;const Gt={},N=new a.__emitter(a);Ai();let C="",Oe=0,Q=0,st=0,ot=!1;try{if(D.__emitTokens)D.__emitTokens(d,N);else{for(y.matcher.considerAll();;){st++,ot?ot=!1:y.matcher.considerAll(),y.matcher.lastIndex=Q;const f=y.matcher.exec(d);if(!f)break;const p=d.substring(Q,f.index),v=Wt(p,f);Q=f.index+v}Wt(d.substring(Q))}return N.finalize(),rt=N.toHTML(),{language:u,value:rt,relevance:Oe,illegal:!1,_emitter:N,_top:y}}catch(f){if(f.message&&f.message.includes("Illegal"))return{language:u,value:ht(d),illegal:!0,relevance:0,_illegalBy:{message:f.message,index:Q,context:d.slice(Q-100,Q+100),mode:f.mode,resultSoFar:rt},_emitter:N};if(r)return{language:u,value:ht(d),illegal:!1,relevance:0,errorRaised:f,_emitter:N,_top:y};throw f}}function g(u){const d={value:ht(u),illegal:!1,relevance:0,_top:s,_emitter:new a.__emitter(a)};return d._emitter.addText(u),d}function _(u,d){d=d||a.languages||Object.keys(e);const w=g(u),x=d.filter(L).filter(Ee).map(P=>b(P,u,!1));x.unshift(w);const k=x.sort((P,B)=>{if(P.relevance!==B.relevance)return B.relevance-P.relevance;if(P.language&&B.language){if(L(P.language).supersetOf===B.language)return 1;if(L(B.language).supersetOf===P.language)return-1}return 0}),[I,q]=k,Se=I;return Se.secondBest=q,Se}function R(u,d,w){const x=d&&t[d]||w;u.classList.add("hljs"),u.classList.add(`language-${x}`)}function T(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 To("One of your code blocks includes unescaped HTML.",u.innerHTML);d=u;const x=d.textContent,k=w?h(x,{language:w,ignoreIllegals:!0}):_(x);u.innerHTML=k.value,u.dataset.highlighted="yes",R(u,w,k.language),u.result={language:k.language,re:k.relevance,relevance:k.relevance},k.secondBest&&(u.secondBest={language:k.secondBest.language,relevance:k.secondBest.relevance}),X("after:highlightElement",{el:u,result:k,text:x})}function m(u){a=bn(a,u)}const F=()=>{j(),ie("10.6.0","initHighlighting() deprecated. Use highlightAll() now.")};function H(){j(),ie("10.6.0","initHighlightingOnLoad() deprecated. Use highlightAll() now.")}let V=!1;function j(){if(document.readyState==="loading"){V=!0;return}document.querySelectorAll(a.cssSelector).forEach(T)}function W(){V&&j()}typeof window<"u"&&window.addEventListener&&window.addEventListener("DOMContentLoaded",W,!1);function le(u,d){let w=null;try{w=d(i)}catch(x){if(Y("Language definition for '{}' could not be registered.".replace("{}",u)),r)Y(x);else throw x;w=s}w.name||(w.name=u),e[u]=w,w.rawDefinition=d.bind(null,i),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 z(){return Object.keys(e)}function L(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 Ee(u){const d=L(u);return d&&!d.disableAutodetect}function et(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 tt(u){et(u),n.push(u)}function nt(u){const d=n.indexOf(u);d!==-1&&n.splice(d,1)}function X(u,d){const w=u;n.forEach(function(x){x[w]&&x[w](d)})}function it(u){return ie("10.7.0","highlightBlock will be removed entirely in v12.0"),ie("10.7.0","Please use highlightElement now."),T(u)}Object.assign(i,{highlight:h,highlightAuto:_,highlightAll:j,highlightElement:T,highlightBlock:it,configure:m,initHighlighting:F,initHighlightingOnLoad:H,registerLanguage:le,unregisterLanguage:ne,listLanguages:z,getLanguage:L,registerAliases:J,autoDetection:Ee,inherit:bn,addPlugin:tt,removePlugin:nt}),i.debugMode=function(){r=!1},i.safeMode=function(){r=!0},i.versionString=Po,i.regex={concat:te,lookahead:si,either:zt,optional:Vs,anyNumberOfTimes:Ks};for(const u in Te)typeof Te[u]=="object"&&ii(Te[u]);return Object.assign(i,Te),i},ae=pi({});ae.newInstance=()=>pi({});var $o=ae;ae.HighlightJS=ae;ae.default=ae;const Ye=Hs($o),Ge="[A-Za-z$_][0-9A-Za-z$_]*",gi=["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"],mi=["true","false","null","undefined","NaN","Infinity"],bi=["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"],yi=["Error","EvalError","InternalError","RangeError","ReferenceError","SyntaxError","TypeError","URIError"],wi=["setInterval","setTimeout","clearInterval","clearTimeout","require","exports","eval","isFinite","isNaN","parseFloat","parseInt","decodeURI","decodeURIComponent","encodeURI","encodeURIComponent","escape","unescape"],vi=["arguments","this","super","console","window","document","localStorage","sessionStorage","module","global"],xi=[].concat(wi,bi,yi);function zo(i){const e=i.regex,t=(u,{after:d})=>{const w="</"+u[0].slice(1);return u.input.indexOf(w,d)!==-1},n=Ge,r={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,x=u.input[w];if(x==="<"||x===","){d.ignoreMatch();return}x===">"&&(t(u,{after:w})||d.ignoreMatch());let k;const I=u.input.substring(w);if(k=I.match(/^\s*=/)){d.ignoreMatch();return}if((k=I.match(/^\s+extends\s+/))&&k.index===0){d.ignoreMatch();return}}},a={$pattern:Ge,keyword:gi,literal:mi,built_in:xi,"variable.language":vi},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:[]},_={begin:"html`",end:"",starts:{end:"`",returnEnd:!1,contains:[i.BACKSLASH_ESCAPE,g],subLanguage:"xml"}},R={begin:"css`",end:"",starts:{end:"`",returnEnd:!1,contains:[i.BACKSLASH_ESCAPE,g],subLanguage:"css"}},T={begin:"gql`",end:"",starts:{end:"`",returnEnd:!1,contains:[i.BACKSLASH_ESCAPE,g],subLanguage:"graphql"}},m={className:"string",begin:"`",end:"`",contains:[i.BACKSLASH_ESCAPE,g]},F={className:"comment",variants:[i.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}]}]}),i.C_BLOCK_COMMENT_MODE,i.C_LINE_COMMENT_MODE]},H=[i.APOS_STRING_MODE,i.QUOTE_STRING_MODE,_,R,T,m,{match:/\$\d+/},b];g.contains=H.concat({begin:/\{/,end:/\}/,keywords:a,contains:["self"].concat(H)});const V=[].concat(F,g.contains),j=V.concat([{begin:/\(/,end:/\)/,keywords:a,contains:["self"].concat(V)}]),W={className:"params",begin:/\(/,end:/\)/,excludeBegin:!0,excludeEnd:!0,keywords:a,contains:j},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:{_:[...bi,...yi]}},z={label:"use_strict",className:"meta",relevance:10,begin:/^\s*['"]use (strict|asm)['"]/},L={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 Ee(u){return e.concat("(?!",u.join("|"),")")}const et={match:e.concat(/\b/,Ee([...wi,"super","import"]),n,e.lookahead(/\(/)),className:"title.function",relevance:0},tt={begin:e.concat(/\./,e.lookahead(e.concat(n,/(?![0-9A-Za-z$_(])/))),end:n,excludeBegin:!0,keywords:"prototype",className:"property",relevance:0},nt={match:[/get|set/,/\s+/,n,/(?=\()/],className:{1:"keyword",3:"title.function"},contains:[{begin:/\(\)/},W]},X="(\\([^()]*(\\([^()]*(\\([^()]*\\)[^()]*)*\\)[^()]*)*\\)|"+i.UNDERSCORE_IDENT_RE+")\\s*=>",it={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:j,CLASS_REFERENCE:ne},illegal:/#(?![$_A-z])/,contains:[i.SHEBANG({label:"shebang",binary:"node",relevance:5}),z,i.APOS_STRING_MODE,i.QUOTE_STRING_MODE,_,R,T,m,F,{match:/\$\d+/},b,ne,{className:"attr",begin:n+e.lookahead(":"),relevance:0},it,{begin:"("+i.RE_STARTERS_RE+"|\\b(case|return|throw)\\b)\\s*",keywords:"return throw case",relevance:0,contains:[F,i.REGEXP_MODE,{className:"function",begin:X,returnBegin:!0,end:"\\s*=>",contains:[{className:"params",variants:[{begin:i.UNDERSCORE_IDENT_RE,relevance:0},{className:null,begin:/\(\s*\)/,skip:!0},{begin:/\(/,end:/\)/,excludeBegin:!0,excludeEnd:!0,keywords:a,contains:j}]}]},{begin:/,/,relevance:0},{match:/\s+/,relevance:0},{variants:[{begin:r.begin,end:r.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"]}]}]},L,{beginKeywords:"while if switch catch for"},{begin:"\\b(?!function)"+i.UNDERSCORE_IDENT_RE+"\\([^()]*(\\([^()]*(\\([^()]*\\)[^()]*)*\\)[^()]*)*\\)\\s*\\{",returnBegin:!0,label:"func.def",contains:[W,i.inherit(i.TITLE_MODE,{begin:n,className:"title.function"})]},{match:/\.\.\./,relevance:0},tt,{match:"\\$"+n,relevance:0},{match:[/\bconstructor(?=\s*\()/],className:{1:"title.function"},contains:[W]},et,J,le,nt,{match:/\$[(.]/}]}}function Bo(i){const e=zo(i),t=Ge,n=["any","void","number","boolean","string","object","never","symbol","bigint","unknown"],r={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:Ge,keyword:gi.concat(a),literal:mi,built_in:xi.concat(n),"variable.language":vi},c={className:"meta",begin:"@"+t},h=(g,_,R)=>{const T=g.contains.findIndex(m=>m.label===_);if(T===-1)throw new Error("can not find mode to replace");g.contains.splice(T,1,R)};Object.assign(e.keywords,l),e.exports.PARAMS_CONTAINS.push(c),e.contains=e.contains.concat([c,r,o]),h(e,"shebang",i.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 Do(i){const e=i.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,r={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=i.inherit(o,{begin:/\(/,end:/\)/}),a=i.inherit(i.APOS_STRING_MODE,{className:"string"}),l=i.inherit(i.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:[r]},{begin:/'/,end:/'/,contains:[r]},{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]}]}]},i.COMMENT(/<!--/,/-->/,{relevance:10}),{begin:/<!\[CDATA\[/,end:/\]\]>/,relevance:10},r,{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 Uo=i=>({IMPORTANT:{scope:"meta",begin:"!important"},BLOCK_COMMENT:i.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:[i.APOS_STRING_MODE,i.QUOTE_STRING_MODE]},CSS_NUMBER_MODE:{scope:"number",begin:i.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_-]*/}}),Fo=["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"],Ho=["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"],Wo=["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"],Go=["after","backdrop","before","cue","cue-region","first-letter","first-line","grammar-error","marker","part","placeholder","selection","slotted","spelling-error"],Zo=["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 qo(i){const e=i.regex,t=Uo(i),n={begin:/-(webkit|moz|ms|o)-(?=[a-z])/},r="and or not only",o=/@-?\w[\w]*(-\w+)*/,s="[a-zA-Z-][a-zA-Z0-9_-]*",a=[i.APOS_STRING_MODE,i.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:":("+Wo.join("|")+")"},{begin:":(:)?("+Go.join("|")+")"}]},t.CSS_VARIABLE,{className:"attribute",begin:"\\b("+Zo.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:r,attribute:Ho.join(" ")},contains:[{begin:/[a-z-]+(?=:)/,className:"attribute"},...a,t.CSS_NUMBER_MODE]}]},{className:"selector-tag",begin:"\\b("+Fo.join("|")+")\\b"}]}}const Ei=document.createElement("style");Ei.innerText=[Us,Fs].join(`
|
|
186
|
-
`);document.head.appendChild(
|
|
187
|
-
`).trim();return
|
|
182
|
+
`)&&(r=`\r
|
|
183
|
+
`),this.css+=r+"/*# sourceMappingURL="+t+" */"}applyPrevMaps(){for(let t of this.previous()){let r=this.toUrl(this.path(t.file)),l=t.root||s(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&&v&&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:""},p,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,p=S.lastIndexOf(`
|
|
184
|
+
`),r=S.length-p):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?s(this.opts.to):".";typeof this.mapOpts.annotation=="string"&&(l=s(b(l,this.mapOpts.annotation)));let u=f(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 g(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(o){let l=o(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;d==="\\"&&(t=t.replace(/\\/g,"/"));let l=encodeURI(t).replace(/[#?]/g,encodeURIComponent);return this.memoizedURLs.set(t,l),l}}return Rt=e,Rt}var Ot,Or;function ai(){if(Or)return Ot;Or=1;const s=39,f=34,b=92,d=47,n=10,h=32,o=12,g=9,v=13,c=91,e=93,i=40,t=41,r=123,l=125,u=59,p=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 Ot=function(T,U={}){let L=T.css.valueOf(),K=U.ignoreErrors,q,be,ae,N,Ee,H,Q,ie,se,de,ye=L.length,z=0,Oe=[],Se=[];function et(){return z}function Ae(pe){throw T.error("Unclosed "+pe,z)}function tt(){return Se.length===0&&z>=ye}function ke(pe){if(Se.length)return Se.pop();if(z>=ye)return;let _e=pe?pe.ignoreUnclosed:!1;switch(q=L.charCodeAt(z),q){case n:case h:case g:case v:case o:{N=z;do N+=1,q=L.charCodeAt(N);while(q===h||q===n||q===g||q===v||q===o);H=["space",L.slice(z,N)],z=N-1;break}case c:case e:case r:case l:case E:case u:case t:{let Te=String.fromCharCode(q);H=[Te,Te,z];break}case i:{if(de=Oe.length?Oe.pop()[1]:"",se=L.charCodeAt(z+1),de==="url"&&se!==s&&se!==f&&se!==h&&se!==n&&se!==g&&se!==o&&se!==v){N=z;do{if(Q=!1,N=L.indexOf(")",N+1),N===-1)if(K||_e){N=z;break}else Ae("bracket");for(ie=N;L.charCodeAt(ie-1)===b;)ie-=1,Q=!Q}while(Q);H=["brackets",L.slice(z,N+1),z,N],z=N}else N=L.indexOf(")",z+1),be=L.slice(z,N+1),N===-1||m.test(be)?H=["(","(",z]:(H=["brackets",be,z,N],z=N);break}case s:case f:{Ee=q===s?"'":'"',N=z;do{if(Q=!1,N=L.indexOf(Ee,N+1),N===-1)if(K||_e){N=z+1;break}else Ae("string");for(ie=N;L.charCodeAt(ie-1)===b;)ie-=1,Q=!Q}while(Q);H=["string",L.slice(z,N+1),z,N],z=N;break}case S:{w.lastIndex=z+1,w.test(L),w.lastIndex===0?N=L.length-1:N=w.lastIndex-2,H=["at-word",L.slice(z,N+1),z,N],z=N;break}case b:{for(N=z,ae=!0;L.charCodeAt(N+1)===b;)N+=1,ae=!ae;if(q=L.charCodeAt(N+1),ae&&q!==d&&q!==h&&q!==n&&q!==g&&q!==v&&q!==o&&(N+=1,k.test(L.charAt(N)))){for(;k.test(L.charAt(N+1));)N+=1;L.charCodeAt(N+1)===h&&(N+=1)}H=["word",L.slice(z,N+1),z,N],z=N;break}default:{q===d&&L.charCodeAt(z+1)===p?(N=L.indexOf("*/",z+2)+1,N===0&&(K||_e?N=L.length:Ae("comment")),H=["comment",L.slice(z,N+1),z,N],z=N):(y.lastIndex=z+1,y.test(L),y.lastIndex===0?N=L.length-1:N=y.lastIndex-2,H=["word",L.slice(z,N+1),z,N],Oe.push(H),z=N);break}}return z++,H}function rt(pe){Se.push(pe)}return{back:rt,endOfFile:tt,nextToken:ke,position:et}},Ot}var At,Ar;function li(){if(Ar)return At;Ar=1;let s=Ut(),f=Ve(),b=Xe(),d=Ie(),n=$t(),h=ai();const o={empty:!0,space:!0};function g(c){for(let e=c.length-1;e>=0;e--){let i=c[e],t=i[3]||i[2];if(t)return t}}class v{constructor(e){this.input=e,this.root=new d,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 s;i.name=e[1].slice(1),i.name===""&&this.unnamedAtrule(i,e),this.init(i,e[2]);let t,r,l,u=!1,p=!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==="{"){p=!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=""),p&&(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,p]of e.entries()){if(r=p,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 f;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]||g(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=[],p;for(;e.length&&(p=e[0][0],!(p!=="space"&&p!=="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=[],p=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(p&&r&&t==="{")l||(l=S),u.push("}");else if(u.length===0)if(t===";")if(r){this.decl(E,p);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(!p)for(;E.length&&(S=E[E.length-1][0],!(S!=="space"&&S!=="comment"));)this.tokenizer.back(E.pop());this.decl(E,p)}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,p=t.length,E="",S=!0,w,y;for(let m=0;m<p;m+=1)l=t[m],u=l[0],u==="space"&&m===p-1&&!r?S=!1:u==="comment"?(y=t[m-1]?t[m-1][0]:"empty",w=t[m+1]?t[m+1][0]:"empty",!o[y]&&!o[w]?E.slice(-1)===","?S=!1:E+=l[1]:S=!1):E+=l[1];if(!S){let m=t.reduce((k,A)=>k+A[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 At=v,At}var _t,_r;function qt(){if(_r)return _t;_r=1;let s=xe(),f=Qe(),b=li();function d(n,h){let o=new f(n,h),g=new b(o);try{g.parse()}catch(v){throw v}return g.root}return _t=d,d.default=d,s.registerParse(d),_t}var Nt,Nr;function Wr(){if(Nr)return Nt;Nr=1;class s{constructor(b,d={}){if(this.type="warning",this.text=b,d.node&&d.node.source){let n=d.node.rangeBy(d);this.line=n.start.line,this.column=n.start.column,this.endLine=n.end.line,this.endColumn=n.end.column}for(let n in d)this[n]=d[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 Nt=s,s.default=s,Nt}var Mt,Mr;function Wt(){if(Mr)return Mt;Mr=1;let s=Wr();class f{get content(){return this.css}constructor(d,n,h){this.processor=d,this.messages=[],this.root=n,this.opts=h,this.css="",this.map=void 0}toString(){return this.css}warn(d,n={}){n.plugin||this.lastPlugin&&this.lastPlugin.postcssPlugin&&(n.plugin=this.lastPlugin.postcssPlugin);let h=new s(d,n);return this.messages.push(h),h}warnings(){return this.messages.filter(d=>d.type==="warning")}}return Mt=f,f.default=f,Mt}var Pt,Pr;function Hr(){if(Pr)return Pt;Pr=1;let s=xe(),f=Ft(),b=qr(),d=qt(),n=Wt(),h=Ie(),o=Je(),{isClean:g,my:v}=Dt();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 p(w){return w[g]=!1,w.nodes&&w.nodes.forEach(y=>p(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 A;if(typeof m=="object"&&m!==null&&(m.type==="root"||m.type==="document"))A=p(m);else if(m instanceof S||m instanceof n)A=p(m.root),m.map&&(typeof k.map>"u"&&(k.map={}),k.map.inline||(k.map.inline=!1),k.map.prev=m.map);else{let T=d;k.syntax&&(T=k.syntax.parse),k.parser&&(T=k.parser),T.parse&&(T=T.parse);try{A=T(m,k)}catch(U){this.processed=!0,this.error=U}A&&!A[v]&&s.rebuild(A)}this.result=new n(y,A,k),this.helpers={...E,postcss:E,result:this.result},this.plugins=this.processor.plugins.map(T=>typeof T=="object"&&T.prepare?{...T,...T.prepare(this.result)}:T)}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(A){console&&console.error&&console.error(A)}return y}prepareVisitors(){this.listeners={};let y=(m,k,A)=>{this.listeners[k]||(this.listeners[k]=[]),this.listeners[k].push([m,A])};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 A in m[k])A==="*"?y(m,k,m[k][A]):y(m,k+"-"+A.toLowerCase(),m[k][A]);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(A){throw this.handleError(A)}}if(this.prepareVisitors(),this.hasListener){let y=this.result.root;for(;!y[g];){y[g]=!0;let m=[u(y)];for(;m.length>0;){let k=this.visitTick(m);if(r(k))try{await k}catch(A){let T=m[m.length-1].node;throw this.handleError(A,T)}}}if(this.listeners.OnceExit)for(let[m,k]of this.listeners.OnceExit){this.result.lastPlugin=m;try{if(y.type==="document"){let A=y.nodes.map(T=>k(T,this.helpers));await Promise.all(A)}else await k(y,this.helpers)}catch(A){throw this.handleError(A)}}}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=o;y.syntax&&(m=y.syntax.stringify),y.stringifier&&(m=y.stringifier),m.stringify&&(m=m.stringify);let A=new b(m,this.result.root,this.result.opts).generate();return this.result.css=A[0],this.result.map=A[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[g];)y[g]=!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,A]of y){this.result.lastPlugin=k;let T;try{T=A(m,this.helpers)}catch(U){throw this.handleError(U,m.proxyOf)}if(m.type!=="root"&&m.type!=="document"&&!m.parent)return!0;if(r(T))throw this.getAsyncError()}}visitTick(y){let m=y[y.length-1],{node:k,visitors:A}=m;if(k.type!=="root"&&k.type!=="document"&&!k.parent){y.pop();return}if(A.length>0&&m.visitorIndex<A.length){let[U,L]=A[m.visitorIndex];m.visitorIndex+=1,m.visitorIndex===A.length&&(m.visitors=[],m.visitorIndex=0),this.result.lastPlugin=U;try{return L(k.toProxy(),this.helpers)}catch(K){throw this.handleError(K,k)}}if(m.iterator!==0){let U=m.iterator,L;for(;L=k.nodes[k.indexes[U]];)if(k.indexes[U]+=1,!L[g]){L[g]=!0,y.push(u(L));return}m.iterator=0,delete k.indexes[U]}let T=m.events;for(;m.eventIndex<T.length;){let U=T[m.eventIndex];if(m.eventIndex+=1,U===t){k.nodes&&k.nodes.length&&(k[g]=!0,m.iterator=k.getIterator());return}else if(this.listeners[U]){m.visitors=this.listeners[U];return}}y.pop()}walkSync(y){y[g]=!0;let m=l(y);for(let k of m)if(k===t)y.nodes&&y.each(A=>{A[g]||this.walkSync(A)});else{let A=this.listeners[k];if(A&&this.visitSync(A,y.toProxy()))return}}warnings(){return this.sync().warnings()}}return S.registerPostcss=w=>{E=w},Pt=S,S.default=S,h.registerLazyResult(S),f.registerLazyResult(S),Pt}var Lt,Lr;function ci(){if(Lr)return Lt;Lr=1;let s=qr(),f=qt();const b=Wt();let d=Je();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 o,g=f;try{o=g(this._css,this._opts)}catch(v){this.error=v}if(this.error)throw this.error;return this._root=o,o}get[Symbol.toStringTag](){return"NoWorkResult"}constructor(o,g,v){g=g.toString(),this.stringified=!1,this._processor=o,this._css=g,this._opts=v,this._map=void 0;let c,e=d;this.result=new b(this._processor,c,this._opts),this.result.css=g;let i=this;Object.defineProperty(this.result,"root",{get(){return i.root}});let t=new s(e,c,this._opts,g);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(o){return this.async().catch(o)}finally(o){return this.async().then(o,o)}sync(){if(this.error)throw this.error;return this.result}then(o,g){return this.async().then(o,g)}toString(){return this._css}warnings(){return[]}}return Lt=n,n.default=n,Lt}var It,Ir;function ui(){if(Ir)return It;Ir=1;let s=Ft(),f=Hr(),b=ci(),d=Ie();class n{constructor(o=[]){this.version="8.5.6",this.plugins=this.normalize(o)}normalize(o){let g=[];for(let v of o)if(v.postcss===!0?v=v():v.postcss&&(v=v.postcss),typeof v=="object"&&Array.isArray(v.plugins))g=g.concat(v.plugins);else if(typeof v=="object"&&v.postcssPlugin)g.push(v);else if(typeof v=="function")g.push(v);else if(!(typeof v=="object"&&(v.parse||v.stringify)))throw new Error(v+" is not a PostCSS plugin");return g}process(o,g={}){return!this.plugins.length&&!g.parser&&!g.stringifier&&!g.syntax?new b(this,o,g):new f(this,o,g)}use(o){return this.plugins=this.plugins.concat(this.normalize([o])),this}}return It=n,n.default=n,d.registerProcessor(n),s.registerProcessor(n),It}var Tt,Tr;function hi(){if(Tr)return Tt;Tr=1;var s={};let f=Ut(),b=Ve(),d=xe(),n=Bt(),h=Xe(),o=Ft(),g=oi(),v=Qe(),c=Hr(),e=$r(),i=Ke(),t=qt(),r=ui(),l=Wt(),u=Ie(),p=$t(),E=Je(),S=Wr();function w(...y){return y.length===1&&Array.isArray(y[0])&&(y=y[0]),new r(y)}return w.plugin=function(m,k){let A=!1;function T(...L){console&&console.warn&&!A&&(A=!0,console.warn(m+`: postcss.plugin was deprecated. Migration guide:
|
|
185
|
+
https://evilmartians.com/chronicles/postcss-8-plugin-migration`),s.LANG&&s.LANG.startsWith("cn")&&console.warn(m+`: 里面 postcss.plugin 被弃用. 迁移指南:
|
|
186
|
+
https://www.w3ctech.com/topic/2226`));let K=k(...L);return K.postcssPlugin=m,K.postcssVersion=new r().version,K}let U;return Object.defineProperty(T,"postcss",{get(){return U||(U=T()),U}}),T.process=function(L,K,q){return w([T(q)]).process(L,K)},T},w.stringify=E,w.parse=t,w.fromJSON=g,w.list=e,w.comment=y=>new b(y),w.atRule=y=>new f(y),w.decl=y=>new h(y),w.rule=y=>new p(y),w.root=y=>new u(y),w.document=y=>new o(y),w.CssSyntaxError=n,w.Declaration=h,w.Container=d,w.Processor=r,w.Document=o,w.Comment=b,w.Warning=S,w.AtRule=f,w.Result=l,w.Input=v,w.Rule=p,w.Root=u,w.Node=i,c.registerPostcss(w),Tt=w,w.default=w,Tt}var fi=hi();const J=Dr(fi);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 jt,jr;function di(){if(jr)return jt;jr=1;const s=(d={})=>{const n=d.prefix,h=/\s+$/.test(n)?n:`${n} `,o=d.ignoreFiles?[].concat(d.ignoreFiles):[],g=d.includeFiles?[].concat(d.includeFiles):[];return{postcssPlugin:"postcss-prefix-selector",prepare(v){const c=v.root,e=c.source.input.file;if(!(o.length&&e&&f(e,o))&&!(g.length&&e&&!f(e,g)))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=>d.exclude&&b(l,d.exclude)?l:d.transform?d.transform(n,l,h+l,c.source.input.file,i):[":root","body","html"].some(u=>l.startsWith(u))?d.skipGlobalSelectors?l:l.replace(/(html\s+body|:root\s+body|html|:root|body)/gm,n):h+l))}}}}};function f(d,n){return n.some(h=>h instanceof RegExp?h.test(d):d.includes(h))}function b(d,n){return n.some(h=>h instanceof RegExp?h.test(d):d===h)}return s.postcss=!0,jt=s,jt}var pi=di();const gi=Dr(pi),mi="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}",bi="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 yi(s){return s&&s.__esModule&&Object.prototype.hasOwnProperty.call(s,"default")?s.default:s}var zt,zr;function wi(){if(zr)return zt;zr=1;function s(a){return a instanceof Map?a.clear=a.delete=a.set=function(){throw new Error("map is read-only")}:a instanceof Set&&(a.add=a.clear=a.delete=function(){throw new Error("set is read-only")}),Object.freeze(a),Object.getOwnPropertyNames(a).forEach(x=>{const O=a[x],D=typeof O;(D==="object"||D==="function")&&!Object.isFrozen(O)&&s(O)}),a}class f{constructor(x){x.data===void 0&&(x.data={}),this.data=x.data,this.isMatchIgnored=!1}ignoreMatch(){this.isMatchIgnored=!0}}function b(a){return a.replace(/&/g,"&").replace(/</g,"<").replace(/>/g,">").replace(/"/g,""").replace(/'/g,"'")}function d(a,...x){const O=Object.create(null);for(const D in a)O[D]=a[D];return x.forEach(function(D){for(const V in D)O[V]=D[V]}),O}const n="</span>",h=a=>!!a.scope,o=(a,{prefix:x})=>{if(a.startsWith("language:"))return a.replace("language:","language-");if(a.includes(".")){const O=a.split(".");return[`${x}${O.shift()}`,...O.map((D,V)=>`${D}${"_".repeat(V+1)}`)].join(" ")}return`${x}${a}`};class g{constructor(x,O){this.buffer="",this.classPrefix=O.classPrefix,x.walk(this)}addText(x){this.buffer+=b(x)}openNode(x){if(!h(x))return;const O=o(x.scope,{prefix:this.classPrefix});this.span(O)}closeNode(x){h(x)&&(this.buffer+=n)}value(){return this.buffer}span(x){this.buffer+=`<span class="${x}">`}}const v=(a={})=>{const x={children:[]};return Object.assign(x,a),x};class c{constructor(){this.rootNode=v(),this.stack=[this.rootNode]}get top(){return this.stack[this.stack.length-1]}get root(){return this.rootNode}add(x){this.top.children.push(x)}openNode(x){const O=v({scope:x});this.add(O),this.stack.push(O)}closeNode(){if(this.stack.length>1)return this.stack.pop()}closeAllNodes(){for(;this.closeNode(););}toJSON(){return JSON.stringify(this.rootNode,null,4)}walk(x){return this.constructor._walk(x,this.rootNode)}static _walk(x,O){return typeof O=="string"?x.addText(O):O.children&&(x.openNode(O),O.children.forEach(D=>this._walk(x,D)),x.closeNode(O)),x}static _collapse(x){typeof x!="string"&&x.children&&(x.children.every(O=>typeof O=="string")?x.children=[x.children.join("")]:x.children.forEach(O=>{c._collapse(O)}))}}class e extends c{constructor(x){super(),this.options=x}addText(x){x!==""&&this.add(x)}startScope(x){this.openNode(x)}endScope(){this.closeNode()}__addSublanguage(x,O){const D=x.root;O&&(D.scope=`language:${O}`),this.add(D)}toHTML(){return new g(this,this.options).value()}finalize(){return this.closeAllNodes(),!0}}function i(a){return a?typeof a=="string"?a:a.source:null}function t(a){return u("(?=",a,")")}function r(a){return u("(?:",a,")*")}function l(a){return u("(?:",a,")?")}function u(...a){return a.map(x=>i(x)).join("")}function p(a){const x=a[a.length-1];return typeof x=="object"&&x.constructor===Object?(a.splice(a.length-1,1),x):{}}function E(...a){return"("+(p(a).capture?"":"?:")+a.map(x=>i(x)).join("|")+")"}function S(a){return new RegExp(a.toString()+"|").exec("").length-1}function w(a,x){const O=a&&a.exec(x);return O&&O.index===0}const y=/\[(?:[^\\\]]|\\.)*\]|\(\??|\\([1-9][0-9]*)|\\./;function m(a,{joinWith:x}){let O=0;return a.map(D=>{O+=1;const V=O;let X=i(D),M="";for(;X.length>0;){const _=y.exec(X);if(!_){M+=X;break}M+=X.substring(0,_.index),X=X.substring(_.index+_[0].length),_[0][0]==="\\"&&_[1]?M+="\\"+String(Number(_[1])+V):(M+=_[0],_[0]==="("&&O++)}return M}).map(D=>`(${D})`).join(x)}const k=/\b\B/,A="[a-zA-Z]\\w*",T="[a-zA-Z_]\\w*",U="\\b\\d+(\\.\\d+)?",L="(-?)(\\b0[xX][a-fA-F0-9]+|(\\b\\d+(\\.\\d*)?|\\.\\d+)([eE][-+]?\\d+)?)",K="\\b(0b[01]+)",q="!|!=|!==|%|%=|&|&&|&=|\\*|\\*=|\\+|\\+=|,|-|-=|/=|/|:|;|<<|<<=|<=|<|===|==|=|>>>=|>>=|>=|>>>|>>|>|\\?|\\[|\\{|\\(|\\^|\\^=|\\||\\|=|\\|\\||~",be=(a={})=>{const x=/^#![ ]*\//;return a.binary&&(a.begin=u(x,/.*\b/,a.binary,/\b.*/)),d({scope:"meta",begin:x,end:/$/,relevance:0,"on:begin":(O,D)=>{O.index!==0&&D.ignoreMatch()}},a)},ae={begin:"\\\\[\\s\\S]",relevance:0},N={scope:"string",begin:"'",end:"'",illegal:"\\n",contains:[ae]},Ee={scope:"string",begin:'"',end:'"',illegal:"\\n",contains:[ae]},H={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(a,x,O={}){const D=d({scope:"comment",begin:a,end:x,contains:[]},O);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},z={scope:"number",begin:L,relevance:0},Oe={scope:"number",begin:K,relevance:0},Se={scope:"regexp",begin:/\/(?=[^/\n]*\/)/,end:/\/[gimuy]*/,contains:[ae,{begin:/\[/,end:/\]/,relevance:0,contains:[ae]}]},et={scope:"title",begin:A,relevance:0},Ae={scope:"title",begin:T,relevance:0},tt={begin:"\\.\\s*"+T,relevance:0};var ke=Object.freeze({__proto__:null,APOS_STRING_MODE:N,BACKSLASH_ESCAPE:ae,BINARY_NUMBER_MODE:Oe,BINARY_NUMBER_RE:K,COMMENT:Q,C_BLOCK_COMMENT_MODE:se,C_LINE_COMMENT_MODE:ie,C_NUMBER_MODE:z,C_NUMBER_RE:L,END_SAME_AS_BEGIN:function(a){return Object.assign(a,{"on:begin":(x,O)=>{O.data._beginMatch=x[1]},"on:end":(x,O)=>{O.data._beginMatch!==x[1]&&O.ignoreMatch()}})},HASH_COMMENT_MODE:de,IDENT_RE:A,MATCH_NOTHING_RE:k,METHOD_GUARD:tt,NUMBER_MODE:ye,NUMBER_RE:U,PHRASAL_WORDS_MODE:H,QUOTE_STRING_MODE:Ee,REGEXP_MODE:Se,RE_STARTERS_RE:q,SHEBANG:be,TITLE_MODE:et,UNDERSCORE_IDENT_RE:T,UNDERSCORE_TITLE_MODE:Ae});function rt(a,x){a.input[a.index-1]==="."&&x.ignoreMatch()}function pe(a,x){a.className!==void 0&&(a.scope=a.className,delete a.className)}function _e(a,x){x&&a.beginKeywords&&(a.begin="\\b("+a.beginKeywords.split(" ").join("|")+")(?!\\.)(?=\\b|\\s)",a.__beforeBegin=rt,a.keywords=a.keywords||a.beginKeywords,delete a.beginKeywords,a.relevance===void 0&&(a.relevance=0))}function Te(a,x){Array.isArray(a.illegal)&&(a.illegal=E(...a.illegal))}function en(a,x){if(a.match){if(a.begin||a.end)throw new Error("begin & end are not supported with match");a.begin=a.match,delete a.match}}function tn(a,x){a.relevance===void 0&&(a.relevance=1)}const rn=(a,x)=>{if(!a.beforeMatch)return;if(a.starts)throw new Error("beforeMatch cannot be used with starts");const O=Object.assign({},a);Object.keys(a).forEach(D=>{delete a[D]}),a.keywords=O.keywords,a.begin=u(O.beforeMatch,t(O.begin)),a.starts={relevance:0,contains:[Object.assign(O,{endsParent:!0})]},a.relevance=0,delete O.beforeMatch},nn=["of","and","for","in","not","or","if","then","parent","list","value"],sn="keyword";function Ht(a,x,O=sn){const D=Object.create(null);return typeof a=="string"?V(O,a.split(" ")):Array.isArray(a)?V(O,a):Object.keys(a).forEach(function(X){Object.assign(D,Ht(a[X],x,X))}),D;function V(X,M){x&&(M=M.map(_=>_.toLowerCase())),M.forEach(function(_){const j=_.split("|");D[j[0]]=[X,on(j[0],j[1])]})}}function on(a,x){return x?Number(x):an(a)?0:1}function an(a){return nn.includes(a.toLowerCase())}const Gt={},we=a=>{console.error(a)},Zt=(a,...x)=>{console.log(`WARN: ${a}`,...x)},Ce=(a,x)=>{Gt[`${a}/${x}`]||(console.log(`Deprecated as of ${a}. ${x}`),Gt[`${a}/${x}`]=!0)},je=new Error;function Jt(a,x,{key:O}){let D=0;const V=a[O],X={},M={};for(let _=1;_<=x.length;_++)M[_+D]=V[_],X[_+D]=!0,D+=S(x[_-1]);a[O]=M,a[O]._emit=X,a[O]._multi=!0}function ln(a){if(Array.isArray(a.begin)){if(a.skip||a.excludeBegin||a.returnBegin)throw we("skip, excludeBegin, returnBegin not compatible with beginScope: {}"),je;if(typeof a.beginScope!="object"||a.beginScope===null)throw we("beginScope must be object"),je;Jt(a,a.begin,{key:"beginScope"}),a.begin=m(a.begin,{joinWith:""})}}function cn(a){if(Array.isArray(a.end)){if(a.skip||a.excludeEnd||a.returnEnd)throw we("skip, excludeEnd, returnEnd not compatible with endScope: {}"),je;if(typeof a.endScope!="object"||a.endScope===null)throw we("endScope must be object"),je;Jt(a,a.end,{key:"endScope"}),a.end=m(a.end,{joinWith:""})}}function un(a){a.scope&&typeof a.scope=="object"&&a.scope!==null&&(a.beginScope=a.scope,delete a.scope)}function hn(a){un(a),typeof a.beginScope=="string"&&(a.beginScope={_wrap:a.beginScope}),typeof a.endScope=="string"&&(a.endScope={_wrap:a.endScope}),ln(a),cn(a)}function fn(a){function x(M,_){return new RegExp(i(M),"m"+(a.case_insensitive?"i":"")+(a.unicodeRegex?"u":"")+(_?"g":""))}class O{constructor(){this.matchIndexes={},this.regexes=[],this.matchAt=1,this.position=0}addRule(_,j){j.position=this.position++,this.matchIndexes[this.matchAt]=j,this.regexes.push([j,_]),this.matchAt+=S(_)+1}compile(){this.regexes.length===0&&(this.exec=()=>null);const _=this.regexes.map(j=>j[1]);this.matcherRe=x(m(_,{joinWith:"|"}),!0),this.lastIndex=0}exec(_){this.matcherRe.lastIndex=this.lastIndex;const j=this.matcherRe.exec(_);if(!j)return null;const te=j.findIndex((Ne,it)=>it>0&&Ne!==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(_){if(this.multiRegexes[_])return this.multiRegexes[_];const j=new O;return this.rules.slice(_).forEach(([te,Y])=>j.addRule(te,Y)),j.compile(),this.multiRegexes[_]=j,j}resumingScanAtSamePosition(){return this.regexIndex!==0}considerAll(){this.regexIndex=0}addRule(_,j){this.rules.push([_,j]),j.type==="begin"&&this.count++}exec(_){const j=this.getMatcher(this.regexIndex);j.lastIndex=this.lastIndex;let te=j.exec(_);if(this.resumingScanAtSamePosition()&&!(te&&te.index===this.lastIndex)){const Y=this.getMatcher(0);Y.lastIndex=this.lastIndex+1,te=Y.exec(_)}return te&&(this.regexIndex+=te.position+1,this.regexIndex===this.count&&this.considerAll()),te}}function V(M){const _=new D;return M.contains.forEach(j=>_.addRule(j.begin,{rule:j,type:"begin"})),M.terminatorEnd&&_.addRule(M.terminatorEnd,{type:"end"}),M.illegal&&_.addRule(M.illegal,{type:"illegal"}),_}function X(M,_){const j=M;if(M.isCompiled)return j;[pe,en,hn,rn].forEach(Y=>Y(M,_)),a.compilerExtensions.forEach(Y=>Y(M,_)),M.__beforeBegin=null,[_e,Te,tn].forEach(Y=>Y(M,_)),M.isCompiled=!0;let te=null;return typeof M.keywords=="object"&&M.keywords.$pattern&&(M.keywords=Object.assign({},M.keywords),te=M.keywords.$pattern,delete M.keywords.$pattern),te=te||/\w+/,M.keywords&&(M.keywords=Ht(M.keywords,a.case_insensitive)),j.keywordPatternRe=x(te,!0),_&&(M.begin||(M.begin=/\B|\b/),j.beginRe=x(j.begin),!M.end&&!M.endsWithParent&&(M.end=/\B|\b/),M.end&&(j.endRe=x(j.end)),j.terminatorEnd=i(j.end)||"",M.endsWithParent&&_.terminatorEnd&&(j.terminatorEnd+=(M.end?"|":"")+_.terminatorEnd)),M.illegal&&(j.illegalRe=x(M.illegal)),M.contains||(M.contains=[]),M.contains=[].concat(...M.contains.map(function(Y){return dn(Y==="self"?M:Y)})),M.contains.forEach(function(Y){X(Y,j)}),M.starts&&X(M.starts,_),j.matcher=V(j),j}if(a.compilerExtensions||(a.compilerExtensions=[]),a.contains&&a.contains.includes("self"))throw new Error("ERR: contains `self` is not supported at the top-level of a language. See documentation.");return a.classNameAliases=d(a.classNameAliases||{}),X(a)}function Kt(a){return a?a.endsWithParent||Kt(a.starts):!1}function dn(a){return a.variants&&!a.cachedVariants&&(a.cachedVariants=a.variants.map(function(x){return d(a,{variants:null},x)})),a.cachedVariants?a.cachedVariants:Kt(a)?d(a,{starts:a.starts?d(a.starts):null}):Object.isFrozen(a)?d(a):a}var pn="11.11.1";class gn extends Error{constructor(x,O){super(x),this.name="HTMLInjectionError",this.html=O}}const nt=b,Vt=d,Xt=Symbol("nomatch"),mn=7,Qt=function(a){const x=Object.create(null),O=Object.create(null),D=[];let V=!0;const X="Could not find the language '{}', did you forget to load/include a language module?",M={disableAutodetect:!0,name:"Plain text",contains:[]};let _={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(C){return _.noHighlightRe.test(C)}function te(C){let I=C.className+" ";I+=C.parentNode?C.parentNode.className:"";const $=_.languageDetectRe.exec(I);if($){const G=ge($[1]);return G||(Zt(X.replace("{}",$[1])),Zt("Falling back to no-highlight mode for this block.",C)),G?$[1]:"no-highlight"}return I.split(/\s+/).find(G=>j(G)||ge(G))}function Y(C,I,$){let G="",ee="";typeof I=="object"?(G=C,$=I.ignoreIllegals,ee=I.language):(Ce("10.7.0","highlight(lang, code, ...args) has been deprecated."),Ce("10.7.0",`Please use highlight(code, options) instead.
|
|
187
|
+
https://github.com/highlightjs/highlight.js/issues/2277`),ee=C,G=I),$===void 0&&($=!0);const ce={code:G,language:ee};Be("before:highlight",ce);const me=ce.result?ce.result:Ne(ce.language,ce.code,$);return me.code=ce.code,Be("after:highlight",me),me}function Ne(C,I,$,G){const ee=Object.create(null);function ce(R,P){return R.keywords[P]}function me(){if(!B.keywords){re.addText(Z);return}let R=0;B.keywordPatternRe.lastIndex=0;let P=B.keywordPatternRe.exec(Z),F="";for(;P;){F+=Z.substring(R,P.index);const W=he.case_insensitive?P[0].toLowerCase():P[0],ne=ce(B,W);if(ne){const[fe,Ln]=ne;if(re.addText(F),F="",ee[W]=(ee[W]||0)+1,ee[W]<=mn&&(Fe+=Ln),fe.startsWith("_"))F+=P[0];else{const In=he.classNameAliases[fe]||fe;ue(P[0],In)}}else F+=P[0];R=B.keywordPatternRe.lastIndex,P=B.keywordPatternRe.exec(Z)}F+=Z.substring(R),re.addText(F)}function De(){if(Z==="")return;let R=null;if(typeof B.subLanguage=="string"){if(!x[B.subLanguage]){re.addText(Z);return}R=Ne(B.subLanguage,Z,!0,or[B.subLanguage]),or[B.subLanguage]=R._top}else R=st(Z,B.subLanguage.length?B.subLanguage:null);B.relevance>0&&(Fe+=R.relevance),re.__addSublanguage(R._emitter,R.language)}function oe(){B.subLanguage!=null?De():me(),Z=""}function ue(R,P){R!==""&&(re.startScope(P),re.addText(R),re.endScope())}function rr(R,P){let F=1;const W=P.length-1;for(;F<=W;){if(!R._emit[F]){F++;continue}const ne=he.classNameAliases[R[F]]||R[F],fe=P[F];ne?ue(fe,ne):(Z=fe,me(),Z=""),F++}}function nr(R,P){return R.scope&&typeof R.scope=="string"&&re.openNode(he.classNameAliases[R.scope]||R.scope),R.beginScope&&(R.beginScope._wrap?(ue(Z,he.classNameAliases[R.beginScope._wrap]||R.beginScope._wrap),Z=""):R.beginScope._multi&&(rr(R.beginScope,P),Z="")),B=Object.create(R,{parent:{value:B}}),B}function ir(R,P,F){let W=w(R.endRe,F);if(W){if(R["on:end"]){const ne=new f(R);R["on:end"](P,ne),ne.isMatchIgnored&&(W=!1)}if(W){for(;R.endsParent&&R.parent;)R=R.parent;return R}}if(R.endsWithParent)return ir(R.parent,P,F)}function An(R){return B.matcher.regexIndex===0?(Z+=R[0],1):(ct=!0,0)}function _n(R){const P=R[0],F=R.rule,W=new f(F),ne=[F.__beforeBegin,F["on:begin"]];for(const fe of ne)if(fe&&(fe(R,W),W.isMatchIgnored))return An(P);return F.skip?Z+=P:(F.excludeBegin&&(Z+=P),oe(),!F.returnBegin&&!F.excludeBegin&&(Z=P)),nr(F,R),F.returnBegin?0:P.length}function Nn(R){const P=R[0],F=I.substring(R.index),W=ir(B,R,F);if(!W)return Xt;const ne=B;B.endScope&&B.endScope._wrap?(oe(),ue(P,B.endScope._wrap)):B.endScope&&B.endScope._multi?(oe(),rr(B.endScope,R)):ne.skip?Z+=P:(ne.returnEnd||ne.excludeEnd||(Z+=P),oe(),ne.excludeEnd&&(Z=P));do B.scope&&re.closeNode(),!B.skip&&!B.subLanguage&&(Fe+=B.relevance),B=B.parent;while(B!==W.parent);return W.starts&&nr(W.starts,R),ne.returnEnd?0:P.length}function Mn(){const R=[];for(let P=B;P!==he;P=P.parent)P.scope&&R.unshift(P.scope);R.forEach(P=>re.openNode(P))}let Ue={};function sr(R,P){const F=P&&P[0];if(Z+=R,F==null)return oe(),0;if(Ue.type==="begin"&&P.type==="end"&&Ue.index===P.index&&F===""){if(Z+=I.slice(P.index,P.index+1),!V){const W=new Error(`0 width match regex (${C})`);throw W.languageName=C,W.badRule=Ue.rule,W}return 1}if(Ue=P,P.type==="begin")return _n(P);if(P.type==="illegal"&&!$){const W=new Error('Illegal lexeme "'+F+'" for mode "'+(B.scope||"<unnamed>")+'"');throw W.mode=B,W}else if(P.type==="end"){const W=Nn(P);if(W!==Xt)return W}if(P.type==="illegal"&&F==="")return Z+=`
|
|
188
|
+
`,1;if(lt>1e5&<>P.index*3)throw new Error("potential infinite loop, way more iterations than matches");return Z+=F,F.length}const he=ge(C);if(!he)throw we(X.replace("{}",C)),new Error('Unknown language: "'+C+'"');const Pn=fn(he);let at="",B=G||Pn;const or={},re=new _.__emitter(_);Mn();let Z="",Fe=0,ve=0,lt=0,ct=!1;try{if(he.__emitTokens)he.__emitTokens(I,re);else{for(B.matcher.considerAll();;){lt++,ct?ct=!1:B.matcher.considerAll(),B.matcher.lastIndex=ve;const R=B.matcher.exec(I);if(!R)break;const P=I.substring(ve,R.index),F=sr(P,R);ve=R.index+F}sr(I.substring(ve))}return re.finalize(),at=re.toHTML(),{language:C,value:at,relevance:Fe,illegal:!1,_emitter:re,_top:B}}catch(R){if(R.message&&R.message.includes("Illegal"))return{language:C,value:nt(I),illegal:!0,relevance:0,_illegalBy:{message:R.message,index:ve,context:I.slice(ve-100,ve+100),mode:R.mode,resultSoFar:at},_emitter:re};if(V)return{language:C,value:nt(I),illegal:!1,relevance:0,errorRaised:R,_emitter:re,_top:B};throw R}}function it(C){const I={value:nt(C),illegal:!1,relevance:0,_top:M,_emitter:new _.__emitter(_)};return I._emitter.addText(C),I}function st(C,I){I=I||_.languages||Object.keys(x);const $=it(C),G=I.filter(ge).filter(tr).map(oe=>Ne(oe,C,!1));G.unshift($);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,De=ce;return De.secondBest=me,De}function bn(C,I,$){const G=I&&O[I]||$;C.classList.add("hljs"),C.classList.add(`language-${G}`)}function ot(C){let I=null;const $=te(C);if(j($))return;if(Be("before:highlightElement",{el:C,language:$}),C.dataset.highlighted){console.log("Element previously highlighted. To highlight again, first unset `dataset.highlighted`.",C);return}if(C.children.length>0&&(_.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(C)),_.throwUnescapedHTML))throw new gn("One of your code blocks includes unescaped HTML.",C.innerHTML);I=C;const G=I.textContent,ee=$?Y(G,{language:$,ignoreIllegals:!0}):st(G);C.innerHTML=ee.value,C.dataset.highlighted="yes",bn(C,$,ee.language),C.result={language:ee.language,re:ee.relevance,relevance:ee.relevance},ee.secondBest&&(C.secondBest={language:ee.secondBest.language,relevance:ee.secondBest.relevance}),Be("after:highlightElement",{el:C,result:ee,text:G})}function yn(C){_=Vt(_,C)}const wn=()=>{ze(),Ce("10.6.0","initHighlighting() deprecated. Use highlightAll() now.")};function vn(){ze(),Ce("10.6.0","initHighlightingOnLoad() deprecated. Use highlightAll() now.")}let Yt=!1;function ze(){function C(){ze()}if(document.readyState==="loading"){Yt||window.addEventListener("DOMContentLoaded",C,!1),Yt=!0;return}document.querySelectorAll(_.cssSelector).forEach(ot)}function xn(C,I){let $=null;try{$=I(a)}catch(G){if(we("Language definition for '{}' could not be registered.".replace("{}",C)),V)we(G);else throw G;$=M}$.name||($.name=C),x[C]=$,$.rawDefinition=I.bind(null,a),$.aliases&&er($.aliases,{languageName:C})}function En(C){delete x[C];for(const I of Object.keys(O))O[I]===C&&delete O[I]}function Sn(){return Object.keys(x)}function ge(C){return C=(C||"").toLowerCase(),x[C]||x[O[C]]}function er(C,{languageName:I}){typeof C=="string"&&(C=[C]),C.forEach($=>{O[$.toLowerCase()]=I})}function tr(C){const I=ge(C);return I&&!I.disableAutodetect}function kn(C){C["before:highlightBlock"]&&!C["before:highlightElement"]&&(C["before:highlightElement"]=I=>{C["before:highlightBlock"](Object.assign({block:I.el},I))}),C["after:highlightBlock"]&&!C["after:highlightElement"]&&(C["after:highlightElement"]=I=>{C["after:highlightBlock"](Object.assign({block:I.el},I))})}function Cn(C){kn(C),D.push(C)}function Rn(C){const I=D.indexOf(C);I!==-1&&D.splice(I,1)}function Be(C,I){const $=C;D.forEach(function(G){G[$]&&G[$](I)})}function On(C){return Ce("10.7.0","highlightBlock will be removed entirely in v12.0"),Ce("10.7.0","Please use highlightElement now."),ot(C)}Object.assign(a,{highlight:Y,highlightAuto:st,highlightAll:ze,highlightElement:ot,highlightBlock:On,configure:yn,initHighlighting:wn,initHighlightingOnLoad:vn,registerLanguage:xn,unregisterLanguage:En,listLanguages:Sn,getLanguage:ge,registerAliases:er,autoDetection:tr,inherit:Vt,addPlugin:Cn,removePlugin:Rn}),a.debugMode=function(){V=!1},a.safeMode=function(){V=!0},a.versionString=pn,a.regex={concat:u,lookahead:t,either:E,optional:l,anyNumberOfTimes:r};for(const C in ke)typeof ke[C]=="object"&&s(ke[C]);return Object.assign(a,ke),a},Re=Qt({});return Re.newInstance=()=>Qt({}),zt=Re,Re.HighlightJS=Re,Re.default=Re,zt}var vi=wi();const Ye=yi(vi),Ge="[A-Za-z$_][0-9A-Za-z$_]*",Gr=["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"],Zr=["true","false","null","undefined","NaN","Infinity"],Jr=["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"],Kr=["Error","EvalError","InternalError","RangeError","ReferenceError","SyntaxError","TypeError","URIError"],Vr=["setInterval","setTimeout","clearInterval","clearTimeout","require","exports","eval","isFinite","isNaN","parseFloat","parseInt","decodeURI","decodeURIComponent","encodeURI","encodeURIComponent","escape","unescape"],Xr=["arguments","this","super","console","window","document","localStorage","sessionStorage","module","global"],Qr=[].concat(Vr,Jr,Kr);function xi(s){const f=s.regex,b=(H,{after:Q})=>{const ie="</"+H[0].slice(1);return H.input.indexOf(ie,Q)!==-1},d=Ge,n={begin:"<>",end:"</>"},h=/<[A-Za-z0-9\\._:-]+\s*\/>/,o={begin:/<[A-Za-z0-9\\._:-]+/,end:/\/[A-Za-z0-9\\._:-]+>|\/>/,isTrulyOpeningTag:(H,Q)=>{const ie=H[0].length+H.index,se=H.input[ie];if(se==="<"||se===","){Q.ignoreMatch();return}se===">"&&(b(H,{after:ie})||Q.ignoreMatch());let de;const ye=H.input.substring(ie);if(de=ye.match(/^\s*=/)){Q.ignoreMatch();return}if((de=ye.match(/^\s+extends\s+/))&&de.index===0){Q.ignoreMatch();return}}},g={$pattern:Ge,keyword:Gr,literal:Zr,built_in:Qr,"variable.language":Xr},v="[0-9](_?[0-9])*",c=`\\.(${v})`,e="0|[1-9](_?[0-9])*|0[0-7]*[89][0-9]*",i={className:"number",variants:[{begin:`(\\b(${e})((${c})|\\.)?|(${c}))[eE][+-]?(${v})\\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:g,contains:[]},r={begin:".?html`",end:"",starts:{end:"`",returnEnd:!1,contains:[s.BACKSLASH_ESCAPE,t],subLanguage:"xml"}},l={begin:".?css`",end:"",starts:{end:"`",returnEnd:!1,contains:[s.BACKSLASH_ESCAPE,t],subLanguage:"css"}},u={begin:".?gql`",end:"",starts:{end:"`",returnEnd:!1,contains:[s.BACKSLASH_ESCAPE,t],subLanguage:"graphql"}},p={className:"string",begin:"`",end:"`",contains:[s.BACKSLASH_ESCAPE,t]},E={className:"comment",variants:[s.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:d+"(?=\\s*(-)|$)",endsParent:!0,relevance:0},{begin:/(?=[^\n])\s/,relevance:0}]}]}),s.C_BLOCK_COMMENT_MODE,s.C_LINE_COMMENT_MODE]},S=[s.APOS_STRING_MODE,s.QUOTE_STRING_MODE,r,l,u,p,{match:/\$\d+/},i];t.contains=S.concat({begin:/\{/,end:/\}/,keywords:g,contains:["self"].concat(S)});const w=[].concat(E,t.contains),y=w.concat([{begin:/(\s*)\(/,end:/\)/,keywords:g,contains:["self"].concat(w)}]),m={className:"params",begin:/(\s*)\(/,end:/\)/,excludeBegin:!0,excludeEnd:!0,keywords:g,contains:y},k={variants:[{match:[/class/,/\s+/,d,/\s+/,/extends/,/\s+/,f.concat(d,"(",f.concat(/\./,d),")*")],scope:{1:"keyword",3:"title.class",5:"keyword",7:"title.class.inherited"}},{match:[/class/,/\s+/,d],scope:{1:"keyword",3:"title.class"}}]},A={relevance:0,match:f.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:{_:[...Jr,...Kr]}},T={label:"use_strict",className:"meta",relevance:10,begin:/^\s*['"]use (strict|asm)['"]/},U={variants:[{match:[/function/,/\s+/,d,/(?=\s*\()/]},{match:[/function/,/\s*(?=\()/]}],className:{1:"keyword",3:"title.function"},label:"func.def",contains:[m],illegal:/%/},L={relevance:0,match:/\b[A-Z][A-Z_0-9]+\b/,className:"variable.constant"};function K(H){return f.concat("(?!",H.join("|"),")")}const q={match:f.concat(/\b/,K([...Vr,"super","import"].map(H=>`${H}\\s*\\(`)),d,f.lookahead(/\s*\(/)),className:"title.function",relevance:0},be={begin:f.concat(/\./,f.lookahead(f.concat(d,/(?![0-9A-Za-z$_(])/))),end:d,excludeBegin:!0,keywords:"prototype",className:"property",relevance:0},ae={match:[/get|set/,/\s+/,d,/(?=\()/],className:{1:"keyword",3:"title.function"},contains:[{begin:/\(\)/},m]},N="(\\([^()]*(\\([^()]*(\\([^()]*\\)[^()]*)*\\)[^()]*)*\\)|"+s.UNDERSCORE_IDENT_RE+")\\s*=>",Ee={match:[/const|var|let/,/\s+/,d,/\s*/,/=\s*/,/(async\s*)?/,f.lookahead(N)],keywords:"async",className:{1:"keyword",3:"title.function"},contains:[m]};return{name:"JavaScript",aliases:["js","jsx","mjs","cjs"],keywords:g,exports:{PARAMS_CONTAINS:y,CLASS_REFERENCE:A},illegal:/#(?![$_A-z])/,contains:[s.SHEBANG({label:"shebang",binary:"node",relevance:5}),T,s.APOS_STRING_MODE,s.QUOTE_STRING_MODE,r,l,u,p,E,{match:/\$\d+/},i,A,{scope:"attr",match:d+f.lookahead(":"),relevance:0},Ee,{begin:"("+s.RE_STARTERS_RE+"|\\b(case|return|throw)\\b)\\s*",keywords:"return throw case",relevance:0,contains:[E,s.REGEXP_MODE,{className:"function",begin:N,returnBegin:!0,end:"\\s*=>",contains:[{className:"params",variants:[{begin:s.UNDERSCORE_IDENT_RE,relevance:0},{className:null,begin:/\(\s*\)/,skip:!0},{begin:/(\s*)\(/,end:/\)/,excludeBegin:!0,excludeEnd:!0,keywords:g,contains:y}]}]},{begin:/,/,relevance:0},{match:/\s+/,relevance:0},{variants:[{begin:n.begin,end:n.end},{match:h},{begin:o.begin,"on:begin":o.isTrulyOpeningTag,end:o.end}],subLanguage:"xml",contains:[{begin:o.begin,end:o.end,skip:!0,contains:["self"]}]}]},U,{beginKeywords:"while if switch catch for"},{begin:"\\b(?!function)"+s.UNDERSCORE_IDENT_RE+"\\([^()]*(\\([^()]*(\\([^()]*\\)[^()]*)*\\)[^()]*)*\\)\\s*\\{",returnBegin:!0,label:"func.def",contains:[m,s.inherit(s.TITLE_MODE,{begin:d,className:"title.function"})]},{match:/\.\.\./,relevance:0},be,{match:"\\$"+d,relevance:0},{match:[/\bconstructor(?=\s*\()/],className:{1:"title.function"},contains:[m]},q,L,k,ae,{match:/\$[(.]/}]}}function Ei(s){const f=s.regex,b=xi(s),d=Ge,n=["any","void","number","boolean","string","object","never","symbol","bigint","unknown"],h={begin:[/namespace/,/\s+/,s.IDENT_RE],beginScope:{1:"keyword",3:"title.class"}},o={beginKeywords:"interface",end:/\{/,excludeEnd:!0,keywords:{keyword:"interface extends",built_in:n},contains:[b.exports.CLASS_REFERENCE]},g={className:"meta",relevance:10,begin:/^\s*['"]use strict['"]/},v=["type","interface","public","private","protected","implements","declare","abstract","readonly","enum","override","satisfies"],c={$pattern:Ge,keyword:Gr.concat(v),literal:Zr,built_in:Qr.concat(n),"variable.language":Xr},e={className:"meta",begin:"@"+d},i=(u,p,E)=>{const S=u.contains.findIndex(w=>w.label===p);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:f.concat(d,f.lookahead(/\s*\?:/))});b.exports.PARAMS_CONTAINS.push([b.exports.CLASS_REFERENCE,t,r]),b.contains=b.contains.concat([e,h,o,r]),i(b,"shebang",s.SHEBANG()),i(b,"use_strict",g);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 Si(s){const f=s.regex,b=f.concat(/[\p{L}_]/u,f.optional(/[\p{L}0-9_.-]*:/u),/[\p{L}0-9_.-]*/u),d=/[\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/}]},o=s.inherit(h,{begin:/\(/,end:/\)/}),g=s.inherit(s.APOS_STRING_MODE,{className:"string"}),v=s.inherit(s.QUOTE_STRING_MODE,{className:"string"}),c={endsWithParent:!0,illegal:/</,relevance:0,contains:[{className:"attr",begin:d,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,v,g,o,{begin:/\[/,end:/\]/,contains:[{className:"meta",begin:/<![a-z]/,end:/>/,contains:[h,o,v,g]}]}]},s.COMMENT(/<!--/,/-->/,{relevance:10}),{begin:/<!\[CDATA\[/,end:/\]\]>/,relevance:10},n,{className:"meta",end:/\?>/,variants:[{begin:/<\?xml/,relevance:10,contains:[v]},{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:f.concat(/</,f.lookahead(f.concat(b,f.either(/\/>/,/>/,/\s/)))),end:/\/?>/,contains:[{className:"name",begin:b,relevance:0,starts:c}]},{className:"tag",begin:f.concat(/<\//,f.lookahead(f.concat(b,/>/))),contains:[{className:"name",begin:b,relevance:0},{begin:/>/,relevance:0,endsParent:!0}]}]}}const ki=s=>({IMPORTANT:{scope:"meta",begin:"!important"},BLOCK_COMMENT:s.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:[s.APOS_STRING_MODE,s.QUOTE_STRING_MODE]},CSS_NUMBER_MODE:{scope:"number",begin:s.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_-]*/}}),Ci=["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"],Ri=["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"],Oi=[...Ci,...Ri],Ai=["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(),Ni=["after","backdrop","before","cue","cue-region","first-letter","first-line","grammar-error","marker","part","placeholder","selection","slotted","spelling-error"].sort().reverse(),Mi=["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 Pi(s){const f=s.regex,b=ki(s),d={begin:/-(webkit|moz|ms|o)-(?=[a-z])/},n="and or not only",h=/@-?\w[\w]*(-\w+)*/,o="[a-zA-Z-][a-zA-Z0-9_-]*",g=[s.APOS_STRING_MODE,s.QUOTE_STRING_MODE];return{name:"CSS",case_insensitive:!0,illegal:/[=|'\$]/,keywords:{keyframePosition:"from to"},classNameAliases:{keyframePosition:"selector-tag"},contains:[b.BLOCK_COMMENT,d,b.CSS_NUMBER_MODE,{className:"selector-id",begin:/#[A-Za-z0-9_-]+/,relevance:0},{className:"selector-class",begin:"\\."+o,relevance:0},b.ATTRIBUTE_SELECTOR_MODE,{className:"selector-pseudo",variants:[{begin:":("+_i.join("|")+")"},{begin:":(:)?("+Ni.join("|")+")"}]},b.CSS_VARIABLE,{className:"attribute",begin:"\\b("+Mi.join("|")+")\\b"},{begin:/:/,end:/[;}{]/,contains:[b.BLOCK_COMMENT,b.HEXCOLOR,b.IMPORTANT,b.CSS_NUMBER_MODE,...g,{begin:/(url|data-uri)\(/,end:/\)/,relevance:0,keywords:{built_in:"url data-uri"},contains:[...g,{className:"string",begin:/[^)]/,endsWithParent:!0,excludeEnd:!0}]},b.FUNCTION_DISPATCH]},{begin:f.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:Ai.join(" ")},contains:[{begin:/[a-z-]+(?=:)/,className:"attribute"},...g,b.CSS_NUMBER_MODE]}]},{className:"selector-tag",begin:"\\b("+Oi.join("|")+")\\b"}]}}const Yr=document.createElement("style");Yr.innerText=[mi,bi].join(`
|
|
189
|
+
`);document.head.appendChild(Yr);Ye.registerLanguage("typescript",Ei);Ye.registerLanguage("html",Si);Ye.registerLanguage("css",Pi);function Li(...s){const f=document.createElement("div"),b=document.createElement("div");b.classList.add("tab-control");const d=document.createElement("div");return s.forEach(n=>{f.appendChild(n),n.addEventListener("click",()=>{s.forEach(h=>h.removeAttribute("selected")),n.setAttribute("selected",""),d.innerHTML="",d.appendChild(n.content),d.className=n.className,d.classList.add("tab-content")})}),b.appendChild(f),b.appendChild(d),d.classList.add("tab-content"),s[0].setAttribute("selected",""),d.appendChild(s[0].content),b}function Me(s,f){const b=document.createElement("div");return b.role="tab",b.tabIndex=0,b.innerText=s,b.content=f,f.tagName=="PRE"&&b.classList.add("code"),b}function Le(s,f){const b=document.createElement(s);return typeof f=="string"?b.innerHTML=f:f.forEach(d=>{b.appendChild(d)}),b}async function Ii(s,f,b){const d=f.mainContent,n=Le("div",d);n.id=`example-preview-${b}`;const h=typeof f.css=="string"?void 0:f.css?.label,o=typeof f.css=="string"?f.css:f.css?.content,g=Li(Me("Preview",n),Me("HTML",We("html",d)),...o?[Me(h??"CSS",We("css",o))]:[],...f.initializer&&f.initializer.content?[Me(f.initializer.label??"TS",We("typescript",f.initializer.content))]:[],...(f.additionalSources||[]).map(c=>Me(c.label,We(c.language,c.content))));f.description&&s.appendChild(Le("div",f.description));const v=Le("div",[g]);v.classList.add("example"),s.appendChild(v),o&&Ti(`#${n.id}`,o),f.initializer?.initialize&&await f.initializer.initialize(n)}function We(s,f){let b=f.split(/\r?\n/).map(d=>{const n=d.indexOf("///");if(n>-1){const h=d.substring(n+3).trimStart();return h?d.replace(/^(\s*)([^\s].*)$/,`$1${h}`):void 0}return d}).filter(d=>typeof d<"u").join(`
|
|
190
|
+
`).trim();return s&&s!="raw"&&(b=Ye.highlight(b,{language:s}).value),Le("pre",[Le("code",b)])}function Ti(s,f){const b=document.createElement("style");b.innerHTML=J().use(gi({prefix:s})).process(f).css,document.head.appendChild(b)}async function ji(s,f=document.body){const b=Bi(f);let d=0;Object.keys(s).sort().forEach(async n=>{const h=document.createElement("div");h.className="example-container",b.appendChild(h);const o=s[n].default;Ii(h,o,d++)})}function zi(s){const f=document.createElement("div");f.id="examples-container";const b=s.querySelector("#examples");return b?b.after(f):s.appendChild(f),f}function Bi(s){return s.children?zi(s):s}const Di=`<h1 id="@cas-smartdesign/message">@cas-smartdesign/message</h1>
|
|
188
191
|
<p>A custom element which represents the SmartDesign message widget.</p>
|
|
189
192
|
<h2 id="slots">Slots</h2>
|
|
190
193
|
<ul>
|
|
@@ -205,10 +208,4 @@ https://github.com/highlightjs/highlight.js/issues/2277`),k=u,x=d),w===void 0&&(
|
|
|
205
208
|
</ul>
|
|
206
209
|
</li>
|
|
207
210
|
</ul>
|
|
208
|
-
`,
|
|
209
|
-
function __vite__mapDeps(indexes) {
|
|
210
|
-
if (!__vite__mapDeps.viteFileDeps) {
|
|
211
|
-
__vite__mapDeps.viteFileDeps = []
|
|
212
|
-
}
|
|
213
|
-
return indexes.map((i) => __vite__mapDeps.viteFileDeps[i])
|
|
214
|
-
}
|
|
211
|
+
`,Ui=document.querySelector("#markdown-container");Ui.innerHTML=Di;ji(Object.assign({"./examples/1_declarative/index.ts":Bn,"./examples/2_created_from_source/index.ts":Gn}),document.querySelector(".markdown-body"));export{ei as L,Pe as M};
|