@posthog/rrdom 0.0.34 → 0.0.36
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +21 -0
- package/dist/rrdom.cjs +156 -126
- package/dist/rrdom.cjs.map +1 -1
- package/dist/rrdom.js +156 -126
- package/dist/rrdom.js.map +1 -1
- package/dist/rrdom.umd.cjs +158 -142
- package/dist/rrdom.umd.cjs.map +3 -3
- package/dist/rrdom.umd.min.cjs +20 -32
- package/dist/rrdom.umd.min.cjs.map +4 -4
- package/package.json +52 -51
package/dist/rrdom.umd.min.cjs
CHANGED
|
@@ -1,18 +1,6 @@
|
|
|
1
|
-
(function (g, f) {
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
} else if ("function" == typeof define && define.amd) {
|
|
5
|
-
define("rrdom", [], f);
|
|
6
|
-
} else if ("object" == typeof exports) {
|
|
7
|
-
exports["rrdom"] = f();
|
|
8
|
-
} else {
|
|
9
|
-
g["rrdom"] = f();
|
|
10
|
-
}
|
|
11
|
-
}(this, () => {
|
|
12
|
-
var exports = {};
|
|
13
|
-
var module = { exports };
|
|
14
|
-
"use strict";var Sr=Object.defineProperty,Nr=Object.defineProperties;var Or=Object.getOwnPropertyDescriptors;var ee=Object.getOwnPropertySymbols;var ht=Object.prototype.hasOwnProperty,ft=Object.prototype.propertyIsEnumerable;var ct=(t,e,i)=>e in t?Sr(t,e,{enumerable:!0,configurable:!0,writable:!0,value:i}):t[e]=i,k=(t,e)=>{for(var i in e||(e={}))ht.call(e,i)&&ct(t,i,e[i]);if(ee)for(var i of ee(e))ft.call(e,i)&&ct(t,i,e[i]);return t},Y=(t,e)=>Nr(t,Or(e));var de=(t,e)=>{var i={};for(var c in t)ht.call(t,c)&&e.indexOf(c)<0&&(i[c]=t[c]);if(t!=null&&ee)for(var c of ee(t))e.indexOf(c)<0&&ft.call(t,c)&&(i[c]=t[c]);return i};var Dr=Object.defineProperty,Ar=(t,e,i)=>e in t?Dr(t,e,{enumerable:!0,configurable:!0,writable:!0,value:i}):t[e]=i,x=(t,e,i)=>Ar(t,typeof e!="symbol"?e+"":e,i);Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});var Mr=Object.defineProperty,_r=(t,e,i)=>e in t?Mr(t,e,{enumerable:!0,configurable:!0,writable:!0,value:i}):t[e]=i,pt=(t,e,i)=>_r(t,typeof e!="symbol"?e+"":e,i);let Tr=class{constructor(){pt(this,"idNodeMap",new Map),pt(this,"nodeMetaMap",new WeakMap)}getId(e){var i;if(!e)return-1;const c=(i=this.getMeta(e))==null?void 0:i.id;return c!=null?c:-1}getNode(e){return this.idNodeMap.get(e)||null}getIds(){return Array.from(this.idNodeMap.keys())}getMeta(e){return this.nodeMetaMap.get(e)||null}removeNodeFromMap(e){const i=this.getId(e);this.idNodeMap.delete(i),e.childNodes&&e.childNodes.forEach(c=>this.removeNodeFromMap(c))}has(e){return this.idNodeMap.has(e)}hasNode(e){return this.nodeMetaMap.has(e)}add(e,i){const c=i.id;this.idNodeMap.set(c,e),this.nodeMetaMap.set(e,i)}replace(e,i){const c=this.getNode(e);if(c){const s=this.nodeMetaMap.get(c);s&&this.nodeMetaMap.set(i,s)}this.idNodeMap.set(e,i)}reset(){this.idNodeMap=new Map,this.nodeMetaMap=new WeakMap}};function Ir(){return new Tr}function Pr(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}function Lr(t){if(t.__esModule)return t;var e=t.default;if(typeof e=="function"){var i=function c(){return this instanceof c?Reflect.construct(e,arguments,this.constructor):e.apply(this,arguments)};i.prototype=e.prototype}else i={};return Object.defineProperty(i,"__esModule",{value:!0}),Object.keys(t).forEach(function(c){var s=Object.getOwnPropertyDescriptor(t,c);Object.defineProperty(i,c,s.get?s:{enumerable:!0,get:function(){return t[c]}})}),i}var te={exports:{}},dt;function kr(){if(dt)return te.exports;dt=1;var t=String,e=function(){return{isColorSupported:!1,reset:t,bold:t,dim:t,italic:t,underline:t,inverse:t,hidden:t,strikethrough:t,black:t,red:t,green:t,yellow:t,blue:t,magenta:t,cyan:t,white:t,gray:t,bgBlack:t,bgRed:t,bgGreen:t,bgYellow:t,bgBlue:t,bgMagenta:t,bgCyan:t,bgWhite:t,blackBright:t,redBright:t,greenBright:t,yellowBright:t,blueBright:t,magentaBright:t,cyanBright:t,whiteBright:t,bgBlackBright:t,bgRedBright:t,bgGreenBright:t,bgYellowBright:t,bgBlueBright:t,bgMagentaBright:t,bgCyanBright:t,bgWhiteBright:t}};return te.exports=e(),te.exports.createColors=e,te.exports}const Br={},Ur=Object.freeze(Object.defineProperty({__proto__:null,default:Br},Symbol.toStringTag,{value:"Module"})),B=Lr(Ur);var me,mt;function Ve(){if(mt)return me;mt=1;let t=kr(),e=B;class i extends Error{constructor(s,l,o,p,g,f){super(s),this.name="CssSyntaxError",this.reason=s,g&&(this.file=g),p&&(this.source=p),f&&(this.plugin=f),typeof l!="undefined"&&typeof o!="undefined"&&(typeof l=="number"?(this.line=l,this.column=o):(this.line=l.line,this.column=l.column,this.endLine=o.line,this.endColumn=o.column)),this.setMessage(),Error.captureStackTrace&&Error.captureStackTrace(this,i)}setMessage(){this.message=this.plugin?this.plugin+": ":"",this.message+=this.file?this.file:"<css input>",typeof this.line!="undefined"&&(this.message+=":"+this.line+":"+this.column),this.message+=": "+this.reason}showSourceCode(s){if(!this.source)return"";let l=this.source;s==null&&(s=t.isColorSupported);let o=n=>n,p=n=>n,g=n=>n;if(s){let{bold:n,gray:d,red:h}=t.createColors(!0);p=m=>n(h(m)),o=m=>d(m),e&&(g=m=>e(m))}let f=l.split(/\r?\n/),r=Math.max(this.line-3,0),u=Math.min(this.line+2,f.length),a=String(u).length;return f.slice(r,u).map((n,d)=>{let h=r+1+d,m=" "+(" "+h).slice(-a)+" | ";if(h===this.line){if(n.length>160){let w=20,E=Math.max(0,this.column-w),v=Math.max(this.column+w,this.endColumn+w),R=n.slice(E,v),y=o(m.replace(/\d/g," "))+n.slice(0,Math.min(this.column-1,w-1)).replace(/[^\t]/g," ");return p(">")+o(m)+g(R)+`
|
|
15
|
-
`+y+p("^")}let b=o(m.replace(/\d/g," "))+n.slice(0,this.column-1).replace(/[^\t]/g," ");return p(">")+o(m)+g(n)+`
|
|
1
|
+
(function (g, f) {if ("object" == typeof exports && "object" == typeof module) {module.exports = f();} else if ("function" == typeof define && define.amd) {define("rrdom", [], f);} else if ("object" == typeof exports) {exports["rrdom"] = f();} else {g["rrdom"] = f();}}(typeof self !== 'undefined' ? self : typeof globalThis !== 'undefined' ? globalThis : this, () => {var exports = {};var module = { exports };
|
|
2
|
+
"use strict";var Sr=Object.defineProperty,Nr=Object.defineProperties;var Or=Object.getOwnPropertyDescriptors;var ee=Object.getOwnPropertySymbols;var ht=Object.prototype.hasOwnProperty,ft=Object.prototype.propertyIsEnumerable;var ct=(t,e,i)=>e in t?Sr(t,e,{enumerable:!0,configurable:!0,writable:!0,value:i}):t[e]=i,k=(t,e)=>{for(var i in e||(e={}))ht.call(e,i)&&ct(t,i,e[i]);if(ee)for(var i of ee(e))ft.call(e,i)&&ct(t,i,e[i]);return t},Y=(t,e)=>Nr(t,Or(e));var de=(t,e)=>{var i={};for(var c in t)ht.call(t,c)&&e.indexOf(c)<0&&(i[c]=t[c]);if(t!=null&&ee)for(var c of ee(t))e.indexOf(c)<0&&ft.call(t,c)&&(i[c]=t[c]);return i};var Dr=Object.defineProperty,Ar=(t,e,i)=>e in t?Dr(t,e,{enumerable:!0,configurable:!0,writable:!0,value:i}):t[e]=i,v=(t,e,i)=>Ar(t,typeof e!="symbol"?e+"":e,i);Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});var Mr=Object.defineProperty,_r=(t,e,i)=>e in t?Mr(t,e,{enumerable:!0,configurable:!0,writable:!0,value:i}):t[e]=i,pt=(t,e,i)=>_r(t,typeof e!="symbol"?e+"":e,i);let Tr=class{constructor(){pt(this,"idNodeMap",new Map),pt(this,"nodeMetaMap",new WeakMap)}getId(e){var i;if(!e)return-1;const c=(i=this.getMeta(e))==null?void 0:i.id;return c!=null?c:-1}getNode(e){return this.idNodeMap.get(e)||null}getIds(){return Array.from(this.idNodeMap.keys())}getMeta(e){return this.nodeMetaMap.get(e)||null}removeNodeFromMap(e){const i=this.getId(e);this.idNodeMap.delete(i),e.childNodes&&e.childNodes.forEach(c=>this.removeNodeFromMap(c))}has(e){return this.idNodeMap.has(e)}hasNode(e){return this.nodeMetaMap.has(e)}add(e,i){const c=i.id;this.idNodeMap.set(c,e),this.nodeMetaMap.set(e,i)}replace(e,i){const c=this.getNode(e);if(c){const s=this.nodeMetaMap.get(c);s&&this.nodeMetaMap.set(i,s)}this.idNodeMap.set(e,i)}reset(){this.idNodeMap=new Map,this.nodeMetaMap=new WeakMap}};function Ir(){return new Tr}function Pr(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}function Lr(t){if(Object.prototype.hasOwnProperty.call(t,"__esModule"))return t;var e=t.default;if(typeof e=="function"){var i=function c(){return this instanceof c?Reflect.construct(e,arguments,this.constructor):e.apply(this,arguments)};i.prototype=e.prototype}else i={};return Object.defineProperty(i,"__esModule",{value:!0}),Object.keys(t).forEach(function(c){var s=Object.getOwnPropertyDescriptor(t,c);Object.defineProperty(i,c,s.get?s:{enumerable:!0,get:function(){return t[c]}})}),i}var te={exports:{}},dt;function kr(){if(dt)return te.exports;dt=1;var t=String,e=function(){return{isColorSupported:!1,reset:t,bold:t,dim:t,italic:t,underline:t,inverse:t,hidden:t,strikethrough:t,black:t,red:t,green:t,yellow:t,blue:t,magenta:t,cyan:t,white:t,gray:t,bgBlack:t,bgRed:t,bgGreen:t,bgYellow:t,bgBlue:t,bgMagenta:t,bgCyan:t,bgWhite:t,blackBright:t,redBright:t,greenBright:t,yellowBright:t,blueBright:t,magentaBright:t,cyanBright:t,whiteBright:t,bgBlackBright:t,bgRedBright:t,bgGreenBright:t,bgYellowBright:t,bgBlueBright:t,bgMagentaBright:t,bgCyanBright:t,bgWhiteBright:t}};return te.exports=e(),te.exports.createColors=e,te.exports}const Br={},Ur=Object.freeze(Object.defineProperty({__proto__:null,default:Br},Symbol.toStringTag,{value:"Module"})),B=Lr(Ur);var me,mt;function Ve(){if(mt)return me;mt=1;let t=kr(),e=B;class i extends Error{constructor(s,a,o,p,g,h){super(s),this.name="CssSyntaxError",this.reason=s,g&&(this.file=g),p&&(this.source=p),h&&(this.plugin=h),typeof a!="undefined"&&typeof o!="undefined"&&(typeof a=="number"?(this.line=a,this.column=o):(this.line=a.line,this.column=a.column,this.endLine=o.line,this.endColumn=o.column)),this.setMessage(),Error.captureStackTrace&&Error.captureStackTrace(this,i)}setMessage(){this.message=this.plugin?this.plugin+": ":"",this.message+=this.file?this.file:"<css input>",typeof this.line!="undefined"&&(this.message+=":"+this.line+":"+this.column),this.message+=": "+this.reason}showSourceCode(s){if(!this.source)return"";let a=this.source;s==null&&(s=t.isColorSupported);let o=n=>n,p=n=>n,g=n=>n;if(s){let{bold:n,gray:f,red:d}=t.createColors(!0);p=m=>n(d(m)),o=m=>f(m),e&&(g=m=>e(m))}let h=a.split(/\r?\n/),r=Math.max(this.line-3,0),u=Math.min(this.line+2,h.length),l=String(u).length;return h.slice(r,u).map((n,f)=>{let d=r+1+f,m=" "+(" "+d).slice(-l)+" | ";if(d===this.line){if(n.length>160){let w=20,E=Math.max(0,this.column-w),x=Math.max(this.column+w,this.endColumn+w),y=n.slice(E,x),R=o(m.replace(/\d/g," "))+n.slice(0,Math.min(this.column-1,w-1)).replace(/[^\t]/g," ");return p(">")+o(m)+g(y)+`
|
|
3
|
+
`+R+p("^")}let b=o(m.replace(/\d/g," "))+n.slice(0,this.column-1).replace(/[^\t]/g," ");return p(">")+o(m)+g(n)+`
|
|
16
4
|
`+b+p("^")}return" "+o(m)+g(n)}).join(`
|
|
17
5
|
`)}toString(){let s=this.showSourceCode();return s&&(s=`
|
|
18
6
|
|
|
@@ -22,25 +10,25 @@ var module = { exports };
|
|
|
22
10
|
`,beforeComment:`
|
|
23
11
|
`,beforeDecl:`
|
|
24
12
|
`,beforeOpen:" ",beforeRule:`
|
|
25
|
-
`,colon:": ",commentLeft:" ",commentRight:" ",emptyBody:"",indent:" ",semicolon:!1};function e(c){return c[0].toUpperCase()+c.slice(1)}class i{constructor(s){this.builder=s}atrule(s,
|
|
26
|
-
`)){let
|
|
27
|
-
`)&&(
|
|
28
|
-
`)&&(o=o.replace(/[^\n]+$/,"")),!1}),typeof o=="undefined"?o=this.raw(
|
|
29
|
-
`)&&(o=o.replace(/[^\n]+$/,"")),!1}),typeof o=="undefined"?o=this.raw(
|
|
30
|
-
`)&&(
|
|
31
|
-
`);return
|
|
32
|
-
`?(r=1,u+=1):r+=1}return
|
|
33
|
-
`?(r=1,u+=1):r+=1;return{column:r,line:u}}prev(){if(!this.parent)return;let f=this.parent.index(this);return this.parent.nodes[f-1]}rangeBy(f){let r={column:this.source.start.column,line:this.source.start.line},u=this.source.end?{column:this.source.end.column+1,line:this.source.end.line}:{column:r.column+1,line:r.line};if(f.word){let a="document"in this.source.input?this.source.input.document:this.source.input.css,d=a.slice(o(a,this.source.start),o(a,this.source.end)).indexOf(f.word);d!==-1&&(r=this.positionInside(d),u=this.positionInside(d+f.word.length))}else f.start?r={column:f.start.column,line:f.start.line}:f.index&&(r=this.positionInside(f.index)),f.end?u={column:f.end.column,line:f.end.line}:typeof f.endIndex=="number"?u=this.positionInside(f.endIndex):f.index&&(u=this.positionInside(f.index+1));return(u.line<r.line||u.line===r.line&&u.column<=r.column)&&(u={column:r.column+1,line:r.line}),{end:u,start:r}}raw(f,r){return new e().raw(this,f,r)}remove(){return this.parent&&this.parent.removeChild(this),this.parent=void 0,this}replaceWith(...f){if(this.parent){let r=this,u=!1;for(let a of f)a===this?u=!0:u?(this.parent.insertAfter(r,a),r=a):this.parent.insertBefore(r,a);u||this.remove()}return this}root(){let f=this;for(;f.parent&&f.parent.type!=="document";)f=f.parent;return f}toJSON(f,r){let u={},a=r==null;r=r||new Map;let n=0;for(let d in this){if(!Object.prototype.hasOwnProperty.call(this,d)||d==="parent"||d==="proxyCache")continue;let h=this[d];if(Array.isArray(h))u[d]=h.map(m=>typeof m=="object"&&m.toJSON?m.toJSON(null,r):m);else if(typeof h=="object"&&h.toJSON)u[d]=h.toJSON(null,r);else if(d==="source"){let m=r.get(h.input);m==null&&(m=n,r.set(h.input,n),n++),u[d]={end:h.end,inputId:m,start:h.start}}else u[d]=h}return a&&(u.inputs=[...r.keys()].map(d=>d.toJSON())),u}toProxy(){return this.proxyCache||(this.proxyCache=new Proxy(this,this.getProxyProcessor())),this.proxyCache}toString(f=i){f.stringify&&(f=f.stringify);let r="";return f(this,u=>{r+=u}),r}warn(f,r,u){let a={node:this};for(let n in u)a[n]=u[n];return f.warn(r,a)}get proxyOf(){return this}}return ye=p,p.default=p,ye}var Re,Et;function H(){if(Et)return Re;Et=1;let t=oe();class e extends t{constructor(c){super(c),this.type="comment"}}return Re=e,e.default=e,Re}var Ee,bt;function le(){if(bt)return Ee;bt=1;let t=oe();class e extends t{constructor(c){c&&typeof c.value!="undefined"&&typeof c.value!="string"&&(c=Y(k({},c),{value:String(c.value)})),super(c),this.type="decl"}get variable(){return this.prop.startsWith("--")||this.prop[0]==="$"}}return Ee=e,e.default=e,Ee}var be,Ct;function W(){if(Ct)return be;Ct=1;let t=H(),e=le(),i=oe(),{isClean:c,my:s}=Ye(),l,o,p,g;function f(a){return a.map(n=>(n.nodes&&(n.nodes=f(n.nodes)),delete n.source,n))}function r(a){if(a[c]=!1,a.proxyOf.nodes)for(let n of a.proxyOf.nodes)r(n)}class u extends i{append(...n){for(let d of n){let h=this.normalize(d,this.last);for(let m of h)this.proxyOf.nodes.push(m)}return this.markDirty(),this}cleanRaws(n){if(super.cleanRaws(n),this.nodes)for(let d of this.nodes)d.cleanRaws(n)}each(n){if(!this.proxyOf.nodes)return;let d=this.getIterator(),h,m;for(;this.indexes[d]<this.proxyOf.nodes.length&&(h=this.indexes[d],m=n(this.proxyOf.nodes[h],h),m!==!1);)this.indexes[d]+=1;return delete this.indexes[d],m}every(n){return this.nodes.every(n)}getIterator(){this.lastEach||(this.lastEach=0),this.indexes||(this.indexes={}),this.lastEach+=1;let n=this.lastEach;return this.indexes[n]=0,n}getProxyProcessor(){return{get(n,d){return d==="proxyOf"?n:n[d]?d==="each"||typeof d=="string"&&d.startsWith("walk")?(...h)=>n[d](...h.map(m=>typeof m=="function"?(b,w)=>m(b.toProxy(),w):m)):d==="every"||d==="some"?h=>n[d]((m,...b)=>h(m.toProxy(),...b)):d==="root"?()=>n.root().toProxy():d==="nodes"?n.nodes.map(h=>h.toProxy()):d==="first"||d==="last"?n[d].toProxy():n[d]:n[d]},set(n,d,h){return n[d]===h||(n[d]=h,(d==="name"||d==="params"||d==="selector")&&n.markDirty()),!0}}}index(n){return typeof n=="number"?n:(n.proxyOf&&(n=n.proxyOf),this.proxyOf.nodes.indexOf(n))}insertAfter(n,d){let h=this.index(n),m=this.normalize(d,this.proxyOf.nodes[h]).reverse();h=this.index(n);for(let w of m)this.proxyOf.nodes.splice(h+1,0,w);let b;for(let w in this.indexes)b=this.indexes[w],h<b&&(this.indexes[w]=b+m.length);return this.markDirty(),this}insertBefore(n,d){let h=this.index(n),m=h===0?"prepend":!1,b=this.normalize(d,this.proxyOf.nodes[h],m).reverse();h=this.index(n);for(let E of b)this.proxyOf.nodes.splice(h,0,E);let w;for(let E in this.indexes)w=this.indexes[E],h<=w&&(this.indexes[E]=w+b.length);return this.markDirty(),this}normalize(n,d){if(typeof n=="string")n=f(o(n).nodes);else if(typeof n=="undefined")n=[];else if(Array.isArray(n)){n=n.slice(0);for(let m of n)m.parent&&m.parent.removeChild(m,"ignore")}else if(n.type==="root"&&this.type!=="document"){n=n.nodes.slice(0);for(let m of n)m.parent&&m.parent.removeChild(m,"ignore")}else if(n.type)n=[n];else if(n.prop){if(typeof n.value=="undefined")throw new Error("Value field is missed in node creation");typeof n.value!="string"&&(n.value=String(n.value)),n=[new e(n)]}else if(n.selector||n.selectors)n=[new g(n)];else if(n.name)n=[new l(n)];else if(n.text)n=[new t(n)];else throw new Error("Unknown node type in node creation");return n.map(m=>(m[s]||u.rebuild(m),m=m.proxyOf,m.parent&&m.parent.removeChild(m),m[c]&&r(m),m.raws||(m.raws={}),typeof m.raws.before=="undefined"&&d&&typeof d.raws.before!="undefined"&&(m.raws.before=d.raws.before.replace(/\S/g,"")),m.parent=this.proxyOf,m))}prepend(...n){n=n.reverse();for(let d of n){let h=this.normalize(d,this.first,"prepend").reverse();for(let m of h)this.proxyOf.nodes.unshift(m);for(let m in this.indexes)this.indexes[m]=this.indexes[m]+h.length}return this.markDirty(),this}push(n){return n.parent=this,this.proxyOf.nodes.push(n),this}removeAll(){for(let n of this.proxyOf.nodes)n.parent=void 0;return this.proxyOf.nodes=[],this.markDirty(),this}removeChild(n){n=this.index(n),this.proxyOf.nodes[n].parent=void 0,this.proxyOf.nodes.splice(n,1);let d;for(let h in this.indexes)d=this.indexes[h],d>=n&&(this.indexes[h]=d-1);return this.markDirty(),this}replaceValues(n,d,h){return h||(h=d,d={}),this.walkDecls(m=>{d.props&&!d.props.includes(m.prop)||d.fast&&!m.value.includes(d.fast)||(m.value=m.value.replace(n,h))}),this.markDirty(),this}some(n){return this.nodes.some(n)}walk(n){return this.each((d,h)=>{let m;try{m=n(d,h)}catch(b){throw d.addToError(b)}return m!==!1&&d.walk&&(m=d.walk(n)),m})}walkAtRules(n,d){return d?n instanceof RegExp?this.walk((h,m)=>{if(h.type==="atrule"&&n.test(h.name))return d(h,m)}):this.walk((h,m)=>{if(h.type==="atrule"&&h.name===n)return d(h,m)}):(d=n,this.walk((h,m)=>{if(h.type==="atrule")return d(h,m)}))}walkComments(n){return this.walk((d,h)=>{if(d.type==="comment")return n(d,h)})}walkDecls(n,d){return d?n instanceof RegExp?this.walk((h,m)=>{if(h.type==="decl"&&n.test(h.prop))return d(h,m)}):this.walk((h,m)=>{if(h.type==="decl"&&h.prop===n)return d(h,m)}):(d=n,this.walk((h,m)=>{if(h.type==="decl")return d(h,m)}))}walkRules(n,d){return d?n instanceof RegExp?this.walk((h,m)=>{if(h.type==="rule"&&n.test(h.selector))return d(h,m)}):this.walk((h,m)=>{if(h.type==="rule"&&h.selector===n)return d(h,m)}):(d=n,this.walk((h,m)=>{if(h.type==="rule")return d(h,m)}))}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]}}return u.registerParse=a=>{o=a},u.registerRule=a=>{g=a},u.registerAtRule=a=>{l=a},u.registerRoot=a=>{p=a},be=u,u.default=u,u.rebuild=a=>{a.type==="atrule"?Object.setPrototypeOf(a,l.prototype):a.type==="rule"?Object.setPrototypeOf(a,g.prototype):a.type==="decl"?Object.setPrototypeOf(a,e.prototype):a.type==="comment"?Object.setPrototypeOf(a,t.prototype):a.type==="root"&&Object.setPrototypeOf(a,p.prototype),a[s]=!0,a.nodes&&a.nodes.forEach(n=>{u.rebuild(n)})},be}var Ce,vt;function He(){if(vt)return Ce;vt=1;let t=W();class e extends t{constructor(c){super(c),this.type="atrule"}append(...c){return this.proxyOf.nodes||(this.nodes=[]),super.append(...c)}prepend(...c){return this.proxyOf.nodes||(this.nodes=[]),super.prepend(...c)}}return Ce=e,e.default=e,t.registerAtRule(e),Ce}var ve,xt;function Je(){if(xt)return ve;xt=1;let t=W(),e,i;class c extends t{constructor(l){super(k({type:"document"},l)),this.nodes||(this.nodes=[])}toResult(l={}){return new e(new i,this,l).stringify()}}return c.registerLazyResult=s=>{e=s},c.registerProcessor=s=>{i=s},ve=c,c.default=c,ve}var xe,St;function Fr(){if(St)return xe;St=1;let t="useandom-26T198340PX75pxJACKVERYMINDBUSHWOLF_GQZbfghjklqvwyzrict";return xe={nanoid:(c=21)=>{let s="",l=c|0;for(;l--;)s+=t[Math.random()*64|0];return s},customAlphabet:(c,s=21)=>(l=s)=>{let o="",p=l|0;for(;p--;)o+=c[Math.random()*c.length|0];return o}},xe}var Se,Nt;function Yt(){if(Nt)return Se;Nt=1;let{existsSync:t,readFileSync:e}=B,{dirname:i,join:c}=B,{SourceMapConsumer:s,SourceMapGenerator:l}=B;function o(g){return Buffer?Buffer.from(g,"base64").toString():window.atob(g)}class p{constructor(f,r){if(r.map===!1)return;this.loadAnnotation(f),this.inline=this.startWith(this.annotation,"data:");let u=r.map?r.map.prev:void 0,a=this.loadMap(r.from,u);!this.mapFile&&r.from&&(this.mapFile=r.from),this.mapFile&&(this.root=i(this.mapFile)),a&&(this.text=a)}consumer(){return this.consumerCache||(this.consumerCache=new s(this.text)),this.consumerCache}decodeInline(f){let r=/^data:application\/json;charset=utf-?8;base64,/,u=/^data:application\/json;base64,/,a=/^data:application\/json;charset=utf-?8,/,n=/^data:application\/json,/,d=f.match(a)||f.match(n);if(d)return decodeURIComponent(f.substr(d[0].length));let h=f.match(r)||f.match(u);if(h)return o(f.substr(h[0].length));let m=f.match(/data:application\/json;([^,]+),/)[1];throw new Error("Unsupported source map encoding "+m)}getAnnotationURL(f){return f.replace(/^\/\*\s*# sourceMappingURL=/,"").trim()}isMap(f){return typeof f!="object"?!1:typeof f.mappings=="string"||typeof f._mappings=="string"||Array.isArray(f.sections)}loadAnnotation(f){let r=f.match(/\/\*\s*# sourceMappingURL=/g);if(!r)return;let u=f.lastIndexOf(r.pop()),a=f.indexOf("*/",u);u>-1&&a>-1&&(this.annotation=this.getAnnotationURL(f.substring(u,a)))}loadFile(f){if(this.root=i(f),t(f))return this.mapFile=f,e(f,"utf-8").toString().trim()}loadMap(f,r){if(r===!1)return!1;if(r){if(typeof r=="string")return r;if(typeof r=="function"){let u=r(f);if(u){let a=this.loadFile(u);if(!a)throw new Error("Unable to load previous source map: "+u.toString());return a}}else{if(r instanceof s)return l.fromSourceMap(r).toString();if(r instanceof l)return r.toString();if(this.isMap(r))return JSON.stringify(r);throw new Error("Unsupported previous source map format: "+r.toString())}}else{if(this.inline)return this.decodeInline(this.annotation);if(this.annotation){let u=this.annotation;return f&&(u=c(i(f),u)),this.loadFile(u)}}}startWith(f,r){return f?f.substr(0,r.length)===r:!1}withContent(){return!!(this.consumer().sourcesContent&&this.consumer().sourcesContent.length>0)}}return Se=p,p.default=p,Se}var Ne,Ot;function ae(){if(Ot)return Ne;Ot=1;let{nanoid:t}=Fr(),{isAbsolute:e,resolve:i}=B,{SourceMapConsumer:c,SourceMapGenerator:s}=B,{fileURLToPath:l,pathToFileURL:o}=B,p=Ve(),g=Yt(),f=B,r=Symbol("fromOffsetCache"),u=!!(c&&s),a=!!(i&&e);class n{constructor(h,m={}){if(h===null||typeof h=="undefined"||typeof h=="object"&&!h.toString)throw new Error(`PostCSS received ${h} instead of CSS string`);if(this.css=h.toString(),this.css[0]==="\uFEFF"||this.css[0]==="\uFFFE"?(this.hasBOM=!0,this.css=this.css.slice(1)):this.hasBOM=!1,this.document=this.css,m.document&&(this.document=m.document.toString()),m.from&&(!a||/^\w+:\/\//.test(m.from)||e(m.from)?this.file=m.from:this.file=i(m.from)),a&&u){let b=new g(this.css,m);if(b.text){this.map=b;let w=b.consumer().file;!this.file&&w&&(this.file=this.mapResolve(w))}}this.file||(this.id="<input css "+t(6)+">"),this.map&&(this.map.file=this.from)}error(h,m,b,w={}){let E,v,R;if(m&&typeof m=="object"){let C=m,N=b;if(typeof C.offset=="number"){let M=this.fromOffset(C.offset);m=M.line,b=M.col}else m=C.line,b=C.column;if(typeof N.offset=="number"){let M=this.fromOffset(N.offset);v=M.line,E=M.col}else v=N.line,E=N.column}else if(!b){let C=this.fromOffset(m);m=C.line,b=C.col}let y=this.origin(m,b,v,E);return y?R=new p(h,y.endLine===void 0?y.line:{column:y.column,line:y.line},y.endLine===void 0?y.column:{column:y.endColumn,line:y.endLine},y.source,y.file,w.plugin):R=new p(h,v===void 0?m:{column:b,line:m},v===void 0?b:{column:E,line:v},this.css,this.file,w.plugin),R.input={column:b,endColumn:E,endLine:v,line:m,source:this.css},this.file&&(o&&(R.input.url=o(this.file).toString()),R.input.file=this.file),R}fromOffset(h){let m,b;if(this[r])b=this[r];else{let E=this.css.split(`
|
|
34
|
-
`)
|
|
35
|
-
`," "];return t.split(e,i)},split(e,i,c){let s=[],
|
|
13
|
+
`,colon:": ",commentLeft:" ",commentRight:" ",emptyBody:"",indent:" ",semicolon:!1};function e(c){return c[0].toUpperCase()+c.slice(1)}class i{constructor(s){this.builder=s}atrule(s,a){let o="@"+s.name,p=s.params?this.rawValue(s,"params"):"";if(typeof s.raws.afterName!="undefined"?o+=s.raws.afterName:p&&(o+=" "),s.nodes)this.block(s,o+p);else{let g=(s.raws.between||"")+(a?";":"");this.builder(o+p+g,s)}}beforeAfter(s,a){let o;s.type==="decl"?o=this.raw(s,null,"beforeDecl"):s.type==="comment"?o=this.raw(s,null,"beforeComment"):a==="before"?o=this.raw(s,null,"beforeRule"):o=this.raw(s,null,"beforeClose");let p=s.parent,g=0;for(;p&&p.type!=="root";)g+=1,p=p.parent;if(o.includes(`
|
|
14
|
+
`)){let h=this.raw(s,null,"indent");if(h.length)for(let r=0;r<g;r++)o+=h}return o}block(s,a){let o=this.raw(s,"between","beforeOpen");this.builder(a+o+"{",s,"start");let p;s.nodes&&s.nodes.length?(this.body(s),p=this.raw(s,"after")):p=this.raw(s,"after","emptyBody"),p&&this.builder(p),this.builder("}",s,"end")}body(s){let a=s.nodes.length-1;for(;a>0&&s.nodes[a].type==="comment";)a-=1;let o=this.raw(s,"semicolon");for(let p=0;p<s.nodes.length;p++){let g=s.nodes[p],h=this.raw(g,"before");h&&this.builder(h),this.stringify(g,a!==p||o)}}comment(s){let a=this.raw(s,"left","commentLeft"),o=this.raw(s,"right","commentRight");this.builder("/*"+a+s.text+o+"*/",s)}decl(s,a){let o=this.raw(s,"between","colon"),p=s.prop+o+this.rawValue(s,"value");s.important&&(p+=s.raws.important||" !important"),a&&(p+=";"),this.builder(p,s)}document(s){this.body(s)}raw(s,a,o){let p;if(o||(o=a),a&&(p=s.raws[a],typeof p!="undefined"))return p;let g=s.parent;if(o==="before"&&(!g||g.type==="root"&&g.first===s||g&&g.type==="document"))return"";if(!g)return t[o];let h=s.root();if(h.rawCache||(h.rawCache={}),typeof h.rawCache[o]!="undefined")return h.rawCache[o];if(o==="before"||o==="after")return this.beforeAfter(s,o);{let r="raw"+e(o);this[r]?p=this[r](h,s):h.walk(u=>{if(p=u.raws[a],typeof p!="undefined")return!1})}return typeof p=="undefined"&&(p=t[o]),h.rawCache[o]=p,p}rawBeforeClose(s){let a;return s.walk(o=>{if(o.nodes&&o.nodes.length>0&&typeof o.raws.after!="undefined")return a=o.raws.after,a.includes(`
|
|
15
|
+
`)&&(a=a.replace(/[^\n]+$/,"")),!1}),a&&(a=a.replace(/\S/g,"")),a}rawBeforeComment(s,a){let o;return s.walkComments(p=>{if(typeof p.raws.before!="undefined")return o=p.raws.before,o.includes(`
|
|
16
|
+
`)&&(o=o.replace(/[^\n]+$/,"")),!1}),typeof o=="undefined"?o=this.raw(a,null,"beforeDecl"):o&&(o=o.replace(/\S/g,"")),o}rawBeforeDecl(s,a){let o;return s.walkDecls(p=>{if(typeof p.raws.before!="undefined")return o=p.raws.before,o.includes(`
|
|
17
|
+
`)&&(o=o.replace(/[^\n]+$/,"")),!1}),typeof o=="undefined"?o=this.raw(a,null,"beforeRule"):o&&(o=o.replace(/\S/g,"")),o}rawBeforeOpen(s){let a;return s.walk(o=>{if(o.type!=="decl"&&(a=o.raws.between,typeof a!="undefined"))return!1}),a}rawBeforeRule(s){let a;return s.walk(o=>{if(o.nodes&&(o.parent!==s||s.first!==o)&&typeof o.raws.before!="undefined")return a=o.raws.before,a.includes(`
|
|
18
|
+
`)&&(a=a.replace(/[^\n]+$/,"")),!1}),a&&(a=a.replace(/\S/g,"")),a}rawColon(s){let a;return s.walkDecls(o=>{if(typeof o.raws.between!="undefined")return a=o.raws.between.replace(/[^\s:]/g,""),!1}),a}rawEmptyBody(s){let a;return s.walk(o=>{if(o.nodes&&o.nodes.length===0&&(a=o.raws.after,typeof a!="undefined"))return!1}),a}rawIndent(s){if(s.raws.indent)return s.raws.indent;let a;return s.walk(o=>{let p=o.parent;if(p&&p!==s&&p.parent&&p.parent===s&&typeof o.raws.before!="undefined"){let g=o.raws.before.split(`
|
|
19
|
+
`);return a=g[g.length-1],a=a.replace(/\S/g,""),!1}}),a}rawSemicolon(s){let a;return s.walk(o=>{if(o.nodes&&o.nodes.length&&o.last.type==="decl"&&(a=o.raws.semicolon,typeof a!="undefined"))return!1}),a}rawValue(s,a){let o=s[a],p=s.raws[a];return p&&p.value===o?p.raw:o}root(s){this.body(s),s.raws.after&&this.builder(s.raws.after)}rule(s){this.block(s,this.rawValue(s,"selector")),s.raws.ownSemicolon&&this.builder(s.raws.ownSemicolon,s,"end")}stringify(s,a){if(!this[s.type])throw new Error("Unknown AST node type "+s.type+". Maybe you need to change PostCSS stringifier.");this[s.type](s,a)}}return ge=i,i.default=i,ge}var we,wt;function ne(){if(wt)return we;wt=1;let t=Vt();function e(i,c){new t(c).stringify(i)}return we=e,e.default=e,we}var re={},yt;function Ye(){return yt||(yt=1,re.isClean=Symbol("isClean"),re.my=Symbol("my")),re}var ye,Rt;function oe(){if(Rt)return ye;Rt=1;let t=Ve(),e=Vt(),i=ne(),{isClean:c,my:s}=Ye();function a(g,h){let r=new g.constructor;for(let u in g){if(!Object.prototype.hasOwnProperty.call(g,u)||u==="proxyCache")continue;let l=g[u],n=typeof l;u==="parent"&&n==="object"?h&&(r[u]=h):u==="source"?r[u]=l:Array.isArray(l)?r[u]=l.map(f=>a(f,r)):(n==="object"&&l!==null&&(l=a(l)),r[u]=l)}return r}function o(g,h){if(h&&typeof h.offset!="undefined")return h.offset;let r=1,u=1,l=0;for(let n=0;n<g.length;n++){if(u===h.line&&r===h.column){l=n;break}g[n]===`
|
|
20
|
+
`?(r=1,u+=1):r+=1}return l}class p{get proxyOf(){return this}constructor(h={}){this.raws={},this[c]=!1,this[s]=!0;for(let r in h)if(r==="nodes"){this.nodes=[];for(let u of h[r])typeof u.clone=="function"?this.append(u.clone()):this.append(u)}else this[r]=h[r]}addToError(h){if(h.postcssNode=this,h.stack&&this.source&&/\n\s{4}at /.test(h.stack)){let r=this.source;h.stack=h.stack.replace(/\n\s{4}at /,`$&${r.input.from}:${r.start.line}:${r.start.column}$&`)}return h}after(h){return this.parent.insertAfter(this,h),this}assign(h={}){for(let r in h)this[r]=h[r];return this}before(h){return this.parent.insertBefore(this,h),this}cleanRaws(h){delete this.raws.before,delete this.raws.after,h||delete this.raws.between}clone(h={}){let r=a(this);for(let u in h)r[u]=h[u];return r}cloneAfter(h={}){let r=this.clone(h);return this.parent.insertAfter(this,r),r}cloneBefore(h={}){let r=this.clone(h);return this.parent.insertBefore(this,r),r}error(h,r={}){if(this.source){let{end:u,start:l}=this.rangeBy(r);return this.source.input.error(h,{column:l.column,line:l.line},{column:u.column,line:u.line},r)}return new t(h)}getProxyProcessor(){return{get(h,r){return r==="proxyOf"?h:r==="root"?()=>h.root().toProxy():h[r]},set(h,r,u){return h[r]===u||(h[r]=u,(r==="prop"||r==="value"||r==="name"||r==="params"||r==="important"||r==="text")&&h.markDirty()),!0}}}markClean(){this[c]=!0}markDirty(){if(this[c]){this[c]=!1;let h=this;for(;h=h.parent;)h[c]=!1}}next(){if(!this.parent)return;let h=this.parent.index(this);return this.parent.nodes[h+1]}positionBy(h={}){let r=this.source.start;if(h.index)r=this.positionInside(h.index);else if(h.word){let u="document"in this.source.input?this.source.input.document:this.source.input.css,n=u.slice(o(u,this.source.start),o(u,this.source.end)).indexOf(h.word);n!==-1&&(r=this.positionInside(n))}return r}positionInside(h){let r=this.source.start.column,u=this.source.start.line,l="document"in this.source.input?this.source.input.document:this.source.input.css,n=o(l,this.source.start),f=n+h;for(let d=n;d<f;d++)l[d]===`
|
|
21
|
+
`?(r=1,u+=1):r+=1;return{column:r,line:u,offset:f}}prev(){if(!this.parent)return;let h=this.parent.index(this);return this.parent.nodes[h-1]}rangeBy(h={}){let r="document"in this.source.input?this.source.input.document:this.source.input.css,u={column:this.source.start.column,line:this.source.start.line,offset:o(r,this.source.start)},l=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(r,this.source.end)+1}:{column:u.column+1,line:u.line,offset:u.offset+1};if(h.word){let f=r.slice(o(r,this.source.start),o(r,this.source.end)).indexOf(h.word);f!==-1&&(u=this.positionInside(f),l=this.positionInside(f+h.word.length))}else h.start?u={column:h.start.column,line:h.start.line,offset:o(r,h.start)}:h.index&&(u=this.positionInside(h.index)),h.end?l={column:h.end.column,line:h.end.line,offset:o(r,h.end)}:typeof h.endIndex=="number"?l=this.positionInside(h.endIndex):h.index&&(l=this.positionInside(h.index+1));return(l.line<u.line||l.line===u.line&&l.column<=u.column)&&(l={column:u.column+1,line:u.line,offset:u.offset+1}),{end:l,start:u}}raw(h,r){return new e().raw(this,h,r)}remove(){return this.parent&&this.parent.removeChild(this),this.parent=void 0,this}replaceWith(...h){if(this.parent){let r=this,u=!1;for(let l of h)l===this?u=!0:u?(this.parent.insertAfter(r,l),r=l):this.parent.insertBefore(r,l);u||this.remove()}return this}root(){let h=this;for(;h.parent&&h.parent.type!=="document";)h=h.parent;return h}toJSON(h,r){let u={},l=r==null;r=r||new Map;let n=0;for(let f in this){if(!Object.prototype.hasOwnProperty.call(this,f)||f==="parent"||f==="proxyCache")continue;let d=this[f];if(Array.isArray(d))u[f]=d.map(m=>typeof m=="object"&&m.toJSON?m.toJSON(null,r):m);else if(typeof d=="object"&&d.toJSON)u[f]=d.toJSON(null,r);else if(f==="source"){if(d==null)continue;let m=r.get(d.input);m==null&&(m=n,r.set(d.input,n),n++),u[f]={end:d.end,inputId:m,start:d.start}}else u[f]=d}return l&&(u.inputs=[...r.keys()].map(f=>f.toJSON())),u}toProxy(){return this.proxyCache||(this.proxyCache=new Proxy(this,this.getProxyProcessor())),this.proxyCache}toString(h=i){h.stringify&&(h=h.stringify);let r="";return h(this,u=>{r+=u}),r}warn(h,r,u={}){let l={node:this};for(let n in u)l[n]=u[n];return h.warn(r,l)}}return ye=p,p.default=p,ye}var Re,Et;function H(){if(Et)return Re;Et=1;let t=oe();class e extends t{constructor(c){super(c),this.type="comment"}}return Re=e,e.default=e,Re}var Ee,bt;function le(){if(bt)return Ee;bt=1;let t=oe();class e extends t{get variable(){return this.prop.startsWith("--")||this.prop[0]==="$"}constructor(c){c&&typeof c.value!="undefined"&&typeof c.value!="string"&&(c=Y(k({},c),{value:String(c.value)})),super(c),this.type="decl"}}return Ee=e,e.default=e,Ee}var be,Ct;function W(){if(Ct)return be;Ct=1;let t=H(),e=le(),i=oe(),{isClean:c,my:s}=Ye(),a,o,p,g;function h(l){return l.map(n=>(n.nodes&&(n.nodes=h(n.nodes)),delete n.source,n))}function r(l){if(l[c]=!1,l.proxyOf.nodes)for(let n of l.proxyOf.nodes)r(n)}class u extends i{get first(){if(this.proxyOf.nodes)return this.proxyOf.nodes[0]}get last(){if(this.proxyOf.nodes)return this.proxyOf.nodes[this.proxyOf.nodes.length-1]}append(...n){for(let f of n){let d=this.normalize(f,this.last);for(let m of d)this.proxyOf.nodes.push(m)}return this.markDirty(),this}cleanRaws(n){if(super.cleanRaws(n),this.nodes)for(let f of this.nodes)f.cleanRaws(n)}each(n){if(!this.proxyOf.nodes)return;let f=this.getIterator(),d,m;for(;this.indexes[f]<this.proxyOf.nodes.length&&(d=this.indexes[f],m=n(this.proxyOf.nodes[d],d),m!==!1);)this.indexes[f]+=1;return delete this.indexes[f],m}every(n){return this.nodes.every(n)}getIterator(){this.lastEach||(this.lastEach=0),this.indexes||(this.indexes={}),this.lastEach+=1;let n=this.lastEach;return this.indexes[n]=0,n}getProxyProcessor(){return{get(n,f){return f==="proxyOf"?n:n[f]?f==="each"||typeof f=="string"&&f.startsWith("walk")?(...d)=>n[f](...d.map(m=>typeof m=="function"?(b,w)=>m(b.toProxy(),w):m)):f==="every"||f==="some"?d=>n[f]((m,...b)=>d(m.toProxy(),...b)):f==="root"?()=>n.root().toProxy():f==="nodes"?n.nodes.map(d=>d.toProxy()):f==="first"||f==="last"?n[f].toProxy():n[f]:n[f]},set(n,f,d){return n[f]===d||(n[f]=d,(f==="name"||f==="params"||f==="selector")&&n.markDirty()),!0}}}index(n){return typeof n=="number"?n:(n.proxyOf&&(n=n.proxyOf),this.proxyOf.nodes.indexOf(n))}insertAfter(n,f){let d=this.index(n),m=this.normalize(f,this.proxyOf.nodes[d]).reverse();d=this.index(n);for(let w of m)this.proxyOf.nodes.splice(d+1,0,w);let b;for(let w in this.indexes)b=this.indexes[w],d<b&&(this.indexes[w]=b+m.length);return this.markDirty(),this}insertBefore(n,f){let d=this.index(n),m=d===0?"prepend":!1,b=this.normalize(f,this.proxyOf.nodes[d],m).reverse();d=this.index(n);for(let E of b)this.proxyOf.nodes.splice(d,0,E);let w;for(let E in this.indexes)w=this.indexes[E],d<=w&&(this.indexes[E]=w+b.length);return this.markDirty(),this}normalize(n,f){if(typeof n=="string")n=h(o(n).nodes);else if(typeof n=="undefined")n=[];else if(Array.isArray(n)){n=n.slice(0);for(let m of n)m.parent&&m.parent.removeChild(m,"ignore")}else if(n.type==="root"&&this.type!=="document"){n=n.nodes.slice(0);for(let m of n)m.parent&&m.parent.removeChild(m,"ignore")}else if(n.type)n=[n];else if(n.prop){if(typeof n.value=="undefined")throw new Error("Value field is missed in node creation");typeof n.value!="string"&&(n.value=String(n.value)),n=[new e(n)]}else if(n.selector||n.selectors)n=[new g(n)];else if(n.name)n=[new a(n)];else if(n.text)n=[new t(n)];else throw new Error("Unknown node type in node creation");return n.map(m=>(m[s]||u.rebuild(m),m=m.proxyOf,m.parent&&m.parent.removeChild(m),m[c]&&r(m),m.raws||(m.raws={}),typeof m.raws.before=="undefined"&&f&&typeof f.raws.before!="undefined"&&(m.raws.before=f.raws.before.replace(/\S/g,"")),m.parent=this.proxyOf,m))}prepend(...n){n=n.reverse();for(let f of n){let d=this.normalize(f,this.first,"prepend").reverse();for(let m of d)this.proxyOf.nodes.unshift(m);for(let m in this.indexes)this.indexes[m]=this.indexes[m]+d.length}return this.markDirty(),this}push(n){return n.parent=this,this.proxyOf.nodes.push(n),this}removeAll(){for(let n of this.proxyOf.nodes)n.parent=void 0;return this.proxyOf.nodes=[],this.markDirty(),this}removeChild(n){n=this.index(n),this.proxyOf.nodes[n].parent=void 0,this.proxyOf.nodes.splice(n,1);let f;for(let d in this.indexes)f=this.indexes[d],f>=n&&(this.indexes[d]=f-1);return this.markDirty(),this}replaceValues(n,f,d){return d||(d=f,f={}),this.walkDecls(m=>{f.props&&!f.props.includes(m.prop)||f.fast&&!m.value.includes(f.fast)||(m.value=m.value.replace(n,d))}),this.markDirty(),this}some(n){return this.nodes.some(n)}walk(n){return this.each((f,d)=>{let m;try{m=n(f,d)}catch(b){throw f.addToError(b)}return m!==!1&&f.walk&&(m=f.walk(n)),m})}walkAtRules(n,f){return f?n instanceof RegExp?this.walk((d,m)=>{if(d.type==="atrule"&&n.test(d.name))return f(d,m)}):this.walk((d,m)=>{if(d.type==="atrule"&&d.name===n)return f(d,m)}):(f=n,this.walk((d,m)=>{if(d.type==="atrule")return f(d,m)}))}walkComments(n){return this.walk((f,d)=>{if(f.type==="comment")return n(f,d)})}walkDecls(n,f){return f?n instanceof RegExp?this.walk((d,m)=>{if(d.type==="decl"&&n.test(d.prop))return f(d,m)}):this.walk((d,m)=>{if(d.type==="decl"&&d.prop===n)return f(d,m)}):(f=n,this.walk((d,m)=>{if(d.type==="decl")return f(d,m)}))}walkRules(n,f){return f?n instanceof RegExp?this.walk((d,m)=>{if(d.type==="rule"&&n.test(d.selector))return f(d,m)}):this.walk((d,m)=>{if(d.type==="rule"&&d.selector===n)return f(d,m)}):(f=n,this.walk((d,m)=>{if(d.type==="rule")return f(d,m)}))}}return u.registerParse=l=>{o=l},u.registerRule=l=>{g=l},u.registerAtRule=l=>{a=l},u.registerRoot=l=>{p=l},be=u,u.default=u,u.rebuild=l=>{l.type==="atrule"?Object.setPrototypeOf(l,a.prototype):l.type==="rule"?Object.setPrototypeOf(l,g.prototype):l.type==="decl"?Object.setPrototypeOf(l,e.prototype):l.type==="comment"?Object.setPrototypeOf(l,t.prototype):l.type==="root"&&Object.setPrototypeOf(l,p.prototype),l[s]=!0,l.nodes&&l.nodes.forEach(n=>{u.rebuild(n)})},be}var Ce,xt;function He(){if(xt)return Ce;xt=1;let t=W();class e extends t{constructor(c){super(c),this.type="atrule"}append(...c){return this.proxyOf.nodes||(this.nodes=[]),super.append(...c)}prepend(...c){return this.proxyOf.nodes||(this.nodes=[]),super.prepend(...c)}}return Ce=e,e.default=e,t.registerAtRule(e),Ce}var xe,vt;function Je(){if(vt)return xe;vt=1;let t=W(),e,i;class c extends t{constructor(a){super(k({type:"document"},a)),this.nodes||(this.nodes=[])}toResult(a={}){return new e(new i,this,a).stringify()}}return c.registerLazyResult=s=>{e=s},c.registerProcessor=s=>{i=s},xe=c,c.default=c,xe}var ve,St;function Fr(){if(St)return ve;St=1;let t="useandom-26T198340PX75pxJACKVERYMINDBUSHWOLF_GQZbfghjklqvwyzrict";return ve={nanoid:(c=21)=>{let s="",a=c|0;for(;a--;)s+=t[Math.random()*64|0];return s},customAlphabet:(c,s=21)=>(a=s)=>{let o="",p=a|0;for(;p--;)o+=c[Math.random()*c.length|0];return o}},ve}var Se,Nt;function Yt(){if(Nt)return Se;Nt=1;let{existsSync:t,readFileSync:e}=B,{dirname:i,join:c}=B,{SourceMapConsumer:s,SourceMapGenerator:a}=B;function o(g){return Buffer?Buffer.from(g,"base64").toString():window.atob(g)}class p{constructor(h,r){if(r.map===!1)return;this.loadAnnotation(h),this.inline=this.startWith(this.annotation,"data:");let u=r.map?r.map.prev:void 0,l=this.loadMap(r.from,u);!this.mapFile&&r.from&&(this.mapFile=r.from),this.mapFile&&(this.root=i(this.mapFile)),l&&(this.text=l)}consumer(){return this.consumerCache||(this.consumerCache=new s(this.text)),this.consumerCache}decodeInline(h){let r=/^data:application\/json;charset=utf-?8;base64,/,u=/^data:application\/json;base64,/,l=/^data:application\/json;charset=utf-?8,/,n=/^data:application\/json,/,f=h.match(l)||h.match(n);if(f)return decodeURIComponent(h.substr(f[0].length));let d=h.match(r)||h.match(u);if(d)return o(h.substr(d[0].length));let m=h.match(/data:application\/json;([^,]+),/)[1];throw new Error("Unsupported source map encoding "+m)}getAnnotationURL(h){return h.replace(/^\/\*\s*# sourceMappingURL=/,"").trim()}isMap(h){return typeof h!="object"?!1:typeof h.mappings=="string"||typeof h._mappings=="string"||Array.isArray(h.sections)}loadAnnotation(h){let r=h.match(/\/\*\s*# sourceMappingURL=/g);if(!r)return;let u=h.lastIndexOf(r.pop()),l=h.indexOf("*/",u);u>-1&&l>-1&&(this.annotation=this.getAnnotationURL(h.substring(u,l)))}loadFile(h){if(this.root=i(h),t(h))return this.mapFile=h,e(h,"utf-8").toString().trim()}loadMap(h,r){if(r===!1)return!1;if(r){if(typeof r=="string")return r;if(typeof r=="function"){let u=r(h);if(u){let l=this.loadFile(u);if(!l)throw new Error("Unable to load previous source map: "+u.toString());return l}}else{if(r instanceof s)return a.fromSourceMap(r).toString();if(r instanceof a)return r.toString();if(this.isMap(r))return JSON.stringify(r);throw new Error("Unsupported previous source map format: "+r.toString())}}else{if(this.inline)return this.decodeInline(this.annotation);if(this.annotation){let u=this.annotation;return h&&(u=c(i(h),u)),this.loadFile(u)}}}startWith(h,r){return h?h.substr(0,r.length)===r:!1}withContent(){return!!(this.consumer().sourcesContent&&this.consumer().sourcesContent.length>0)}}return Se=p,p.default=p,Se}var Ne,Ot;function ae(){if(Ot)return Ne;Ot=1;let{nanoid:t}=Fr(),{isAbsolute:e,resolve:i}=B,{SourceMapConsumer:c,SourceMapGenerator:s}=B,{fileURLToPath:a,pathToFileURL:o}=B,p=Ve(),g=Yt(),h=B,r=Symbol("lineToIndexCache"),u=!!(c&&s),l=!!(i&&e);function n(d){if(d[r])return d[r];let m=d.css.split(`
|
|
22
|
+
`),b=new Array(m.length),w=0;for(let E=0,x=m.length;E<x;E++)b[E]=w,w+=m[E].length+1;return d[r]=b,b}class f{get from(){return this.file||this.id}constructor(m,b={}){if(m===null||typeof m=="undefined"||typeof m=="object"&&!m.toString)throw new Error(`PostCSS received ${m} instead of CSS string`);if(this.css=m.toString(),this.css[0]==="\uFEFF"||this.css[0]==="\uFFFE"?(this.hasBOM=!0,this.css=this.css.slice(1)):this.hasBOM=!1,this.document=this.css,b.document&&(this.document=b.document.toString()),b.from&&(!l||/^\w+:\/\//.test(b.from)||e(b.from)?this.file=b.from:this.file=i(b.from)),l&&u){let w=new g(this.css,b);if(w.text){this.map=w;let E=w.consumer().file;!this.file&&E&&(this.file=this.mapResolve(E))}}this.file||(this.id="<input css "+t(6)+">"),this.map&&(this.map.file=this.from)}error(m,b,w,E={}){let x,y,R,C,S;if(b&&typeof b=="object"){let N=b,I=w;if(typeof N.offset=="number"){C=N.offset;let _=this.fromOffset(C);b=_.line,w=_.col}else b=N.line,w=N.column,C=this.fromLineAndColumn(b,w);if(typeof I.offset=="number"){R=I.offset;let _=this.fromOffset(R);y=_.line,x=_.col}else y=I.line,x=I.column,R=this.fromLineAndColumn(I.line,I.column)}else if(w)C=this.fromLineAndColumn(b,w);else{C=b;let N=this.fromOffset(C);b=N.line,w=N.col}let D=this.origin(b,w,y,x);return D?S=new p(m,D.endLine===void 0?D.line:{column:D.column,line:D.line},D.endLine===void 0?D.column:{column:D.endColumn,line:D.endLine},D.source,D.file,E.plugin):S=new p(m,y===void 0?b:{column:w,line:b},y===void 0?w:{column:x,line:y},this.css,this.file,E.plugin),S.input={column:w,endColumn:x,endLine:y,endOffset:R,line:b,offset:C,source:this.css},this.file&&(o&&(S.input.url=o(this.file).toString()),S.input.file=this.file),S}fromLineAndColumn(m,b){return n(this)[m-1]+b-1}fromOffset(m){let b=n(this),w=b[b.length-1],E=0;if(m>=w)E=b.length-1;else{let x=b.length-2,y;for(;E<x;)if(y=E+(x-E>>1),m<b[y])x=y-1;else if(m>=b[y+1])E=y+1;else{E=y;break}}return{col:m-b[E]+1,line:E+1}}mapResolve(m){return/^\w+:\/\//.test(m)?m:i(this.map.consumer().sourceRoot||this.map.root||".",m)}origin(m,b,w,E){if(!this.map)return!1;let x=this.map.consumer(),y=x.originalPositionFor({column:b,line:m});if(!y.source)return!1;let R;typeof w=="number"&&(R=x.originalPositionFor({column:E,line:w}));let C;e(y.source)?C=o(y.source):C=new URL(y.source,this.map.consumer().sourceRoot||o(this.map.mapFile));let S={column:y.column,endColumn:R&&R.column,endLine:R&&R.line,line:y.line,url:C.toString()};if(C.protocol==="file:")if(a)S.file=a(C);else throw new Error("file: protocol is not available in this PostCSS build");let D=x.sourceContentFor(y.source);return D&&(S.source=D),S}toJSON(){let m={};for(let b of["hasBOM","css","file","id"])this[b]!=null&&(m[b]=this[b]);return this.map&&(m.map=k({},this.map),m.map.consumerCache&&(m.map.consumerCache=void 0)),m}}return Ne=f,f.default=f,h&&h.registerInput&&h.registerInput(f),Ne}var Oe,Dt;function J(){if(Dt)return Oe;Dt=1;let t=W(),e,i;class c extends t{constructor(a){super(a),this.type="root",this.nodes||(this.nodes=[])}normalize(a,o,p){let g=super.normalize(a);if(o){if(p==="prepend")this.nodes.length>1?o.raws.before=this.nodes[1].raws.before:delete o.raws.before;else if(this.first!==o)for(let h of g)h.raws.before=o.raws.before}return g}removeChild(a,o){let p=this.index(a);return!o&&p===0&&this.nodes.length>1&&(this.nodes[1].raws.before=this.nodes[p].raws.before),super.removeChild(a)}toResult(a={}){return new e(new i,this,a).stringify()}}return c.registerLazyResult=s=>{e=s},c.registerProcessor=s=>{i=s},Oe=c,c.default=c,t.registerRoot(c),Oe}var De,At;function Ht(){if(At)return De;At=1;let t={comma(e){return t.split(e,[","],!0)},space(e){let i=[" ",`
|
|
23
|
+
`," "];return t.split(e,i)},split(e,i,c){let s=[],a="",o=!1,p=0,g=!1,h="",r=!1;for(let u of e)r?r=!1:u==="\\"?r=!0:g?u===h&&(g=!1):u==='"'||u==="'"?(g=!0,h=u):u==="("?p+=1:u===")"?p>0&&(p-=1):p===0&&i.includes(u)&&(o=!0),o?(a!==""&&s.push(a.trim()),a="",o=!1):a+=u;return(c||a!=="")&&s.push(a.trim()),s}};return De=t,t.default=t,De}var Ae,Mt;function Xe(){if(Mt)return Ae;Mt=1;let t=W(),e=Ht();class i extends t{get selectors(){return e.comma(this.selector)}set selectors(s){let a=this.selector?this.selector.match(/,\s*/):null,o=a?a[0]:","+this.raw("between","beforeOpen");this.selector=s.join(o)}constructor(s){super(s),this.type="rule",this.nodes||(this.nodes=[])}}return Ae=i,i.default=i,t.registerRule(i),Ae}var Me,_t;function zr(){if(_t)return Me;_t=1;let t=He(),e=H(),i=le(),c=ae(),s=Yt(),a=J(),o=Xe();function p(g,h){if(Array.isArray(g))return g.map(f=>p(f));let l=g,{inputs:r}=l,u=de(l,["inputs"]);if(r){h=[];for(let f of r){let d=Y(k({},f),{__proto__:c.prototype});d.map&&(d.map=Y(k({},d.map),{__proto__:s.prototype})),h.push(d)}}if(u.nodes&&(u.nodes=g.nodes.map(f=>p(f,h))),u.source){let n=u.source,{inputId:f}=n,d=de(n,["inputId"]);u.source=d,f!=null&&(u.source.input=h[f])}if(u.type==="root")return new a(u);if(u.type==="decl")return new i(u);if(u.type==="rule")return new o(u);if(u.type==="comment")return new e(u);if(u.type==="atrule")return new t(u);throw new Error("Unknown node type: "+g.type)}return Me=p,p.default=p,Me}var _e,Tt;function Jt(){if(Tt)return _e;Tt=1;let{dirname:t,relative:e,resolve:i,sep:c}=B,{SourceMapConsumer:s,SourceMapGenerator:a}=B,{pathToFileURL:o}=B,p=ae(),g=!!(s&&a),h=!!(t&&i&&e&&c);class r{constructor(l,n,f,d){this.stringify=l,this.mapOpts=f.map||{},this.root=n,this.opts=f,this.css=d,this.originalCSS=d,this.usesFileUrls=!this.mapOpts.from&&this.mapOpts.absolute,this.memoizedFileURLs=new Map,this.memoizedPaths=new Map,this.memoizedURLs=new Map}addAnnotation(){let l;this.isInline()?l="data:application/json;base64,"+this.toBase64(this.map.toString()):typeof this.mapOpts.annotation=="string"?l=this.mapOpts.annotation:typeof this.mapOpts.annotation=="function"?l=this.mapOpts.annotation(this.opts.to,this.root):l=this.outputFile()+".map";let n=`
|
|
36
24
|
`;this.css.includes(`\r
|
|
37
25
|
`)&&(n=`\r
|
|
38
|
-
`),this.css+=n+"/*# sourceMappingURL="+
|
|
39
|
-
`),n=w.length-m):n+=w.length,E&&v!=="start"){let R=E.parent||{raws:{}};(!(E.type==="decl"||E.type==="atrule"&&!E.nodes)||E!==R.last||R.raws.semicolon)&&(E.source&&E.source.end?(h.source=this.sourcePath(E),h.original.line=E.source.end.line,h.original.column=E.source.end.column-1,h.generated.line=a,h.generated.column=n-2,this.map.addMapping(h)):(h.source=d,h.original.line=1,h.original.column=0,h.generated.line=a,h.generated.column=n-1,this.map.addMapping(h)))}})}isAnnotation(){return this.isInline()?!0:typeof this.mapOpts.annotation!="undefined"?this.mapOpts.annotation:this.previous().length?this.previous().some(a=>a.annotation):!0}isInline(){if(typeof this.mapOpts.inline!="undefined")return this.mapOpts.inline;let a=this.mapOpts.annotation;return typeof a!="undefined"&&a!==!0?!1:this.previous().length?this.previous().some(n=>n.inline):!0}isMap(){return typeof this.opts.map!="undefined"?!!this.opts.map:this.previous().length>0}isSourcesContent(){return typeof this.mapOpts.sourcesContent!="undefined"?this.mapOpts.sourcesContent:this.previous().length?this.previous().some(a=>a.withContent()):!0}outputFile(){return this.opts.to?this.path(this.opts.to):this.opts.from?this.path(this.opts.from):"to.css"}path(a){if(this.mapOpts.absolute||a.charCodeAt(0)===60||/^\w+:\/\//.test(a))return a;let n=this.memoizedPaths.get(a);if(n)return n;let d=this.opts.to?t(this.opts.to):".";typeof this.mapOpts.annotation=="string"&&(d=t(i(d,this.mapOpts.annotation)));let h=e(d,a);return this.memoizedPaths.set(a,h),h}previous(){if(!this.previousMaps)if(this.previousMaps=[],this.root)this.root.walk(a=>{if(a.source&&a.source.input.map){let n=a.source.input.map;this.previousMaps.includes(n)||this.previousMaps.push(n)}});else{let a=new p(this.originalCSS,this.opts);a.map&&this.previousMaps.push(a.map)}return this.previousMaps}setSourcesContent(){let a={};if(this.root)this.root.walk(n=>{if(n.source){let d=n.source.input.from;if(d&&!a[d]){a[d]=!0;let h=this.usesFileUrls?this.toFileUrl(d):this.toUrl(this.path(d));this.map.setSourceContent(h,n.source.input.css)}}});else if(this.css){let n=this.opts.from?this.toUrl(this.path(this.opts.from)):"<no source>";this.map.setSourceContent(n,this.css)}}sourcePath(a){return this.mapOpts.from?this.toUrl(this.mapOpts.from):this.usesFileUrls?this.toFileUrl(a.source.input.from):this.toUrl(this.path(a.source.input.from))}toBase64(a){return Buffer?Buffer.from(a).toString("base64"):window.btoa(unescape(encodeURIComponent(a)))}toFileUrl(a){let n=this.memoizedFileURLs.get(a);if(n)return n;if(o){let d=o(a).toString();return this.memoizedFileURLs.set(a,d),d}else throw new Error("`map.absolute` option is not available in this PostCSS build")}toUrl(a){let n=this.memoizedURLs.get(a);if(n)return n;c==="\\"&&(a=a.replace(/\\/g,"/"));let d=encodeURI(a).replace(/[#?]/g,encodeURIComponent);return this.memoizedURLs.set(a,d),d}}return _e=r,_e}var Te,It;function Xt(){if(It)return Te;It=1;const t=39,e=34,i=92,c=47,s=10,l=32,o=12,p=9,g=13,f=91,r=93,u=40,a=41,n=123,d=125,h=59,m=42,b=58,w=64,E=/[\t\n\f\r "#'()/;[\\\]{}]/g,v=/[\t\n\f\r !"#'():;@[\\\]{}]|\/(?=\*)/g,R=/.[\r\n"'(/\\]/,y=/[\da-f]/i;return Te=function(N,M={}){let O=N.css.valueOf(),P=M.ignoreErrors,T,ce,Q,S,ot,L,z,j,q,lt,at=O.length,D=0,he=[],K=[];function br(){return D}function fe(G){throw N.error("Unclosed "+G,D)}function Cr(){return K.length===0&&D>=at}function vr(G){if(K.length)return K.pop();if(D>=at)return;let pe=G?G.ignoreUnclosed:!1;switch(T=O.charCodeAt(D),T){case s:case l:case p:case g:case o:{S=D;do S+=1,T=O.charCodeAt(S);while(T===l||T===s||T===p||T===g||T===o);L=["space",O.slice(D,S)],D=S-1;break}case f:case r:case n:case d:case b:case h:case a:{let ut=String.fromCharCode(T);L=[ut,ut,D];break}case u:{if(lt=he.length?he.pop()[1]:"",q=O.charCodeAt(D+1),lt==="url"&&q!==t&&q!==e&&q!==l&&q!==s&&q!==p&&q!==o&&q!==g){S=D;do{if(z=!1,S=O.indexOf(")",S+1),S===-1)if(P||pe){S=D;break}else fe("bracket");for(j=S;O.charCodeAt(j-1)===i;)j-=1,z=!z}while(z);L=["brackets",O.slice(D,S+1),D,S],D=S}else S=O.indexOf(")",D+1),ce=O.slice(D,S+1),S===-1||R.test(ce)?L=["(","(",D]:(L=["brackets",ce,D,S],D=S);break}case t:case e:{ot=T===t?"'":'"',S=D;do{if(z=!1,S=O.indexOf(ot,S+1),S===-1)if(P||pe){S=D+1;break}else fe("string");for(j=S;O.charCodeAt(j-1)===i;)j-=1,z=!z}while(z);L=["string",O.slice(D,S+1),D,S],D=S;break}case w:{E.lastIndex=D+1,E.test(O),E.lastIndex===0?S=O.length-1:S=E.lastIndex-2,L=["at-word",O.slice(D,S+1),D,S],D=S;break}case i:{for(S=D,Q=!0;O.charCodeAt(S+1)===i;)S+=1,Q=!Q;if(T=O.charCodeAt(S+1),Q&&T!==c&&T!==l&&T!==s&&T!==p&&T!==g&&T!==o&&(S+=1,y.test(O.charAt(S)))){for(;y.test(O.charAt(S+1));)S+=1;O.charCodeAt(S+1)===l&&(S+=1)}L=["word",O.slice(D,S+1),D,S],D=S;break}default:{T===c&&O.charCodeAt(D+1)===m?(S=O.indexOf("*/",D+2)+1,S===0&&(P||pe?S=O.length:fe("comment")),L=["comment",O.slice(D,S+1),D,S],D=S):(v.lastIndex=D+1,v.test(O),v.lastIndex===0?S=O.length-1:S=v.lastIndex-2,L=["word",O.slice(D,S+1),D,S],he.push(L),D=S);break}}return D++,L}function xr(G){K.push(G)}return{back:xr,endOfFile:Cr,nextToken:vr,position:br}},Te}var Ie,Pt;function Zt(){if(Pt)return Ie;Pt=1;let t=He(),e=H(),i=le(),c=J(),s=Xe(),l=Xt();const o={empty:!0,space:!0};function p(f){for(let r=f.length-1;r>=0;r--){let u=f[r],a=u[3]||u[2];if(a)return a}}class g{constructor(r){this.input=r,this.root=new c,this.current=this.root,this.spaces="",this.semicolon=!1,this.createTokenizer(),this.root.source={input:r,start:{column:1,line:1,offset:0}}}atrule(r){let u=new t;u.name=r[1].slice(1),u.name===""&&this.unnamedAtrule(u,r),this.init(u,r[2]);let a,n,d,h=!1,m=!1,b=[],w=[];for(;!this.tokenizer.endOfFile();){if(r=this.tokenizer.nextToken(),a=r[0],a==="("||a==="["?w.push(a==="("?")":"]"):a==="{"&&w.length>0?w.push("}"):a===w[w.length-1]&&w.pop(),w.length===0)if(a===";"){u.source.end=this.getPosition(r[2]),u.source.end.offset++,this.semicolon=!0;break}else if(a==="{"){m=!0;break}else if(a==="}"){if(b.length>0){for(d=b.length-1,n=b[d];n&&n[0]==="space";)n=b[--d];n&&(u.source.end=this.getPosition(n[3]||n[2]),u.source.end.offset++)}this.end(r);break}else b.push(r);else b.push(r);if(this.tokenizer.endOfFile()){h=!0;break}}u.raws.between=this.spacesAndCommentsFromEnd(b),b.length?(u.raws.afterName=this.spacesAndCommentsFromStart(b),this.raw(u,"params",b),h&&(r=b[b.length-1],u.source.end=this.getPosition(r[3]||r[2]),u.source.end.offset++,this.spaces=u.raws.between,u.raws.between="")):(u.raws.afterName="",u.params=""),m&&(u.nodes=[],this.current=u)}checkMissedSemicolon(r){let u=this.colon(r);if(u===!1)return;let a=0,n;for(let d=u-1;d>=0&&(n=r[d],!(n[0]!=="space"&&(a+=1,a===2)));d--);throw this.input.error("Missed semicolon",n[0]==="word"?n[3]+1:n[2])}colon(r){let u=0,a,n,d;for(let[h,m]of r.entries()){if(n=m,d=n[0],d==="("&&(u+=1),d===")"&&(u-=1),u===0&&d===":")if(!a)this.doubleColon(n);else{if(a[0]==="word"&&a[1]==="progid")continue;return h}a=n}return!1}comment(r){let u=new e;this.init(u,r[2]),u.source.end=this.getPosition(r[3]||r[2]),u.source.end.offset++;let a=r[1].slice(2,-2);if(/^\s*$/.test(a))u.text="",u.raws.left=a,u.raws.right="";else{let n=a.match(/^(\s*)([^]*\S)(\s*)$/);u.text=n[2],u.raws.left=n[1],u.raws.right=n[3]}}createTokenizer(){this.tokenizer=l(this.input)}decl(r,u){let a=new i;this.init(a,r[0][2]);let n=r[r.length-1];for(n[0]===";"&&(this.semicolon=!0,r.pop()),a.source.end=this.getPosition(n[3]||n[2]||p(r)),a.source.end.offset++;r[0][0]!=="word";)r.length===1&&this.unknownWord(r),a.raws.before+=r.shift()[1];for(a.source.start=this.getPosition(r[0][2]),a.prop="";r.length;){let w=r[0][0];if(w===":"||w==="space"||w==="comment")break;a.prop+=r.shift()[1]}a.raws.between="";let d;for(;r.length;)if(d=r.shift(),d[0]===":"){a.raws.between+=d[1];break}else d[0]==="word"&&/\w/.test(d[1])&&this.unknownWord([d]),a.raws.between+=d[1];(a.prop[0]==="_"||a.prop[0]==="*")&&(a.raws.before+=a.prop[0],a.prop=a.prop.slice(1));let h=[],m;for(;r.length&&(m=r[0][0],!(m!=="space"&&m!=="comment"));)h.push(r.shift());this.precheckMissedSemicolon(r);for(let w=r.length-1;w>=0;w--){if(d=r[w],d[1].toLowerCase()==="!important"){a.important=!0;let E=this.stringFrom(r,w);E=this.spacesFromEnd(r)+E,E!==" !important"&&(a.raws.important=E);break}else if(d[1].toLowerCase()==="important"){let E=r.slice(0),v="";for(let R=w;R>0;R--){let y=E[R][0];if(v.trim().startsWith("!")&&y!=="space")break;v=E.pop()[1]+v}v.trim().startsWith("!")&&(a.important=!0,a.raws.important=v,r=E)}if(d[0]!=="space"&&d[0]!=="comment")break}r.some(w=>w[0]!=="space"&&w[0]!=="comment")&&(a.raws.between+=h.map(w=>w[1]).join(""),h=[]),this.raw(a,"value",h.concat(r),u),a.value.includes(":")&&!u&&this.checkMissedSemicolon(r)}doubleColon(r){throw this.input.error("Double colon",{offset:r[2]},{offset:r[2]+r[1].length})}emptyRule(r){let u=new s;this.init(u,r[2]),u.selector="",u.raws.between="",this.current=u}end(r){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(r[2]),this.current.source.end.offset++,this.current=this.current.parent):this.unexpectedClose(r)}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(r){if(this.spaces+=r[1],this.current.nodes){let u=this.current.nodes[this.current.nodes.length-1];u&&u.type==="rule"&&!u.raws.ownSemicolon&&(u.raws.ownSemicolon=this.spaces,this.spaces="")}}getPosition(r){let u=this.input.fromOffset(r);return{column:u.col,line:u.line,offset:r}}init(r,u){this.current.push(r),r.source={input:this.input,start:this.getPosition(u)},r.raws.before=this.spaces,this.spaces="",r.type!=="comment"&&(this.semicolon=!1)}other(r){let u=!1,a=null,n=!1,d=null,h=[],m=r[1].startsWith("--"),b=[],w=r;for(;w;){if(a=w[0],b.push(w),a==="("||a==="[")d||(d=w),h.push(a==="("?")":"]");else if(m&&n&&a==="{")d||(d=w),h.push("}");else if(h.length===0)if(a===";")if(n){this.decl(b,m);return}else break;else if(a==="{"){this.rule(b);return}else if(a==="}"){this.tokenizer.back(b.pop()),u=!0;break}else a===":"&&(n=!0);else a===h[h.length-1]&&(h.pop(),h.length===0&&(d=null));w=this.tokenizer.nextToken()}if(this.tokenizer.endOfFile()&&(u=!0),h.length>0&&this.unclosedBracket(d),u&&n){if(!m)for(;b.length&&(w=b[b.length-1][0],!(w!=="space"&&w!=="comment"));)this.tokenizer.back(b.pop());this.decl(b,m)}else this.unknownWord(b)}parse(){let r;for(;!this.tokenizer.endOfFile();)switch(r=this.tokenizer.nextToken(),r[0]){case"space":this.spaces+=r[1];break;case";":this.freeSemicolon(r);break;case"}":this.end(r);break;case"comment":this.comment(r);break;case"at-word":this.atrule(r);break;case"{":this.emptyRule(r);break;default:this.other(r);break}this.endFile()}precheckMissedSemicolon(){}raw(r,u,a,n){let d,h,m=a.length,b="",w=!0,E,v;for(let R=0;R<m;R+=1)d=a[R],h=d[0],h==="space"&&R===m-1&&!n?w=!1:h==="comment"?(v=a[R-1]?a[R-1][0]:"empty",E=a[R+1]?a[R+1][0]:"empty",!o[v]&&!o[E]?b.slice(-1)===","?w=!1:b+=d[1]:w=!1):b+=d[1];if(!w){let R=a.reduce((y,C)=>y+C[1],"");r.raws[u]={raw:R,value:b}}r[u]=b}rule(r){r.pop();let u=new s;this.init(u,r[0][2]),u.raws.between=this.spacesAndCommentsFromEnd(r),this.raw(u,"selector",r),this.current=u}spacesAndCommentsFromEnd(r){let u,a="";for(;r.length&&(u=r[r.length-1][0],!(u!=="space"&&u!=="comment"));)a=r.pop()[1]+a;return a}spacesAndCommentsFromStart(r){let u,a="";for(;r.length&&(u=r[0][0],!(u!=="space"&&u!=="comment"));)a+=r.shift()[1];return a}spacesFromEnd(r){let u,a="";for(;r.length&&(u=r[r.length-1][0],u==="space");)a=r.pop()[1]+a;return a}stringFrom(r,u){let a="";for(let n=u;n<r.length;n++)a+=r[n][1];return r.splice(u,r.length-u),a}unclosedBlock(){let r=this.current.source.start;throw this.input.error("Unclosed block",r.line,r.column)}unclosedBracket(r){throw this.input.error("Unclosed bracket",{offset:r[2]},{offset:r[2]+1})}unexpectedClose(r){throw this.input.error("Unexpected }",{offset:r[2]},{offset:r[2]+1})}unknownWord(r){throw this.input.error("Unknown word",{offset:r[0][2]},{offset:r[0][2]+r[0][1].length})}unnamedAtrule(r,u){throw this.input.error("At-rule without name",{offset:u[2]},{offset:u[2]+u[1].length})}}return Ie=g,Ie}var Pe,Lt;function Ze(){if(Lt)return Pe;Lt=1;let t=W(),e=ae(),i=Zt();function c(s,l){let o=new e(s,l),p=new i(o);try{p.parse()}catch(g){throw g}return p.root}return Pe=c,c.default=c,t.registerParse(c),Pe}var Le,kt;function Qt(){if(kt)return Le;kt=1;class t{constructor(i,c={}){if(this.type="warning",this.text=i,c.node&&c.node.source){let s=c.node.rangeBy(c);this.line=s.start.line,this.column=s.start.column,this.endLine=s.end.line,this.endColumn=s.end.column}for(let s in c)this[s]=c[s]}toString(){return this.node?this.node.error(this.text,{index:this.index,plugin:this.plugin,word:this.word}).message:this.plugin?this.plugin+": "+this.text:this.text}}return Le=t,t.default=t,Le}var ke,Bt;function Qe(){if(Bt)return ke;Bt=1;let t=Qt();class e{constructor(c,s,l){this.processor=c,this.messages=[],this.root=s,this.opts=l,this.css=void 0,this.map=void 0}toString(){return this.css}warn(c,s={}){s.plugin||this.lastPlugin&&this.lastPlugin.postcssPlugin&&(s.plugin=this.lastPlugin.postcssPlugin);let l=new t(c,s);return this.messages.push(l),l}warnings(){return this.messages.filter(c=>c.type==="warning")}get content(){return this.css}}return ke=e,e.default=e,ke}var Be,Ut;function Kt(){if(Ut)return Be;Ut=1;let t={};return Be=function(i){t[i]||(t[i]=!0,typeof console!="undefined"&&console.warn&&console.warn(i))},Be}var Ue,Ft;function er(){if(Ft)return Ue;Ft=1;let t=W(),e=Je(),i=Jt(),c=Ze(),s=Qe(),l=J(),o=ne(),{isClean:p,my:g}=Ye(),f=Kt();const r={atrule:"AtRule",comment:"Comment",decl:"Declaration",document:"Document",root:"Root",rule:"Rule"},u={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},a={Once:!0,postcssPlugin:!0,prepare:!0},n=0;function d(v){return typeof v=="object"&&typeof v.then=="function"}function h(v){let R=!1,y=r[v.type];return v.type==="decl"?R=v.prop.toLowerCase():v.type==="atrule"&&(R=v.name.toLowerCase()),R&&v.append?[y,y+"-"+R,n,y+"Exit",y+"Exit-"+R]:R?[y,y+"-"+R,y+"Exit",y+"Exit-"+R]:v.append?[y,n,y+"Exit"]:[y,y+"Exit"]}function m(v){let R;return v.type==="document"?R=["Document",n,"DocumentExit"]:v.type==="root"?R=["Root",n,"RootExit"]:R=h(v),{eventIndex:0,events:R,iterator:0,node:v,visitorIndex:0,visitors:[]}}function b(v){return v[p]=!1,v.nodes&&v.nodes.forEach(R=>b(R)),v}let w={};class E{constructor(R,y,C){this.stringified=!1,this.processed=!1;let N;if(typeof y=="object"&&y!==null&&(y.type==="root"||y.type==="document"))N=b(y);else if(y instanceof E||y instanceof s)N=b(y.root),y.map&&(typeof C.map=="undefined"&&(C.map={}),C.map.inline||(C.map.inline=!1),C.map.prev=y.map);else{let M=c;C.syntax&&(M=C.syntax.parse),C.parser&&(M=C.parser),M.parse&&(M=M.parse);try{N=M(y,C)}catch(O){this.processed=!0,this.error=O}N&&!N[g]&&t.rebuild(N)}this.result=new s(R,N,C),this.helpers=Y(k({},w),{postcss:w,result:this.result}),this.plugins=this.processor.plugins.map(M=>typeof M=="object"&&M.prepare?k(k({},M),M.prepare(this.result)):M)}async(){return this.error?Promise.reject(this.error):this.processed?Promise.resolve(this.result):(this.processing||(this.processing=this.runAsync()),this.processing)}catch(R){return this.async().catch(R)}finally(R){return this.async().then(R,R)}getAsyncError(){throw new Error("Use process(css).then(cb) to work with async plugins")}handleError(R,y){let C=this.result.lastPlugin;try{y&&y.addToError(R),this.error=R,R.name==="CssSyntaxError"&&!R.plugin?(R.plugin=C.postcssPlugin,R.setMessage()):C.postcssVersion}catch(N){console&&console.error&&console.error(N)}return R}prepareVisitors(){this.listeners={};let R=(y,C,N)=>{this.listeners[C]||(this.listeners[C]=[]),this.listeners[C].push([y,N])};for(let y of this.plugins)if(typeof y=="object")for(let C in y){if(!u[C]&&/^[A-Z]/.test(C))throw new Error(`Unknown event ${C} in ${y.postcssPlugin}. Try to update PostCSS (${this.processor.version} now).`);if(!a[C])if(typeof y[C]=="object")for(let N in y[C])N==="*"?R(y,C,y[C][N]):R(y,C+"-"+N.toLowerCase(),y[C][N]);else typeof y[C]=="function"&&R(y,C,y[C])}this.hasListener=Object.keys(this.listeners).length>0}async runAsync(){this.plugin=0;for(let R=0;R<this.plugins.length;R++){let y=this.plugins[R],C=this.runOnRoot(y);if(d(C))try{await C}catch(N){throw this.handleError(N)}}if(this.prepareVisitors(),this.hasListener){let R=this.result.root;for(;!R[p];){R[p]=!0;let y=[m(R)];for(;y.length>0;){let C=this.visitTick(y);if(d(C))try{await C}catch(N){let M=y[y.length-1].node;throw this.handleError(N,M)}}}if(this.listeners.OnceExit)for(let[y,C]of this.listeners.OnceExit){this.result.lastPlugin=y;try{if(R.type==="document"){let N=R.nodes.map(M=>C(M,this.helpers));await Promise.all(N)}else await C(R,this.helpers)}catch(N){throw this.handleError(N)}}}return this.processed=!0,this.stringify()}runOnRoot(R){this.result.lastPlugin=R;try{if(typeof R=="object"&&R.Once){if(this.result.root.type==="document"){let y=this.result.root.nodes.map(C=>R.Once(C,this.helpers));return d(y[0])?Promise.all(y):y}return R.Once(this.result.root,this.helpers)}else if(typeof R=="function")return R(this.result.root,this.result)}catch(y){throw this.handleError(y)}}stringify(){if(this.error)throw this.error;if(this.stringified)return this.result;this.stringified=!0,this.sync();let R=this.result.opts,y=o;R.syntax&&(y=R.syntax.stringify),R.stringifier&&(y=R.stringifier),y.stringify&&(y=y.stringify);let N=new i(y,this.result.root,this.result.opts).generate();return this.result.css=N[0],this.result.map=N[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 R of this.plugins){let y=this.runOnRoot(R);if(d(y))throw this.getAsyncError()}if(this.prepareVisitors(),this.hasListener){let R=this.result.root;for(;!R[p];)R[p]=!0,this.walkSync(R);if(this.listeners.OnceExit)if(R.type==="document")for(let y of R.nodes)this.visitSync(this.listeners.OnceExit,y);else this.visitSync(this.listeners.OnceExit,R)}return this.result}then(R,y){return this.async().then(R,y)}toString(){return this.css}visitSync(R,y){for(let[C,N]of R){this.result.lastPlugin=C;let M;try{M=N(y,this.helpers)}catch(O){throw this.handleError(O,y.proxyOf)}if(y.type!=="root"&&y.type!=="document"&&!y.parent)return!0;if(d(M))throw this.getAsyncError()}}visitTick(R){let y=R[R.length-1],{node:C,visitors:N}=y;if(C.type!=="root"&&C.type!=="document"&&!C.parent){R.pop();return}if(N.length>0&&y.visitorIndex<N.length){let[O,P]=N[y.visitorIndex];y.visitorIndex+=1,y.visitorIndex===N.length&&(y.visitors=[],y.visitorIndex=0),this.result.lastPlugin=O;try{return P(C.toProxy(),this.helpers)}catch(T){throw this.handleError(T,C)}}if(y.iterator!==0){let O=y.iterator,P;for(;P=C.nodes[C.indexes[O]];)if(C.indexes[O]+=1,!P[p]){P[p]=!0,R.push(m(P));return}y.iterator=0,delete C.indexes[O]}let M=y.events;for(;y.eventIndex<M.length;){let O=M[y.eventIndex];if(y.eventIndex+=1,O===n){C.nodes&&C.nodes.length&&(C[p]=!0,y.iterator=C.getIterator());return}else if(this.listeners[O]){y.visitors=this.listeners[O];return}}R.pop()}walkSync(R){R[p]=!0;let y=h(R);for(let C of y)if(C===n)R.nodes&&R.each(N=>{N[p]||this.walkSync(N)});else{let N=this.listeners[C];if(N&&this.visitSync(N,R.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"}}return E.registerPostcss=v=>{w=v},Ue=E,E.default=E,l.registerLazyResult(E),e.registerLazyResult(E),Ue}var Fe,zt;function qr(){if(zt)return Fe;zt=1;let t=Jt(),e=Ze();const i=Qe();let c=ne(),s=Kt();class l{constructor(p,g,f){g=g.toString(),this.stringified=!1,this._processor=p,this._css=g,this._opts=f,this._map=void 0;let r,u=c;this.result=new i(this._processor,r,this._opts),this.result.css=g;let a=this;Object.defineProperty(this.result,"root",{get(){return a.root}});let n=new t(u,r,this._opts,g);if(n.isMap()){let[d,h]=n.generate();d&&(this.result.css=d),h&&(this.result.map=h)}else n.clearAnnotation(),this.result.css=n.css}async(){return this.error?Promise.reject(this.error):Promise.resolve(this.result)}catch(p){return this.async().catch(p)}finally(p){return this.async().then(p,p)}sync(){if(this.error)throw this.error;return this.result}then(p,g){return this.async().then(p,g)}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 p,g=e;try{p=g(this._css,this._opts)}catch(f){this.error=f}if(this.error)throw this.error;return this._root=p,p}get[Symbol.toStringTag](){return"NoWorkResult"}}return Fe=l,l.default=l,Fe}var ze,qt;function Wr(){if(qt)return ze;qt=1;let t=Je(),e=er(),i=qr(),c=J();class s{constructor(o=[]){this.version="8.5.1",this.plugins=this.normalize(o)}normalize(o){let p=[];for(let g of o)if(g.postcss===!0?g=g():g.postcss&&(g=g.postcss),typeof g=="object"&&Array.isArray(g.plugins))p=p.concat(g.plugins);else if(typeof g=="object"&&g.postcssPlugin)p.push(g);else if(typeof g=="function")p.push(g);else if(!(typeof g=="object"&&(g.parse||g.stringify)))throw new Error(g+" is not a PostCSS plugin");return p}process(o,p={}){return!this.plugins.length&&!p.parser&&!p.stringifier&&!p.syntax?new i(this,o,p):new e(this,o,p)}use(o){return this.plugins=this.plugins.concat(this.normalize([o])),this}}return ze=s,s.default=s,c.registerProcessor(s),t.registerProcessor(s),ze}var qe,Wt;function tr(){if(Wt)return qe;Wt=1;let t=He(),e=H(),i=W(),c=Ve(),s=le(),l=Je(),o=zr(),p=ae(),g=er(),f=Ht(),r=oe(),u=Ze(),a=Wr(),n=Qe(),d=J(),h=Xe(),m=ne(),b=Qt();function w(...E){return E.length===1&&Array.isArray(E[0])&&(E=E[0]),new a(E)}return w.plugin=function(v,R){let y=!1;function C(...M){console&&console.warn&&!y&&(y=!0,console.warn(v+`: postcss.plugin was deprecated. Migration guide:
|
|
40
|
-
https://evilmartians.com/chronicles/postcss-8-plugin-migration`),process.env.LANG&&process.env.LANG.startsWith("cn")&&console.warn(
|
|
41
|
-
https://www.w3ctech.com/topic/2226`));let O=R(...M);return O.postcssPlugin=v,O.postcssVersion=new a().version,O}let N;return Object.defineProperty(C,"postcss",{get(){return N||(N=C()),N}}),C.process=function(M,O,P){return w([C(P)]).process(M,O)},C},w.stringify=m,w.parse=u,w.fromJSON=o,w.list=f,w.comment=E=>new e(E),w.atRule=E=>new t(E),w.decl=E=>new s(E),w.rule=E=>new h(E),w.root=E=>new d(E),w.document=E=>new l(E),w.CssSyntaxError=c,w.Declaration=s,w.Container=i,w.Processor=a,w.Document=l,w.Comment=e,w.Warning=b,w.AtRule=t,w.Result=n,w.Input=p,w.Rule=h,w.Root=d,w.Node=r,g.registerPostcss(w),qe=w,w.default=w,qe}var We,jt;function jr(){if(jt)return We;jt=1;let t=H(),e=Zt(),i=Xt();class c extends e{checkMissedSemicolon(){}comment(l){let o=new t;this.init(o,l[2]);let p=this.input.fromOffset(l[3])||this.input.fromOffset(this.input.css.length-1);o.source.end={column:p.col,line:p.line,offset:l[3]+1};let g=l[1].slice(2);if(g.slice(-2)==="*/"&&(g=g.slice(0,-2)),/^\s*$/.test(g))o.text="",o.raws.left=g,o.raws.right="";else{let f=g.match(/^(\s*)([^]*\S)(\s*)$/);o.text=f[2],o.raws.left=f[1],o.raws.right=f[3]}}createTokenizer(){this.tokenizer=i(this.input,{ignoreErrors:!0})}decl(l){l.length>1&&l.some(o=>o[0]==="word")&&super.decl(l)}doubleColon(){}endFile(){for(this.current.nodes&&this.current.nodes.length&&(this.current.raws.semicolon=this.semicolon),this.current.raws.after=(this.current.raws.after||"")+this.spaces;this.current.parent;)this.current=this.current.parent,this.current.raws.after="";this.root.source.end=this.getPosition(this.tokenizer.position())}precheckMissedSemicolon(l){let o=this.colon(l);if(o===!1)return;let p,g;for(p=o-1;p>=0&&l[p][0]!=="word";p--);if(p===0||p<0)return;for(g=p-1;g>=0;g--)if(l[g][0]!=="space"){g+=1;break}let f=l.slice(p),r=l.slice(g,p);l.splice(g,l.length-g),this.spaces=r.map(u=>u[1]).join(""),this.decl(f)}unclosedBracket(){}unexpectedClose(){this.current.raws.after+="}"}unknownWord(l){this.spaces+=l.map(o=>o[1]).join("")}unnamedAtrule(l){l.name=""}}return We=c,We}var je,Gt;function Gr(){if(Gt)return je;Gt=1;let{Input:t}=tr(),e=jr();return je=function(c,s){let l=new t(c,s),o=new e(l);return o.parse(),o.root},je}Gr();var $r=tr();const _=Pr($r);_.stringify;_.fromJSON;_.plugin;_.parse;_.list;_.document;_.comment;_.atRule;_.rule;_.decl;_.root;_.CssSyntaxError;_.Declaration;_.Container;_.Processor;_.Document;_.Comment;_.Warning;_.AtRule;_.Result;_.Input;_.Rule;_.Root;_.Node;var A=(t=>(t[t.Document=0]="Document",t[t.DocumentType=1]="DocumentType",t[t.Element=2]="Element",t[t.Text=3]="Text",t[t.CDATA=4]="CDATA",t[t.Comment=5]="Comment",t))(A||{});function Vr(t){const e={},i=/;(?![^(]*\))/g,c=/:(.+)/,s=/\/\*.*?\*\//g;return t.replace(s,"").split(i).forEach(function(l){if(l){const o=l.split(c);o.length>1&&(e[Ge(o[0].trim())]=o[1].trim())}}),e}function $t(t){const e=[];for(const i in t){const c=t[i];if(typeof c!="string")continue;const s=Xr(i);e.push(`${s}: ${c};`)}return e.join(" ")}const Yr=/-([a-z])/g,Hr=/^--[a-zA-Z0-9-]+$/,Ge=t=>Hr.test(t)?t:t.replace(Yr,(e,i)=>i?i.toUpperCase():""),Jr=/\B([A-Z])/g,Xr=t=>t.replace(Jr,"-$1").toLowerCase();class F{constructor(...e){x(this,"parentElement",null),x(this,"parentNode",null),x(this,"ownerDocument"),x(this,"firstChild",null),x(this,"lastChild",null),x(this,"previousSibling",null),x(this,"nextSibling",null),x(this,"ELEMENT_NODE",1),x(this,"TEXT_NODE",3),x(this,"nodeType"),x(this,"nodeName"),x(this,"RRNodeType")}get childNodes(){const e=[];let i=this.firstChild;for(;i;)e.push(i),i=i.nextSibling;return e}contains(e){if(e instanceof F){if(e.ownerDocument!==this.ownerDocument)return!1;if(e===this)return!0}else return!1;for(;e.parentNode;){if(e.parentNode===this)return!0;e=e.parentNode}return!1}appendChild(e){throw new Error("RRDomException: Failed to execute 'appendChild' on 'RRNode': This RRNode type does not support this method.")}insertBefore(e,i){throw new Error("RRDomException: Failed to execute 'insertBefore' on 'RRNode': This RRNode type does not support this method.")}removeChild(e){throw new Error("RRDomException: Failed to execute 'removeChild' on 'RRNode': This RRNode type does not support this method.")}toString(){return"RRNode"}}class ue extends F{constructor(...e){super(e),x(this,"nodeType",9),x(this,"nodeName","#document"),x(this,"compatMode","CSS1Compat"),x(this,"RRNodeType",A.Document),x(this,"textContent",null),this.ownerDocument=this}get documentElement(){return this.childNodes.find(e=>e.RRNodeType===A.Element&&e.tagName==="HTML")||null}get body(){var e;return((e=this.documentElement)==null?void 0:e.childNodes.find(i=>i.RRNodeType===A.Element&&i.tagName==="BODY"))||null}get head(){var e;return((e=this.documentElement)==null?void 0:e.childNodes.find(i=>i.RRNodeType===A.Element&&i.tagName==="HEAD"))||null}get implementation(){return this}get firstElementChild(){return this.documentElement}appendChild(e){const i=e.RRNodeType;if((i===A.Element||i===A.DocumentType)&&this.childNodes.some(s=>s.RRNodeType===i))throw new Error(`RRDomException: Failed to execute 'appendChild' on 'RRNode': Only one ${i===A.Element?"RRElement":"RRDoctype"} on RRDocument allowed.`);const c=st(this,e);return c.parentElement=null,c}insertBefore(e,i){const c=e.RRNodeType;if((c===A.Element||c===A.DocumentType)&&this.childNodes.some(l=>l.RRNodeType===c))throw new Error(`RRDomException: Failed to execute 'insertBefore' on 'RRNode': Only one ${c===A.Element?"RRElement":"RRDoctype"} on RRDocument allowed.`);const s=nr(this,e,i);return s.parentElement=null,s}removeChild(e){return or(this,e)}open(){this.firstChild=null,this.lastChild=null}close(){}write(e){let i;if(e==='<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "">'?i="-//W3C//DTD XHTML 1.0 Transitional//EN":e==='<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN" "">'&&(i="-//W3C//DTD HTML 4.0 Transitional//EN"),i){const c=this.createDocumentType("html",i,"");this.open(),this.appendChild(c)}}createDocument(e,i,c){return new ue}createDocumentType(e,i,c){const s=new Ke(e,i,c);return s.ownerDocument=this,s}createElement(e){const i=new X(e);return i.ownerDocument=this,i}createElementNS(e,i){return this.createElement(i)}createTextNode(e){const i=new et(e);return i.ownerDocument=this,i}createComment(e){const i=new tt(e);return i.ownerDocument=this,i}createCDATASection(e){const i=new rt(e);return i.ownerDocument=this,i}toString(){return"RRDocument"}}class Ke extends F{constructor(e,i,c){super(),x(this,"nodeType",10),x(this,"RRNodeType",A.DocumentType),x(this,"name"),x(this,"publicId"),x(this,"systemId"),x(this,"textContent",null),this.name=e,this.publicId=i,this.systemId=c,this.nodeName=e}toString(){return"RRDocumentType"}}class X extends F{constructor(e){super(),x(this,"nodeType",1),x(this,"RRNodeType",A.Element),x(this,"tagName"),x(this,"attributes",{}),x(this,"shadowRoot",null),x(this,"scrollLeft"),x(this,"scrollTop"),this.tagName=e.toUpperCase(),this.nodeName=e.toUpperCase()}get textContent(){let e="";return this.childNodes.forEach(i=>e+=i.textContent),e}set textContent(e){this.firstChild=null,this.lastChild=null,this.appendChild(this.ownerDocument.createTextNode(e))}get classList(){return new ir(this.attributes.class,e=>{this.attributes.class=e})}get id(){return this.attributes.id||""}get className(){return this.attributes.class||""}get style(){const e=this.attributes.style?Vr(this.attributes.style):{},i=/\B([A-Z])/g;return e.setProperty=(c,s,l)=>{if(i.test(c))return;const o=Ge(c);s?e[o]=s:delete e[o],l==="important"&&(e[o]+=" !important"),this.attributes.style=$t(e)},e.removeProperty=c=>{if(i.test(c))return"";const s=Ge(c),l=e[s]||"";return delete e[s],this.attributes.style=$t(e),l},e}getAttribute(e){return this.attributes[e]===void 0?null:this.attributes[e]}setAttribute(e,i){this.attributes[e]=i}setAttributeNS(e,i,c){this.setAttribute(i,c)}removeAttribute(e){delete this.attributes[e]}appendChild(e){return st(this,e)}insertBefore(e,i){return nr(this,e,i)}removeChild(e){return or(this,e)}attachShadow(e){const i=this.ownerDocument.createElement("SHADOWROOT");return this.shadowRoot=i,i}dispatchEvent(e){return!0}toString(){let e="";for(const i in this.attributes)e+=`${i}="${this.attributes[i]}" `;return`${this.tagName} ${e}`}}class rr extends X{constructor(){super(...arguments),x(this,"currentTime"),x(this,"volume"),x(this,"paused"),x(this,"muted"),x(this,"playbackRate"),x(this,"loop")}attachShadow(e){throw new Error("RRDomException: Failed to execute 'attachShadow' on 'RRElement': This RRElement does not support attachShadow")}play(){this.paused=!1}pause(){this.paused=!0}}class sr extends X{constructor(){super(...arguments),x(this,"tagName","DIALOG"),x(this,"nodeName","DIALOG")}get isModal(){return this.getAttribute("rr_open_mode")==="modal"}get open(){return this.getAttribute("open")!==null}close(){this.removeAttribute("open"),this.removeAttribute("rr_open_mode")}show(){this.setAttribute("open",""),this.setAttribute("rr_open_mode","non-modal")}showModal(){this.setAttribute("open",""),this.setAttribute("rr_open_mode","modal")}}class et extends F{constructor(e){super(),x(this,"nodeType",3),x(this,"nodeName","#text"),x(this,"RRNodeType",A.Text),x(this,"data"),this.data=e}get textContent(){return this.data}set textContent(e){this.data=e}toString(){return`RRText text=${JSON.stringify(this.data)}`}}class tt extends F{constructor(e){super(),x(this,"nodeType",8),x(this,"nodeName","#comment"),x(this,"RRNodeType",A.Comment),x(this,"data"),this.data=e}get textContent(){return this.data}set textContent(e){this.data=e}toString(){return`RRComment text=${JSON.stringify(this.data)}`}}class rt extends F{constructor(e){super(),x(this,"nodeName","#cdata-section"),x(this,"nodeType",4),x(this,"RRNodeType",A.CDATA),x(this,"data"),this.data=e}get textContent(){return this.data}set textContent(e){this.data=e}toString(){return`RRCDATASection data=${JSON.stringify(this.data)}`}}class ir{constructor(e,i){if(x(this,"onChange"),x(this,"classes",[]),x(this,"add",(...c)=>{for(const s of c){const l=String(s);this.classes.indexOf(l)>=0||this.classes.push(l)}this.onChange&&this.onChange(this.classes.join(" "))}),x(this,"remove",(...c)=>{this.classes=this.classes.filter(s=>c.indexOf(s)===-1),this.onChange&&this.onChange(this.classes.join(" "))}),e){const c=e.trim().split(/\s+/);this.classes.push(...c)}this.onChange=i}}function st(t,e){return e.parentNode&&e.parentNode.removeChild(e),t.lastChild?(t.lastChild.nextSibling=e,e.previousSibling=t.lastChild):(t.firstChild=e,e.previousSibling=null),t.lastChild=e,e.nextSibling=null,e.parentNode=t,e.parentElement=t,e.ownerDocument=t.ownerDocument,e}function nr(t,e,i){if(!i)return st(t,e);if(i.parentNode!==t)throw new Error("Failed to execute 'insertBefore' on 'RRNode': The RRNode before which the new node is to be inserted is not a child of this RRNode.");return e===i||(e.parentNode&&e.parentNode.removeChild(e),e.previousSibling=i.previousSibling,i.previousSibling=e,e.nextSibling=i,e.previousSibling?e.previousSibling.nextSibling=e:t.firstChild=e,e.parentElement=t,e.parentNode=t,e.ownerDocument=t.ownerDocument),e}function or(t,e){if(e.parentNode!==t)throw new Error("Failed to execute 'removeChild' on 'RRNode': The RRNode to be removed is not a child of this RRNode.");return e.previousSibling?e.previousSibling.nextSibling=e.nextSibling:t.firstChild=e.nextSibling,e.nextSibling?e.nextSibling.previousSibling=e.previousSibling:t.lastChild=e.previousSibling,e.previousSibling=null,e.nextSibling=null,e.parentElement=null,e.parentNode=null,e}var I=(t=>(t[t.PLACEHOLDER=0]="PLACEHOLDER",t[t.ELEMENT_NODE=1]="ELEMENT_NODE",t[t.ATTRIBUTE_NODE=2]="ATTRIBUTE_NODE",t[t.TEXT_NODE=3]="TEXT_NODE",t[t.CDATA_SECTION_NODE=4]="CDATA_SECTION_NODE",t[t.ENTITY_REFERENCE_NODE=5]="ENTITY_REFERENCE_NODE",t[t.ENTITY_NODE=6]="ENTITY_NODE",t[t.PROCESSING_INSTRUCTION_NODE=7]="PROCESSING_INSTRUCTION_NODE",t[t.COMMENT_NODE=8]="COMMENT_NODE",t[t.DOCUMENT_NODE=9]="DOCUMENT_NODE",t[t.DOCUMENT_TYPE_NODE=10]="DOCUMENT_TYPE_NODE",t[t.DOCUMENT_FRAGMENT_NODE=11]="DOCUMENT_FRAGMENT_NODE",t))(I||{});const $e={svg:"http://www.w3.org/2000/svg","xlink:href":"http://www.w3.org/1999/xlink",xmlns:"http://www.w3.org/2000/xmlns/"},Zr={altglyph:"altGlyph",altglyphdef:"altGlyphDef",altglyphitem:"altGlyphItem",animatecolor:"animateColor",animatemotion:"animateMotion",animatetransform:"animateTransform",clippath:"clipPath",feblend:"feBlend",fecolormatrix:"feColorMatrix",fecomponenttransfer:"feComponentTransfer",fecomposite:"feComposite",feconvolvematrix:"feConvolveMatrix",fediffuselighting:"feDiffuseLighting",fedisplacementmap:"feDisplacementMap",fedistantlight:"feDistantLight",fedropshadow:"feDropShadow",feflood:"feFlood",fefunca:"feFuncA",fefuncb:"feFuncB",fefuncg:"feFuncG",fefuncr:"feFuncR",fegaussianblur:"feGaussianBlur",feimage:"feImage",femerge:"feMerge",femergenode:"feMergeNode",femorphology:"feMorphology",feoffset:"feOffset",fepointlight:"fePointLight",fespecularlighting:"feSpecularLighting",fespotlight:"feSpotLight",fetile:"feTile",feturbulence:"feTurbulence",foreignobject:"foreignObject",glyphref:"glyphRef",lineargradient:"linearGradient",radialgradient:"radialGradient"};let U=null;function it(t,e,i,c=e.mirror||e.ownerDocument.mirror){t=Qr(t,e,i,c),lr(t,e,i,c),Kr(t,e,i)}function Qr(t,e,i,c){var s;if(i.afterAppend&&!U&&(U=new WeakSet,setTimeout(()=>{U=null},0)),!nt(t,e)){const l=ie(e,i.mirror,c);(s=t.parentNode)==null||s.replaceChild(l,t),t=l}switch(e.RRNodeType){case A.Document:{if(!$(t,e,i.mirror,c)){const l=c.getMeta(e);l&&(i.mirror.removeNodeFromMap(t),t.close(),t.open(),i.mirror.add(t,l),U==null||U.add(t))}break}case A.Element:{const l=t,o=e;switch(o.tagName){case"IFRAME":{const p=t.contentDocument;if(!p)break;it(p,e.contentDocument,i,c);break}}o.shadowRoot&&(l.shadowRoot||l.attachShadow({mode:"open"}),lr(l.shadowRoot,o.shadowRoot,i,c)),es(l,o,c);break}}return t}function Kr(t,e,i){var c;switch(e.RRNodeType){case A.Document:{const s=e.scrollData;s&&i.applyScroll(s,!0);break}case A.Element:{const s=t,l=e;switch(l.scrollData&&i.applyScroll(l.scrollData,!0),l.inputData&&i.applyInput(l.inputData),l.tagName){case"AUDIO":case"VIDEO":{const o=t,p=l;p.paused!==void 0&&(p.paused?o.pause():o.play()),p.muted!==void 0&&(o.muted=p.muted),p.volume!==void 0&&(o.volume=p.volume),p.currentTime!==void 0&&(o.currentTime=p.currentTime),p.playbackRate!==void 0&&(o.playbackRate=p.playbackRate),p.loop!==void 0&&(o.loop=p.loop);break}case"CANVAS":{const o=e;if(o.rr_dataURL!==null){const p=document.createElement("img");p.onload=()=>{const g=s.getContext("2d");g&&g.drawImage(p,0,0,p.width,p.height)},p.src=o.rr_dataURL}o.canvasMutations.forEach(p=>i.applyCanvas(p.event,p.mutation,t));break}case"STYLE":{const o=s.sheet;o&&e.rules.forEach(p=>i.applyStyleSheetMutation(p,o));break}case"DIALOG":{const o=s,p=l,g=o.open,f=o.matches("dialog:modal"),r=p.open,u=p.isModal,a=f!==u,n=g!==r;if((a||g&&n)&&o.close(),r&&(n||a))try{u?o.showModal():o.show()}catch(d){console.warn(d)}break}}break}case A.Text:case A.Comment:case A.CDATA:{t.textContent!==e.data&&(t.textContent=e.data);break}}U!=null&&U.has(t)&&(U.delete(t),(c=i.afterAppend)==null||c.call(i,t,i.mirror.getId(t)))}function es(t,e,i){const c=t.attributes,s=e.attributes;for(const l in s){const o=s[l],p=i.getMeta(e);if(p!=null&&p.isSVG&&$e[l])t.setAttributeNS($e[l],l,o);else if(e.tagName==="CANVAS"&&l==="rr_dataURL"){const g=document.createElement("img");g.src=o,g.onload=()=>{const f=t.getContext("2d");f&&f.drawImage(g,0,0,g.width,g.height)}}else{if(e.tagName==="IFRAME"&&l==="srcdoc")continue;try{t.setAttribute(l,o)}catch(g){console.warn(g)}}}for(const{name:l}of Array.from(c))l in s||t.removeAttribute(l);e.scrollLeft&&(t.scrollLeft=e.scrollLeft),e.scrollTop&&(t.scrollTop=e.scrollTop)}function lr(t,e,i,c){const s=Array.from(t.childNodes),l=e.childNodes;if(s.length===0&&l.length===0)return;let o=0,p=s.length-1,g=0,f=l.length-1,r=s[o],u=s[p],a=l[g],n=l[f],d,h;for(;o<=p&&g<=f;)if(r===void 0)r=s[++o];else if(u===void 0)u=s[--p];else if($(r,a,i.mirror,c))r=s[++o],a=l[++g];else if($(u,n,i.mirror,c))u=s[--p],n=l[--f];else if($(r,n,i.mirror,c)){try{t.insertBefore(r,u.nextSibling)}catch(w){console.warn(w)}r=s[++o],n=l[--f]}else if($(u,a,i.mirror,c)){try{t.insertBefore(u,r)}catch(w){console.warn(w)}u=s[--p],a=l[++g]}else{if(!d){d={};for(let E=o;E<=p;E++){const v=s[E];v&&i.mirror.hasNode(v)&&(d[i.mirror.getId(v)]=E)}}h=d[c.getId(a)];const w=s[h];if(h!==void 0&&w&&$(w,a,i.mirror,c)){try{t.insertBefore(w,r)}catch(E){console.warn(E)}s[h]=void 0}else{const E=ie(a,i.mirror,c);t.nodeName==="#document"&&r&&(E.nodeType===E.DOCUMENT_TYPE_NODE&&r.nodeType===r.DOCUMENT_TYPE_NODE||E.nodeType===E.ELEMENT_NODE&&r.nodeType===r.ELEMENT_NODE)&&(t.removeChild(r),i.mirror.removeNodeFromMap(r),r=s[++o]);try{t.insertBefore(E,r||null)}catch(v){console.warn(v)}}a=l[++g]}if(o>p){const w=l[f+1];let E=null;for(w&&(E=i.mirror.getNode(c.getId(w)));g<=f;++g){const v=ie(l[g],i.mirror,c);try{t.insertBefore(v,E)}catch(R){console.warn(R)}}}else if(g>f)for(;o<=p;o++){const w=s[o];if(!(!w||w.parentNode!==t))try{t.removeChild(w),i.mirror.removeNodeFromMap(w)}catch(E){console.warn(E)}}let m=t.firstChild,b=e.firstChild;for(;m!==null&&b!==null;)it(m,b,i,c),m=m.nextSibling,b=b.nextSibling}function ie(t,e,i){const c=i.getId(t),s=i.getMeta(t);let l=null;if(c>-1&&(l=e.getNode(c)),l!==null&&nt(l,t))return l;switch(t.RRNodeType){case A.Document:l=new Document;break;case A.DocumentType:l=document.implementation.createDocumentType(t.name,t.publicId,t.systemId);break;case A.Element:{let o=t.tagName.toLowerCase();o=Zr[o]||o,s&&"isSVG"in s&&(s!=null&&s.isSVG)?l=document.createElementNS($e.svg,o):l=document.createElement(t.tagName);break}case A.Text:l=document.createTextNode(t.data);break;case A.Comment:l=document.createComment(t.data);break;case A.CDATA:l=document.createCDATASection(t.data);break}s&&e.add(l,k({},s));try{U==null||U.add(l)}catch(o){}return l}function nt(t,e){return t.nodeType!==e.nodeType?!1:t.nodeType!==t.ELEMENT_NODE||t.tagName.toUpperCase()===e.tagName}function $(t,e,i,c){const s=i.getId(t),l=c.getId(e);return s===-1||s!==l?!1:nt(t,e)}class V extends ue{constructor(e){super(),x(this,"UNSERIALIZED_STARTING_ID",-2),x(this,"_unserializedId",this.UNSERIALIZED_STARTING_ID),x(this,"mirror",yr()),x(this,"scrollData",null),e&&(this.mirror=e)}get unserializedId(){return this._unserializedId--}createDocument(e,i,c){return new V}createDocumentType(e,i,c){const s=new ar(e,i,c);return s.ownerDocument=this,s}createElement(e){const i=e.toUpperCase();let c;switch(i){case"AUDIO":case"VIDEO":c=new ur(i);break;case"IFRAME":c=new pr(i,this.mirror);break;case"CANVAS":c=new hr(i);break;case"STYLE":c=new fr(i);break;case"DIALOG":c=new cr(i);break;default:c=new Z(i);break}return c.ownerDocument=this,c}createComment(e){const i=new mr(e);return i.ownerDocument=this,i}createCDATASection(e){const i=new gr(e);return i.ownerDocument=this,i}createTextNode(e){const i=new dr(e);return i.ownerDocument=this,i}destroyTree(){this.firstChild=null,this.lastChild=null,this.mirror.reset()}open(){super.open(),this._unserializedId=this.UNSERIALIZED_STARTING_ID}}const ar=Ke;class Z extends X{constructor(){super(...arguments),x(this,"inputData",null),x(this,"scrollData",null)}}class ur extends rr{}class cr extends sr{}class hr extends Z{constructor(){super(...arguments),x(this,"rr_dataURL",null),x(this,"canvasMutations",[])}getContext(){return null}}class fr extends Z{constructor(){super(...arguments),x(this,"rules",[])}}class pr extends Z{constructor(e,i){super(e),x(this,"contentDocument",new V),this.contentDocument.mirror=i}}const dr=et,mr=tt,gr=rt;function ts(t){return t instanceof HTMLFormElement?"FORM":t.tagName.toUpperCase()}function wr(t,e,i,c){let s;switch(t.nodeType){case I.DOCUMENT_NODE:c&&c.nodeName==="IFRAME"?s=c.contentDocument:(s=e,s.compatMode=t.compatMode);break;case I.DOCUMENT_TYPE_NODE:{const o=t;s=e.createDocumentType(o.name,o.publicId,o.systemId);break}case I.ELEMENT_NODE:{const o=t,p=ts(o);s=e.createElement(p);const g=s;for(const{name:f,value:r}of Array.from(o.attributes))g.attributes[f]=r;o.scrollLeft&&(g.scrollLeft=o.scrollLeft),o.scrollTop&&(g.scrollTop=o.scrollTop);break}case I.TEXT_NODE:s=e.createTextNode(t.textContent||"");break;case I.CDATA_SECTION_NODE:s=e.createCDATASection(t.data);break;case I.COMMENT_NODE:s=e.createComment(t.textContent||"");break;case I.DOCUMENT_FRAGMENT_NODE:s=c.attachShadow({mode:"open"});break;default:return null}let l=i.getMeta(t);return e instanceof V&&(l||(l=Er(s,e.unserializedId),i.add(t,l)),e.mirror.add(s,k({},l))),s}function rs(t,e=Ir(),i=new V){function c(s,l){const o=wr(s,i,e,l);if(o!==null)if((l==null?void 0:l.nodeName)!=="IFRAME"&&s.nodeType!==I.DOCUMENT_FRAGMENT_NODE&&(l==null||l.appendChild(o),o.parentNode=l,o.parentElement=l),s.nodeName==="IFRAME"){const p=s.contentDocument;p&&c(p,o)}else(s.nodeType===I.DOCUMENT_NODE||s.nodeType===I.ELEMENT_NODE||s.nodeType===I.DOCUMENT_FRAGMENT_NODE)&&(s.nodeType===I.ELEMENT_NODE&&s.shadowRoot&&c(s.shadowRoot,o),s.childNodes.forEach(p=>c(p,o)))}return c(t,null),i}function yr(){return new Rr}class Rr{constructor(){x(this,"idNodeMap",new Map),x(this,"nodeMetaMap",new WeakMap)}getId(e){var i;if(!e)return-1;const c=(i=this.getMeta(e))==null?void 0:i.id;return c!=null?c:-1}getNode(e){return this.idNodeMap.get(e)||null}getIds(){return Array.from(this.idNodeMap.keys())}getMeta(e){return this.nodeMetaMap.get(e)||null}removeNodeFromMap(e){const i=this.getId(e);this.idNodeMap.delete(i),e.childNodes&&e.childNodes.forEach(c=>this.removeNodeFromMap(c))}has(e){return this.idNodeMap.has(e)}hasNode(e){return this.nodeMetaMap.has(e)}add(e,i){const c=i.id;this.idNodeMap.set(c,e),this.nodeMetaMap.set(e,i)}replace(e,i){const c=this.getNode(e);if(c){const s=this.nodeMetaMap.get(c);s&&this.nodeMetaMap.set(i,s)}this.idNodeMap.set(e,i)}reset(){this.idNodeMap=new Map,this.nodeMetaMap=new WeakMap}}function Er(t,e){switch(t.RRNodeType){case A.Document:return{id:e,type:t.RRNodeType,childNodes:[]};case A.DocumentType:{const i=t;return{id:e,type:t.RRNodeType,name:i.name,publicId:i.publicId,systemId:i.systemId}}case A.Element:return{id:e,type:t.RRNodeType,tagName:t.tagName.toLowerCase(),attributes:{},childNodes:[]};case A.Text:return{id:e,type:t.RRNodeType,textContent:t.textContent||""};case A.Comment:return{id:e,type:t.RRNodeType,textContent:t.textContent||""};case A.CDATA:return{id:e,type:t.RRNodeType,textContent:""}}}function ss(t,e){return se(t,e,"")}function se(t,e,i){let c=`${i}${e.getId(t)} ${t.toString()}
|
|
42
|
-
`;if(t.RRNodeType===
|
|
43
|
-
if (typeof module.exports == "object" && typeof exports == "object") {
|
|
26
|
+
`),this.css+=n+"/*# sourceMappingURL="+l+" */"}applyPrevMaps(){for(let l of this.previous()){let n=this.toUrl(this.path(l.file)),f=l.root||t(l.file),d;this.mapOpts.sourcesContent===!1?(d=new s(l.text),d.sourcesContent&&(d.sourcesContent=null)):d=l.consumer(),this.map.applySourceMap(d,n,this.toUrl(this.path(f)))}}clearAnnotation(){if(this.mapOpts.annotation!==!1)if(this.root){let l;for(let n=this.root.nodes.length-1;n>=0;n--)l=this.root.nodes[n],l.type==="comment"&&l.text.startsWith("# sourceMappingURL=")&&this.root.removeChild(n)}else this.css&&(this.css=this.css.replace(/\n*\/\*#[\S\s]*?\*\/$/gm,""))}generate(){if(this.clearAnnotation(),h&&g&&this.isMap())return this.generateMap();{let l="";return this.stringify(this.root,n=>{l+=n}),[l]}}generateMap(){if(this.root)this.generateString();else if(this.previous().length===1){let l=this.previous()[0].consumer();l.file=this.outputFile(),this.map=a.fromSourceMap(l,{ignoreInvalidMapping:!0})}else this.map=new a({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 a({file:this.outputFile(),ignoreInvalidMapping:!0});let l=1,n=1,f="<no source>",d={generated:{column:0,line:0},original:{column:0,line:0},source:""},m,b;this.stringify(this.root,(w,E,x)=>{if(this.css+=w,E&&x!=="end"&&(d.generated.line=l,d.generated.column=n-1,E.source&&E.source.start?(d.source=this.sourcePath(E),d.original.line=E.source.start.line,d.original.column=E.source.start.column-1,this.map.addMapping(d)):(d.source=f,d.original.line=1,d.original.column=0,this.map.addMapping(d))),b=w.match(/\n/g),b?(l+=b.length,m=w.lastIndexOf(`
|
|
27
|
+
`),n=w.length-m):n+=w.length,E&&x!=="start"){let y=E.parent||{raws:{}};(!(E.type==="decl"||E.type==="atrule"&&!E.nodes)||E!==y.last||y.raws.semicolon)&&(E.source&&E.source.end?(d.source=this.sourcePath(E),d.original.line=E.source.end.line,d.original.column=E.source.end.column-1,d.generated.line=l,d.generated.column=n-2,this.map.addMapping(d)):(d.source=f,d.original.line=1,d.original.column=0,d.generated.line=l,d.generated.column=n-1,this.map.addMapping(d)))}})}isAnnotation(){return this.isInline()?!0:typeof this.mapOpts.annotation!="undefined"?this.mapOpts.annotation:this.previous().length?this.previous().some(l=>l.annotation):!0}isInline(){if(typeof this.mapOpts.inline!="undefined")return this.mapOpts.inline;let l=this.mapOpts.annotation;return typeof l!="undefined"&&l!==!0?!1:this.previous().length?this.previous().some(n=>n.inline):!0}isMap(){return typeof this.opts.map!="undefined"?!!this.opts.map:this.previous().length>0}isSourcesContent(){return typeof this.mapOpts.sourcesContent!="undefined"?this.mapOpts.sourcesContent:this.previous().length?this.previous().some(l=>l.withContent()):!0}outputFile(){return this.opts.to?this.path(this.opts.to):this.opts.from?this.path(this.opts.from):"to.css"}path(l){if(this.mapOpts.absolute||l.charCodeAt(0)===60||/^\w+:\/\//.test(l))return l;let n=this.memoizedPaths.get(l);if(n)return n;let f=this.opts.to?t(this.opts.to):".";typeof this.mapOpts.annotation=="string"&&(f=t(i(f,this.mapOpts.annotation)));let d=e(f,l);return this.memoizedPaths.set(l,d),d}previous(){if(!this.previousMaps)if(this.previousMaps=[],this.root)this.root.walk(l=>{if(l.source&&l.source.input.map){let n=l.source.input.map;this.previousMaps.includes(n)||this.previousMaps.push(n)}});else{let l=new p(this.originalCSS,this.opts);l.map&&this.previousMaps.push(l.map)}return this.previousMaps}setSourcesContent(){let l={};if(this.root)this.root.walk(n=>{if(n.source){let f=n.source.input.from;if(f&&!l[f]){l[f]=!0;let d=this.usesFileUrls?this.toFileUrl(f):this.toUrl(this.path(f));this.map.setSourceContent(d,n.source.input.css)}}});else if(this.css){let n=this.opts.from?this.toUrl(this.path(this.opts.from)):"<no source>";this.map.setSourceContent(n,this.css)}}sourcePath(l){return this.mapOpts.from?this.toUrl(this.mapOpts.from):this.usesFileUrls?this.toFileUrl(l.source.input.from):this.toUrl(this.path(l.source.input.from))}toBase64(l){return Buffer?Buffer.from(l).toString("base64"):window.btoa(unescape(encodeURIComponent(l)))}toFileUrl(l){let n=this.memoizedFileURLs.get(l);if(n)return n;if(o){let f=o(l).toString();return this.memoizedFileURLs.set(l,f),f}else throw new Error("`map.absolute` option is not available in this PostCSS build")}toUrl(l){let n=this.memoizedURLs.get(l);if(n)return n;c==="\\"&&(l=l.replace(/\\/g,"/"));let f=encodeURI(l).replace(/[#?]/g,encodeURIComponent);return this.memoizedURLs.set(l,f),f}}return _e=r,_e}var Te,It;function Xt(){if(It)return Te;It=1;const t=39,e=34,i=92,c=47,s=10,a=32,o=12,p=9,g=13,h=91,r=93,u=40,l=41,n=123,f=125,d=59,m=42,b=58,w=64,E=/[\t\n\f\r "#'()/;[\\\]{}]/g,x=/[\t\n\f\r !"#'():;@[\\\]{}]|\/(?=\*)/g,y=/.[\r\n"'(/\\]/,R=/[\da-f]/i;return Te=function(S,D={}){let N=S.css.valueOf(),I=D.ignoreErrors,_,ce,Q,O,ot,L,z,j,q,lt,at=N.length,A=0,he=[],K=[];function br(){return A}function fe(G){throw S.error("Unclosed "+G,A)}function Cr(){return K.length===0&&A>=at}function xr(G){if(K.length)return K.pop();if(A>=at)return;let pe=G?G.ignoreUnclosed:!1;switch(_=N.charCodeAt(A),_){case s:case a:case p:case g:case o:{O=A;do O+=1,_=N.charCodeAt(O);while(_===a||_===s||_===p||_===g||_===o);L=["space",N.slice(A,O)],A=O-1;break}case h:case r:case n:case f:case b:case d:case l:{let ut=String.fromCharCode(_);L=[ut,ut,A];break}case u:{if(lt=he.length?he.pop()[1]:"",q=N.charCodeAt(A+1),lt==="url"&&q!==t&&q!==e&&q!==a&&q!==s&&q!==p&&q!==o&&q!==g){O=A;do{if(z=!1,O=N.indexOf(")",O+1),O===-1)if(I||pe){O=A;break}else fe("bracket");for(j=O;N.charCodeAt(j-1)===i;)j-=1,z=!z}while(z);L=["brackets",N.slice(A,O+1),A,O],A=O}else O=N.indexOf(")",A+1),ce=N.slice(A,O+1),O===-1||y.test(ce)?L=["(","(",A]:(L=["brackets",ce,A,O],A=O);break}case t:case e:{ot=_===t?"'":'"',O=A;do{if(z=!1,O=N.indexOf(ot,O+1),O===-1)if(I||pe){O=A+1;break}else fe("string");for(j=O;N.charCodeAt(j-1)===i;)j-=1,z=!z}while(z);L=["string",N.slice(A,O+1),A,O],A=O;break}case w:{E.lastIndex=A+1,E.test(N),E.lastIndex===0?O=N.length-1:O=E.lastIndex-2,L=["at-word",N.slice(A,O+1),A,O],A=O;break}case i:{for(O=A,Q=!0;N.charCodeAt(O+1)===i;)O+=1,Q=!Q;if(_=N.charCodeAt(O+1),Q&&_!==c&&_!==a&&_!==s&&_!==p&&_!==g&&_!==o&&(O+=1,R.test(N.charAt(O)))){for(;R.test(N.charAt(O+1));)O+=1;N.charCodeAt(O+1)===a&&(O+=1)}L=["word",N.slice(A,O+1),A,O],A=O;break}default:{_===c&&N.charCodeAt(A+1)===m?(O=N.indexOf("*/",A+2)+1,O===0&&(I||pe?O=N.length:fe("comment")),L=["comment",N.slice(A,O+1),A,O],A=O):(x.lastIndex=A+1,x.test(N),x.lastIndex===0?O=N.length-1:O=x.lastIndex-2,L=["word",N.slice(A,O+1),A,O],he.push(L),A=O);break}}return A++,L}function vr(G){K.push(G)}return{back:vr,endOfFile:Cr,nextToken:xr,position:br}},Te}var Ie,Pt;function Zt(){if(Pt)return Ie;Pt=1;let t=He(),e=H(),i=le(),c=J(),s=Xe(),a=Xt();const o={empty:!0,space:!0};function p(h){for(let r=h.length-1;r>=0;r--){let u=h[r],l=u[3]||u[2];if(l)return l}}class g{constructor(r){this.input=r,this.root=new c,this.current=this.root,this.spaces="",this.semicolon=!1,this.createTokenizer(),this.root.source={input:r,start:{column:1,line:1,offset:0}}}atrule(r){let u=new t;u.name=r[1].slice(1),u.name===""&&this.unnamedAtrule(u,r),this.init(u,r[2]);let l,n,f,d=!1,m=!1,b=[],w=[];for(;!this.tokenizer.endOfFile();){if(r=this.tokenizer.nextToken(),l=r[0],l==="("||l==="["?w.push(l==="("?")":"]"):l==="{"&&w.length>0?w.push("}"):l===w[w.length-1]&&w.pop(),w.length===0)if(l===";"){u.source.end=this.getPosition(r[2]),u.source.end.offset++,this.semicolon=!0;break}else if(l==="{"){m=!0;break}else if(l==="}"){if(b.length>0){for(f=b.length-1,n=b[f];n&&n[0]==="space";)n=b[--f];n&&(u.source.end=this.getPosition(n[3]||n[2]),u.source.end.offset++)}this.end(r);break}else b.push(r);else b.push(r);if(this.tokenizer.endOfFile()){d=!0;break}}u.raws.between=this.spacesAndCommentsFromEnd(b),b.length?(u.raws.afterName=this.spacesAndCommentsFromStart(b),this.raw(u,"params",b),d&&(r=b[b.length-1],u.source.end=this.getPosition(r[3]||r[2]),u.source.end.offset++,this.spaces=u.raws.between,u.raws.between="")):(u.raws.afterName="",u.params=""),m&&(u.nodes=[],this.current=u)}checkMissedSemicolon(r){let u=this.colon(r);if(u===!1)return;let l=0,n;for(let f=u-1;f>=0&&(n=r[f],!(n[0]!=="space"&&(l+=1,l===2)));f--);throw this.input.error("Missed semicolon",n[0]==="word"?n[3]+1:n[2])}colon(r){let u=0,l,n,f;for(let[d,m]of r.entries()){if(n=m,f=n[0],f==="("&&(u+=1),f===")"&&(u-=1),u===0&&f===":")if(!l)this.doubleColon(n);else{if(l[0]==="word"&&l[1]==="progid")continue;return d}l=n}return!1}comment(r){let u=new e;this.init(u,r[2]),u.source.end=this.getPosition(r[3]||r[2]),u.source.end.offset++;let l=r[1].slice(2,-2);if(/^\s*$/.test(l))u.text="",u.raws.left=l,u.raws.right="";else{let n=l.match(/^(\s*)([^]*\S)(\s*)$/);u.text=n[2],u.raws.left=n[1],u.raws.right=n[3]}}createTokenizer(){this.tokenizer=a(this.input)}decl(r,u){let l=new i;this.init(l,r[0][2]);let n=r[r.length-1];for(n[0]===";"&&(this.semicolon=!0,r.pop()),l.source.end=this.getPosition(n[3]||n[2]||p(r)),l.source.end.offset++;r[0][0]!=="word";)r.length===1&&this.unknownWord(r),l.raws.before+=r.shift()[1];for(l.source.start=this.getPosition(r[0][2]),l.prop="";r.length;){let w=r[0][0];if(w===":"||w==="space"||w==="comment")break;l.prop+=r.shift()[1]}l.raws.between="";let f;for(;r.length;)if(f=r.shift(),f[0]===":"){l.raws.between+=f[1];break}else f[0]==="word"&&/\w/.test(f[1])&&this.unknownWord([f]),l.raws.between+=f[1];(l.prop[0]==="_"||l.prop[0]==="*")&&(l.raws.before+=l.prop[0],l.prop=l.prop.slice(1));let d=[],m;for(;r.length&&(m=r[0][0],!(m!=="space"&&m!=="comment"));)d.push(r.shift());this.precheckMissedSemicolon(r);for(let w=r.length-1;w>=0;w--){if(f=r[w],f[1].toLowerCase()==="!important"){l.important=!0;let E=this.stringFrom(r,w);E=this.spacesFromEnd(r)+E,E!==" !important"&&(l.raws.important=E);break}else if(f[1].toLowerCase()==="important"){let E=r.slice(0),x="";for(let y=w;y>0;y--){let R=E[y][0];if(x.trim().startsWith("!")&&R!=="space")break;x=E.pop()[1]+x}x.trim().startsWith("!")&&(l.important=!0,l.raws.important=x,r=E)}if(f[0]!=="space"&&f[0]!=="comment")break}r.some(w=>w[0]!=="space"&&w[0]!=="comment")&&(l.raws.between+=d.map(w=>w[1]).join(""),d=[]),this.raw(l,"value",d.concat(r),u),l.value.includes(":")&&!u&&this.checkMissedSemicolon(r)}doubleColon(r){throw this.input.error("Double colon",{offset:r[2]},{offset:r[2]+r[1].length})}emptyRule(r){let u=new s;this.init(u,r[2]),u.selector="",u.raws.between="",this.current=u}end(r){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(r[2]),this.current.source.end.offset++,this.current=this.current.parent):this.unexpectedClose(r)}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(r){if(this.spaces+=r[1],this.current.nodes){let u=this.current.nodes[this.current.nodes.length-1];u&&u.type==="rule"&&!u.raws.ownSemicolon&&(u.raws.ownSemicolon=this.spaces,this.spaces="",u.source.end=this.getPosition(r[2]),u.source.end.offset+=u.raws.ownSemicolon.length)}}getPosition(r){let u=this.input.fromOffset(r);return{column:u.col,line:u.line,offset:r}}init(r,u){this.current.push(r),r.source={input:this.input,start:this.getPosition(u)},r.raws.before=this.spaces,this.spaces="",r.type!=="comment"&&(this.semicolon=!1)}other(r){let u=!1,l=null,n=!1,f=null,d=[],m=r[1].startsWith("--"),b=[],w=r;for(;w;){if(l=w[0],b.push(w),l==="("||l==="[")f||(f=w),d.push(l==="("?")":"]");else if(m&&n&&l==="{")f||(f=w),d.push("}");else if(d.length===0)if(l===";")if(n){this.decl(b,m);return}else break;else if(l==="{"){this.rule(b);return}else if(l==="}"){this.tokenizer.back(b.pop()),u=!0;break}else l===":"&&(n=!0);else l===d[d.length-1]&&(d.pop(),d.length===0&&(f=null));w=this.tokenizer.nextToken()}if(this.tokenizer.endOfFile()&&(u=!0),d.length>0&&this.unclosedBracket(f),u&&n){if(!m)for(;b.length&&(w=b[b.length-1][0],!(w!=="space"&&w!=="comment"));)this.tokenizer.back(b.pop());this.decl(b,m)}else this.unknownWord(b)}parse(){let r;for(;!this.tokenizer.endOfFile();)switch(r=this.tokenizer.nextToken(),r[0]){case"space":this.spaces+=r[1];break;case";":this.freeSemicolon(r);break;case"}":this.end(r);break;case"comment":this.comment(r);break;case"at-word":this.atrule(r);break;case"{":this.emptyRule(r);break;default:this.other(r);break}this.endFile()}precheckMissedSemicolon(){}raw(r,u,l,n){let f,d,m=l.length,b="",w=!0,E,x;for(let y=0;y<m;y+=1)f=l[y],d=f[0],d==="space"&&y===m-1&&!n?w=!1:d==="comment"?(x=l[y-1]?l[y-1][0]:"empty",E=l[y+1]?l[y+1][0]:"empty",!o[x]&&!o[E]?b.slice(-1)===","?w=!1:b+=f[1]:w=!1):b+=f[1];if(!w){let y=l.reduce((R,C)=>R+C[1],"");r.raws[u]={raw:y,value:b}}r[u]=b}rule(r){r.pop();let u=new s;this.init(u,r[0][2]),u.raws.between=this.spacesAndCommentsFromEnd(r),this.raw(u,"selector",r),this.current=u}spacesAndCommentsFromEnd(r){let u,l="";for(;r.length&&(u=r[r.length-1][0],!(u!=="space"&&u!=="comment"));)l=r.pop()[1]+l;return l}spacesAndCommentsFromStart(r){let u,l="";for(;r.length&&(u=r[0][0],!(u!=="space"&&u!=="comment"));)l+=r.shift()[1];return l}spacesFromEnd(r){let u,l="";for(;r.length&&(u=r[r.length-1][0],u==="space");)l=r.pop()[1]+l;return l}stringFrom(r,u){let l="";for(let n=u;n<r.length;n++)l+=r[n][1];return r.splice(u,r.length-u),l}unclosedBlock(){let r=this.current.source.start;throw this.input.error("Unclosed block",r.line,r.column)}unclosedBracket(r){throw this.input.error("Unclosed bracket",{offset:r[2]},{offset:r[2]+1})}unexpectedClose(r){throw this.input.error("Unexpected }",{offset:r[2]},{offset:r[2]+1})}unknownWord(r){throw this.input.error("Unknown word "+r[0][1],{offset:r[0][2]},{offset:r[0][2]+r[0][1].length})}unnamedAtrule(r,u){throw this.input.error("At-rule without name",{offset:u[2]},{offset:u[2]+u[1].length})}}return Ie=g,Ie}var Pe,Lt;function Ze(){if(Lt)return Pe;Lt=1;let t=W(),e=ae(),i=Zt();function c(s,a){let o=new e(s,a),p=new i(o);try{p.parse()}catch(g){throw g}return p.root}return Pe=c,c.default=c,t.registerParse(c),Pe}var Le,kt;function Qt(){if(kt)return Le;kt=1;class t{constructor(i,c={}){if(this.type="warning",this.text=i,c.node&&c.node.source){let s=c.node.rangeBy(c);this.line=s.start.line,this.column=s.start.column,this.endLine=s.end.line,this.endColumn=s.end.column}for(let s in c)this[s]=c[s]}toString(){return this.node?this.node.error(this.text,{index:this.index,plugin:this.plugin,word:this.word}).message:this.plugin?this.plugin+": "+this.text:this.text}}return Le=t,t.default=t,Le}var ke,Bt;function Qe(){if(Bt)return ke;Bt=1;let t=Qt();class e{get content(){return this.css}constructor(c,s,a){this.processor=c,this.messages=[],this.root=s,this.opts=a,this.css="",this.map=void 0}toString(){return this.css}warn(c,s={}){s.plugin||this.lastPlugin&&this.lastPlugin.postcssPlugin&&(s.plugin=this.lastPlugin.postcssPlugin);let a=new t(c,s);return this.messages.push(a),a}warnings(){return this.messages.filter(c=>c.type==="warning")}}return ke=e,e.default=e,ke}var Be,Ut;function Kt(){if(Ut)return Be;Ut=1;let t={};return Be=function(i){t[i]||(t[i]=!0,typeof console!="undefined"&&console.warn&&console.warn(i))},Be}var Ue,Ft;function er(){if(Ft)return Ue;Ft=1;let t=W(),e=Je(),i=Jt(),c=Ze(),s=Qe(),a=J(),o=ne(),{isClean:p,my:g}=Ye(),h=Kt();const r={atrule:"AtRule",comment:"Comment",decl:"Declaration",document:"Document",root:"Root",rule:"Rule"},u={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},l={Once:!0,postcssPlugin:!0,prepare:!0},n=0;function f(x){return typeof x=="object"&&typeof x.then=="function"}function d(x){let y=!1,R=r[x.type];return x.type==="decl"?y=x.prop.toLowerCase():x.type==="atrule"&&(y=x.name.toLowerCase()),y&&x.append?[R,R+"-"+y,n,R+"Exit",R+"Exit-"+y]:y?[R,R+"-"+y,R+"Exit",R+"Exit-"+y]:x.append?[R,n,R+"Exit"]:[R,R+"Exit"]}function m(x){let y;return x.type==="document"?y=["Document",n,"DocumentExit"]:x.type==="root"?y=["Root",n,"RootExit"]:y=d(x),{eventIndex:0,events:y,iterator:0,node:x,visitorIndex:0,visitors:[]}}function b(x){return x[p]=!1,x.nodes&&x.nodes.forEach(y=>b(y)),x}let w={};class E{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,R,C){this.stringified=!1,this.processed=!1;let S;if(typeof R=="object"&&R!==null&&(R.type==="root"||R.type==="document"))S=b(R);else if(R instanceof E||R instanceof s)S=b(R.root),R.map&&(typeof C.map=="undefined"&&(C.map={}),C.map.inline||(C.map.inline=!1),C.map.prev=R.map);else{let D=c;C.syntax&&(D=C.syntax.parse),C.parser&&(D=C.parser),D.parse&&(D=D.parse);try{S=D(R,C)}catch(N){this.processed=!0,this.error=N}S&&!S[g]&&t.rebuild(S)}this.result=new s(y,S,C),this.helpers=Y(k({},w),{postcss:w,result:this.result}),this.plugins=this.processor.plugins.map(D=>typeof D=="object"&&D.prepare?k(k({},D),D.prepare(this.result)):D)}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,R){let C=this.result.lastPlugin;try{R&&R.addToError(y),this.error=y,y.name==="CssSyntaxError"&&!y.plugin?(y.plugin=C.postcssPlugin,y.setMessage()):C.postcssVersion}catch(S){console&&console.error&&console.error(S)}return y}prepareVisitors(){this.listeners={};let y=(R,C,S)=>{this.listeners[C]||(this.listeners[C]=[]),this.listeners[C].push([R,S])};for(let R of this.plugins)if(typeof R=="object")for(let C in R){if(!u[C]&&/^[A-Z]/.test(C))throw new Error(`Unknown event ${C} in ${R.postcssPlugin}. Try to update PostCSS (${this.processor.version} now).`);if(!l[C])if(typeof R[C]=="object")for(let S in R[C])S==="*"?y(R,C,R[C][S]):y(R,C+"-"+S.toLowerCase(),R[C][S]);else typeof R[C]=="function"&&y(R,C,R[C])}this.hasListener=Object.keys(this.listeners).length>0}async runAsync(){this.plugin=0;for(let y=0;y<this.plugins.length;y++){let R=this.plugins[y],C=this.runOnRoot(R);if(f(C))try{await C}catch(S){throw this.handleError(S)}}if(this.prepareVisitors(),this.hasListener){let y=this.result.root;for(;!y[p];){y[p]=!0;let R=[m(y)];for(;R.length>0;){let C=this.visitTick(R);if(f(C))try{await C}catch(S){let D=R[R.length-1].node;throw this.handleError(S,D)}}}if(this.listeners.OnceExit)for(let[R,C]of this.listeners.OnceExit){this.result.lastPlugin=R;try{if(y.type==="document"){let S=y.nodes.map(D=>C(D,this.helpers));await Promise.all(S)}else await C(y,this.helpers)}catch(S){throw this.handleError(S)}}}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 R=this.result.root.nodes.map(C=>y.Once(C,this.helpers));return f(R[0])?Promise.all(R):R}return y.Once(this.result.root,this.helpers)}else if(typeof y=="function")return y(this.result.root,this.result)}catch(R){throw this.handleError(R)}}stringify(){if(this.error)throw this.error;if(this.stringified)return this.result;this.stringified=!0,this.sync();let y=this.result.opts,R=o;y.syntax&&(R=y.syntax.stringify),y.stringifier&&(R=y.stringifier),R.stringify&&(R=R.stringify);let S=new i(R,this.result.root,this.result.opts).generate();return this.result.css=S[0],this.result.map=S[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 R=this.runOnRoot(y);if(f(R))throw this.getAsyncError()}if(this.prepareVisitors(),this.hasListener){let y=this.result.root;for(;!y[p];)y[p]=!0,this.walkSync(y);if(this.listeners.OnceExit)if(y.type==="document")for(let R of y.nodes)this.visitSync(this.listeners.OnceExit,R);else this.visitSync(this.listeners.OnceExit,y)}return this.result}then(y,R){return this.async().then(y,R)}toString(){return this.css}visitSync(y,R){for(let[C,S]of y){this.result.lastPlugin=C;let D;try{D=S(R,this.helpers)}catch(N){throw this.handleError(N,R.proxyOf)}if(R.type!=="root"&&R.type!=="document"&&!R.parent)return!0;if(f(D))throw this.getAsyncError()}}visitTick(y){let R=y[y.length-1],{node:C,visitors:S}=R;if(C.type!=="root"&&C.type!=="document"&&!C.parent){y.pop();return}if(S.length>0&&R.visitorIndex<S.length){let[N,I]=S[R.visitorIndex];R.visitorIndex+=1,R.visitorIndex===S.length&&(R.visitors=[],R.visitorIndex=0),this.result.lastPlugin=N;try{return I(C.toProxy(),this.helpers)}catch(_){throw this.handleError(_,C)}}if(R.iterator!==0){let N=R.iterator,I;for(;I=C.nodes[C.indexes[N]];)if(C.indexes[N]+=1,!I[p]){I[p]=!0,y.push(m(I));return}R.iterator=0,delete C.indexes[N]}let D=R.events;for(;R.eventIndex<D.length;){let N=D[R.eventIndex];if(R.eventIndex+=1,N===n){C.nodes&&C.nodes.length&&(C[p]=!0,R.iterator=C.getIterator());return}else if(this.listeners[N]){R.visitors=this.listeners[N];return}}y.pop()}walkSync(y){y[p]=!0;let R=d(y);for(let C of R)if(C===n)y.nodes&&y.each(S=>{S[p]||this.walkSync(S)});else{let S=this.listeners[C];if(S&&this.visitSync(S,y.toProxy()))return}}warnings(){return this.sync().warnings()}}return E.registerPostcss=x=>{w=x},Ue=E,E.default=E,a.registerLazyResult(E),e.registerLazyResult(E),Ue}var Fe,zt;function qr(){if(zt)return Fe;zt=1;let t=Jt(),e=Ze();const i=Qe();let c=ne(),s=Kt();class a{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 p,g=e;try{p=g(this._css,this._opts)}catch(h){this.error=h}if(this.error)throw this.error;return this._root=p,p}get[Symbol.toStringTag](){return"NoWorkResult"}constructor(p,g,h){g=g.toString(),this.stringified=!1,this._processor=p,this._css=g,this._opts=h,this._map=void 0;let r,u=c;this.result=new i(this._processor,r,this._opts),this.result.css=g;let l=this;Object.defineProperty(this.result,"root",{get(){return l.root}});let n=new t(u,r,this._opts,g);if(n.isMap()){let[f,d]=n.generate();f&&(this.result.css=f),d&&(this.result.map=d)}else n.clearAnnotation(),this.result.css=n.css}async(){return this.error?Promise.reject(this.error):Promise.resolve(this.result)}catch(p){return this.async().catch(p)}finally(p){return this.async().then(p,p)}sync(){if(this.error)throw this.error;return this.result}then(p,g){return this.async().then(p,g)}toString(){return this._css}warnings(){return[]}}return Fe=a,a.default=a,Fe}var ze,qt;function Wr(){if(qt)return ze;qt=1;let t=Je(),e=er(),i=qr(),c=J();class s{constructor(o=[]){this.version="8.5.6",this.plugins=this.normalize(o)}normalize(o){let p=[];for(let g of o)if(g.postcss===!0?g=g():g.postcss&&(g=g.postcss),typeof g=="object"&&Array.isArray(g.plugins))p=p.concat(g.plugins);else if(typeof g=="object"&&g.postcssPlugin)p.push(g);else if(typeof g=="function")p.push(g);else if(!(typeof g=="object"&&(g.parse||g.stringify)))throw new Error(g+" is not a PostCSS plugin");return p}process(o,p={}){return!this.plugins.length&&!p.parser&&!p.stringifier&&!p.syntax?new i(this,o,p):new e(this,o,p)}use(o){return this.plugins=this.plugins.concat(this.normalize([o])),this}}return ze=s,s.default=s,c.registerProcessor(s),t.registerProcessor(s),ze}var qe,Wt;function tr(){if(Wt)return qe;Wt=1;let t=He(),e=H(),i=W(),c=Ve(),s=le(),a=Je(),o=zr(),p=ae(),g=er(),h=Ht(),r=oe(),u=Ze(),l=Wr(),n=Qe(),f=J(),d=Xe(),m=ne(),b=Qt();function w(...E){return E.length===1&&Array.isArray(E[0])&&(E=E[0]),new l(E)}return w.plugin=function(x,y){let R=!1;function C(...D){console&&console.warn&&!R&&(R=!0,console.warn(x+`: postcss.plugin was deprecated. Migration guide:
|
|
28
|
+
https://evilmartians.com/chronicles/postcss-8-plugin-migration`),process.env.LANG&&process.env.LANG.startsWith("cn")&&console.warn(x+`: \u91CC\u9762 postcss.plugin \u88AB\u5F03\u7528. \u8FC1\u79FB\u6307\u5357:
|
|
29
|
+
https://www.w3ctech.com/topic/2226`));let N=y(...D);return N.postcssPlugin=x,N.postcssVersion=new l().version,N}let S;return Object.defineProperty(C,"postcss",{get(){return S||(S=C()),S}}),C.process=function(D,N,I){return w([C(I)]).process(D,N)},C},w.stringify=m,w.parse=u,w.fromJSON=o,w.list=h,w.comment=E=>new e(E),w.atRule=E=>new t(E),w.decl=E=>new s(E),w.rule=E=>new d(E),w.root=E=>new f(E),w.document=E=>new a(E),w.CssSyntaxError=c,w.Declaration=s,w.Container=i,w.Processor=l,w.Document=a,w.Comment=e,w.Warning=b,w.AtRule=t,w.Result=n,w.Input=p,w.Rule=d,w.Root=f,w.Node=r,g.registerPostcss(w),qe=w,w.default=w,qe}var We,jt;function jr(){if(jt)return We;jt=1;let t=H(),e=Zt(),i=Xt();class c extends e{checkMissedSemicolon(){}comment(a){let o=new t;this.init(o,a[2]);let p=this.input.fromOffset(a[3])||this.input.fromOffset(this.input.css.length-1);o.source.end={column:p.col,line:p.line,offset:a[3]+1};let g=a[1].slice(2);if(g.slice(-2)==="*/"&&(g=g.slice(0,-2)),/^\s*$/.test(g))o.text="",o.raws.left=g,o.raws.right="";else{let h=g.match(/^(\s*)([^]*\S)(\s*)$/);o.text=h[2],o.raws.left=h[1],o.raws.right=h[3]}}createTokenizer(){this.tokenizer=i(this.input,{ignoreErrors:!0})}decl(a){a.length>1&&a.some(o=>o[0]==="word")&&super.decl(a)}doubleColon(){}endFile(){for(this.current.nodes&&this.current.nodes.length&&(this.current.raws.semicolon=this.semicolon),this.current.raws.after=(this.current.raws.after||"")+this.spaces;this.current.parent;)this.current=this.current.parent,this.current.raws.after="";this.root.source.end=this.getPosition(this.tokenizer.position())}precheckMissedSemicolon(a){let o=this.colon(a);if(o===!1)return;let p,g;for(p=o-1;p>=0&&a[p][0]!=="word";p--);if(p===0||p<0)return;for(g=p-1;g>=0;g--)if(a[g][0]!=="space"){g+=1;break}let h=a.slice(p),r=a.slice(g,p);a.splice(g,a.length-g),this.spaces=r.map(u=>u[1]).join(""),this.decl(h)}unclosedBracket(){}unexpectedClose(){this.current.raws.after+="}"}unknownWord(a){this.spaces+=a.map(o=>o[1]).join("")}unnamedAtrule(a){a.name=""}}return We=c,We}var je,Gt;function Gr(){if(Gt)return je;Gt=1;let{Input:t}=tr(),e=jr();return je=function(c,s){let a=new t(c,s),o=new e(a);return o.parse(),o.root},je}Gr();var $r=tr();const T=Pr($r);T.stringify;T.fromJSON;T.plugin;T.parse;T.list;T.document;T.comment;T.atRule;T.rule;T.decl;T.root;T.CssSyntaxError;T.Declaration;T.Container;T.Processor;T.Document;T.Comment;T.Warning;T.AtRule;T.Result;T.Input;T.Rule;T.Root;T.Node;var M=(t=>(t[t.Document=0]="Document",t[t.DocumentType=1]="DocumentType",t[t.Element=2]="Element",t[t.Text=3]="Text",t[t.CDATA=4]="CDATA",t[t.Comment=5]="Comment",t))(M||{});function Vr(t){const e={},i=/;(?![^(]*\))/g,c=/:(.+)/,s=/\/\*.*?\*\//g;return t.replace(s,"").split(i).forEach(function(a){if(a){const o=a.split(c);o.length>1&&(e[Ge(o[0].trim())]=o[1].trim())}}),e}function $t(t){const e=[];for(const i in t){const c=t[i];if(typeof c!="string")continue;const s=Xr(i);e.push(`${s}: ${c};`)}return e.join(" ")}const Yr=/-([a-z])/g,Hr=/^--[a-zA-Z0-9-]+$/,Ge=t=>Hr.test(t)?t:t.replace(Yr,(e,i)=>i?i.toUpperCase():""),Jr=/\B([A-Z])/g,Xr=t=>t.replace(Jr,"-$1").toLowerCase();class F{constructor(...e){v(this,"parentElement",null),v(this,"parentNode",null),v(this,"ownerDocument"),v(this,"firstChild",null),v(this,"lastChild",null),v(this,"previousSibling",null),v(this,"nextSibling",null),v(this,"ELEMENT_NODE",1),v(this,"TEXT_NODE",3),v(this,"nodeType"),v(this,"nodeName"),v(this,"RRNodeType")}get childNodes(){const e=[];let i=this.firstChild;for(;i;)e.push(i),i=i.nextSibling;return e}contains(e){if(e instanceof F){if(e.ownerDocument!==this.ownerDocument)return!1;if(e===this)return!0}else return!1;for(;e.parentNode;){if(e.parentNode===this)return!0;e=e.parentNode}return!1}appendChild(e){throw new Error("RRDomException: Failed to execute 'appendChild' on 'RRNode': This RRNode type does not support this method.")}insertBefore(e,i){throw new Error("RRDomException: Failed to execute 'insertBefore' on 'RRNode': This RRNode type does not support this method.")}removeChild(e){throw new Error("RRDomException: Failed to execute 'removeChild' on 'RRNode': This RRNode type does not support this method.")}toString(){return"RRNode"}}class ue extends F{constructor(...e){super(e),v(this,"nodeType",9),v(this,"nodeName","#document"),v(this,"compatMode","CSS1Compat"),v(this,"RRNodeType",M.Document),v(this,"textContent",null),this.ownerDocument=this}get documentElement(){return this.childNodes.find(e=>e.RRNodeType===M.Element&&e.tagName==="HTML")||null}get body(){var e;return((e=this.documentElement)==null?void 0:e.childNodes.find(i=>i.RRNodeType===M.Element&&i.tagName==="BODY"))||null}get head(){var e;return((e=this.documentElement)==null?void 0:e.childNodes.find(i=>i.RRNodeType===M.Element&&i.tagName==="HEAD"))||null}get implementation(){return this}get firstElementChild(){return this.documentElement}appendChild(e){const i=e.RRNodeType;if((i===M.Element||i===M.DocumentType)&&this.childNodes.some(s=>s.RRNodeType===i))throw new Error(`RRDomException: Failed to execute 'appendChild' on 'RRNode': Only one ${i===M.Element?"RRElement":"RRDoctype"} on RRDocument allowed.`);const c=st(this,e);return c.parentElement=null,c}insertBefore(e,i){const c=e.RRNodeType;if((c===M.Element||c===M.DocumentType)&&this.childNodes.some(a=>a.RRNodeType===c))throw new Error(`RRDomException: Failed to execute 'insertBefore' on 'RRNode': Only one ${c===M.Element?"RRElement":"RRDoctype"} on RRDocument allowed.`);const s=nr(this,e,i);return s.parentElement=null,s}removeChild(e){return or(this,e)}open(){this.firstChild=null,this.lastChild=null}close(){}write(e){let i;if(e==='<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "">'?i="-//W3C//DTD XHTML 1.0 Transitional//EN":e==='<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN" "">'&&(i="-//W3C//DTD HTML 4.0 Transitional//EN"),i){const c=this.createDocumentType("html",i,"");this.open(),this.appendChild(c)}}createDocument(e,i,c){return new ue}createDocumentType(e,i,c){const s=new Ke(e,i,c);return s.ownerDocument=this,s}createElement(e){const i=new X(e);return i.ownerDocument=this,i}createElementNS(e,i){return this.createElement(i)}createTextNode(e){const i=new et(e);return i.ownerDocument=this,i}createComment(e){const i=new tt(e);return i.ownerDocument=this,i}createCDATASection(e){const i=new rt(e);return i.ownerDocument=this,i}toString(){return"RRDocument"}}class Ke extends F{constructor(e,i,c){super(),v(this,"nodeType",10),v(this,"RRNodeType",M.DocumentType),v(this,"name"),v(this,"publicId"),v(this,"systemId"),v(this,"textContent",null),this.name=e,this.publicId=i,this.systemId=c,this.nodeName=e}toString(){return"RRDocumentType"}}class X extends F{constructor(e){super(),v(this,"nodeType",1),v(this,"RRNodeType",M.Element),v(this,"tagName"),v(this,"attributes",{}),v(this,"shadowRoot",null),v(this,"scrollLeft"),v(this,"scrollTop"),this.tagName=e.toUpperCase(),this.nodeName=e.toUpperCase()}get textContent(){let e="";return this.childNodes.forEach(i=>e+=i.textContent),e}set textContent(e){this.firstChild=null,this.lastChild=null,this.appendChild(this.ownerDocument.createTextNode(e))}get classList(){return new ir(this.attributes.class,e=>{this.attributes.class=e})}get id(){return this.attributes.id||""}get className(){return this.attributes.class||""}get style(){const e=this.attributes.style?Vr(this.attributes.style):{},i=/\B([A-Z])/g;return e.setProperty=(c,s,a)=>{if(i.test(c))return;const o=Ge(c);s?e[o]=s:delete e[o],a==="important"&&(e[o]+=" !important"),this.attributes.style=$t(e)},e.removeProperty=c=>{if(i.test(c))return"";const s=Ge(c),a=e[s]||"";return delete e[s],this.attributes.style=$t(e),a},e}getAttribute(e){return this.attributes[e]===void 0?null:this.attributes[e]}setAttribute(e,i){this.attributes[e]=i}setAttributeNS(e,i,c){this.setAttribute(i,c)}removeAttribute(e){delete this.attributes[e]}appendChild(e){return st(this,e)}insertBefore(e,i){return nr(this,e,i)}removeChild(e){return or(this,e)}attachShadow(e){const i=this.ownerDocument.createElement("SHADOWROOT");return this.shadowRoot=i,i}dispatchEvent(e){return!0}toString(){let e="";for(const i in this.attributes)e+=`${i}="${this.attributes[i]}" `;return`${this.tagName} ${e}`}}class rr extends X{constructor(){super(...arguments),v(this,"currentTime"),v(this,"volume"),v(this,"paused"),v(this,"muted"),v(this,"playbackRate"),v(this,"loop")}attachShadow(e){throw new Error("RRDomException: Failed to execute 'attachShadow' on 'RRElement': This RRElement does not support attachShadow")}play(){this.paused=!1}pause(){this.paused=!0}}class sr extends X{constructor(){super(...arguments),v(this,"tagName","DIALOG"),v(this,"nodeName","DIALOG")}get isModal(){return this.getAttribute("rr_open_mode")==="modal"}get open(){return this.getAttribute("open")!==null}close(){this.removeAttribute("open"),this.removeAttribute("rr_open_mode")}show(){this.setAttribute("open",""),this.setAttribute("rr_open_mode","non-modal")}showModal(){this.setAttribute("open",""),this.setAttribute("rr_open_mode","modal")}}class et extends F{constructor(e){super(),v(this,"nodeType",3),v(this,"nodeName","#text"),v(this,"RRNodeType",M.Text),v(this,"data"),this.data=e}get textContent(){return this.data}set textContent(e){this.data=e}toString(){return`RRText text=${JSON.stringify(this.data)}`}}class tt extends F{constructor(e){super(),v(this,"nodeType",8),v(this,"nodeName","#comment"),v(this,"RRNodeType",M.Comment),v(this,"data"),this.data=e}get textContent(){return this.data}set textContent(e){this.data=e}toString(){return`RRComment text=${JSON.stringify(this.data)}`}}class rt extends F{constructor(e){super(),v(this,"nodeName","#cdata-section"),v(this,"nodeType",4),v(this,"RRNodeType",M.CDATA),v(this,"data"),this.data=e}get textContent(){return this.data}set textContent(e){this.data=e}toString(){return`RRCDATASection data=${JSON.stringify(this.data)}`}}class ir{constructor(e,i){if(v(this,"onChange"),v(this,"classes",[]),v(this,"add",(...c)=>{for(const s of c){const a=String(s);this.classes.indexOf(a)>=0||this.classes.push(a)}this.onChange&&this.onChange(this.classes.join(" "))}),v(this,"remove",(...c)=>{this.classes=this.classes.filter(s=>c.indexOf(s)===-1),this.onChange&&this.onChange(this.classes.join(" "))}),e){const c=e.trim().split(/\s+/);this.classes.push(...c)}this.onChange=i}}function st(t,e){return e.parentNode&&e.parentNode.removeChild(e),t.lastChild?(t.lastChild.nextSibling=e,e.previousSibling=t.lastChild):(t.firstChild=e,e.previousSibling=null),t.lastChild=e,e.nextSibling=null,e.parentNode=t,e.parentElement=t,e.ownerDocument=t.ownerDocument,e}function nr(t,e,i){if(!i)return st(t,e);if(i.parentNode!==t)throw new Error("Failed to execute 'insertBefore' on 'RRNode': The RRNode before which the new node is to be inserted is not a child of this RRNode.");return e===i||(e.parentNode&&e.parentNode.removeChild(e),e.previousSibling=i.previousSibling,i.previousSibling=e,e.nextSibling=i,e.previousSibling?e.previousSibling.nextSibling=e:t.firstChild=e,e.parentElement=t,e.parentNode=t,e.ownerDocument=t.ownerDocument),e}function or(t,e){if(e.parentNode!==t)throw new Error("Failed to execute 'removeChild' on 'RRNode': The RRNode to be removed is not a child of this RRNode.");return e.previousSibling?e.previousSibling.nextSibling=e.nextSibling:t.firstChild=e.nextSibling,e.nextSibling?e.nextSibling.previousSibling=e.previousSibling:t.lastChild=e.previousSibling,e.previousSibling=null,e.nextSibling=null,e.parentElement=null,e.parentNode=null,e}var P=(t=>(t[t.PLACEHOLDER=0]="PLACEHOLDER",t[t.ELEMENT_NODE=1]="ELEMENT_NODE",t[t.ATTRIBUTE_NODE=2]="ATTRIBUTE_NODE",t[t.TEXT_NODE=3]="TEXT_NODE",t[t.CDATA_SECTION_NODE=4]="CDATA_SECTION_NODE",t[t.ENTITY_REFERENCE_NODE=5]="ENTITY_REFERENCE_NODE",t[t.ENTITY_NODE=6]="ENTITY_NODE",t[t.PROCESSING_INSTRUCTION_NODE=7]="PROCESSING_INSTRUCTION_NODE",t[t.COMMENT_NODE=8]="COMMENT_NODE",t[t.DOCUMENT_NODE=9]="DOCUMENT_NODE",t[t.DOCUMENT_TYPE_NODE=10]="DOCUMENT_TYPE_NODE",t[t.DOCUMENT_FRAGMENT_NODE=11]="DOCUMENT_FRAGMENT_NODE",t))(P||{});const $e={svg:"http://www.w3.org/2000/svg","xlink:href":"http://www.w3.org/1999/xlink",xmlns:"http://www.w3.org/2000/xmlns/"},Zr={altglyph:"altGlyph",altglyphdef:"altGlyphDef",altglyphitem:"altGlyphItem",animatecolor:"animateColor",animatemotion:"animateMotion",animatetransform:"animateTransform",clippath:"clipPath",feblend:"feBlend",fecolormatrix:"feColorMatrix",fecomponenttransfer:"feComponentTransfer",fecomposite:"feComposite",feconvolvematrix:"feConvolveMatrix",fediffuselighting:"feDiffuseLighting",fedisplacementmap:"feDisplacementMap",fedistantlight:"feDistantLight",fedropshadow:"feDropShadow",feflood:"feFlood",fefunca:"feFuncA",fefuncb:"feFuncB",fefuncg:"feFuncG",fefuncr:"feFuncR",fegaussianblur:"feGaussianBlur",feimage:"feImage",femerge:"feMerge",femergenode:"feMergeNode",femorphology:"feMorphology",feoffset:"feOffset",fepointlight:"fePointLight",fespecularlighting:"feSpecularLighting",fespotlight:"feSpotLight",fetile:"feTile",feturbulence:"feTurbulence",foreignobject:"foreignObject",glyphref:"glyphRef",lineargradient:"linearGradient",radialgradient:"radialGradient"};let U=null;function it(t,e,i,c=e.mirror||e.ownerDocument.mirror){t=Qr(t,e,i,c),lr(t,e,i,c),Kr(t,e,i)}function Qr(t,e,i,c){var s;if(i.afterAppend&&!U&&(U=new WeakSet,setTimeout(()=>{U=null},0)),!nt(t,e)){const a=ie(e,i.mirror,c);(s=t.parentNode)==null||s.replaceChild(a,t),t=a}switch(e.RRNodeType){case M.Document:{if(!$(t,e,i.mirror,c)){const a=c.getMeta(e);a&&(i.mirror.removeNodeFromMap(t),t.close(),t.open(),i.mirror.add(t,a),U==null||U.add(t))}break}case M.Element:{const a=t,o=e;switch(o.tagName){case"IFRAME":{const p=t.contentDocument;if(!p)break;it(p,e.contentDocument,i,c);break}}o.shadowRoot&&(a.shadowRoot||a.attachShadow({mode:"open"}),lr(a.shadowRoot,o.shadowRoot,i,c)),es(a,o,c);break}}return t}function Kr(t,e,i){var c;switch(e.RRNodeType){case M.Document:{const s=e.scrollData;s&&i.applyScroll(s,!0);break}case M.Element:{const s=t,a=e;switch(a.scrollData&&i.applyScroll(a.scrollData,!0),a.inputData&&i.applyInput(a.inputData),a.tagName){case"AUDIO":case"VIDEO":{const o=t,p=a;p.paused!==void 0&&(p.paused?o.pause():o.play()),p.muted!==void 0&&(o.muted=p.muted),p.volume!==void 0&&(o.volume=p.volume),p.currentTime!==void 0&&(o.currentTime=p.currentTime),p.playbackRate!==void 0&&(o.playbackRate=p.playbackRate),p.loop!==void 0&&(o.loop=p.loop);break}case"CANVAS":{const o=e;if(o.rr_dataURL!==null){const p=document.createElement("img");p.onload=()=>{const g=s.getContext("2d");g&&g.drawImage(p,0,0,p.width,p.height)},p.src=o.rr_dataURL}o.canvasMutations.forEach(p=>i.applyCanvas(p.event,p.mutation,t));break}case"STYLE":{const o=s.sheet;o&&e.rules.forEach(p=>i.applyStyleSheetMutation(p,o));break}case"DIALOG":{const o=s,p=a,g=o.open,h=o.matches("dialog:modal"),r=p.open,u=p.isModal,l=h!==u,n=g!==r;if((l||g&&n)&&o.close(),r&&(n||l))try{u?o.showModal():o.show()}catch(f){console.warn(f)}break}}break}case M.Text:case M.Comment:case M.CDATA:{t.textContent!==e.data&&(t.textContent=e.data);break}}U!=null&&U.has(t)&&(U.delete(t),(c=i.afterAppend)==null||c.call(i,t,i.mirror.getId(t)))}function es(t,e,i){const c=t.attributes,s=e.attributes;for(const a in s){const o=s[a],p=i.getMeta(e);if(p!=null&&p.isSVG&&$e[a])t.setAttributeNS($e[a],a,o);else if(e.tagName==="CANVAS"&&a==="rr_dataURL"){const g=document.createElement("img");g.src=o,g.onload=()=>{const h=t.getContext("2d");h&&h.drawImage(g,0,0,g.width,g.height)}}else{if(e.tagName==="IFRAME"&&a==="srcdoc")continue;try{t.setAttribute(a,o)}catch(g){console.warn(g)}}}for(const{name:a}of Array.from(c))a in s||t.removeAttribute(a);e.scrollLeft&&(t.scrollLeft=e.scrollLeft),e.scrollTop&&(t.scrollTop=e.scrollTop)}function lr(t,e,i,c){const s=Array.from(t.childNodes),a=e.childNodes;if(s.length===0&&a.length===0)return;let o=0,p=s.length-1,g=0,h=a.length-1,r=s[o],u=s[p],l=a[g],n=a[h],f,d;for(;o<=p&&g<=h;)if(r===void 0)r=s[++o];else if(u===void 0)u=s[--p];else if($(r,l,i.mirror,c))r=s[++o],l=a[++g];else if($(u,n,i.mirror,c))u=s[--p],n=a[--h];else if($(r,n,i.mirror,c)){try{t.insertBefore(r,u.nextSibling)}catch(w){console.warn(w)}r=s[++o],n=a[--h]}else if($(u,l,i.mirror,c)){try{t.insertBefore(u,r)}catch(w){console.warn(w)}u=s[--p],l=a[++g]}else{if(!f){f={};for(let E=o;E<=p;E++){const x=s[E];x&&i.mirror.hasNode(x)&&(f[i.mirror.getId(x)]=E)}}d=f[c.getId(l)];const w=s[d];if(d!==void 0&&w&&$(w,l,i.mirror,c)){try{t.insertBefore(w,r)}catch(E){console.warn(E)}s[d]=void 0}else{const E=ie(l,i.mirror,c);t.nodeName==="#document"&&r&&(E.nodeType===E.DOCUMENT_TYPE_NODE&&r.nodeType===r.DOCUMENT_TYPE_NODE||E.nodeType===E.ELEMENT_NODE&&r.nodeType===r.ELEMENT_NODE)&&(t.removeChild(r),i.mirror.removeNodeFromMap(r),r=s[++o]);try{t.insertBefore(E,r||null)}catch(x){console.warn(x)}}l=a[++g]}if(o>p){const w=a[h+1];let E=null;for(w&&(E=i.mirror.getNode(c.getId(w)));g<=h;++g){const x=ie(a[g],i.mirror,c);try{t.insertBefore(x,E)}catch(y){console.warn(y)}}}else if(g>h)for(;o<=p;o++){const w=s[o];if(!(!w||w.parentNode!==t))try{t.removeChild(w),i.mirror.removeNodeFromMap(w)}catch(E){console.warn(E)}}let m=t.firstChild,b=e.firstChild;for(;m!==null&&b!==null;)it(m,b,i,c),m=m.nextSibling,b=b.nextSibling}function ie(t,e,i){const c=i.getId(t),s=i.getMeta(t);let a=null;if(c>-1&&(a=e.getNode(c)),a!==null&&nt(a,t))return a;switch(t.RRNodeType){case M.Document:a=new Document;break;case M.DocumentType:a=document.implementation.createDocumentType(t.name,t.publicId,t.systemId);break;case M.Element:{let o=t.tagName.toLowerCase();o=Zr[o]||o,s&&"isSVG"in s&&(s!=null&&s.isSVG)?a=document.createElementNS($e.svg,o):a=document.createElement(t.tagName);break}case M.Text:a=document.createTextNode(t.data);break;case M.Comment:a=document.createComment(t.data);break;case M.CDATA:a=document.createCDATASection(t.data);break}s&&e.add(a,k({},s));try{U==null||U.add(a)}catch(o){}return a}function nt(t,e){return t.nodeType!==e.nodeType?!1:t.nodeType!==t.ELEMENT_NODE||t.tagName.toUpperCase()===e.tagName}function $(t,e,i,c){const s=i.getId(t),a=c.getId(e);return s===-1||s!==a?!1:nt(t,e)}class V extends ue{constructor(e){super(),v(this,"UNSERIALIZED_STARTING_ID",-2),v(this,"_unserializedId",this.UNSERIALIZED_STARTING_ID),v(this,"mirror",yr()),v(this,"scrollData",null),e&&(this.mirror=e)}get unserializedId(){return this._unserializedId--}createDocument(e,i,c){return new V}createDocumentType(e,i,c){const s=new ar(e,i,c);return s.ownerDocument=this,s}createElement(e){const i=e.toUpperCase();let c;switch(i){case"AUDIO":case"VIDEO":c=new ur(i);break;case"IFRAME":c=new pr(i,this.mirror);break;case"CANVAS":c=new hr(i);break;case"STYLE":c=new fr(i);break;case"DIALOG":c=new cr(i);break;default:c=new Z(i);break}return c.ownerDocument=this,c}createComment(e){const i=new mr(e);return i.ownerDocument=this,i}createCDATASection(e){const i=new gr(e);return i.ownerDocument=this,i}createTextNode(e){const i=new dr(e);return i.ownerDocument=this,i}destroyTree(){this.firstChild=null,this.lastChild=null,this.mirror.reset()}open(){super.open(),this._unserializedId=this.UNSERIALIZED_STARTING_ID}}const ar=Ke;class Z extends X{constructor(){super(...arguments),v(this,"inputData",null),v(this,"scrollData",null)}}class ur extends rr{}class cr extends sr{}class hr extends Z{constructor(){super(...arguments),v(this,"rr_dataURL",null),v(this,"canvasMutations",[])}getContext(){return null}}class fr extends Z{constructor(){super(...arguments),v(this,"rules",[])}}class pr extends Z{constructor(e,i){super(e),v(this,"contentDocument",new V),this.contentDocument.mirror=i}}const dr=et,mr=tt,gr=rt;function ts(t){return t instanceof HTMLFormElement?"FORM":t.tagName.toUpperCase()}function wr(t,e,i,c){let s;switch(t.nodeType){case P.DOCUMENT_NODE:c&&c.nodeName==="IFRAME"?s=c.contentDocument:(s=e,s.compatMode=t.compatMode);break;case P.DOCUMENT_TYPE_NODE:{const o=t;s=e.createDocumentType(o.name,o.publicId,o.systemId);break}case P.ELEMENT_NODE:{const o=t,p=ts(o);s=e.createElement(p);const g=s;for(const{name:h,value:r}of Array.from(o.attributes))g.attributes[h]=r;o.scrollLeft&&(g.scrollLeft=o.scrollLeft),o.scrollTop&&(g.scrollTop=o.scrollTop);break}case P.TEXT_NODE:s=e.createTextNode(t.textContent||"");break;case P.CDATA_SECTION_NODE:s=e.createCDATASection(t.data);break;case P.COMMENT_NODE:s=e.createComment(t.textContent||"");break;case P.DOCUMENT_FRAGMENT_NODE:s=c.attachShadow({mode:"open"});break;default:return null}let a=i.getMeta(t);return e instanceof V&&(a||(a=Er(s,e.unserializedId),i.add(t,a)),e.mirror.add(s,k({},a))),s}function rs(t,e=Ir(),i=new V){function c(s,a){const o=wr(s,i,e,a);if(o!==null)if((a==null?void 0:a.nodeName)!=="IFRAME"&&s.nodeType!==P.DOCUMENT_FRAGMENT_NODE&&(a==null||a.appendChild(o),o.parentNode=a,o.parentElement=a),s.nodeName==="IFRAME"){const p=s.contentDocument;p&&c(p,o)}else(s.nodeType===P.DOCUMENT_NODE||s.nodeType===P.ELEMENT_NODE||s.nodeType===P.DOCUMENT_FRAGMENT_NODE)&&(s.nodeType===P.ELEMENT_NODE&&s.shadowRoot&&c(s.shadowRoot,o),s.childNodes.forEach(p=>c(p,o)))}return c(t,null),i}function yr(){return new Rr}class Rr{constructor(){v(this,"idNodeMap",new Map),v(this,"nodeMetaMap",new WeakMap)}getId(e){var i;if(!e)return-1;const c=(i=this.getMeta(e))==null?void 0:i.id;return c!=null?c:-1}getNode(e){return this.idNodeMap.get(e)||null}getIds(){return Array.from(this.idNodeMap.keys())}getMeta(e){return this.nodeMetaMap.get(e)||null}removeNodeFromMap(e){const i=this.getId(e);this.idNodeMap.delete(i),e.childNodes&&e.childNodes.forEach(c=>this.removeNodeFromMap(c))}has(e){return this.idNodeMap.has(e)}hasNode(e){return this.nodeMetaMap.has(e)}add(e,i){const c=i.id;this.idNodeMap.set(c,e),this.nodeMetaMap.set(e,i)}replace(e,i){const c=this.getNode(e);if(c){const s=this.nodeMetaMap.get(c);s&&this.nodeMetaMap.set(i,s)}this.idNodeMap.set(e,i)}reset(){this.idNodeMap=new Map,this.nodeMetaMap=new WeakMap}}function Er(t,e){switch(t.RRNodeType){case M.Document:return{id:e,type:t.RRNodeType,childNodes:[]};case M.DocumentType:{const i=t;return{id:e,type:t.RRNodeType,name:i.name,publicId:i.publicId,systemId:i.systemId}}case M.Element:return{id:e,type:t.RRNodeType,tagName:t.tagName.toLowerCase(),attributes:{},childNodes:[]};case M.Text:return{id:e,type:t.RRNodeType,textContent:t.textContent||""};case M.Comment:return{id:e,type:t.RRNodeType,textContent:t.textContent||""};case M.CDATA:return{id:e,type:t.RRNodeType,textContent:""}}}function ss(t,e){return se(t,e,"")}function se(t,e,i){let c=`${i}${e.getId(t)} ${t.toString()}
|
|
30
|
+
`;if(t.RRNodeType===M.Element){const s=t;s.shadowRoot&&(c+=se(s.shadowRoot,e,i+" "))}for(const s of t.childNodes)c+=se(s,e,i+" ");return t.nodeName==="IFRAME"&&(c+=se(t.contentDocument,e,i+" ")),c}exports.BaseRRCDATASection=rt;exports.BaseRRComment=tt;exports.BaseRRDialogElement=sr;exports.BaseRRDocument=ue;exports.BaseRRDocumentType=Ke;exports.BaseRRElement=X;exports.BaseRRMediaElement=rr;exports.BaseRRNode=F;exports.BaseRRText=et;exports.ClassList=ir;exports.Mirror=Rr;exports.NodeType=P;exports.RRCDATASection=gr;exports.RRCanvasElement=hr;exports.RRComment=mr;exports.RRDialogElement=cr;exports.RRDocument=V;exports.RRDocumentType=ar;exports.RRElement=Z;exports.RRIFrameElement=pr;exports.RRMediaElement=ur;exports.RRNode=F;exports.RRStyleElement=fr;exports.RRText=dr;exports.buildFromDom=rs;exports.buildFromNode=wr;exports.createMirror=yr;exports.createOrGetNode=ie;exports.diff=it;exports.getDefaultSN=Er;exports.printRRDom=ss;
|
|
31
|
+
;if (typeof module.exports == "object" && typeof exports == "object") {
|
|
44
32
|
var __cp = (to, from, except, desc) => {
|
|
45
33
|
if ((from && typeof from === "object") || typeof from === "function") {
|
|
46
34
|
for (let key of Object.getOwnPropertyNames(from)) {
|