vident-rum 0.10.2 → 0.10.3
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.
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import{createRequire as va}from"module";var wa=va("/"),Sa;try{Sa=wa("worker_threads").Worker}catch{}var de=Uint8Array,ue=Uint16Array,kr=Int32Array,_r=new de([0,0,0,0,0,0,0,0,1,1,1,1,2,2,2,2,3,3,3,3,4,4,4,4,5,5,5,5,0,0,0,0]),Pr=new de([0,0,0,0,1,1,2,2,3,3,4,4,5,5,6,6,7,7,8,8,9,9,10,10,11,11,12,12,13,13,0,0]),hs=new de([16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15]),ms=function(i,e){for(var t=new ue(31),r=0;r<31;++r)t[r]=e+=1<<i[r-1];for(var s=new kr(t[30]),r=1;r<30;++r)for(var n=t[r];n<t[r+1];++n)s[n]=n-t[r]<<5|r;return{b:t,r:s}},gs=ms(_r,2),ba=gs.b,Rr=gs.r;ba[28]=258,Rr[258]=28;var ys=ms(Pr,0),ud=ys.b,fs=ys.r,Or=new ue(32768);for($=0;$<32768;++$)be=($&43690)>>1|($&21845)<<1,be=(be&52428)>>2|(be&13107)<<2,be=(be&61680)>>4|(be&3855)<<4,Or[$]=((be&65280)>>8|(be&255)<<8)>>1;var be,$,rt=(function(i,e,t){for(var r=i.length,s=0,n=new ue(e);s<r;++s)i[s]&&++n[i[s]-1];var o=new ue(e);for(s=1;s<e;++s)o[s]=o[s-1]+n[s-1]<<1;var l;if(t){l=new ue(1<<e);var a=15-e;for(s=0;s<r;++s)if(i[s])for(var u=s<<4|i[s],c=e-i[s],h=o[i[s]-1]++<<c,p=h|(1<<c)-1;h<=p;++h)l[Or[h]>>a]=u}else for(l=new ue(r),s=0;s<r;++s)i[s]&&(l[s]=Or[o[i[s]-1]++]>>15-i[s]);return l}),ke=new de(288);for($=0;$<144;++$)ke[$]=8;var $;for($=144;$<256;++$)ke[$]=9;var $;for($=256;$<280;++$)ke[$]=7;var $;for($=280;$<288;++$)ke[$]=8;var $,Mt=new de(32);for($=0;$<32;++$)Mt[$]=5;var $,Ca=rt(ke,9,0);var xa=rt(Mt,5,0);var vs=function(i){return(i+7)/8|0},Ia=function(i,e,t){return(e==null||e<0)&&(e=0),(t==null||t>i.length)&&(t=i.length),new de(i.subarray(e,t))};var Ce=function(i,e,t){t<<=e&7;var r=e/8|0;i[r]|=t,i[r+1]|=t>>8},et=function(i,e,t){t<<=e&7;var r=e/8|0;i[r]|=t,i[r+1]|=t>>8,i[r+2]|=t>>16},Ar=function(i,e){for(var t=[],r=0;r<i.length;++r)i[r]&&t.push({s:r,f:i[r]});var s=t.length,n=t.slice();if(!s)return{t:Ss,l:0};if(s==1){var o=new de(t[0].s+1);return o[t[0].s]=1,{t:o,l:1}}t.sort(function(E,M){return E.f-M.f}),t.push({s:-1,f:25001});var l=t[0],a=t[1],u=0,c=1,h=2;for(t[0]={s:-1,f:l.f+a.f,l,r:a};c!=s-1;)l=t[t[u].f<t[h].f?u++:h++],a=t[u!=c&&t[u].f<t[h].f?u++:h++],t[c++]={s:-1,f:l.f+a.f,l,r:a};for(var p=n[0].s,r=1;r<s;++r)n[r].s>p&&(p=n[r].s);var m=new ue(p+1),g=Tr(t[c-1],m,0);if(g>e){var r=0,d=0,f=g-e,S=1<<f;for(n.sort(function(M,R){return m[R.s]-m[M.s]||M.f-R.f});r<s;++r){var w=n[r].s;if(m[w]>e)d+=S-(1<<g-m[w]),m[w]=e;else break}for(d>>=f;d>0;){var y=n[r].s;m[y]<e?d-=1<<e-m[y]++-1:++r}for(;r>=0&&d;--r){var b=n[r].s;m[b]==e&&(--m[b],++d)}g=e}return{t:new de(m),l:g}},Tr=function(i,e,t){return i.s==-1?Math.max(Tr(i.l,e,t+1),Tr(i.r,e,t+1)):e[i.s]=t},ds=function(i){for(var e=i.length;e&&!i[--e];);for(var t=new ue(++e),r=0,s=i[0],n=1,o=function(a){t[r++]=a},l=1;l<=e;++l)if(i[l]==s&&l!=e)++n;else{if(!s&&n>2){for(;n>138;n-=138)o(32754);n>2&&(o(n>10?n-11<<5|28690:n-3<<5|12305),n=0)}else if(n>3){for(o(s),--n;n>6;n-=6)o(8304);n>2&&(o(n-3<<5|8208),n=0)}for(;n--;)o(s);n=1,s=i[l]}return{c:t.subarray(0,r),n:e}},tt=function(i,e){for(var t=0,r=0;r<e.length;++r)t+=i[r]*e[r];return t},ws=function(i,e,t){var r=t.length,s=vs(e+2);i[s]=r&255,i[s+1]=r>>8,i[s+2]=i[s]^255,i[s+3]=i[s+1]^255;for(var n=0;n<r;++n)i[s+n+4]=t[n];return(s+4+r)*8},ps=function(i,e,t,r,s,n,o,l,a,u,c){Ce(e,c++,t),++s[256];for(var h=Ar(s,15),p=h.t,m=h.l,g=Ar(n,15),d=g.t,f=g.l,S=ds(p),w=S.c,y=S.n,b=ds(d),E=b.c,M=b.n,R=new ue(19),x=0;x<w.length;++x)++R[w[x]&31];for(var x=0;x<E.length;++x)++R[E[x]&31];for(var C=Ar(R,7),k=C.t,N=C.l,O=19;O>4&&!k[hs[O-1]];--O);var I=u+5<<3,j=tt(s,ke)+tt(n,Mt)+o,K=tt(s,p)+tt(n,d)+o+14+3*O+tt(R,k)+2*R[16]+3*R[17]+7*R[18];if(a>=0&&I<=j&&I<=K)return ws(e,c,i.subarray(a,a+u));var L,F,q,Q;if(Ce(e,c,1+(K<j)),c+=2,K<j){L=rt(p,m,0),F=p,q=rt(d,f,0),Q=d;var Fe=rt(k,N,0);Ce(e,c,y-257),Ce(e,c+5,M-1),Ce(e,c+10,O-4),c+=14;for(var x=0;x<O;++x)Ce(e,c+3*x,k[hs[x]]);c+=3*O;for(var ne=[w,E],Ne=0;Ne<2;++Ne)for(var he=ne[Ne],x=0;x<he.length;++x){var le=he[x]&31;Ce(e,c,Fe[le]),c+=k[le],le>15&&(Ce(e,c,he[x]>>5&127),c+=he[x]>>12)}}else L=Ca,F=ke,q=xa,Q=Mt;for(var x=0;x<l;++x){var ee=r[x];if(ee>255){var le=ee>>18&31;et(e,c,L[le+257]),c+=F[le+257],le>7&&(Ce(e,c,ee>>23&31),c+=_r[le]);var Ae=ee&31;et(e,c,q[Ae]),c+=Q[Ae],Ae>3&&(et(e,c,ee>>5&8191),c+=Pr[Ae])}else et(e,c,L[ee]),c+=F[ee]}return et(e,c,L[256]),c+F[256]},Ea=new kr([65540,131080,131088,131104,262176,1048704,1048832,2114560,2117632]),Ss=new de(0),Ma=function(i,e,t,r,s,n){var o=n.z||i.length,l=new de(r+o+5*(1+Math.ceil(o/7e3))+s),a=l.subarray(r,l.length-s),u=n.l,c=(n.r||0)&7;if(e){c&&(a[0]=n.r>>3);for(var h=Ea[e-1],p=h>>13,m=h&8191,g=(1<<t)-1,d=n.p||new ue(32768),f=n.h||new ue(g+1),S=Math.ceil(t/3),w=2*S,y=function(V){return(i[V]^i[V+1]<<S^i[V+2]<<w)&g},b=new kr(25e3),E=new ue(288),M=new ue(32),R=0,x=0,C=n.i||0,k=0,N=n.w||0,O=0;C+2<o;++C){var I=y(C),j=C&32767,K=f[I];if(d[j]=K,f[I]=j,N<=C){var L=o-C;if((R>7e3||k>24576)&&(L>423||!u)){c=ps(i,a,0,b,E,M,x,k,O,C-O,c),k=R=x=0,O=C;for(var F=0;F<286;++F)E[F]=0;for(var F=0;F<30;++F)M[F]=0}var q=2,Q=0,Fe=m,ne=j-K&32767;if(L>2&&I==y(C-ne))for(var Ne=Math.min(p,L)-1,he=Math.min(32767,C),le=Math.min(258,L);ne<=he&&--Fe&&j!=K;){if(i[C+q]==i[C+q-ne]){for(var ee=0;ee<le&&i[C+ee]==i[C+ee-ne];++ee);if(ee>q){if(q=ee,Q=ne,ee>Ne)break;for(var Ae=Math.min(ne,ee-2),ye=0,F=0;F<Ae;++F){var fe=C-ne+F&32767,Qe=d[fe],De=fe-Qe&32767;De>ye&&(ye=De,K=fe)}}}j=K,K=d[j],ne+=j-K&32767}if(Q){b[k++]=268435456|Rr[q]<<18|fs[Q];var _=Rr[q]&31,oe=fs[Q]&31;x+=_r[_]+Pr[oe],++E[257+_],++M[oe],N=C+q,++R}else b[k++]=i[C],++E[i[C]]}}for(C=Math.max(C,N);C<o;++C)b[k++]=i[C],++E[i[C]];c=ps(i,a,u,b,E,M,x,k,O,C-O,c),u||(n.r=c&7|a[c/8|0]<<3,c-=7,n.h=f,n.p=d,n.i=C,n.w=N)}else{for(var C=n.w||0;C<o+u;C+=65535){var W=C+65535;W>=o&&(a[c/8|0]=u,W=o),c=ws(a,c+1,i.subarray(C,W))}n.i=o}return Ia(l,0,r+vs(c)+s)},Na=(function(){for(var i=new Int32Array(256),e=0;e<256;++e){for(var t=e,r=9;--r;)t=(t&1&&-306674912)^t>>>1;i[e]=t}return i})(),Aa=function(){var i=-1;return{p:function(e){for(var t=i,r=0;r<e.length;++r)t=Na[t&255^e[r]]^t>>>8;i=t},d:function(){return~i}}};var Ra=function(i,e,t,r,s){if(!s&&(s={l:1},e.dictionary)){var n=e.dictionary.subarray(-32768),o=new de(n.length+i.length);o.set(n),o.set(i,n.length),i=o,s.w=n.length}return Ma(i,e.level==null?6:e.level,e.mem==null?s.l?Math.ceil(Math.max(8,Math.min(13,Math.log(i.length)))*1.5):20:12+e.mem,t,r,s)};var Dr=function(i,e,t){for(;t;++e)i[e]=t,t>>>=8},Oa=function(i,e){var t=e.filename;if(i[0]=31,i[1]=139,i[2]=8,i[8]=e.level<2?4:e.level==9?2:0,i[9]=3,e.mtime!=0&&Dr(i,4,Math.floor(new Date(e.mtime||Date.now())/1e3)),t){i[3]=8;for(var r=0;r<=t.length;++r)i[r+10]=t.charCodeAt(r)}};var Ta=function(i){return 10+(i.filename?i.filename.length+1:0)};function bs(i,e){e||(e={});var t=Aa(),r=i.length;t.p(i);var s=Ra(i,e,Ta(e),8),n=s.length;return Oa(s,e),Dr(s,n-8,t.d()),Dr(s,n-4,r),s}var Da=typeof TextDecoder<"u"&&new TextDecoder,ka=0;try{Da.decode(Ss,{stream:!0}),ka=1}catch{}var _a=Object.defineProperty,Pa=(i,e,t)=>e in i?_a(i,e,{enumerable:!0,configurable:!0,writable:!0,value:t}):i[e]=t,v=(i,e,t)=>Pa(i,typeof e!="symbol"?e+"":e,t),Cs,$a=Object.defineProperty,La=(i,e,t)=>e in i?$a(i,e,{enumerable:!0,configurable:!0,writable:!0,value:t}):i[e]=t,xs=(i,e,t)=>La(i,typeof e!="symbol"?e+"":e,t),te=(i=>(i[i.Document=0]="Document",i[i.DocumentType=1]="DocumentType",i[i.Element=2]="Element",i[i.Text=3]="Text",i[i.CDATA=4]="CDATA",i[i.Comment=5]="Comment",i))(te||{}),Is={Node:["childNodes","parentNode","parentElement","textContent"],ShadowRoot:["host","styleSheets"],Element:["shadowRoot","querySelector","querySelectorAll"],MutationObserver:[]},Es={Node:["contains","getRootNode"],ShadowRoot:["getSelection"],Element:[],MutationObserver:["constructor"]},Nt={},Fa=()=>!!globalThis.Zone;function zi(i){if(Nt[i])return Nt[i];let e=globalThis[i],t=e.prototype,r=i in Is?Is[i]:void 0,s=!!(r&&r.every(l=>{var a,u;return!!((u=(a=Object.getOwnPropertyDescriptor(t,l))==null?void 0:a.get)!=null&&u.toString().includes("[native code]"))})),n=i in Es?Es[i]:void 0,o=!!(n&&n.every(l=>{var a;return typeof t[l]=="function"&&((a=t[l])==null?void 0:a.toString().includes("[native code]"))}));if(s&&o&&!Fa())return Nt[i]=e.prototype,e.prototype;try{let l=document.createElement("iframe");document.body.appendChild(l);let a=l.contentWindow;if(!a)return e.prototype;let u=a[i].prototype;return document.body.removeChild(l),u?Nt[i]=u:t}catch{return t}}var $r={};function Oe(i,e,t){var r;let s=`${i}.${String(t)}`;if($r[s])return $r[s].call(e);let n=zi(i),o=(r=Object.getOwnPropertyDescriptor(n,t))==null?void 0:r.get;return o?($r[s]=o,o.call(e)):e[t]}var Lr={};function xn(i,e,t){let r=`${i}.${String(t)}`;if(Lr[r])return Lr[r].bind(e);let n=zi(i)[t];return typeof n!="function"?e[t]:(Lr[r]=n,n.bind(e))}function Ua(i){return Oe("Node",i,"childNodes")}function za(i){return Oe("Node",i,"parentNode")}function Ba(i){return Oe("Node",i,"parentElement")}function Wa(i){return Oe("Node",i,"textContent")}function Va(i,e){return xn("Node",i,"contains")(e)}function Ga(i){return xn("Node",i,"getRootNode")()}function ja(i){return!i||!("host"in i)?null:Oe("ShadowRoot",i,"host")}function Ha(i){return i.styleSheets}function Ya(i){return!i||!("shadowRoot"in i)?null:Oe("Element",i,"shadowRoot")}function Za(i,e){return Oe("Element",i,"querySelector")(e)}function Xa(i,e){return Oe("Element",i,"querySelectorAll")(e)}function Ja(){return zi("MutationObserver").constructor}var re={childNodes:Ua,parentNode:za,parentElement:Ba,textContent:Wa,contains:Va,getRootNode:Ga,host:ja,styleSheets:Ha,shadowRoot:Ya,querySelector:Za,querySelectorAll:Xa,mutationObserver:Ja};function In(i){return i.nodeType===i.ELEMENT_NODE}function lt(i){let e=i&&"host"in i&&"mode"in i&&re.host(i)||null;return!!(e&&"shadowRoot"in e&&re.shadowRoot(e)===i)}function ut(i){return Object.prototype.toString.call(i)==="[object ShadowRoot]"}function Ka(i){return i.includes(" background-clip: text;")&&!i.includes(" -webkit-background-clip: text;")&&(i=i.replace(/\sbackground-clip:\s*text;/g," -webkit-background-clip: text; background-clip: text;")),i}function qa(i){let{cssText:e}=i;if(e.split('"').length<3)return e;let t=["@import",`url(${JSON.stringify(i.href)})`];return i.layerName===""?t.push("layer"):i.layerName&&t.push(`layer(${i.layerName})`),i.supportsText&&t.push(`supports(${i.supportsText})`),i.media.length&&t.push(i.media.mediaText),t.join(" ")+";"}function Kr(i){try{let e=i.rules||i.cssRules;if(!e)return null;let t=i.href;!t&&i.ownerNode&&i.ownerNode.ownerDocument&&(t=i.ownerNode.ownerDocument.location.href);let r=Array.from(e,s=>En(s,t)).join("");return Ka(r)}catch{return null}}function En(i,e){if(el(i)){let t;try{t=Kr(i.styleSheet)||qa(i)}catch{t=i.cssText}return i.styleSheet.href?rr(t,i.styleSheet.href):t}else{let t=i.cssText;return tl(i)&&i.selectorText.includes(":")&&(t=Qa(t)),e?rr(t,e):t}}function Qa(i){let e=/(\[(?:[\w-]+)[^\\])(:(?:[\w-]+)\])/gm;return i.replace(e,"$1\\$2")}function el(i){return"styleSheet"in i}function tl(i){return"selectorText"in i}var tr=class{constructor(){xs(this,"idNodeMap",new Map),xs(this,"nodeMetaMap",new WeakMap)}getId(e){var t;return e?((t=this.getMeta(e))==null?void 0:t.id)??-1:-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){let t=this.getId(e);this.idNodeMap.delete(t),e.childNodes&&e.childNodes.forEach(r=>this.removeNodeFromMap(r))}has(e){return this.idNodeMap.has(e)}hasNode(e){return this.nodeMetaMap.has(e)}add(e,t){let r=t.id;this.idNodeMap.set(r,e),this.nodeMetaMap.set(e,t)}replace(e,t){let r=this.getNode(e);if(r){let s=this.nodeMetaMap.get(r);s&&this.nodeMetaMap.set(t,s)}this.idNodeMap.set(e,t)}reset(){this.idNodeMap=new Map,this.nodeMetaMap=new WeakMap}};function rl(){return new tr}function Bi({element:i,maskInputOptions:e,tagName:t,type:r,value:s,maskInputFn:n}){let o=s||"",l=r&&Pe(r);return(e[t.toLowerCase()]||l&&e[l])&&(n?o=n(o,i):o="*".repeat(o.length)),o}function Pe(i){return i.toLowerCase()}var Ms="__rrweb_original__";function il(i){let e=i.getContext("2d");if(!e)return!0;let t=50;for(let r=0;r<i.width;r+=t)for(let s=0;s<i.height;s+=t){let n=e.getImageData,o=Ms in n?n[Ms]:n;if(new Uint32Array(o.call(e,r,s,Math.min(t,i.width-r),Math.min(t,i.height-s)).data.buffer).some(a=>a!==0))return!1}return!0}function Wi(i){let e=i.type;return i.hasAttribute("data-rr-is-password")?"password":e?Pe(e):null}function Mn(i,e){let t;try{t=new URL(i,e??window.location.href)}catch{return null}let r=/\.([0-9a-z]+)(?:$)/i,s=t.pathname.match(r);return s?.[1]??null}function sl(i){let e="";return i.indexOf("//")>-1?e=i.split("/").slice(0,3).join("/"):e=i.split("/")[0],e=e.split("?")[0],e}var nl=/url\((?:(')([^']*)'|(")(.*?)"|([^)]*))\)/gm,ol=/^(?:[a-z+]+:)?\/\//i,al=/^www\..*/i,ll=/^(data:)([^,]*),(.*)/i;function rr(i,e){return(i||"").replace(nl,(t,r,s,n,o,l)=>{let a=s||o||l,u=r||n||"";if(!a)return t;if(ol.test(a)||al.test(a))return`url(${u}${a}${u})`;if(ll.test(a))return`url(${u}${a}${u})`;if(a[0]==="/")return`url(${u}${sl(e)+a}${u})`;let c=e.split("/"),h=a.split("/");c.pop();for(let p of h)p!=="."&&(p===".."?c.pop():c.push(p));return`url(${u}${c.join("/")}${u})`})}function Fr(i){return i.replace(/(\/\*[^*]*\*\/)|[\s;]/g,"")}function ul(i,e){let t=Array.from(e.childNodes),r=[];if(t.length>1&&i&&typeof i=="string"){let s=Fr(i);for(let n=1;n<t.length;n++)if(t[n].textContent&&typeof t[n].textContent=="string"){let o=Fr(t[n].textContent);for(let l=3;l<o.length;l++){let a=o.substring(0,l);if(s.split(a).length===2){let u=s.indexOf(a);for(let c=u;c<i.length;c++)if(Fr(i.substring(0,c)).length===u){r.push(i.substring(0,c)),i=i.substring(c);break}break}}}}return r.push(i),r}function cl(i,e){return ul(i,e).join("/* rr_split */")}var hl=1,fl=new RegExp("[^a-z0-9-_:]"),ht=-2;function Nn(){return hl++}function dl(i){if(i instanceof HTMLFormElement)return"form";let e=Pe(i.tagName);return fl.test(e)?"div":e}var Ue,Ns,pl=/^[^ \t\n\r\u000c]+/,ml=/^[, \t\n\r\u000c]+/;function gl(i,e){if(e.trim()==="")return e;let t=0;function r(n){let o,l=n.exec(e.substring(t));return l?(o=l[0],t+=o.length,o):""}let s=[];for(;r(ml),!(t>=e.length);){let n=r(pl);if(n.slice(-1)===",")n=We(i,n.substring(0,n.length-1)),s.push(n);else{let o="";n=We(i,n);let l=!1;for(;;){let a=e.charAt(t);if(a===""){s.push((n+o).trim());break}else if(l)a===")"&&(l=!1);else if(a===","){t+=1,s.push((n+o).trim());break}else a==="("&&(l=!0);o+=a,t+=1}}}return s.join(", ")}var As=new WeakMap;function We(i,e){return!e||e.trim()===""?e:Vi(i,e)}function yl(i){return!!(i.tagName==="svg"||i.ownerSVGElement)}function Vi(i,e){let t=As.get(i);if(t||(t=i.createElement("a"),As.set(i,t)),!e)e="";else if(e.startsWith("blob:")||e.startsWith("data:"))return e;return t.setAttribute("href",e),t.href}function An(i,e,t,r){return r&&(t==="src"||t==="href"&&!(e==="use"&&r[0]==="#")||t==="xlink:href"&&r[0]!=="#"||t==="background"&&(e==="table"||e==="td"||e==="th")?We(i,r):t==="srcset"?gl(i,r):t==="style"?rr(r,Vi(i)):e==="object"&&t==="data"?We(i,r):r)}function Rn(i,e,t){return(i==="video"||i==="audio")&&e==="autoplay"}function vl(i,e,t){try{if(typeof e=="string"){if(i.classList.contains(e))return!0}else for(let r=i.classList.length;r--;){let s=i.classList[r];if(e.test(s))return!0}if(t)return i.matches(t)}catch{}return!1}function ir(i,e,t){if(!i)return!1;if(i.nodeType!==i.ELEMENT_NODE)return t?ir(re.parentNode(i),e,t):!1;for(let r=i.classList.length;r--;){let s=i.classList[r];if(e.test(s))return!0}return t?ir(re.parentNode(i),e,t):!1}function On(i,e,t,r){let s;if(In(i)){if(s=i,!re.childNodes(s).length)return!1}else{if(re.parentElement(i)===null)return!1;s=re.parentElement(i)}try{if(typeof e=="string"){if(r){if(s.closest(`.${e}`))return!0}else if(s.classList.contains(e))return!0}else if(ir(s,e,r))return!0;if(t){if(r){if(s.closest(t))return!0}else if(s.matches(t))return!0}}catch{}return!1}function wl(i,e,t){let r=i.contentWindow;if(!r)return;let s=!1,n;try{n=r.document.readyState}catch{return}if(n!=="complete"){let l=setTimeout(()=>{s||(e(),s=!0)},t);i.addEventListener("load",()=>{clearTimeout(l),s=!0,e()});return}let o="about:blank";if(r.location.href!==o||i.src===o||i.src==="")return setTimeout(e,0),i.addEventListener("load",e);i.addEventListener("load",e)}function Sl(i,e,t){let r=!1,s;try{s=i.sheet}catch{return}if(s)return;let n=setTimeout(()=>{r||(e(),r=!0)},t);i.addEventListener("load",()=>{clearTimeout(n),r=!0,e()})}function bl(i,e){let{doc:t,mirror:r,blockClass:s,blockSelector:n,needsMask:o,inlineStylesheet:l,maskInputOptions:a={},maskTextFn:u,maskInputFn:c,dataURLOptions:h={},inlineImages:p,recordCanvas:m,keepIframeSrcFn:g,newlyAddedElement:d=!1,cssCaptured:f=!1}=e,S=Cl(t,r);switch(i.nodeType){case i.DOCUMENT_NODE:return i.compatMode!=="CSS1Compat"?{type:te.Document,childNodes:[],compatMode:i.compatMode}:{type:te.Document,childNodes:[]};case i.DOCUMENT_TYPE_NODE:return{type:te.DocumentType,name:i.name,publicId:i.publicId,systemId:i.systemId,rootId:S};case i.ELEMENT_NODE:return Il(i,{doc:t,blockClass:s,blockSelector:n,inlineStylesheet:l,maskInputOptions:a,maskInputFn:c,dataURLOptions:h,inlineImages:p,recordCanvas:m,keepIframeSrcFn:g,newlyAddedElement:d,rootId:S});case i.TEXT_NODE:return xl(i,{doc:t,needsMask:o,maskTextFn:u,rootId:S,cssCaptured:f});case i.CDATA_SECTION_NODE:return{type:te.CDATA,textContent:"",rootId:S};case i.COMMENT_NODE:return{type:te.Comment,textContent:re.textContent(i)||"",rootId:S};default:return!1}}function Cl(i,e){if(!e.hasNode(i))return;let t=e.getId(i);return t===1?void 0:t}function xl(i,e){let{needsMask:t,maskTextFn:r,rootId:s,cssCaptured:n}=e,o=re.parentNode(i),l=o&&o.tagName,a="",u=l==="STYLE"?!0:void 0,c=l==="SCRIPT"?!0:void 0;return c?a="SCRIPT_PLACEHOLDER":n||(a=re.textContent(i),u&&a&&(a=rr(a,Vi(e.doc)))),!u&&!c&&a&&t&&(a=r?r(a,re.parentElement(i)):a.replace(/[\S]/g,"*")),{type:te.Text,textContent:a||"",rootId:s}}function Il(i,e){let{doc:t,blockClass:r,blockSelector:s,inlineStylesheet:n,maskInputOptions:o={},maskInputFn:l,dataURLOptions:a={},inlineImages:u,recordCanvas:c,keepIframeSrcFn:h,newlyAddedElement:p=!1,rootId:m}=e,g=vl(i,r,s),d=dl(i),f={},S=i.attributes.length;for(let y=0;y<S;y++){let b=i.attributes[y];Rn(d,b.name,b.value)||(f[b.name]=An(t,d,Pe(b.name),b.value))}if(d==="link"&&n){let y=Array.from(t.styleSheets).find(E=>E.href===i.href),b=null;y&&(b=Kr(y)),b&&(delete f.rel,delete f.href,f._cssText=b)}if(d==="style"&&i.sheet){let y=Kr(i.sheet);y&&(i.childNodes.length>1&&(y=cl(y,i)),f._cssText=y)}if(d==="input"||d==="textarea"||d==="select"){let y=i.value,b=i.checked;f.type!=="radio"&&f.type!=="checkbox"&&f.type!=="submit"&&f.type!=="button"&&y?f.value=Bi({element:i,type:Wi(i),tagName:d,value:y,maskInputOptions:o,maskInputFn:l}):b&&(f.checked=b)}if(d==="option"&&(i.selected&&!o.select?f.selected=!0:delete f.selected),d==="dialog"&&i.open&&(f.rr_open_mode=i.matches("dialog:modal")?"modal":"non-modal"),d==="canvas"&&c){if(i.__context==="2d")il(i)||(f.rr_dataURL=i.toDataURL(a.type,a.quality));else if(!("__context"in i)){let y=i.toDataURL(a.type,a.quality),b=t.createElement("canvas");b.width=i.width,b.height=i.height;let E=b.toDataURL(a.type,a.quality);y!==E&&(f.rr_dataURL=y)}}if(d==="img"&&u){Ue||(Ue=t.createElement("canvas"),Ns=Ue.getContext("2d"));let y=i,b=y.currentSrc||y.getAttribute("src")||"<unknown-src>",E=y.crossOrigin,M=()=>{y.removeEventListener("load",M);try{Ue.width=y.naturalWidth,Ue.height=y.naturalHeight,Ns.drawImage(y,0,0),f.rr_dataURL=Ue.toDataURL(a.type,a.quality)}catch(R){if(y.crossOrigin!=="anonymous"){y.crossOrigin="anonymous",y.complete&&y.naturalWidth!==0?M():y.addEventListener("load",M);return}else console.warn(`Cannot inline img src=${b}! Error: ${R}`)}y.crossOrigin==="anonymous"&&(E?f.crossOrigin=E:y.removeAttribute("crossorigin"))};y.complete&&y.naturalWidth!==0?M():y.addEventListener("load",M)}if(d==="audio"||d==="video"){let y=f;y.rr_mediaState=i.paused?"paused":"played",y.rr_mediaCurrentTime=i.currentTime,y.rr_mediaPlaybackRate=i.playbackRate,y.rr_mediaMuted=i.muted,y.rr_mediaLoop=i.loop,y.rr_mediaVolume=i.volume}if(p||(i.scrollLeft&&(f.rr_scrollLeft=i.scrollLeft),i.scrollTop&&(f.rr_scrollTop=i.scrollTop)),g){let{width:y,height:b}=i.getBoundingClientRect();f={class:f.class,rr_width:`${y}px`,rr_height:`${b}px`}}d==="iframe"&&!h(f.src)&&(i.contentDocument||(f.rr_src=f.src),delete f.src);let w;try{customElements.get(d)&&(w=!0)}catch{}return{type:te.Element,tagName:d,attributes:f,childNodes:[],isSVG:yl(i)||void 0,needBlock:g,rootId:m,isCustom:w}}function G(i){return i==null?"":i.toLowerCase()}function El(i,e){if(e.comment&&i.type===te.Comment)return!0;if(i.type===te.Element){if(e.script&&(i.tagName==="script"||i.tagName==="link"&&(i.attributes.rel==="preload"||i.attributes.rel==="modulepreload")&&i.attributes.as==="script"||i.tagName==="link"&&i.attributes.rel==="prefetch"&&typeof i.attributes.href=="string"&&Mn(i.attributes.href)==="js"))return!0;if(e.headFavicon&&(i.tagName==="link"&&i.attributes.rel==="shortcut icon"||i.tagName==="meta"&&(G(i.attributes.name).match(/^msapplication-tile(image|color)$/)||G(i.attributes.name)==="application-name"||G(i.attributes.rel)==="icon"||G(i.attributes.rel)==="apple-touch-icon"||G(i.attributes.rel)==="shortcut icon")))return!0;if(i.tagName==="meta"){if(e.headMetaDescKeywords&&G(i.attributes.name).match(/^description|keywords$/))return!0;if(e.headMetaSocial&&(G(i.attributes.property).match(/^(og|twitter|fb):/)||G(i.attributes.name).match(/^(og|twitter):/)||G(i.attributes.name)==="pinterest"))return!0;if(e.headMetaRobots&&(G(i.attributes.name)==="robots"||G(i.attributes.name)==="googlebot"||G(i.attributes.name)==="bingbot"))return!0;if(e.headMetaHttpEquiv&&i.attributes["http-equiv"]!==void 0)return!0;if(e.headMetaAuthorship&&(G(i.attributes.name)==="author"||G(i.attributes.name)==="generator"||G(i.attributes.name)==="framework"||G(i.attributes.name)==="publisher"||G(i.attributes.name)==="progid"||G(i.attributes.property).match(/^article:/)||G(i.attributes.property).match(/^product:/)))return!0;if(e.headMetaVerification&&(G(i.attributes.name)==="google-site-verification"||G(i.attributes.name)==="yandex-verification"||G(i.attributes.name)==="csrf-token"||G(i.attributes.name)==="p:domain_verify"||G(i.attributes.name)==="verify-v1"||G(i.attributes.name)==="verification"||G(i.attributes.name)==="shopify-checkout-api-token"))return!0}}return!1}function Ve(i,e){let{doc:t,mirror:r,blockClass:s,blockSelector:n,maskTextClass:o,maskTextSelector:l,skipChild:a=!1,inlineStylesheet:u=!0,maskInputOptions:c={},maskTextFn:h,maskInputFn:p,slimDOMOptions:m,dataURLOptions:g={},inlineImages:d=!1,recordCanvas:f=!1,onSerialize:S,onIframeLoad:w,iframeLoadTimeout:y=5e3,onStylesheetLoad:b,stylesheetLoadTimeout:E=5e3,keepIframeSrcFn:M=()=>!1,newlyAddedElement:R=!1,cssCaptured:x=!1}=e,{needsMask:C}=e,{preserveWhiteSpace:k=!0}=e;C||(C=On(i,o,l,C===void 0));let N=bl(i,{doc:t,mirror:r,blockClass:s,blockSelector:n,needsMask:C,inlineStylesheet:u,maskInputOptions:c,maskTextFn:h,maskInputFn:p,dataURLOptions:g,inlineImages:d,recordCanvas:f,keepIframeSrcFn:M,newlyAddedElement:R,cssCaptured:x});if(!N)return console.warn(i,"not serialized"),null;let O;r.hasNode(i)?O=r.getId(i):El(N,m)||!k&&N.type===te.Text&&!N.textContent.replace(/^\s+|\s+$/gm,"").length?O=ht:O=Nn();let I=Object.assign(N,{id:O});if(r.add(i,I),O===ht)return null;S&&S(i);let j=!a;if(I.type===te.Element){j=j&&!I.needBlock,delete I.needBlock;let L=re.shadowRoot(i);L&&ut(L)&&(I.isShadowHost=!0)}if((I.type===te.Document||I.type===te.Element)&&j){m.headWhitespace&&I.type===te.Element&&I.tagName==="head"&&(k=!1);let L={doc:t,mirror:r,blockClass:s,blockSelector:n,needsMask:C,maskTextClass:o,maskTextSelector:l,skipChild:a,inlineStylesheet:u,maskInputOptions:c,maskTextFn:h,maskInputFn:p,slimDOMOptions:m,dataURLOptions:g,inlineImages:d,recordCanvas:f,preserveWhiteSpace:k,onSerialize:S,onIframeLoad:w,iframeLoadTimeout:y,onStylesheetLoad:b,stylesheetLoadTimeout:E,keepIframeSrcFn:M,cssCaptured:!1};if(!(I.type===te.Element&&I.tagName==="textarea"&&I.attributes.value!==void 0)){I.type===te.Element&&I.attributes._cssText!==void 0&&typeof I.attributes._cssText=="string"&&(L.cssCaptured=!0);for(let q of Array.from(re.childNodes(i))){let Q=Ve(q,L);Q&&I.childNodes.push(Q)}}let F=null;if(In(i)&&(F=re.shadowRoot(i)))for(let q of Array.from(re.childNodes(F))){let Q=Ve(q,L);Q&&(ut(F)&&(Q.isShadow=!0),I.childNodes.push(Q))}}let K=re.parentNode(i);return K&<(K)&&ut(K)&&(I.isShadow=!0),I.type===te.Element&&I.tagName==="iframe"&&wl(i,()=>{let L=i.contentDocument;if(L&&w){let F=Ve(L,{doc:L,mirror:r,blockClass:s,blockSelector:n,needsMask:C,maskTextClass:o,maskTextSelector:l,skipChild:!1,inlineStylesheet:u,maskInputOptions:c,maskTextFn:h,maskInputFn:p,slimDOMOptions:m,dataURLOptions:g,inlineImages:d,recordCanvas:f,preserveWhiteSpace:k,onSerialize:S,onIframeLoad:w,iframeLoadTimeout:y,onStylesheetLoad:b,stylesheetLoadTimeout:E,keepIframeSrcFn:M});F&&w(i,F)}},y),I.type===te.Element&&I.tagName==="link"&&typeof I.attributes.rel=="string"&&(I.attributes.rel==="stylesheet"||I.attributes.rel==="preload"&&typeof I.attributes.href=="string"&&Mn(I.attributes.href)==="css")&&Sl(i,()=>{if(b){let L=Ve(i,{doc:t,mirror:r,blockClass:s,blockSelector:n,needsMask:C,maskTextClass:o,maskTextSelector:l,skipChild:!1,inlineStylesheet:u,maskInputOptions:c,maskTextFn:h,maskInputFn:p,slimDOMOptions:m,dataURLOptions:g,inlineImages:d,recordCanvas:f,preserveWhiteSpace:k,onSerialize:S,onIframeLoad:w,iframeLoadTimeout:y,onStylesheetLoad:b,stylesheetLoadTimeout:E,keepIframeSrcFn:M});L&&b(i,L)}},E),I}function Ml(i,e){let{mirror:t=new tr,blockClass:r="rr-block",blockSelector:s=null,maskTextClass:n="rr-mask",maskTextSelector:o=null,inlineStylesheet:l=!0,inlineImages:a=!1,recordCanvas:u=!1,maskAllInputs:c=!1,maskTextFn:h,maskInputFn:p,slimDOM:m=!1,dataURLOptions:g,preserveWhiteSpace:d,onSerialize:f,onIframeLoad:S,iframeLoadTimeout:w,onStylesheetLoad:y,stylesheetLoadTimeout:b,keepIframeSrcFn:E=()=>!1}=e||{};return Ve(i,{doc:i,mirror:t,blockClass:r,blockSelector:s,maskTextClass:n,maskTextSelector:o,skipChild:!1,inlineStylesheet:l,maskInputOptions:c===!0?{color:!0,date:!0,"datetime-local":!0,email:!0,month:!0,number:!0,range:!0,search:!0,tel:!0,text:!0,time:!0,url:!0,week:!0,textarea:!0,select:!0,password:!0}:c===!1?{password:!0}:c,maskTextFn:h,maskInputFn:p,slimDOMOptions:m===!0||m==="all"?{script:!0,comment:!0,headFavicon:!0,headWhitespace:!0,headMetaDescKeywords:m==="all",headMetaSocial:!0,headMetaRobots:!0,headMetaHttpEquiv:!0,headMetaAuthorship:!0,headMetaVerification:!0}:m===!1?{}:m,dataURLOptions:g,inlineImages:a,recordCanvas:u,preserveWhiteSpace:d,onSerialize:f,onIframeLoad:S,iframeLoadTimeout:w,onStylesheetLoad:y,stylesheetLoadTimeout:b,keepIframeSrcFn:E,newlyAddedElement:!1})}var Nl=/(max|min)-device-(width|height)/,hd=new RegExp(Nl.source,"g");function Al(i){return i&&i.__esModule&&Object.prototype.hasOwnProperty.call(i,"default")?i.default:i}function Rl(i){if(i.__esModule)return i;var e=i.default;if(typeof e=="function"){var t=function r(){return this instanceof r?Reflect.construct(e,arguments,this.constructor):e.apply(this,arguments)};t.prototype=e.prototype}else t={};return Object.defineProperty(t,"__esModule",{value:!0}),Object.keys(i).forEach(function(r){var s=Object.getOwnPropertyDescriptor(i,r);Object.defineProperty(t,r,s.get?s:{enumerable:!0,get:function(){return i[r]}})}),t}var Gi={exports:{}},H=String,Tn=function(){return{isColorSupported:!1,reset:H,bold:H,dim:H,italic:H,underline:H,inverse:H,hidden:H,strikethrough:H,black:H,red:H,green:H,yellow:H,blue:H,magenta:H,cyan:H,white:H,gray:H,bgBlack:H,bgRed:H,bgGreen:H,bgYellow:H,bgBlue:H,bgMagenta:H,bgCyan:H,bgWhite:H}};Gi.exports=Tn();Gi.exports.createColors=Tn;var Ol=Gi.exports,Tl={},Dl=Object.freeze(Object.defineProperty({__proto__:null,default:Tl},Symbol.toStringTag,{value:"Module"})),me=Rl(Dl),Rs=Ol,Os=me,qr=class Dn extends Error{constructor(e,t,r,s,n,o){super(e),this.name="CssSyntaxError",this.reason=e,n&&(this.file=n),s&&(this.source=s),o&&(this.plugin=o),typeof t<"u"&&typeof r<"u"&&(typeof t=="number"?(this.line=t,this.column=r):(this.line=t.line,this.column=t.column,this.endLine=r.line,this.endColumn=r.column)),this.setMessage(),Error.captureStackTrace&&Error.captureStackTrace(this,Dn)}setMessage(){this.message=this.plugin?this.plugin+": ":"",this.message+=this.file?this.file:"<css input>",typeof this.line<"u"&&(this.message+=":"+this.line+":"+this.column),this.message+=": "+this.reason}showSourceCode(e){if(!this.source)return"";let t=this.source;e==null&&(e=Rs.isColorSupported),Os&&e&&(t=Os(t));let r=t.split(/\r?\n/),s=Math.max(this.line-3,0),n=Math.min(this.line+2,r.length),o=String(n).length,l,a;if(e){let{bold:u,gray:c,red:h}=Rs.createColors(!0);l=p=>u(h(p)),a=p=>c(p)}else l=a=u=>u;return r.slice(s,n).map((u,c)=>{let h=s+1+c,p=" "+(" "+h).slice(-o)+" | ";if(h===this.line){let m=a(p.replace(/\d/g," "))+u.slice(0,this.column-1).replace(/[^\t]/g," ");return l(">")+a(p)+u+`
|
|
2
|
-
`+m+l("^")}return" "+a(
|
|
1
|
+
var pe=Uint8Array,ue=Uint16Array,kr=Int32Array,$r=new pe([0,0,0,0,0,0,0,0,1,1,1,1,2,2,2,2,3,3,3,3,4,4,4,4,5,5,5,5,0,0,0,0]),_r=new pe([0,0,0,0,1,1,2,2,3,3,4,4,5,5,6,6,7,7,8,8,9,9,10,10,11,11,12,12,13,13,0,0]),hs=new pe([16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15]),ms=function(i,e){for(var t=new ue(31),r=0;r<31;++r)t[r]=e+=1<<i[r-1];for(var s=new kr(t[30]),r=1;r<30;++r)for(var n=t[r];n<t[r+1];++n)s[n]=n-t[r]<<5|r;return{b:t,r:s}},gs=ms($r,2),da=gs.b,Rr=gs.r;da[28]=258,Rr[258]=28;var ys=ms(_r,0),Kf=ys.b,fs=ys.r,Or=new ue(32768);for(P=0;P<32768;++P)be=(P&43690)>>1|(P&21845)<<1,be=(be&52428)>>2|(be&13107)<<2,be=(be&61680)>>4|(be&3855)<<4,Or[P]=((be&65280)>>8|(be&255)<<8)>>1;var be,P,rt=(function(i,e,t){for(var r=i.length,s=0,n=new ue(e);s<r;++s)i[s]&&++n[i[s]-1];var o=new ue(e);for(s=1;s<e;++s)o[s]=o[s-1]+n[s-1]<<1;var l;if(t){l=new ue(1<<e);var a=15-e;for(s=0;s<r;++s)if(i[s])for(var u=s<<4|i[s],c=e-i[s],h=o[i[s]-1]++<<c,d=h|(1<<c)-1;h<=d;++h)l[Or[h]>>a]=u}else for(l=new ue(r),s=0;s<r;++s)i[s]&&(l[s]=Or[o[i[s]-1]++]>>15-i[s]);return l}),ke=new pe(288);for(P=0;P<144;++P)ke[P]=8;var P;for(P=144;P<256;++P)ke[P]=9;var P;for(P=256;P<280;++P)ke[P]=7;var P;for(P=280;P<288;++P)ke[P]=8;var P,Mt=new pe(32);for(P=0;P<32;++P)Mt[P]=5;var P,ma=rt(ke,9,0);var ga=rt(Mt,5,0);var vs=function(i){return(i+7)/8|0},ya=function(i,e,t){return(e==null||e<0)&&(e=0),(t==null||t>i.length)&&(t=i.length),new pe(i.subarray(e,t))};var Ce=function(i,e,t){t<<=e&7;var r=e/8|0;i[r]|=t,i[r+1]|=t>>8},et=function(i,e,t){t<<=e&7;var r=e/8|0;i[r]|=t,i[r+1]|=t>>8,i[r+2]|=t>>16},Ar=function(i,e){for(var t=[],r=0;r<i.length;++r)i[r]&&t.push({s:r,f:i[r]});var s=t.length,n=t.slice();if(!s)return{t:Ss,l:0};if(s==1){var o=new pe(t[0].s+1);return o[t[0].s]=1,{t:o,l:1}}t.sort(function(I,M){return I.f-M.f}),t.push({s:-1,f:25001});var l=t[0],a=t[1],u=0,c=1,h=2;for(t[0]={s:-1,f:l.f+a.f,l,r:a};c!=s-1;)l=t[t[u].f<t[h].f?u++:h++],a=t[u!=c&&t[u].f<t[h].f?u++:h++],t[c++]={s:-1,f:l.f+a.f,l,r:a};for(var d=n[0].s,r=1;r<s;++r)n[r].s>d&&(d=n[r].s);var m=new ue(d+1),g=Tr(t[c-1],m,0);if(g>e){var r=0,p=0,f=g-e,S=1<<f;for(n.sort(function(M,R){return m[R.s]-m[M.s]||M.f-R.f});r<s;++r){var w=n[r].s;if(m[w]>e)p+=S-(1<<g-m[w]),m[w]=e;else break}for(p>>=f;p>0;){var y=n[r].s;m[y]<e?p-=1<<e-m[y]++-1:++r}for(;r>=0&&p;--r){var b=n[r].s;m[b]==e&&(--m[b],++p)}g=e}return{t:new pe(m),l:g}},Tr=function(i,e,t){return i.s==-1?Math.max(Tr(i.l,e,t+1),Tr(i.r,e,t+1)):e[i.s]=t},ps=function(i){for(var e=i.length;e&&!i[--e];);for(var t=new ue(++e),r=0,s=i[0],n=1,o=function(a){t[r++]=a},l=1;l<=e;++l)if(i[l]==s&&l!=e)++n;else{if(!s&&n>2){for(;n>138;n-=138)o(32754);n>2&&(o(n>10?n-11<<5|28690:n-3<<5|12305),n=0)}else if(n>3){for(o(s),--n;n>6;n-=6)o(8304);n>2&&(o(n-3<<5|8208),n=0)}for(;n--;)o(s);n=1,s=i[l]}return{c:t.subarray(0,r),n:e}},tt=function(i,e){for(var t=0,r=0;r<e.length;++r)t+=i[r]*e[r];return t},ws=function(i,e,t){var r=t.length,s=vs(e+2);i[s]=r&255,i[s+1]=r>>8,i[s+2]=i[s]^255,i[s+3]=i[s+1]^255;for(var n=0;n<r;++n)i[s+n+4]=t[n];return(s+4+r)*8},ds=function(i,e,t,r,s,n,o,l,a,u,c){Ce(e,c++,t),++s[256];for(var h=Ar(s,15),d=h.t,m=h.l,g=Ar(n,15),p=g.t,f=g.l,S=ps(d),w=S.c,y=S.n,b=ps(p),I=b.c,M=b.n,R=new ue(19),x=0;x<w.length;++x)++R[w[x]&31];for(var x=0;x<I.length;++x)++R[I[x]&31];for(var C=Ar(R,7),k=C.t,N=C.l,O=19;O>4&&!k[hs[O-1]];--O);var E=u+5<<3,j=tt(s,ke)+tt(n,Mt)+o,K=tt(s,d)+tt(n,p)+o+14+3*O+tt(R,k)+2*R[16]+3*R[17]+7*R[18];if(a>=0&&E<=j&&E<=K)return ws(e,c,i.subarray(a,a+u));var L,F,q,Q;if(Ce(e,c,1+(K<j)),c+=2,K<j){L=rt(d,m,0),F=d,q=rt(p,f,0),Q=p;var Fe=rt(k,N,0);Ce(e,c,y-257),Ce(e,c+5,M-1),Ce(e,c+10,O-4),c+=14;for(var x=0;x<O;++x)Ce(e,c+3*x,k[hs[x]]);c+=3*O;for(var ne=[w,I],Ne=0;Ne<2;++Ne)for(var he=ne[Ne],x=0;x<he.length;++x){var le=he[x]&31;Ce(e,c,Fe[le]),c+=k[le],le>15&&(Ce(e,c,he[x]>>5&127),c+=he[x]>>12)}}else L=ma,F=ke,q=ga,Q=Mt;for(var x=0;x<l;++x){var ee=r[x];if(ee>255){var le=ee>>18&31;et(e,c,L[le+257]),c+=F[le+257],le>7&&(Ce(e,c,ee>>23&31),c+=$r[le]);var Ae=ee&31;et(e,c,q[Ae]),c+=Q[Ae],Ae>3&&(et(e,c,ee>>5&8191),c+=_r[Ae])}else et(e,c,L[ee]),c+=F[ee]}return et(e,c,L[256]),c+F[256]},va=new kr([65540,131080,131088,131104,262176,1048704,1048832,2114560,2117632]),Ss=new pe(0),wa=function(i,e,t,r,s,n){var o=n.z||i.length,l=new pe(r+o+5*(1+Math.ceil(o/7e3))+s),a=l.subarray(r,l.length-s),u=n.l,c=(n.r||0)&7;if(e){c&&(a[0]=n.r>>3);for(var h=va[e-1],d=h>>13,m=h&8191,g=(1<<t)-1,p=n.p||new ue(32768),f=n.h||new ue(g+1),S=Math.ceil(t/3),w=2*S,y=function(V){return(i[V]^i[V+1]<<S^i[V+2]<<w)&g},b=new kr(25e3),I=new ue(288),M=new ue(32),R=0,x=0,C=n.i||0,k=0,N=n.w||0,O=0;C+2<o;++C){var E=y(C),j=C&32767,K=f[E];if(p[j]=K,f[E]=j,N<=C){var L=o-C;if((R>7e3||k>24576)&&(L>423||!u)){c=ds(i,a,0,b,I,M,x,k,O,C-O,c),k=R=x=0,O=C;for(var F=0;F<286;++F)I[F]=0;for(var F=0;F<30;++F)M[F]=0}var q=2,Q=0,Fe=m,ne=j-K&32767;if(L>2&&E==y(C-ne))for(var Ne=Math.min(d,L)-1,he=Math.min(32767,C),le=Math.min(258,L);ne<=he&&--Fe&&j!=K;){if(i[C+q]==i[C+q-ne]){for(var ee=0;ee<le&&i[C+ee]==i[C+ee-ne];++ee);if(ee>q){if(q=ee,Q=ne,ee>Ne)break;for(var Ae=Math.min(ne,ee-2),ye=0,F=0;F<Ae;++F){var fe=C-ne+F&32767,Qe=p[fe],De=fe-Qe&32767;De>ye&&(ye=De,K=fe)}}}j=K,K=p[j],ne+=j-K&32767}if(Q){b[k++]=268435456|Rr[q]<<18|fs[Q];var $=Rr[q]&31,oe=fs[Q]&31;x+=$r[$]+_r[oe],++I[257+$],++M[oe],N=C+q,++R}else b[k++]=i[C],++I[i[C]]}}for(C=Math.max(C,N);C<o;++C)b[k++]=i[C],++I[i[C]];c=ds(i,a,u,b,I,M,x,k,O,C-O,c),u||(n.r=c&7|a[c/8|0]<<3,c-=7,n.h=f,n.p=p,n.i=C,n.w=N)}else{for(var C=n.w||0;C<o+u;C+=65535){var W=C+65535;W>=o&&(a[c/8|0]=u,W=o),c=ws(a,c+1,i.subarray(C,W))}n.i=o}return ya(l,0,r+vs(c)+s)},Sa=(function(){for(var i=new Int32Array(256),e=0;e<256;++e){for(var t=e,r=9;--r;)t=(t&1&&-306674912)^t>>>1;i[e]=t}return i})(),ba=function(){var i=-1;return{p:function(e){for(var t=i,r=0;r<e.length;++r)t=Sa[t&255^e[r]]^t>>>8;i=t},d:function(){return~i}}};var Ca=function(i,e,t,r,s){if(!s&&(s={l:1},e.dictionary)){var n=e.dictionary.subarray(-32768),o=new pe(n.length+i.length);o.set(n),o.set(i,n.length),i=o,s.w=n.length}return wa(i,e.level==null?6:e.level,e.mem==null?s.l?Math.ceil(Math.max(8,Math.min(13,Math.log(i.length)))*1.5):20:12+e.mem,t,r,s)};var Dr=function(i,e,t){for(;t;++e)i[e]=t,t>>>=8},xa=function(i,e){var t=e.filename;if(i[0]=31,i[1]=139,i[2]=8,i[8]=e.level<2?4:e.level==9?2:0,i[9]=3,e.mtime!=0&&Dr(i,4,Math.floor(new Date(e.mtime||Date.now())/1e3)),t){i[3]=8;for(var r=0;r<=t.length;++r)i[r+10]=t.charCodeAt(r)}};var Ea=function(i){return 10+(i.filename?i.filename.length+1:0)};function bs(i,e){e||(e={});var t=ba(),r=i.length;t.p(i);var s=Ca(i,e,Ea(e),8),n=s.length;return xa(s,e),Dr(s,n-8,t.d()),Dr(s,n-4,r),s}var Ia=typeof TextDecoder<"u"&&new TextDecoder,Ma=0;try{Ia.decode(Ss,{stream:!0}),Ma=1}catch{}var Na=Object.defineProperty,Aa=(i,e,t)=>e in i?Na(i,e,{enumerable:!0,configurable:!0,writable:!0,value:t}):i[e]=t,v=(i,e,t)=>Aa(i,typeof e!="symbol"?e+"":e,t),Cs,Ra=Object.defineProperty,Oa=(i,e,t)=>e in i?Ra(i,e,{enumerable:!0,configurable:!0,writable:!0,value:t}):i[e]=t,xs=(i,e,t)=>Oa(i,typeof e!="symbol"?e+"":e,t),te=(i=>(i[i.Document=0]="Document",i[i.DocumentType=1]="DocumentType",i[i.Element=2]="Element",i[i.Text=3]="Text",i[i.CDATA=4]="CDATA",i[i.Comment=5]="Comment",i))(te||{}),Es={Node:["childNodes","parentNode","parentElement","textContent"],ShadowRoot:["host","styleSheets"],Element:["shadowRoot","querySelector","querySelectorAll"],MutationObserver:[]},Is={Node:["contains","getRootNode"],ShadowRoot:["getSelection"],Element:[],MutationObserver:["constructor"]},Nt={},Ta=()=>!!globalThis.Zone;function zi(i){if(Nt[i])return Nt[i];let e=globalThis[i],t=e.prototype,r=i in Es?Es[i]:void 0,s=!!(r&&r.every(l=>{var a,u;return!!((u=(a=Object.getOwnPropertyDescriptor(t,l))==null?void 0:a.get)!=null&&u.toString().includes("[native code]"))})),n=i in Is?Is[i]:void 0,o=!!(n&&n.every(l=>{var a;return typeof t[l]=="function"&&((a=t[l])==null?void 0:a.toString().includes("[native code]"))}));if(s&&o&&!Ta())return Nt[i]=e.prototype,e.prototype;try{let l=document.createElement("iframe");document.body.appendChild(l);let a=l.contentWindow;if(!a)return e.prototype;let u=a[i].prototype;return document.body.removeChild(l),u?Nt[i]=u:t}catch{return t}}var Pr={};function Oe(i,e,t){var r;let s=`${i}.${String(t)}`;if(Pr[s])return Pr[s].call(e);let n=zi(i),o=(r=Object.getOwnPropertyDescriptor(n,t))==null?void 0:r.get;return o?(Pr[s]=o,o.call(e)):e[t]}var Lr={};function bn(i,e,t){let r=`${i}.${String(t)}`;if(Lr[r])return Lr[r].bind(e);let n=zi(i)[t];return typeof n!="function"?e[t]:(Lr[r]=n,n.bind(e))}function Da(i){return Oe("Node",i,"childNodes")}function ka(i){return Oe("Node",i,"parentNode")}function $a(i){return Oe("Node",i,"parentElement")}function _a(i){return Oe("Node",i,"textContent")}function Pa(i,e){return bn("Node",i,"contains")(e)}function La(i){return bn("Node",i,"getRootNode")()}function Fa(i){return!i||!("host"in i)?null:Oe("ShadowRoot",i,"host")}function Ua(i){return i.styleSheets}function za(i){return!i||!("shadowRoot"in i)?null:Oe("Element",i,"shadowRoot")}function Ba(i,e){return Oe("Element",i,"querySelector")(e)}function Wa(i,e){return Oe("Element",i,"querySelectorAll")(e)}function Va(){return zi("MutationObserver").constructor}var re={childNodes:Da,parentNode:ka,parentElement:$a,textContent:_a,contains:Pa,getRootNode:La,host:Fa,styleSheets:Ua,shadowRoot:za,querySelector:Ba,querySelectorAll:Wa,mutationObserver:Va};function Cn(i){return i.nodeType===i.ELEMENT_NODE}function lt(i){let e=i&&"host"in i&&"mode"in i&&re.host(i)||null;return!!(e&&"shadowRoot"in e&&re.shadowRoot(e)===i)}function ut(i){return Object.prototype.toString.call(i)==="[object ShadowRoot]"}function Ga(i){return i.includes(" background-clip: text;")&&!i.includes(" -webkit-background-clip: text;")&&(i=i.replace(/\sbackground-clip:\s*text;/g," -webkit-background-clip: text; background-clip: text;")),i}function ja(i){let{cssText:e}=i;if(e.split('"').length<3)return e;let t=["@import",`url(${JSON.stringify(i.href)})`];return i.layerName===""?t.push("layer"):i.layerName&&t.push(`layer(${i.layerName})`),i.supportsText&&t.push(`supports(${i.supportsText})`),i.media.length&&t.push(i.media.mediaText),t.join(" ")+";"}function Kr(i){try{let e=i.rules||i.cssRules;if(!e)return null;let t=i.href;!t&&i.ownerNode&&i.ownerNode.ownerDocument&&(t=i.ownerNode.ownerDocument.location.href);let r=Array.from(e,s=>xn(s,t)).join("");return Ga(r)}catch{return null}}function xn(i,e){if(Ya(i)){let t;try{t=Kr(i.styleSheet)||ja(i)}catch{t=i.cssText}return i.styleSheet.href?rr(t,i.styleSheet.href):t}else{let t=i.cssText;return Za(i)&&i.selectorText.includes(":")&&(t=Ha(t)),e?rr(t,e):t}}function Ha(i){let e=/(\[(?:[\w-]+)[^\\])(:(?:[\w-]+)\])/gm;return i.replace(e,"$1\\$2")}function Ya(i){return"styleSheet"in i}function Za(i){return"selectorText"in i}var tr=class{constructor(){xs(this,"idNodeMap",new Map),xs(this,"nodeMetaMap",new WeakMap)}getId(e){var t;return e?((t=this.getMeta(e))==null?void 0:t.id)??-1:-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){let t=this.getId(e);this.idNodeMap.delete(t),e.childNodes&&e.childNodes.forEach(r=>this.removeNodeFromMap(r))}has(e){return this.idNodeMap.has(e)}hasNode(e){return this.nodeMetaMap.has(e)}add(e,t){let r=t.id;this.idNodeMap.set(r,e),this.nodeMetaMap.set(e,t)}replace(e,t){let r=this.getNode(e);if(r){let s=this.nodeMetaMap.get(r);s&&this.nodeMetaMap.set(t,s)}this.idNodeMap.set(e,t)}reset(){this.idNodeMap=new Map,this.nodeMetaMap=new WeakMap}};function Xa(){return new tr}function Bi({element:i,maskInputOptions:e,tagName:t,type:r,value:s,maskInputFn:n}){let o=s||"",l=r&&_e(r);return(e[t.toLowerCase()]||l&&e[l])&&(n?o=n(o,i):o="*".repeat(o.length)),o}function _e(i){return i.toLowerCase()}var Ms="__rrweb_original__";function Ja(i){let e=i.getContext("2d");if(!e)return!0;let t=50;for(let r=0;r<i.width;r+=t)for(let s=0;s<i.height;s+=t){let n=e.getImageData,o=Ms in n?n[Ms]:n;if(new Uint32Array(o.call(e,r,s,Math.min(t,i.width-r),Math.min(t,i.height-s)).data.buffer).some(a=>a!==0))return!1}return!0}function Wi(i){let e=i.type;return i.hasAttribute("data-rr-is-password")?"password":e?_e(e):null}function En(i,e){let t;try{t=new URL(i,e??window.location.href)}catch{return null}let r=/\.([0-9a-z]+)(?:$)/i,s=t.pathname.match(r);return s?.[1]??null}function Ka(i){let e="";return i.indexOf("//")>-1?e=i.split("/").slice(0,3).join("/"):e=i.split("/")[0],e=e.split("?")[0],e}var qa=/url\((?:(')([^']*)'|(")(.*?)"|([^)]*))\)/gm,Qa=/^(?:[a-z+]+:)?\/\//i,el=/^www\..*/i,tl=/^(data:)([^,]*),(.*)/i;function rr(i,e){return(i||"").replace(qa,(t,r,s,n,o,l)=>{let a=s||o||l,u=r||n||"";if(!a)return t;if(Qa.test(a)||el.test(a))return`url(${u}${a}${u})`;if(tl.test(a))return`url(${u}${a}${u})`;if(a[0]==="/")return`url(${u}${Ka(e)+a}${u})`;let c=e.split("/"),h=a.split("/");c.pop();for(let d of h)d!=="."&&(d===".."?c.pop():c.push(d));return`url(${u}${c.join("/")}${u})`})}function Fr(i){return i.replace(/(\/\*[^*]*\*\/)|[\s;]/g,"")}function rl(i,e){let t=Array.from(e.childNodes),r=[];if(t.length>1&&i&&typeof i=="string"){let s=Fr(i);for(let n=1;n<t.length;n++)if(t[n].textContent&&typeof t[n].textContent=="string"){let o=Fr(t[n].textContent);for(let l=3;l<o.length;l++){let a=o.substring(0,l);if(s.split(a).length===2){let u=s.indexOf(a);for(let c=u;c<i.length;c++)if(Fr(i.substring(0,c)).length===u){r.push(i.substring(0,c)),i=i.substring(c);break}break}}}}return r.push(i),r}function il(i,e){return rl(i,e).join("/* rr_split */")}var sl=1,nl=new RegExp("[^a-z0-9-_:]"),ht=-2;function In(){return sl++}function ol(i){if(i instanceof HTMLFormElement)return"form";let e=_e(i.tagName);return nl.test(e)?"div":e}var Ue,Ns,al=/^[^ \t\n\r\u000c]+/,ll=/^[, \t\n\r\u000c]+/;function ul(i,e){if(e.trim()==="")return e;let t=0;function r(n){let o,l=n.exec(e.substring(t));return l?(o=l[0],t+=o.length,o):""}let s=[];for(;r(ll),!(t>=e.length);){let n=r(al);if(n.slice(-1)===",")n=We(i,n.substring(0,n.length-1)),s.push(n);else{let o="";n=We(i,n);let l=!1;for(;;){let a=e.charAt(t);if(a===""){s.push((n+o).trim());break}else if(l)a===")"&&(l=!1);else if(a===","){t+=1,s.push((n+o).trim());break}else a==="("&&(l=!0);o+=a,t+=1}}}return s.join(", ")}var As=new WeakMap;function We(i,e){return!e||e.trim()===""?e:Vi(i,e)}function cl(i){return!!(i.tagName==="svg"||i.ownerSVGElement)}function Vi(i,e){let t=As.get(i);if(t||(t=i.createElement("a"),As.set(i,t)),!e)e="";else if(e.startsWith("blob:")||e.startsWith("data:"))return e;return t.setAttribute("href",e),t.href}function Mn(i,e,t,r){return r&&(t==="src"||t==="href"&&!(e==="use"&&r[0]==="#")||t==="xlink:href"&&r[0]!=="#"||t==="background"&&(e==="table"||e==="td"||e==="th")?We(i,r):t==="srcset"?ul(i,r):t==="style"?rr(r,Vi(i)):e==="object"&&t==="data"?We(i,r):r)}function Nn(i,e,t){return(i==="video"||i==="audio")&&e==="autoplay"}function hl(i,e,t){try{if(typeof e=="string"){if(i.classList.contains(e))return!0}else for(let r=i.classList.length;r--;){let s=i.classList[r];if(e.test(s))return!0}if(t)return i.matches(t)}catch{}return!1}function ir(i,e,t){if(!i)return!1;if(i.nodeType!==i.ELEMENT_NODE)return t?ir(re.parentNode(i),e,t):!1;for(let r=i.classList.length;r--;){let s=i.classList[r];if(e.test(s))return!0}return t?ir(re.parentNode(i),e,t):!1}function An(i,e,t,r){let s;if(Cn(i)){if(s=i,!re.childNodes(s).length)return!1}else{if(re.parentElement(i)===null)return!1;s=re.parentElement(i)}try{if(typeof e=="string"){if(r){if(s.closest(`.${e}`))return!0}else if(s.classList.contains(e))return!0}else if(ir(s,e,r))return!0;if(t){if(r){if(s.closest(t))return!0}else if(s.matches(t))return!0}}catch{}return!1}function fl(i,e,t){let r=i.contentWindow;if(!r)return;let s=!1,n;try{n=r.document.readyState}catch{return}if(n!=="complete"){let l=setTimeout(()=>{s||(e(),s=!0)},t);i.addEventListener("load",()=>{clearTimeout(l),s=!0,e()});return}let o="about:blank";if(r.location.href!==o||i.src===o||i.src==="")return setTimeout(e,0),i.addEventListener("load",e);i.addEventListener("load",e)}function pl(i,e,t){let r=!1,s;try{s=i.sheet}catch{return}if(s)return;let n=setTimeout(()=>{r||(e(),r=!0)},t);i.addEventListener("load",()=>{clearTimeout(n),r=!0,e()})}function dl(i,e){let{doc:t,mirror:r,blockClass:s,blockSelector:n,needsMask:o,inlineStylesheet:l,maskInputOptions:a={},maskTextFn:u,maskInputFn:c,dataURLOptions:h={},inlineImages:d,recordCanvas:m,keepIframeSrcFn:g,newlyAddedElement:p=!1,cssCaptured:f=!1}=e,S=ml(t,r);switch(i.nodeType){case i.DOCUMENT_NODE:return i.compatMode!=="CSS1Compat"?{type:te.Document,childNodes:[],compatMode:i.compatMode}:{type:te.Document,childNodes:[]};case i.DOCUMENT_TYPE_NODE:return{type:te.DocumentType,name:i.name,publicId:i.publicId,systemId:i.systemId,rootId:S};case i.ELEMENT_NODE:return yl(i,{doc:t,blockClass:s,blockSelector:n,inlineStylesheet:l,maskInputOptions:a,maskInputFn:c,dataURLOptions:h,inlineImages:d,recordCanvas:m,keepIframeSrcFn:g,newlyAddedElement:p,rootId:S});case i.TEXT_NODE:return gl(i,{doc:t,needsMask:o,maskTextFn:u,rootId:S,cssCaptured:f});case i.CDATA_SECTION_NODE:return{type:te.CDATA,textContent:"",rootId:S};case i.COMMENT_NODE:return{type:te.Comment,textContent:re.textContent(i)||"",rootId:S};default:return!1}}function ml(i,e){if(!e.hasNode(i))return;let t=e.getId(i);return t===1?void 0:t}function gl(i,e){let{needsMask:t,maskTextFn:r,rootId:s,cssCaptured:n}=e,o=re.parentNode(i),l=o&&o.tagName,a="",u=l==="STYLE"?!0:void 0,c=l==="SCRIPT"?!0:void 0;return c?a="SCRIPT_PLACEHOLDER":n||(a=re.textContent(i),u&&a&&(a=rr(a,Vi(e.doc)))),!u&&!c&&a&&t&&(a=r?r(a,re.parentElement(i)):a.replace(/[\S]/g,"*")),{type:te.Text,textContent:a||"",rootId:s}}function yl(i,e){let{doc:t,blockClass:r,blockSelector:s,inlineStylesheet:n,maskInputOptions:o={},maskInputFn:l,dataURLOptions:a={},inlineImages:u,recordCanvas:c,keepIframeSrcFn:h,newlyAddedElement:d=!1,rootId:m}=e,g=hl(i,r,s),p=ol(i),f={},S=i.attributes.length;for(let y=0;y<S;y++){let b=i.attributes[y];Nn(p,b.name,b.value)||(f[b.name]=Mn(t,p,_e(b.name),b.value))}if(p==="link"&&n){let y=Array.from(t.styleSheets).find(I=>I.href===i.href),b=null;y&&(b=Kr(y)),b&&(delete f.rel,delete f.href,f._cssText=b)}if(p==="style"&&i.sheet){let y=Kr(i.sheet);y&&(i.childNodes.length>1&&(y=il(y,i)),f._cssText=y)}if(p==="input"||p==="textarea"||p==="select"){let y=i.value,b=i.checked;f.type!=="radio"&&f.type!=="checkbox"&&f.type!=="submit"&&f.type!=="button"&&y?f.value=Bi({element:i,type:Wi(i),tagName:p,value:y,maskInputOptions:o,maskInputFn:l}):b&&(f.checked=b)}if(p==="option"&&(i.selected&&!o.select?f.selected=!0:delete f.selected),p==="dialog"&&i.open&&(f.rr_open_mode=i.matches("dialog:modal")?"modal":"non-modal"),p==="canvas"&&c){if(i.__context==="2d")Ja(i)||(f.rr_dataURL=i.toDataURL(a.type,a.quality));else if(!("__context"in i)){let y=i.toDataURL(a.type,a.quality),b=t.createElement("canvas");b.width=i.width,b.height=i.height;let I=b.toDataURL(a.type,a.quality);y!==I&&(f.rr_dataURL=y)}}if(p==="img"&&u){Ue||(Ue=t.createElement("canvas"),Ns=Ue.getContext("2d"));let y=i,b=y.currentSrc||y.getAttribute("src")||"<unknown-src>",I=y.crossOrigin,M=()=>{y.removeEventListener("load",M);try{Ue.width=y.naturalWidth,Ue.height=y.naturalHeight,Ns.drawImage(y,0,0),f.rr_dataURL=Ue.toDataURL(a.type,a.quality)}catch(R){if(y.crossOrigin!=="anonymous"){y.crossOrigin="anonymous",y.complete&&y.naturalWidth!==0?M():y.addEventListener("load",M);return}else console.warn(`Cannot inline img src=${b}! Error: ${R}`)}y.crossOrigin==="anonymous"&&(I?f.crossOrigin=I:y.removeAttribute("crossorigin"))};y.complete&&y.naturalWidth!==0?M():y.addEventListener("load",M)}if(p==="audio"||p==="video"){let y=f;y.rr_mediaState=i.paused?"paused":"played",y.rr_mediaCurrentTime=i.currentTime,y.rr_mediaPlaybackRate=i.playbackRate,y.rr_mediaMuted=i.muted,y.rr_mediaLoop=i.loop,y.rr_mediaVolume=i.volume}if(d||(i.scrollLeft&&(f.rr_scrollLeft=i.scrollLeft),i.scrollTop&&(f.rr_scrollTop=i.scrollTop)),g){let{width:y,height:b}=i.getBoundingClientRect();f={class:f.class,rr_width:`${y}px`,rr_height:`${b}px`}}p==="iframe"&&!h(f.src)&&(i.contentDocument||(f.rr_src=f.src),delete f.src);let w;try{customElements.get(p)&&(w=!0)}catch{}return{type:te.Element,tagName:p,attributes:f,childNodes:[],isSVG:cl(i)||void 0,needBlock:g,rootId:m,isCustom:w}}function G(i){return i==null?"":i.toLowerCase()}function vl(i,e){if(e.comment&&i.type===te.Comment)return!0;if(i.type===te.Element){if(e.script&&(i.tagName==="script"||i.tagName==="link"&&(i.attributes.rel==="preload"||i.attributes.rel==="modulepreload")&&i.attributes.as==="script"||i.tagName==="link"&&i.attributes.rel==="prefetch"&&typeof i.attributes.href=="string"&&En(i.attributes.href)==="js"))return!0;if(e.headFavicon&&(i.tagName==="link"&&i.attributes.rel==="shortcut icon"||i.tagName==="meta"&&(G(i.attributes.name).match(/^msapplication-tile(image|color)$/)||G(i.attributes.name)==="application-name"||G(i.attributes.rel)==="icon"||G(i.attributes.rel)==="apple-touch-icon"||G(i.attributes.rel)==="shortcut icon")))return!0;if(i.tagName==="meta"){if(e.headMetaDescKeywords&&G(i.attributes.name).match(/^description|keywords$/))return!0;if(e.headMetaSocial&&(G(i.attributes.property).match(/^(og|twitter|fb):/)||G(i.attributes.name).match(/^(og|twitter):/)||G(i.attributes.name)==="pinterest"))return!0;if(e.headMetaRobots&&(G(i.attributes.name)==="robots"||G(i.attributes.name)==="googlebot"||G(i.attributes.name)==="bingbot"))return!0;if(e.headMetaHttpEquiv&&i.attributes["http-equiv"]!==void 0)return!0;if(e.headMetaAuthorship&&(G(i.attributes.name)==="author"||G(i.attributes.name)==="generator"||G(i.attributes.name)==="framework"||G(i.attributes.name)==="publisher"||G(i.attributes.name)==="progid"||G(i.attributes.property).match(/^article:/)||G(i.attributes.property).match(/^product:/)))return!0;if(e.headMetaVerification&&(G(i.attributes.name)==="google-site-verification"||G(i.attributes.name)==="yandex-verification"||G(i.attributes.name)==="csrf-token"||G(i.attributes.name)==="p:domain_verify"||G(i.attributes.name)==="verify-v1"||G(i.attributes.name)==="verification"||G(i.attributes.name)==="shopify-checkout-api-token"))return!0}}return!1}function Ve(i,e){let{doc:t,mirror:r,blockClass:s,blockSelector:n,maskTextClass:o,maskTextSelector:l,skipChild:a=!1,inlineStylesheet:u=!0,maskInputOptions:c={},maskTextFn:h,maskInputFn:d,slimDOMOptions:m,dataURLOptions:g={},inlineImages:p=!1,recordCanvas:f=!1,onSerialize:S,onIframeLoad:w,iframeLoadTimeout:y=5e3,onStylesheetLoad:b,stylesheetLoadTimeout:I=5e3,keepIframeSrcFn:M=()=>!1,newlyAddedElement:R=!1,cssCaptured:x=!1}=e,{needsMask:C}=e,{preserveWhiteSpace:k=!0}=e;C||(C=An(i,o,l,C===void 0));let N=dl(i,{doc:t,mirror:r,blockClass:s,blockSelector:n,needsMask:C,inlineStylesheet:u,maskInputOptions:c,maskTextFn:h,maskInputFn:d,dataURLOptions:g,inlineImages:p,recordCanvas:f,keepIframeSrcFn:M,newlyAddedElement:R,cssCaptured:x});if(!N)return console.warn(i,"not serialized"),null;let O;r.hasNode(i)?O=r.getId(i):vl(N,m)||!k&&N.type===te.Text&&!N.textContent.replace(/^\s+|\s+$/gm,"").length?O=ht:O=In();let E=Object.assign(N,{id:O});if(r.add(i,E),O===ht)return null;S&&S(i);let j=!a;if(E.type===te.Element){j=j&&!E.needBlock,delete E.needBlock;let L=re.shadowRoot(i);L&&ut(L)&&(E.isShadowHost=!0)}if((E.type===te.Document||E.type===te.Element)&&j){m.headWhitespace&&E.type===te.Element&&E.tagName==="head"&&(k=!1);let L={doc:t,mirror:r,blockClass:s,blockSelector:n,needsMask:C,maskTextClass:o,maskTextSelector:l,skipChild:a,inlineStylesheet:u,maskInputOptions:c,maskTextFn:h,maskInputFn:d,slimDOMOptions:m,dataURLOptions:g,inlineImages:p,recordCanvas:f,preserveWhiteSpace:k,onSerialize:S,onIframeLoad:w,iframeLoadTimeout:y,onStylesheetLoad:b,stylesheetLoadTimeout:I,keepIframeSrcFn:M,cssCaptured:!1};if(!(E.type===te.Element&&E.tagName==="textarea"&&E.attributes.value!==void 0)){E.type===te.Element&&E.attributes._cssText!==void 0&&typeof E.attributes._cssText=="string"&&(L.cssCaptured=!0);for(let q of Array.from(re.childNodes(i))){let Q=Ve(q,L);Q&&E.childNodes.push(Q)}}let F=null;if(Cn(i)&&(F=re.shadowRoot(i)))for(let q of Array.from(re.childNodes(F))){let Q=Ve(q,L);Q&&(ut(F)&&(Q.isShadow=!0),E.childNodes.push(Q))}}let K=re.parentNode(i);return K&<(K)&&ut(K)&&(E.isShadow=!0),E.type===te.Element&&E.tagName==="iframe"&&fl(i,()=>{let L=i.contentDocument;if(L&&w){let F=Ve(L,{doc:L,mirror:r,blockClass:s,blockSelector:n,needsMask:C,maskTextClass:o,maskTextSelector:l,skipChild:!1,inlineStylesheet:u,maskInputOptions:c,maskTextFn:h,maskInputFn:d,slimDOMOptions:m,dataURLOptions:g,inlineImages:p,recordCanvas:f,preserveWhiteSpace:k,onSerialize:S,onIframeLoad:w,iframeLoadTimeout:y,onStylesheetLoad:b,stylesheetLoadTimeout:I,keepIframeSrcFn:M});F&&w(i,F)}},y),E.type===te.Element&&E.tagName==="link"&&typeof E.attributes.rel=="string"&&(E.attributes.rel==="stylesheet"||E.attributes.rel==="preload"&&typeof E.attributes.href=="string"&&En(E.attributes.href)==="css")&&pl(i,()=>{if(b){let L=Ve(i,{doc:t,mirror:r,blockClass:s,blockSelector:n,needsMask:C,maskTextClass:o,maskTextSelector:l,skipChild:!1,inlineStylesheet:u,maskInputOptions:c,maskTextFn:h,maskInputFn:d,slimDOMOptions:m,dataURLOptions:g,inlineImages:p,recordCanvas:f,preserveWhiteSpace:k,onSerialize:S,onIframeLoad:w,iframeLoadTimeout:y,onStylesheetLoad:b,stylesheetLoadTimeout:I,keepIframeSrcFn:M});L&&b(i,L)}},I),E}function wl(i,e){let{mirror:t=new tr,blockClass:r="rr-block",blockSelector:s=null,maskTextClass:n="rr-mask",maskTextSelector:o=null,inlineStylesheet:l=!0,inlineImages:a=!1,recordCanvas:u=!1,maskAllInputs:c=!1,maskTextFn:h,maskInputFn:d,slimDOM:m=!1,dataURLOptions:g,preserveWhiteSpace:p,onSerialize:f,onIframeLoad:S,iframeLoadTimeout:w,onStylesheetLoad:y,stylesheetLoadTimeout:b,keepIframeSrcFn:I=()=>!1}=e||{};return Ve(i,{doc:i,mirror:t,blockClass:r,blockSelector:s,maskTextClass:n,maskTextSelector:o,skipChild:!1,inlineStylesheet:l,maskInputOptions:c===!0?{color:!0,date:!0,"datetime-local":!0,email:!0,month:!0,number:!0,range:!0,search:!0,tel:!0,text:!0,time:!0,url:!0,week:!0,textarea:!0,select:!0,password:!0}:c===!1?{password:!0}:c,maskTextFn:h,maskInputFn:d,slimDOMOptions:m===!0||m==="all"?{script:!0,comment:!0,headFavicon:!0,headWhitespace:!0,headMetaDescKeywords:m==="all",headMetaSocial:!0,headMetaRobots:!0,headMetaHttpEquiv:!0,headMetaAuthorship:!0,headMetaVerification:!0}:m===!1?{}:m,dataURLOptions:g,inlineImages:a,recordCanvas:u,preserveWhiteSpace:p,onSerialize:f,onIframeLoad:S,iframeLoadTimeout:w,onStylesheetLoad:y,stylesheetLoadTimeout:b,keepIframeSrcFn:I,newlyAddedElement:!1})}var Sl=/(max|min)-device-(width|height)/,Qf=new RegExp(Sl.source,"g");function bl(i){return i&&i.__esModule&&Object.prototype.hasOwnProperty.call(i,"default")?i.default:i}function Cl(i){if(i.__esModule)return i;var e=i.default;if(typeof e=="function"){var t=function r(){return this instanceof r?Reflect.construct(e,arguments,this.constructor):e.apply(this,arguments)};t.prototype=e.prototype}else t={};return Object.defineProperty(t,"__esModule",{value:!0}),Object.keys(i).forEach(function(r){var s=Object.getOwnPropertyDescriptor(i,r);Object.defineProperty(t,r,s.get?s:{enumerable:!0,get:function(){return i[r]}})}),t}var Gi={exports:{}},H=String,Rn=function(){return{isColorSupported:!1,reset:H,bold:H,dim:H,italic:H,underline:H,inverse:H,hidden:H,strikethrough:H,black:H,red:H,green:H,yellow:H,blue:H,magenta:H,cyan:H,white:H,gray:H,bgBlack:H,bgRed:H,bgGreen:H,bgYellow:H,bgBlue:H,bgMagenta:H,bgCyan:H,bgWhite:H}};Gi.exports=Rn();Gi.exports.createColors=Rn;var xl=Gi.exports,El={},Il=Object.freeze(Object.defineProperty({__proto__:null,default:El},Symbol.toStringTag,{value:"Module"})),me=Cl(Il),Rs=xl,Os=me,qr=class On extends Error{constructor(e,t,r,s,n,o){super(e),this.name="CssSyntaxError",this.reason=e,n&&(this.file=n),s&&(this.source=s),o&&(this.plugin=o),typeof t<"u"&&typeof r<"u"&&(typeof t=="number"?(this.line=t,this.column=r):(this.line=t.line,this.column=t.column,this.endLine=r.line,this.endColumn=r.column)),this.setMessage(),Error.captureStackTrace&&Error.captureStackTrace(this,On)}setMessage(){this.message=this.plugin?this.plugin+": ":"",this.message+=this.file?this.file:"<css input>",typeof this.line<"u"&&(this.message+=":"+this.line+":"+this.column),this.message+=": "+this.reason}showSourceCode(e){if(!this.source)return"";let t=this.source;e==null&&(e=Rs.isColorSupported),Os&&e&&(t=Os(t));let r=t.split(/\r?\n/),s=Math.max(this.line-3,0),n=Math.min(this.line+2,r.length),o=String(n).length,l,a;if(e){let{bold:u,gray:c,red:h}=Rs.createColors(!0);l=d=>u(h(d)),a=d=>c(d)}else l=a=u=>u;return r.slice(s,n).map((u,c)=>{let h=s+1+c,d=" "+(" "+h).slice(-o)+" | ";if(h===this.line){let m=a(d.replace(/\d/g," "))+u.slice(0,this.column-1).replace(/[^\t]/g," ");return l(">")+a(d)+u+`
|
|
2
|
+
`+m+l("^")}return" "+a(d)+u}).join(`
|
|
3
3
|
`)}toString(){let e=this.showSourceCode();return e&&(e=`
|
|
4
4
|
|
|
5
5
|
`+e+`
|
|
@@ -8,55 +8,49 @@ import{createRequire as va}from"module";var wa=va("/"),Sa;try{Sa=wa("worker_thre
|
|
|
8
8
|
`,beforeComment:`
|
|
9
9
|
`,beforeDecl:`
|
|
10
10
|
`,beforeOpen:" ",beforeRule:`
|
|
11
|
-
`,colon:": ",commentLeft:" ",commentRight:" ",emptyBody:"",indent:" ",semicolon:!1};function
|
|
12
|
-
`)){let o=this.raw(e,null,"indent");if(o.length)for(let l=0;l<n;l++)r+=o}return r}block(e,t){let r=this.raw(e,"between","beforeOpen");this.builder(t+r+"{",e,"start");let s;e.nodes&&e.nodes.length?(this.body(e),s=this.raw(e,"after")):s=this.raw(e,"after","emptyBody"),s&&this.builder(s),this.builder("}",e,"end")}body(e){let t=e.nodes.length-1;for(;t>0&&e.nodes[t].type==="comment";)t-=1;let r=this.raw(e,"semicolon");for(let s=0;s<e.nodes.length;s++){let n=e.nodes[s],o=this.raw(n,"before");o&&this.builder(o),this.stringify(n,t!==s||r)}}comment(e){let t=this.raw(e,"left","commentLeft"),r=this.raw(e,"right","commentRight");this.builder("/*"+t+e.text+r+"*/",e)}decl(e,t){let r=this.raw(e,"between","colon"),s=e.prop+r+this.rawValue(e,"value");e.important&&(s+=e.raws.important||" !important"),t&&(s+=";"),this.builder(s,e)}document(e){this.body(e)}raw(e,t,r){let s;if(r||(r=t),t&&(s=e.raws[t],typeof s<"u"))return s;let n=e.parent;if(r==="before"&&(!n||n.type==="root"&&n.first===e||n&&n.type==="document"))return"";if(!n)return Ts[r];let o=e.root();if(o.rawCache||(o.rawCache={}),typeof o.rawCache[r]<"u")return o.rawCache[r];if(r==="before"||r==="after")return this.beforeAfter(e,r);{let l="raw"+
|
|
11
|
+
`,colon:": ",commentLeft:" ",commentRight:" ",emptyBody:"",indent:" ",semicolon:!1};function Ml(i){return i[0].toUpperCase()+i.slice(1)}var Qr=class{constructor(e){this.builder=e}atrule(e,t){let r="@"+e.name,s=e.params?this.rawValue(e,"params"):"";if(typeof e.raws.afterName<"u"?r+=e.raws.afterName:s&&(r+=" "),e.nodes)this.block(e,r+s);else{let n=(e.raws.between||"")+(t?";":"");this.builder(r+s+n,e)}}beforeAfter(e,t){let r;e.type==="decl"?r=this.raw(e,null,"beforeDecl"):e.type==="comment"?r=this.raw(e,null,"beforeComment"):t==="before"?r=this.raw(e,null,"beforeRule"):r=this.raw(e,null,"beforeClose");let s=e.parent,n=0;for(;s&&s.type!=="root";)n+=1,s=s.parent;if(r.includes(`
|
|
12
|
+
`)){let o=this.raw(e,null,"indent");if(o.length)for(let l=0;l<n;l++)r+=o}return r}block(e,t){let r=this.raw(e,"between","beforeOpen");this.builder(t+r+"{",e,"start");let s;e.nodes&&e.nodes.length?(this.body(e),s=this.raw(e,"after")):s=this.raw(e,"after","emptyBody"),s&&this.builder(s),this.builder("}",e,"end")}body(e){let t=e.nodes.length-1;for(;t>0&&e.nodes[t].type==="comment";)t-=1;let r=this.raw(e,"semicolon");for(let s=0;s<e.nodes.length;s++){let n=e.nodes[s],o=this.raw(n,"before");o&&this.builder(o),this.stringify(n,t!==s||r)}}comment(e){let t=this.raw(e,"left","commentLeft"),r=this.raw(e,"right","commentRight");this.builder("/*"+t+e.text+r+"*/",e)}decl(e,t){let r=this.raw(e,"between","colon"),s=e.prop+r+this.rawValue(e,"value");e.important&&(s+=e.raws.important||" !important"),t&&(s+=";"),this.builder(s,e)}document(e){this.body(e)}raw(e,t,r){let s;if(r||(r=t),t&&(s=e.raws[t],typeof s<"u"))return s;let n=e.parent;if(r==="before"&&(!n||n.type==="root"&&n.first===e||n&&n.type==="document"))return"";if(!n)return Ts[r];let o=e.root();if(o.rawCache||(o.rawCache={}),typeof o.rawCache[r]<"u")return o.rawCache[r];if(r==="before"||r==="after")return this.beforeAfter(e,r);{let l="raw"+Ml(r);this[l]?s=this[l](o,e):o.walk(a=>{if(s=a.raws[t],typeof s<"u")return!1})}return typeof s>"u"&&(s=Ts[r]),o.rawCache[r]=s,s}rawBeforeClose(e){let t;return e.walk(r=>{if(r.nodes&&r.nodes.length>0&&typeof r.raws.after<"u")return t=r.raws.after,t.includes(`
|
|
13
13
|
`)&&(t=t.replace(/[^\n]+$/,"")),!1}),t&&(t=t.replace(/\S/g,"")),t}rawBeforeComment(e,t){let r;return e.walkComments(s=>{if(typeof s.raws.before<"u")return r=s.raws.before,r.includes(`
|
|
14
14
|
`)&&(r=r.replace(/[^\n]+$/,"")),!1}),typeof r>"u"?r=this.raw(t,null,"beforeDecl"):r&&(r=r.replace(/\S/g,"")),r}rawBeforeDecl(e,t){let r;return e.walkDecls(s=>{if(typeof s.raws.before<"u")return r=s.raws.before,r.includes(`
|
|
15
15
|
`)&&(r=r.replace(/[^\n]+$/,"")),!1}),typeof r>"u"?r=this.raw(t,null,"beforeRule"):r&&(r=r.replace(/\S/g,"")),r}rawBeforeOpen(e){let t;return e.walk(r=>{if(r.type!=="decl"&&(t=r.raws.between,typeof t<"u"))return!1}),t}rawBeforeRule(e){let t;return e.walk(r=>{if(r.nodes&&(r.parent!==e||e.first!==r)&&typeof r.raws.before<"u")return t=r.raws.before,t.includes(`
|
|
16
16
|
`)&&(t=t.replace(/[^\n]+$/,"")),!1}),t&&(t=t.replace(/\S/g,"")),t}rawColon(e){let t;return e.walkDecls(r=>{if(typeof r.raws.between<"u")return t=r.raws.between.replace(/[^\s:]/g,""),!1}),t}rawEmptyBody(e){let t;return e.walk(r=>{if(r.nodes&&r.nodes.length===0&&(t=r.raws.after,typeof t<"u"))return!1}),t}rawIndent(e){if(e.raws.indent)return e.raws.indent;let t;return e.walk(r=>{let s=r.parent;if(s&&s!==e&&s.parent&&s.parent===e&&typeof r.raws.before<"u"){let n=r.raws.before.split(`
|
|
17
|
-
`);return t=n[n.length-1],t=t.replace(/\S/g,""),!1}}),t}rawSemicolon(e){let t;return e.walk(r=>{if(r.nodes&&r.nodes.length&&r.last.type==="decl"&&(t=r.raws.semicolon,typeof t<"u"))return!1}),t}rawValue(e,t){let r=e[t],s=e.raws[t];return s&&s.value===r?s.raw:r}root(e){this.body(e),e.raws.after&&this.builder(e.raws.after)}rule(e){this.block(e,this.rawValue(e,"selector")),e.raws.ownSemicolon&&this.builder(e.raws.ownSemicolon,e,"end")}stringify(e,t){if(!this[e.type])throw new Error("Unknown AST node type "+e.type+". Maybe you need to change PostCSS stringifier.");this[e.type](e,t)}},
|
|
18
|
-
`?(s=1,n+=1):s+=1;return{column:s,line:n}}prev(){if(!this.parent)return;let e=this.parent.index(this);return this.parent.nodes[e-1]}rangeBy(e){let t={column:this.source.start.column,line:this.source.start.line},r=this.source.end?{column:this.source.end.column+1,line:this.source.end.line}:{column:t.column+1,line:t.line};if(e.word){let s=this.toString(),n=s.indexOf(e.word);n!==-1&&(t=this.positionInside(n,s),r=this.positionInside(n+e.word.length,s))}else e.start?t={column:e.start.column,line:e.start.line}:e.index&&(t=this.positionInside(e.index)),e.end?r={column:e.end.column,line:e.end.line}:typeof e.endIndex=="number"?r=this.positionInside(e.endIndex):e.index&&(r=this.positionInside(e.index+1));return(r.line<t.line||r.line===t.line&&r.column<=t.column)&&(r={column:t.column+1,line:t.line}),{end:r,start:t}}raw(e,t){return new
|
|
19
|
-
`);r=new Array(n.length);let o=0;for(let l=0,a=n.length;l<a;l++)r[l]=o,o+=n[l].length+1;this[Br]=r}t=r[r.length-1];let s=0;if(e>=t)s=r.length-1;else{let n=r.length-2,o;for(;s<n;)if(o=s+(n-s>>1),e<r[o])n=o-1;else if(e>=r[o+1])s=o+1;else{s=o;break}}return{col:e-r[s]+1,line:s+1}}mapResolve(e){return/^\w+:\/\//.test(e)?e:oi(this.map.consumer().sourceRoot||this.map.root||".",e)}origin(e,t,r,s){if(!this.map)return!1;let n=this.map.consumer(),o=n.originalPositionFor({column:t,line:e});if(!o.source)return!1;let l;typeof r=="number"&&(l=n.originalPositionFor({column:s,line:r}));let a;ni(o.source)?a=Rt(o.source):a=new URL(o.source,this.map.consumer().sourceRoot||Rt(this.map.mapFile));let u={column:o.column,endColumn:l&&l.column,endLine:l&&l.line,line:o.line,url:a.toString()};if(a.protocol==="file:")if(
|
|
17
|
+
`);return t=n[n.length-1],t=t.replace(/\S/g,""),!1}}),t}rawSemicolon(e){let t;return e.walk(r=>{if(r.nodes&&r.nodes.length&&r.last.type==="decl"&&(t=r.raws.semicolon,typeof t<"u"))return!1}),t}rawValue(e,t){let r=e[t],s=e.raws[t];return s&&s.value===r?s.raw:r}root(e){this.body(e),e.raws.after&&this.builder(e.raws.after)}rule(e){this.block(e,this.rawValue(e,"selector")),e.raws.ownSemicolon&&this.builder(e.raws.ownSemicolon,e,"end")}stringify(e,t){if(!this[e.type])throw new Error("Unknown AST node type "+e.type+". Maybe you need to change PostCSS stringifier.");this[e.type](e,t)}},Tn=Qr;Qr.default=Qr;var Nl=Tn;function ei(i,e){new Nl(e).stringify(i)}var gr=ei;ei.default=ei;var{isClean:At,my:Al}=bt,Rl=ji,Ol=Tn,Tl=gr;function ti(i,e){let t=new i.constructor;for(let r in i){if(!Object.prototype.hasOwnProperty.call(i,r)||r==="proxyCache")continue;let s=i[r],n=typeof s;r==="parent"&&n==="object"?e&&(t[r]=e):r==="source"?t[r]=s:Array.isArray(s)?t[r]=s.map(o=>ti(o,t)):(n==="object"&&s!==null&&(s=ti(s)),t[r]=s)}return t}var ri=class{constructor(e={}){this.raws={},this[At]=!1,this[Al]=!0;for(let t in e)if(t==="nodes"){this.nodes=[];for(let r of e[t])typeof r.clone=="function"?this.append(r.clone()):this.append(r)}else this[t]=e[t]}addToError(e){if(e.postcssNode=this,e.stack&&this.source&&/\n\s{4}at /.test(e.stack)){let t=this.source;e.stack=e.stack.replace(/\n\s{4}at /,`$&${t.input.from}:${t.start.line}:${t.start.column}$&`)}return e}after(e){return this.parent.insertAfter(this,e),this}assign(e={}){for(let t in e)this[t]=e[t];return this}before(e){return this.parent.insertBefore(this,e),this}cleanRaws(e){delete this.raws.before,delete this.raws.after,e||delete this.raws.between}clone(e={}){let t=ti(this);for(let r in e)t[r]=e[r];return t}cloneAfter(e={}){let t=this.clone(e);return this.parent.insertAfter(this,t),t}cloneBefore(e={}){let t=this.clone(e);return this.parent.insertBefore(this,t),t}error(e,t={}){if(this.source){let{end:r,start:s}=this.rangeBy(t);return this.source.input.error(e,{column:s.column,line:s.line},{column:r.column,line:r.line},t)}return new Rl(e)}getProxyProcessor(){return{get(e,t){return t==="proxyOf"?e:t==="root"?()=>e.root().toProxy():e[t]},set(e,t,r){return e[t]===r||(e[t]=r,(t==="prop"||t==="value"||t==="name"||t==="params"||t==="important"||t==="text")&&e.markDirty()),!0}}}markDirty(){if(this[At]){this[At]=!1;let e=this;for(;e=e.parent;)e[At]=!1}}next(){if(!this.parent)return;let e=this.parent.index(this);return this.parent.nodes[e+1]}positionBy(e,t){let r=this.source.start;if(e.index)r=this.positionInside(e.index,t);else if(e.word){t=this.toString();let s=t.indexOf(e.word);s!==-1&&(r=this.positionInside(s,t))}return r}positionInside(e,t){let r=t||this.toString(),s=this.source.start.column,n=this.source.start.line;for(let o=0;o<e;o++)r[o]===`
|
|
18
|
+
`?(s=1,n+=1):s+=1;return{column:s,line:n}}prev(){if(!this.parent)return;let e=this.parent.index(this);return this.parent.nodes[e-1]}rangeBy(e){let t={column:this.source.start.column,line:this.source.start.line},r=this.source.end?{column:this.source.end.column+1,line:this.source.end.line}:{column:t.column+1,line:t.line};if(e.word){let s=this.toString(),n=s.indexOf(e.word);n!==-1&&(t=this.positionInside(n,s),r=this.positionInside(n+e.word.length,s))}else e.start?t={column:e.start.column,line:e.start.line}:e.index&&(t=this.positionInside(e.index)),e.end?r={column:e.end.column,line:e.end.line}:typeof e.endIndex=="number"?r=this.positionInside(e.endIndex):e.index&&(r=this.positionInside(e.index+1));return(r.line<t.line||r.line===t.line&&r.column<=t.column)&&(r={column:t.column+1,line:t.line}),{end:r,start:t}}raw(e,t){return new Ol().raw(this,e,t)}remove(){return this.parent&&this.parent.removeChild(this),this.parent=void 0,this}replaceWith(...e){if(this.parent){let t=this,r=!1;for(let s of e)s===this?r=!0:r?(this.parent.insertAfter(t,s),t=s):this.parent.insertBefore(t,s);r||this.remove()}return this}root(){let e=this;for(;e.parent&&e.parent.type!=="document";)e=e.parent;return e}toJSON(e,t){let r={},s=t==null;t=t||new Map;let n=0;for(let o in this){if(!Object.prototype.hasOwnProperty.call(this,o)||o==="parent"||o==="proxyCache")continue;let l=this[o];if(Array.isArray(l))r[o]=l.map(a=>typeof a=="object"&&a.toJSON?a.toJSON(null,t):a);else if(typeof l=="object"&&l.toJSON)r[o]=l.toJSON(null,t);else if(o==="source"){let a=t.get(l.input);a==null&&(a=n,t.set(l.input,n),n++),r[o]={end:l.end,inputId:a,start:l.start}}else r[o]=l}return s&&(r.inputs=[...t.keys()].map(o=>o.toJSON())),r}toProxy(){return this.proxyCache||(this.proxyCache=new Proxy(this,this.getProxyProcessor())),this.proxyCache}toString(e=Tl){e.stringify&&(e=e.stringify);let t="";return e(this,r=>{t+=r}),t}warn(e,t,r){let s={node:this};for(let n in r)s[n]=r[n];return e.warn(t,s)}get proxyOf(){return this}},yr=ri;ri.default=ri;var Dl=yr,ii=class extends Dl{constructor(e){e&&typeof e.value<"u"&&typeof e.value!="string"&&(e={...e,value:String(e.value)}),super(e),this.type="decl"}get variable(){return this.prop.startsWith("--")||this.prop[0]==="$"}},vr=ii;ii.default=ii;var kl="useandom-26T198340PX75pxJACKVERYMINDBUSHWOLF_GQZbfghjklqvwyzrict",$l=(i,e=21)=>(t=e)=>{let r="",s=t;for(;s--;)r+=i[Math.random()*i.length|0];return r},_l=(i=21)=>{let e="",t=i;for(;t--;)e+=kl[Math.random()*64|0];return e},Pl={nanoid:_l,customAlphabet:$l},{SourceMapConsumer:Ds,SourceMapGenerator:ks}=me,{existsSync:Ll,readFileSync:Fl}=me,{dirname:Ur,join:Ul}=me;function zl(i){return Buffer?Buffer.from(i,"base64").toString():window.atob(i)}var si=class{constructor(e,t){if(t.map===!1)return;this.loadAnnotation(e),this.inline=this.startWith(this.annotation,"data:");let r=t.map?t.map.prev:void 0,s=this.loadMap(t.from,r);!this.mapFile&&t.from&&(this.mapFile=t.from),this.mapFile&&(this.root=Ur(this.mapFile)),s&&(this.text=s)}consumer(){return this.consumerCache||(this.consumerCache=new Ds(this.text)),this.consumerCache}decodeInline(e){let t=/^data:application\/json;charset=utf-?8;base64,/,r=/^data:application\/json;base64,/,s=/^data:application\/json;charset=utf-?8,/,n=/^data:application\/json,/;if(s.test(e)||n.test(e))return decodeURIComponent(e.substr(RegExp.lastMatch.length));if(t.test(e)||r.test(e))return zl(e.substr(RegExp.lastMatch.length));let o=e.match(/data:application\/json;([^,]+),/)[1];throw new Error("Unsupported source map encoding "+o)}getAnnotationURL(e){return e.replace(/^\/\*\s*# sourceMappingURL=/,"").trim()}isMap(e){return typeof e!="object"?!1:typeof e.mappings=="string"||typeof e._mappings=="string"||Array.isArray(e.sections)}loadAnnotation(e){let t=e.match(/\/\*\s*# sourceMappingURL=/gm);if(!t)return;let r=e.lastIndexOf(t.pop()),s=e.indexOf("*/",r);r>-1&&s>-1&&(this.annotation=this.getAnnotationURL(e.substring(r,s)))}loadFile(e){if(this.root=Ur(e),Ll(e))return this.mapFile=e,Fl(e,"utf-8").toString().trim()}loadMap(e,t){if(t===!1)return!1;if(t){if(typeof t=="string")return t;if(typeof t=="function"){let r=t(e);if(r){let s=this.loadFile(r);if(!s)throw new Error("Unable to load previous source map: "+r.toString());return s}}else{if(t instanceof Ds)return ks.fromSourceMap(t).toString();if(t instanceof ks)return t.toString();if(this.isMap(t))return JSON.stringify(t);throw new Error("Unsupported previous source map format: "+t.toString())}}else{if(this.inline)return this.decodeInline(this.annotation);if(this.annotation){let r=this.annotation;return e&&(r=Ul(Ur(e),r)),this.loadFile(r)}}}startWith(e,t){return e?e.substr(0,t.length)===t:!1}withContent(){return!!(this.consumer().sourcesContent&&this.consumer().sourcesContent.length>0)}},Dn=si;si.default=si;var{SourceMapConsumer:Bl,SourceMapGenerator:Wl}=me,{fileURLToPath:$s,pathToFileURL:Rt}=me,{isAbsolute:ni,resolve:oi}=me,{nanoid:Vl}=Pl,zr=me,_s=ji,Gl=Dn,Br=Symbol("fromOffsetCache"),jl=!!(Bl&&Wl),Ps=!!(oi&&ni),sr=class{constructor(e,t={}){if(e===null||typeof e>"u"||typeof e=="object"&&!e.toString)throw new Error(`PostCSS received ${e} instead of CSS string`);if(this.css=e.toString(),this.css[0]==="\uFEFF"||this.css[0]==="\uFFFE"?(this.hasBOM=!0,this.css=this.css.slice(1)):this.hasBOM=!1,t.from&&(!Ps||/^\w+:\/\//.test(t.from)||ni(t.from)?this.file=t.from:this.file=oi(t.from)),Ps&&jl){let r=new Gl(this.css,t);if(r.text){this.map=r;let s=r.consumer().file;!this.file&&s&&(this.file=this.mapResolve(s))}}this.file||(this.id="<input css "+Vl(6)+">"),this.map&&(this.map.file=this.from)}error(e,t,r,s={}){let n,o,l;if(t&&typeof t=="object"){let u=t,c=r;if(typeof u.offset=="number"){let h=this.fromOffset(u.offset);t=h.line,r=h.col}else t=u.line,r=u.column;if(typeof c.offset=="number"){let h=this.fromOffset(c.offset);o=h.line,l=h.col}else o=c.line,l=c.column}else if(!r){let u=this.fromOffset(t);t=u.line,r=u.col}let a=this.origin(t,r,o,l);return a?n=new _s(e,a.endLine===void 0?a.line:{column:a.column,line:a.line},a.endLine===void 0?a.column:{column:a.endColumn,line:a.endLine},a.source,a.file,s.plugin):n=new _s(e,o===void 0?t:{column:r,line:t},o===void 0?r:{column:l,line:o},this.css,this.file,s.plugin),n.input={column:r,endColumn:l,endLine:o,line:t,source:this.css},this.file&&(Rt&&(n.input.url=Rt(this.file).toString()),n.input.file=this.file),n}fromOffset(e){let t,r;if(this[Br])r=this[Br];else{let n=this.css.split(`
|
|
19
|
+
`);r=new Array(n.length);let o=0;for(let l=0,a=n.length;l<a;l++)r[l]=o,o+=n[l].length+1;this[Br]=r}t=r[r.length-1];let s=0;if(e>=t)s=r.length-1;else{let n=r.length-2,o;for(;s<n;)if(o=s+(n-s>>1),e<r[o])n=o-1;else if(e>=r[o+1])s=o+1;else{s=o;break}}return{col:e-r[s]+1,line:s+1}}mapResolve(e){return/^\w+:\/\//.test(e)?e:oi(this.map.consumer().sourceRoot||this.map.root||".",e)}origin(e,t,r,s){if(!this.map)return!1;let n=this.map.consumer(),o=n.originalPositionFor({column:t,line:e});if(!o.source)return!1;let l;typeof r=="number"&&(l=n.originalPositionFor({column:s,line:r}));let a;ni(o.source)?a=Rt(o.source):a=new URL(o.source,this.map.consumer().sourceRoot||Rt(this.map.mapFile));let u={column:o.column,endColumn:l&&l.column,endLine:l&&l.line,line:o.line,url:a.toString()};if(a.protocol==="file:")if($s)u.file=$s(a);else throw new Error("file: protocol is not available in this PostCSS build");let c=n.sourceContentFor(o.source);return c&&(u.source=c),u}toJSON(){let e={};for(let t of["hasBOM","css","file","id"])this[t]!=null&&(e[t]=this[t]);return this.map&&(e.map={...this.map},e.map.consumerCache&&(e.map.consumerCache=void 0)),e}get from(){return this.file||this.id}},wr=sr;sr.default=sr;zr&&zr.registerInput&&zr.registerInput(sr);var{SourceMapConsumer:kn,SourceMapGenerator:Xt}=me,{dirname:Jt,relative:$n,resolve:_n,sep:Pn}=me,{pathToFileURL:Ls}=me,Hl=wr,Yl=!!(kn&&Xt),Zl=!!(Jt&&_n&&$n&&Pn),Xl=class{constructor(e,t,r,s){this.stringify=e,this.mapOpts=r.map||{},this.root=t,this.opts=r,this.css=s,this.originalCSS=s,this.usesFileUrls=!this.mapOpts.from&&this.mapOpts.absolute,this.memoizedFileURLs=new Map,this.memoizedPaths=new Map,this.memoizedURLs=new Map}addAnnotation(){let e;this.isInline()?e="data:application/json;base64,"+this.toBase64(this.map.toString()):typeof this.mapOpts.annotation=="string"?e=this.mapOpts.annotation:typeof this.mapOpts.annotation=="function"?e=this.mapOpts.annotation(this.opts.to,this.root):e=this.outputFile()+".map";let t=`
|
|
20
20
|
`;this.css.includes(`\r
|
|
21
21
|
`)&&(t=`\r
|
|
22
|
-
`),this.css+=t+"/*# sourceMappingURL="+e+" */"}applyPrevMaps(){for(let e of this.previous()){let t=this.toUrl(this.path(e.file)),r=e.root||Jt(e.file),s;this.mapOpts.sourcesContent===!1?(s=new
|
|
23
|
-
`),t=l.length-o):t+=l.length,a&&u!=="start"){let c=a.parent||{raws:{}};(!(a.type==="decl"||a.type==="atrule"&&!a.nodes)||a!==c.last||c.raws.semicolon)&&(a.source&&a.source.end?(s.source=this.sourcePath(a),s.original.line=a.source.end.line,s.original.column=a.source.end.column-1,s.generated.line=e,s.generated.column=t-2,this.map.addMapping(s)):(s.source=r,s.original.line=1,s.original.column=0,s.generated.line=e,s.generated.column=t-1,this.map.addMapping(s)))}})}isAnnotation(){return this.isInline()?!0:typeof this.mapOpts.annotation<"u"?this.mapOpts.annotation:this.previous().length?this.previous().some(e=>e.annotation):!0}isInline(){if(typeof this.mapOpts.inline<"u")return this.mapOpts.inline;let e=this.mapOpts.annotation;return typeof e<"u"&&e!==!0?!1:this.previous().length?this.previous().some(t=>t.inline):!0}isMap(){return typeof this.opts.map<"u"?!!this.opts.map:this.previous().length>0}isSourcesContent(){return typeof this.mapOpts.sourcesContent<"u"?this.mapOpts.sourcesContent:this.previous().length?this.previous().some(e=>e.withContent()):!0}outputFile(){return this.opts.to?this.path(this.opts.to):this.opts.from?this.path(this.opts.from):"to.css"}path(e){if(this.mapOpts.absolute||e.charCodeAt(0)===60||/^\w+:\/\//.test(e))return e;let t=this.memoizedPaths.get(e);if(t)return t;let r=this.opts.to?Jt(this.opts.to):".";typeof this.mapOpts.annotation=="string"&&(r=Jt(Ln(r,this.mapOpts.annotation)));let s=$n(r,e);return this.memoizedPaths.set(e,s),s}previous(){if(!this.previousMaps)if(this.previousMaps=[],this.root)this.root.walk(e=>{if(e.source&&e.source.input.map){let t=e.source.input.map;this.previousMaps.includes(t)||this.previousMaps.push(t)}});else{let e=new Ql(this.originalCSS,this.opts);e.map&&this.previousMaps.push(e.map)}return this.previousMaps}setSourcesContent(){let e={};if(this.root)this.root.walk(t=>{if(t.source){let r=t.source.input.from;if(r&&!e[r]){e[r]=!0;let s=this.usesFileUrls?this.toFileUrl(r):this.toUrl(this.path(r));this.map.setSourceContent(s,t.source.input.css)}}});else if(this.css){let t=this.opts.from?this.toUrl(this.path(this.opts.from)):"<no source>";this.map.setSourceContent(t,this.css)}}sourcePath(e){return this.mapOpts.from?this.toUrl(this.mapOpts.from):this.usesFileUrls?this.toFileUrl(e.source.input.from):this.toUrl(this.path(e.source.input.from))}toBase64(e){return Buffer?Buffer.from(e).toString("base64"):window.btoa(unescape(encodeURIComponent(e)))}toFileUrl(e){let t=this.memoizedFileURLs.get(e);if(t)return t;if(Ls){let r=Ls(e).toString();return this.memoizedFileURLs.set(e,r),r}else throw new Error("`map.absolute` option is not available in this PostCSS build")}toUrl(e){let t=this.memoizedURLs.get(e);if(t)return t;Fn==="\\"&&(e=e.replace(/\\/g,"/"));let r=encodeURI(e).replace(/[#?]/g,encodeURIComponent);return this.memoizedURLs.set(e,r),r}},Un=ru,iu=yr,ai=class extends iu{constructor(e){super(e),this.type="comment"}},Sr=ai;ai.default=ai;var{isClean:zn,my:Bn}=bt,Wn=vr,Vn=Sr,su=yr,Gn,Hi,Yi,jn;function Hn(i){return i.map(e=>(e.nodes&&(e.nodes=Hn(e.nodes)),delete e.source,e))}function Yn(i){if(i[zn]=!1,i.proxyOf.nodes)for(let e of i.proxyOf.nodes)Yn(e)}var Ie=class Zn extends su{append(...e){for(let t of e){let r=this.normalize(t,this.last);for(let s of r)this.proxyOf.nodes.push(s)}return this.markDirty(),this}cleanRaws(e){if(super.cleanRaws(e),this.nodes)for(let t of this.nodes)t.cleanRaws(e)}each(e){if(!this.proxyOf.nodes)return;let t=this.getIterator(),r,s;for(;this.indexes[t]<this.proxyOf.nodes.length&&(r=this.indexes[t],s=e(this.proxyOf.nodes[r],r),s!==!1);)this.indexes[t]+=1;return delete this.indexes[t],s}every(e){return this.nodes.every(e)}getIterator(){this.lastEach||(this.lastEach=0),this.indexes||(this.indexes={}),this.lastEach+=1;let e=this.lastEach;return this.indexes[e]=0,e}getProxyProcessor(){return{get(e,t){return t==="proxyOf"?e:e[t]?t==="each"||typeof t=="string"&&t.startsWith("walk")?(...r)=>e[t](...r.map(s=>typeof s=="function"?(n,o)=>s(n.toProxy(),o):s)):t==="every"||t==="some"?r=>e[t]((s,...n)=>r(s.toProxy(),...n)):t==="root"?()=>e.root().toProxy():t==="nodes"?e.nodes.map(r=>r.toProxy()):t==="first"||t==="last"?e[t].toProxy():e[t]:e[t]},set(e,t,r){return e[t]===r||(e[t]=r,(t==="name"||t==="params"||t==="selector")&&e.markDirty()),!0}}}index(e){return typeof e=="number"?e:(e.proxyOf&&(e=e.proxyOf),this.proxyOf.nodes.indexOf(e))}insertAfter(e,t){let r=this.index(e),s=this.normalize(t,this.proxyOf.nodes[r]).reverse();r=this.index(e);for(let o of s)this.proxyOf.nodes.splice(r+1,0,o);let n;for(let o in this.indexes)n=this.indexes[o],r<n&&(this.indexes[o]=n+s.length);return this.markDirty(),this}insertBefore(e,t){let r=this.index(e),s=r===0?"prepend":!1,n=this.normalize(t,this.proxyOf.nodes[r],s).reverse();r=this.index(e);for(let l of n)this.proxyOf.nodes.splice(r,0,l);let o;for(let l in this.indexes)o=this.indexes[l],r<=o&&(this.indexes[l]=o+n.length);return this.markDirty(),this}normalize(e,t){if(typeof e=="string")e=Hn(Gn(e).nodes);else if(typeof e>"u")e=[];else if(Array.isArray(e)){e=e.slice(0);for(let s of e)s.parent&&s.parent.removeChild(s,"ignore")}else if(e.type==="root"&&this.type!=="document"){e=e.nodes.slice(0);for(let s of e)s.parent&&s.parent.removeChild(s,"ignore")}else if(e.type)e=[e];else if(e.prop){if(typeof e.value>"u")throw new Error("Value field is missed in node creation");typeof e.value!="string"&&(e.value=String(e.value)),e=[new Wn(e)]}else if(e.selector)e=[new Hi(e)];else if(e.name)e=[new Yi(e)];else if(e.text)e=[new Vn(e)];else throw new Error("Unknown node type in node creation");return e.map(s=>(s[Bn]||Zn.rebuild(s),s=s.proxyOf,s.parent&&s.parent.removeChild(s),s[zn]&&Yn(s),typeof s.raws.before>"u"&&t&&typeof t.raws.before<"u"&&(s.raws.before=t.raws.before.replace(/\S/g,"")),s.parent=this.proxyOf,s))}prepend(...e){e=e.reverse();for(let t of e){let r=this.normalize(t,this.first,"prepend").reverse();for(let s of r)this.proxyOf.nodes.unshift(s);for(let s in this.indexes)this.indexes[s]=this.indexes[s]+r.length}return this.markDirty(),this}push(e){return e.parent=this,this.proxyOf.nodes.push(e),this}removeAll(){for(let e of this.proxyOf.nodes)e.parent=void 0;return this.proxyOf.nodes=[],this.markDirty(),this}removeChild(e){e=this.index(e),this.proxyOf.nodes[e].parent=void 0,this.proxyOf.nodes.splice(e,1);let t;for(let r in this.indexes)t=this.indexes[r],t>=e&&(this.indexes[r]=t-1);return this.markDirty(),this}replaceValues(e,t,r){return r||(r=t,t={}),this.walkDecls(s=>{t.props&&!t.props.includes(s.prop)||t.fast&&!s.value.includes(t.fast)||(s.value=s.value.replace(e,r))}),this.markDirty(),this}some(e){return this.nodes.some(e)}walk(e){return this.each((t,r)=>{let s;try{s=e(t,r)}catch(n){throw t.addToError(n)}return s!==!1&&t.walk&&(s=t.walk(e)),s})}walkAtRules(e,t){return t?e instanceof RegExp?this.walk((r,s)=>{if(r.type==="atrule"&&e.test(r.name))return t(r,s)}):this.walk((r,s)=>{if(r.type==="atrule"&&r.name===e)return t(r,s)}):(t=e,this.walk((r,s)=>{if(r.type==="atrule")return t(r,s)}))}walkComments(e){return this.walk((t,r)=>{if(t.type==="comment")return e(t,r)})}walkDecls(e,t){return t?e instanceof RegExp?this.walk((r,s)=>{if(r.type==="decl"&&e.test(r.prop))return t(r,s)}):this.walk((r,s)=>{if(r.type==="decl"&&r.prop===e)return t(r,s)}):(t=e,this.walk((r,s)=>{if(r.type==="decl")return t(r,s)}))}walkRules(e,t){return t?e instanceof RegExp?this.walk((r,s)=>{if(r.type==="rule"&&e.test(r.selector))return t(r,s)}):this.walk((r,s)=>{if(r.type==="rule"&&r.selector===e)return t(r,s)}):(t=e,this.walk((r,s)=>{if(r.type==="rule")return t(r,s)}))}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]}};Ie.registerParse=i=>{Gn=i};Ie.registerRule=i=>{Hi=i};Ie.registerAtRule=i=>{Yi=i};Ie.registerRoot=i=>{jn=i};var $e=Ie;Ie.default=Ie;Ie.rebuild=i=>{i.type==="atrule"?Object.setPrototypeOf(i,Yi.prototype):i.type==="rule"?Object.setPrototypeOf(i,Hi.prototype):i.type==="decl"?Object.setPrototypeOf(i,Wn.prototype):i.type==="comment"?Object.setPrototypeOf(i,Vn.prototype):i.type==="root"&&Object.setPrototypeOf(i,jn.prototype),i[Bn]=!0,i.nodes&&i.nodes.forEach(e=>{Ie.rebuild(e)})};var nu=$e,Xn,Jn,ft=class extends nu{constructor(e){super({type:"document",...e}),this.nodes||(this.nodes=[])}toResult(e={}){return new Xn(new Jn,this,e).stringify()}};ft.registerLazyResult=i=>{Xn=i};ft.registerProcessor=i=>{Jn=i};var Zi=ft;ft.default=ft;var Fs={},Kn=function(e){Fs[e]||(Fs[e]=!0,typeof console<"u"&&console.warn&&console.warn(e))},li=class{constructor(e,t={}){if(this.type="warning",this.text=e,t.node&&t.node.source){let r=t.node.rangeBy(t);this.line=r.start.line,this.column=r.start.column,this.endLine=r.end.line,this.endColumn=r.end.column}for(let r in t)this[r]=t[r]}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}},qn=li;li.default=li;var ou=qn,ui=class{constructor(e,t,r){this.processor=e,this.messages=[],this.root=t,this.opts=r,this.css=void 0,this.map=void 0}toString(){return this.css}warn(e,t={}){t.plugin||this.lastPlugin&&this.lastPlugin.postcssPlugin&&(t.plugin=this.lastPlugin.postcssPlugin);let r=new ou(e,t);return this.messages.push(r),r}warnings(){return this.messages.filter(e=>e.type==="warning")}get content(){return this.css}},Xi=ui;ui.default=ui;var Wr=39,Us=34,Ot=92,zs=47,Tt=10,it=32,Dt=12,kt=9,_t=13,au=91,lu=93,uu=40,cu=41,hu=123,fu=125,du=59,pu=42,mu=58,gu=64,Pt=/[\t\n\f\r "#'()/;[\\\]{}]/g,$t=/[\t\n\f\r !"#'():;@[\\\]{}]|\/(?=\*)/g,yu=/.[\r\n"'(/\\]/,Bs=/[\da-f]/i,vu=function(e,t={}){let r=e.css.valueOf(),s=t.ignoreErrors,n,o,l,a,u,c,h,p,m,g,d=r.length,f=0,S=[],w=[];function y(){return f}function b(x){throw e.error("Unclosed "+x,f)}function E(){return w.length===0&&f>=d}function M(x){if(w.length)return w.pop();if(f>=d)return;let C=x?x.ignoreUnclosed:!1;switch(n=r.charCodeAt(f),n){case Tt:case it:case kt:case _t:case Dt:{o=f;do o+=1,n=r.charCodeAt(o);while(n===it||n===Tt||n===kt||n===_t||n===Dt);g=["space",r.slice(f,o)],f=o-1;break}case au:case lu:case hu:case fu:case mu:case du:case cu:{let k=String.fromCharCode(n);g=[k,k,f];break}case uu:{if(p=S.length?S.pop()[1]:"",m=r.charCodeAt(f+1),p==="url"&&m!==Wr&&m!==Us&&m!==it&&m!==Tt&&m!==kt&&m!==Dt&&m!==_t){o=f;do{if(c=!1,o=r.indexOf(")",o+1),o===-1)if(s||C){o=f;break}else b("bracket");for(h=o;r.charCodeAt(h-1)===Ot;)h-=1,c=!c}while(c);g=["brackets",r.slice(f,o+1),f,o],f=o}else o=r.indexOf(")",f+1),a=r.slice(f,o+1),o===-1||yu.test(a)?g=["(","(",f]:(g=["brackets",a,f,o],f=o);break}case Wr:case Us:{l=n===Wr?"'":'"',o=f;do{if(c=!1,o=r.indexOf(l,o+1),o===-1)if(s||C){o=f+1;break}else b("string");for(h=o;r.charCodeAt(h-1)===Ot;)h-=1,c=!c}while(c);g=["string",r.slice(f,o+1),f,o],f=o;break}case gu:{Pt.lastIndex=f+1,Pt.test(r),Pt.lastIndex===0?o=r.length-1:o=Pt.lastIndex-2,g=["at-word",r.slice(f,o+1),f,o],f=o;break}case Ot:{for(o=f,u=!0;r.charCodeAt(o+1)===Ot;)o+=1,u=!u;if(n=r.charCodeAt(o+1),u&&n!==zs&&n!==it&&n!==Tt&&n!==kt&&n!==_t&&n!==Dt&&(o+=1,Bs.test(r.charAt(o)))){for(;Bs.test(r.charAt(o+1));)o+=1;r.charCodeAt(o+1)===it&&(o+=1)}g=["word",r.slice(f,o+1),f,o],f=o;break}default:{n===zs&&r.charCodeAt(f+1)===pu?(o=r.indexOf("*/",f+2)+1,o===0&&(s||C?o=r.length:b("comment")),g=["comment",r.slice(f,o+1),f,o],f=o):($t.lastIndex=f+1,$t.test(r),$t.lastIndex===0?o=r.length-1:o=$t.lastIndex-2,g=["word",r.slice(f,o+1),f,o],S.push(g),f=o);break}}return f++,g}function R(x){w.push(x)}return{back:R,endOfFile:E,nextToken:M,position:y}},Qn=$e,nr=class extends Qn{constructor(e){super(e),this.type="atrule"}append(...e){return this.proxyOf.nodes||(this.nodes=[]),super.append(...e)}prepend(...e){return this.proxyOf.nodes||(this.nodes=[]),super.prepend(...e)}},Ji=nr;nr.default=nr;Qn.registerAtRule(nr);var eo=$e,to,ro,je=class extends eo{constructor(e){super(e),this.type="root",this.nodes||(this.nodes=[])}normalize(e,t,r){let s=super.normalize(e);if(t){if(r==="prepend")this.nodes.length>1?t.raws.before=this.nodes[1].raws.before:delete t.raws.before;else if(this.first!==t)for(let n of s)n.raws.before=t.raws.before}return s}removeChild(e,t){let r=this.index(e);return!t&&r===0&&this.nodes.length>1&&(this.nodes[1].raws.before=this.nodes[r].raws.before),super.removeChild(e)}toResult(e={}){return new to(new ro,this,e).stringify()}};je.registerLazyResult=i=>{to=i};je.registerProcessor=i=>{ro=i};var Ct=je;je.default=je;eo.registerRoot(je);var dt={comma(i){return dt.split(i,[","],!0)},space(i){let e=[" ",`
|
|
24
|
-
`," "];return dt.split(i,e)},split(i,e,t){let r=[],s="",n=!1,o=0,l=!1,a="",u=!1;for(let c of i)u?u=!1:c==="\\"?u=!0:l?c===a&&(l=!1):c==='"'||c==="'"?(l=!0,a=c):c==="("?o+=1:c===")"?o>0&&(o-=1):o===0&&e.includes(c)&&(n=!0),n?(s!==""&&r.push(s.trim()),s="",n=!1):s+=c;return(t||s!=="")&&r.push(s.trim()),r}},io=dt;dt.default=dt;var so=$e,wu=io,or=class extends so{constructor(e){super(e),this.type="rule",this.nodes||(this.nodes=[])}get selectors(){return wu.comma(this.selector)}set selectors(e){let t=this.selector?this.selector.match(/,\s*/):null,r=t?t[0]:","+this.raw("between","beforeOpen");this.selector=e.join(r)}},Ki=or;or.default=or;so.registerRule(or);var Su=vr,bu=vu,Cu=Sr,xu=Ji,Iu=Ct,Ws=Ki,Vs={empty:!0,space:!0};function Eu(i){for(let e=i.length-1;e>=0;e--){let t=i[e],r=t[3]||t[2];if(r)return r}}var Mu=class{constructor(e){this.input=e,this.root=new Iu,this.current=this.root,this.spaces="",this.semicolon=!1,this.createTokenizer(),this.root.source={input:e,start:{column:1,line:1,offset:0}}}atrule(e){let t=new xu;t.name=e[1].slice(1),t.name===""&&this.unnamedAtrule(t,e),this.init(t,e[2]);let r,s,n,o=!1,l=!1,a=[],u=[];for(;!this.tokenizer.endOfFile();){if(e=this.tokenizer.nextToken(),r=e[0],r==="("||r==="["?u.push(r==="("?")":"]"):r==="{"&&u.length>0?u.push("}"):r===u[u.length-1]&&u.pop(),u.length===0)if(r===";"){t.source.end=this.getPosition(e[2]),t.source.end.offset++,this.semicolon=!0;break}else if(r==="{"){l=!0;break}else if(r==="}"){if(a.length>0){for(n=a.length-1,s=a[n];s&&s[0]==="space";)s=a[--n];s&&(t.source.end=this.getPosition(s[3]||s[2]),t.source.end.offset++)}this.end(e);break}else a.push(e);else a.push(e);if(this.tokenizer.endOfFile()){o=!0;break}}t.raws.between=this.spacesAndCommentsFromEnd(a),a.length?(t.raws.afterName=this.spacesAndCommentsFromStart(a),this.raw(t,"params",a),o&&(e=a[a.length-1],t.source.end=this.getPosition(e[3]||e[2]),t.source.end.offset++,this.spaces=t.raws.between,t.raws.between="")):(t.raws.afterName="",t.params=""),l&&(t.nodes=[],this.current=t)}checkMissedSemicolon(e){let t=this.colon(e);if(t===!1)return;let r=0,s;for(let n=t-1;n>=0&&(s=e[n],!(s[0]!=="space"&&(r+=1,r===2)));n--);throw this.input.error("Missed semicolon",s[0]==="word"?s[3]+1:s[2])}colon(e){let t=0,r,s,n;for(let[o,l]of e.entries()){if(r=l,s=r[0],s==="("&&(t+=1),s===")"&&(t-=1),t===0&&s===":")if(!n)this.doubleColon(r);else{if(n[0]==="word"&&n[1]==="progid")continue;return o}n=r}return!1}comment(e){let t=new Cu;this.init(t,e[2]),t.source.end=this.getPosition(e[3]||e[2]),t.source.end.offset++;let r=e[1].slice(2,-2);if(/^\s*$/.test(r))t.text="",t.raws.left=r,t.raws.right="";else{let s=r.match(/^(\s*)([^]*\S)(\s*)$/);t.text=s[2],t.raws.left=s[1],t.raws.right=s[3]}}createTokenizer(){this.tokenizer=bu(this.input)}decl(e,t){let r=new Su;this.init(r,e[0][2]);let s=e[e.length-1];for(s[0]===";"&&(this.semicolon=!0,e.pop()),r.source.end=this.getPosition(s[3]||s[2]||Eu(e)),r.source.end.offset++;e[0][0]!=="word";)e.length===1&&this.unknownWord(e),r.raws.before+=e.shift()[1];for(r.source.start=this.getPosition(e[0][2]),r.prop="";e.length;){let u=e[0][0];if(u===":"||u==="space"||u==="comment")break;r.prop+=e.shift()[1]}r.raws.between="";let n;for(;e.length;)if(n=e.shift(),n[0]===":"){r.raws.between+=n[1];break}else n[0]==="word"&&/\w/.test(n[1])&&this.unknownWord([n]),r.raws.between+=n[1];(r.prop[0]==="_"||r.prop[0]==="*")&&(r.raws.before+=r.prop[0],r.prop=r.prop.slice(1));let o=[],l;for(;e.length&&(l=e[0][0],!(l!=="space"&&l!=="comment"));)o.push(e.shift());this.precheckMissedSemicolon(e);for(let u=e.length-1;u>=0;u--){if(n=e[u],n[1].toLowerCase()==="!important"){r.important=!0;let c=this.stringFrom(e,u);c=this.spacesFromEnd(e)+c,c!==" !important"&&(r.raws.important=c);break}else if(n[1].toLowerCase()==="important"){let c=e.slice(0),h="";for(let p=u;p>0;p--){let m=c[p][0];if(h.trim().indexOf("!")===0&&m!=="space")break;h=c.pop()[1]+h}h.trim().indexOf("!")===0&&(r.important=!0,r.raws.important=h,e=c)}if(n[0]!=="space"&&n[0]!=="comment")break}e.some(u=>u[0]!=="space"&&u[0]!=="comment")&&(r.raws.between+=o.map(u=>u[1]).join(""),o=[]),this.raw(r,"value",o.concat(e),t),r.value.includes(":")&&!t&&this.checkMissedSemicolon(e)}doubleColon(e){throw this.input.error("Double colon",{offset:e[2]},{offset:e[2]+e[1].length})}emptyRule(e){let t=new Ws;this.init(t,e[2]),t.selector="",t.raws.between="",this.current=t}end(e){this.current.nodes&&this.current.nodes.length&&(this.current.raws.semicolon=this.semicolon),this.semicolon=!1,this.current.raws.after=(this.current.raws.after||"")+this.spaces,this.spaces="",this.current.parent?(this.current.source.end=this.getPosition(e[2]),this.current.source.end.offset++,this.current=this.current.parent):this.unexpectedClose(e)}endFile(){this.current.parent&&this.unclosedBlock(),this.current.nodes&&this.current.nodes.length&&(this.current.raws.semicolon=this.semicolon),this.current.raws.after=(this.current.raws.after||"")+this.spaces,this.root.source.end=this.getPosition(this.tokenizer.position())}freeSemicolon(e){if(this.spaces+=e[1],this.current.nodes){let t=this.current.nodes[this.current.nodes.length-1];t&&t.type==="rule"&&!t.raws.ownSemicolon&&(t.raws.ownSemicolon=this.spaces,this.spaces="")}}getPosition(e){let t=this.input.fromOffset(e);return{column:t.col,line:t.line,offset:e}}init(e,t){this.current.push(e),e.source={input:this.input,start:this.getPosition(t)},e.raws.before=this.spaces,this.spaces="",e.type!=="comment"&&(this.semicolon=!1)}other(e){let t=!1,r=null,s=!1,n=null,o=[],l=e[1].startsWith("--"),a=[],u=e;for(;u;){if(r=u[0],a.push(u),r==="("||r==="[")n||(n=u),o.push(r==="("?")":"]");else if(l&&s&&r==="{")n||(n=u),o.push("}");else if(o.length===0)if(r===";")if(s){this.decl(a,l);return}else break;else if(r==="{"){this.rule(a);return}else if(r==="}"){this.tokenizer.back(a.pop()),t=!0;break}else r===":"&&(s=!0);else r===o[o.length-1]&&(o.pop(),o.length===0&&(n=null));u=this.tokenizer.nextToken()}if(this.tokenizer.endOfFile()&&(t=!0),o.length>0&&this.unclosedBracket(n),t&&s){if(!l)for(;a.length&&(u=a[a.length-1][0],!(u!=="space"&&u!=="comment"));)this.tokenizer.back(a.pop());this.decl(a,l)}else this.unknownWord(a)}parse(){let e;for(;!this.tokenizer.endOfFile();)switch(e=this.tokenizer.nextToken(),e[0]){case"space":this.spaces+=e[1];break;case";":this.freeSemicolon(e);break;case"}":this.end(e);break;case"comment":this.comment(e);break;case"at-word":this.atrule(e);break;case"{":this.emptyRule(e);break;default:this.other(e);break}this.endFile()}precheckMissedSemicolon(){}raw(e,t,r,s){let n,o,l=r.length,a="",u=!0,c,h;for(let p=0;p<l;p+=1)n=r[p],o=n[0],o==="space"&&p===l-1&&!s?u=!1:o==="comment"?(h=r[p-1]?r[p-1][0]:"empty",c=r[p+1]?r[p+1][0]:"empty",!Vs[h]&&!Vs[c]?a.slice(-1)===","?u=!1:a+=n[1]:u=!1):a+=n[1];if(!u){let p=r.reduce((m,g)=>m+g[1],"");e.raws[t]={raw:p,value:a}}e[t]=a}rule(e){e.pop();let t=new Ws;this.init(t,e[0][2]),t.raws.between=this.spacesAndCommentsFromEnd(e),this.raw(t,"selector",e),this.current=t}spacesAndCommentsFromEnd(e){let t,r="";for(;e.length&&(t=e[e.length-1][0],!(t!=="space"&&t!=="comment"));)r=e.pop()[1]+r;return r}spacesAndCommentsFromStart(e){let t,r="";for(;e.length&&(t=e[0][0],!(t!=="space"&&t!=="comment"));)r+=e.shift()[1];return r}spacesFromEnd(e){let t,r="";for(;e.length&&(t=e[e.length-1][0],t==="space");)r=e.pop()[1]+r;return r}stringFrom(e,t){let r="";for(let s=t;s<e.length;s++)r+=e[s][1];return e.splice(t,e.length-t),r}unclosedBlock(){let e=this.current.source.start;throw this.input.error("Unclosed block",e.line,e.column)}unclosedBracket(e){throw this.input.error("Unclosed bracket",{offset:e[2]},{offset:e[2]+1})}unexpectedClose(e){throw this.input.error("Unexpected }",{offset:e[2]},{offset:e[2]+1})}unknownWord(e){throw this.input.error("Unknown word",{offset:e[0][2]},{offset:e[0][2]+e[0][1].length})}unnamedAtrule(e,t){throw this.input.error("At-rule without name",{offset:t[2]},{offset:t[2]+t[1].length})}},Nu=Mu,Au=$e,Ru=Nu,Ou=wr;function ar(i,e){let t=new Ou(i,e),r=new Ru(t);try{r.parse()}catch(s){throw process.env.NODE_ENV!=="production"&&s.name==="CssSyntaxError"&&e&&e.from&&(/\.scss$/i.test(e.from)?s.message+=`
|
|
25
|
-
You tried to parse SCSS with the standard CSS parser; try again with the postcss-scss parser`:/\.sass/i.test(e.from)?s.message+=`
|
|
26
|
-
You tried to parse Sass with the standard CSS parser; try again with the postcss-sass parser`:/\.less$/i.test(e.from)&&(s.message+=`
|
|
27
|
-
You tried to parse Less with the standard CSS parser; try again with the postcss-less parser`)),s}return r.root}var qi=ar;ar.default=ar;Au.registerParse(ar);var{isClean:we,my:Tu}=bt,Du=Un,ku=gr,_u=$e,Pu=Zi,$u=Kn,Gs=Xi,Lu=qi,Fu=Ct,Uu={atrule:"AtRule",comment:"Comment",decl:"Declaration",document:"Document",root:"Root",rule:"Rule"},zu={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},Bu={Once:!0,postcssPlugin:!0,prepare:!0},He=0;function st(i){return typeof i=="object"&&typeof i.then=="function"}function no(i){let e=!1,t=Uu[i.type];return i.type==="decl"?e=i.prop.toLowerCase():i.type==="atrule"&&(e=i.name.toLowerCase()),e&&i.append?[t,t+"-"+e,He,t+"Exit",t+"Exit-"+e]:e?[t,t+"-"+e,t+"Exit",t+"Exit-"+e]:i.append?[t,He,t+"Exit"]:[t,t+"Exit"]}function js(i){let e;return i.type==="document"?e=["Document",He,"DocumentExit"]:i.type==="root"?e=["Root",He,"RootExit"]:e=no(i),{eventIndex:0,events:e,iterator:0,node:i,visitorIndex:0,visitors:[]}}function ci(i){return i[we]=!1,i.nodes&&i.nodes.forEach(e=>ci(e)),i}var hi={},Ye=class oo{constructor(e,t,r){this.stringified=!1,this.processed=!1;let s;if(typeof t=="object"&&t!==null&&(t.type==="root"||t.type==="document"))s=ci(t);else if(t instanceof oo||t instanceof Gs)s=ci(t.root),t.map&&(typeof r.map>"u"&&(r.map={}),r.map.inline||(r.map.inline=!1),r.map.prev=t.map);else{let n=Lu;r.syntax&&(n=r.syntax.parse),r.parser&&(n=r.parser),n.parse&&(n=n.parse);try{s=n(t,r)}catch(o){this.processed=!0,this.error=o}s&&!s[Tu]&&_u.rebuild(s)}this.result=new Gs(e,s,r),this.helpers={...hi,postcss:hi,result:this.result},this.plugins=this.processor.plugins.map(n=>typeof n=="object"&&n.prepare?{...n,...n.prepare(this.result)}:n)}async(){return this.error?Promise.reject(this.error):this.processed?Promise.resolve(this.result):(this.processing||(this.processing=this.runAsync()),this.processing)}catch(e){return this.async().catch(e)}finally(e){return this.async().then(e,e)}getAsyncError(){throw new Error("Use process(css).then(cb) to work with async plugins")}handleError(e,t){let r=this.result.lastPlugin;try{if(t&&t.addToError(e),this.error=e,e.name==="CssSyntaxError"&&!e.plugin)e.plugin=r.postcssPlugin,e.setMessage();else if(r.postcssVersion&&process.env.NODE_ENV!=="production"){let s=r.postcssPlugin,n=r.postcssVersion,o=this.result.processor.version,l=n.split("."),a=o.split(".");(l[0]!==a[0]||parseInt(l[1])>parseInt(a[1]))&&console.error("Unknown error from PostCSS plugin. Your current PostCSS version is "+o+", but "+s+" uses "+n+". Perhaps this is the source of the error below.")}}catch(s){console&&console.error&&console.error(s)}return e}prepareVisitors(){this.listeners={};let e=(t,r,s)=>{this.listeners[r]||(this.listeners[r]=[]),this.listeners[r].push([t,s])};for(let t of this.plugins)if(typeof t=="object")for(let r in t){if(!zu[r]&&/^[A-Z]/.test(r))throw new Error(`Unknown event ${r} in ${t.postcssPlugin}. Try to update PostCSS (${this.processor.version} now).`);if(!Bu[r])if(typeof t[r]=="object")for(let s in t[r])s==="*"?e(t,r,t[r][s]):e(t,r+"-"+s.toLowerCase(),t[r][s]);else typeof t[r]=="function"&&e(t,r,t[r])}this.hasListener=Object.keys(this.listeners).length>0}async runAsync(){this.plugin=0;for(let e=0;e<this.plugins.length;e++){let t=this.plugins[e],r=this.runOnRoot(t);if(st(r))try{await r}catch(s){throw this.handleError(s)}}if(this.prepareVisitors(),this.hasListener){let e=this.result.root;for(;!e[we];){e[we]=!0;let t=[js(e)];for(;t.length>0;){let r=this.visitTick(t);if(st(r))try{await r}catch(s){let n=t[t.length-1].node;throw this.handleError(s,n)}}}if(this.listeners.OnceExit)for(let[t,r]of this.listeners.OnceExit){this.result.lastPlugin=t;try{if(e.type==="document"){let s=e.nodes.map(n=>r(n,this.helpers));await Promise.all(s)}else await r(e,this.helpers)}catch(s){throw this.handleError(s)}}}return this.processed=!0,this.stringify()}runOnRoot(e){this.result.lastPlugin=e;try{if(typeof e=="object"&&e.Once){if(this.result.root.type==="document"){let t=this.result.root.nodes.map(r=>e.Once(r,this.helpers));return st(t[0])?Promise.all(t):t}return e.Once(this.result.root,this.helpers)}else if(typeof e=="function")return e(this.result.root,this.result)}catch(t){throw this.handleError(t)}}stringify(){if(this.error)throw this.error;if(this.stringified)return this.result;this.stringified=!0,this.sync();let e=this.result.opts,t=ku;e.syntax&&(t=e.syntax.stringify),e.stringifier&&(t=e.stringifier),t.stringify&&(t=t.stringify);let s=new Du(t,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 e of this.plugins){let t=this.runOnRoot(e);if(st(t))throw this.getAsyncError()}if(this.prepareVisitors(),this.hasListener){let e=this.result.root;for(;!e[we];)e[we]=!0,this.walkSync(e);if(this.listeners.OnceExit)if(e.type==="document")for(let t of e.nodes)this.visitSync(this.listeners.OnceExit,t);else this.visitSync(this.listeners.OnceExit,e)}return this.result}then(e,t){return process.env.NODE_ENV!=="production"&&("from"in this.opts||$u("Without `from` option PostCSS could generate wrong source map and will not find Browserslist config. Set it to CSS file path or to `undefined` to prevent this warning.")),this.async().then(e,t)}toString(){return this.css}visitSync(e,t){for(let[r,s]of e){this.result.lastPlugin=r;let n;try{n=s(t,this.helpers)}catch(o){throw this.handleError(o,t.proxyOf)}if(t.type!=="root"&&t.type!=="document"&&!t.parent)return!0;if(st(n))throw this.getAsyncError()}}visitTick(e){let t=e[e.length-1],{node:r,visitors:s}=t;if(r.type!=="root"&&r.type!=="document"&&!r.parent){e.pop();return}if(s.length>0&&t.visitorIndex<s.length){let[o,l]=s[t.visitorIndex];t.visitorIndex+=1,t.visitorIndex===s.length&&(t.visitors=[],t.visitorIndex=0),this.result.lastPlugin=o;try{return l(r.toProxy(),this.helpers)}catch(a){throw this.handleError(a,r)}}if(t.iterator!==0){let o=t.iterator,l;for(;l=r.nodes[r.indexes[o]];)if(r.indexes[o]+=1,!l[we]){l[we]=!0,e.push(js(l));return}t.iterator=0,delete r.indexes[o]}let n=t.events;for(;t.eventIndex<n.length;){let o=n[t.eventIndex];if(t.eventIndex+=1,o===He){r.nodes&&r.nodes.length&&(r[we]=!0,t.iterator=r.getIterator());return}else if(this.listeners[o]){t.visitors=this.listeners[o];return}}e.pop()}walkSync(e){e[we]=!0;let t=no(e);for(let r of t)if(r===He)e.nodes&&e.each(s=>{s[we]||this.walkSync(s)});else{let s=this.listeners[r];if(s&&this.visitSync(s,e.toProxy()))return}}warnings(){return this.sync().warnings()}get content(){return this.stringify().content}get css(){return this.stringify().css}get map(){return this.stringify().map}get messages(){return this.sync().messages}get opts(){return this.result.opts}get processor(){return this.result.processor}get root(){return this.sync().root}get[Symbol.toStringTag](){return"LazyResult"}};Ye.registerPostcss=i=>{hi=i};var ao=Ye;Ye.default=Ye;Fu.registerLazyResult(Ye);Pu.registerLazyResult(Ye);var Wu=Un,Vu=gr,Gu=Kn,ju=qi,Hu=Xi,fi=class{constructor(e,t,r){t=t.toString(),this.stringified=!1,this._processor=e,this._css=t,this._opts=r,this._map=void 0;let s,n=Vu;this.result=new Hu(this._processor,s,this._opts),this.result.css=t;let o=this;Object.defineProperty(this.result,"root",{get(){return o.root}});let l=new Wu(n,s,this._opts,t);if(l.isMap()){let[a,u]=l.generate();a&&(this.result.css=a),u&&(this.result.map=u)}else l.clearAnnotation(),this.result.css=l.css}async(){return this.error?Promise.reject(this.error):Promise.resolve(this.result)}catch(e){return this.async().catch(e)}finally(e){return this.async().then(e,e)}sync(){if(this.error)throw this.error;return this.result}then(e,t){return process.env.NODE_ENV!=="production"&&("from"in this._opts||Gu("Without `from` option PostCSS could generate wrong source map and will not find Browserslist config. Set it to CSS file path or to `undefined` to prevent this warning.")),this.async().then(e,t)}toString(){return this._css}warnings(){return[]}get content(){return this.result.css}get css(){return this.result.css}get map(){return this.result.map}get messages(){return[]}get opts(){return this.result.opts}get processor(){return this.result.processor}get root(){if(this._root)return this._root;let e,t=ju;try{e=t(this._css,this._opts)}catch(r){this.error=r}if(this.error)throw this.error;return this._root=e,e}get[Symbol.toStringTag](){return"NoWorkResult"}},Yu=fi;fi.default=fi;var Zu=Yu,Xu=ao,Ju=Zi,Ku=Ct,pt=class{constructor(e=[]){this.version="8.4.38",this.plugins=this.normalize(e)}normalize(e){let t=[];for(let r of e)if(r.postcss===!0?r=r():r.postcss&&(r=r.postcss),typeof r=="object"&&Array.isArray(r.plugins))t=t.concat(r.plugins);else if(typeof r=="object"&&r.postcssPlugin)t.push(r);else if(typeof r=="function")t.push(r);else if(typeof r=="object"&&(r.parse||r.stringify)){if(process.env.NODE_ENV!=="production")throw new Error("PostCSS syntaxes cannot be used as plugins. Instead, please use one of the syntax/parser/stringifier options as outlined in your PostCSS runner documentation.")}else throw new Error(r+" is not a PostCSS plugin");return t}process(e,t={}){return!this.plugins.length&&!t.parser&&!t.stringifier&&!t.syntax?new Zu(this,e,t):new Xu(this,e,t)}use(e){return this.plugins=this.plugins.concat(this.normalize([e])),this}},qu=pt;pt.default=pt;Ku.registerProcessor(pt);Ju.registerProcessor(pt);var Qu=vr,ec=_n,tc=Sr,rc=Ji,ic=wr,sc=Ct,nc=Ki;function mt(i,e){if(Array.isArray(i))return i.map(s=>mt(s));let{inputs:t,...r}=i;if(t){e=[];for(let s of t){let n={...s,__proto__:ic.prototype};n.map&&(n.map={...n.map,__proto__:ec.prototype}),e.push(n)}}if(r.nodes&&(r.nodes=i.nodes.map(s=>mt(s,e))),r.source){let{inputId:s,...n}=r.source;r.source=n,s!=null&&(r.source.input=e[s])}if(r.type==="root")return new sc(r);if(r.type==="decl")return new Qu(r);if(r.type==="rule")return new nc(r);if(r.type==="comment")return new tc(r);if(r.type==="atrule")return new rc(r);throw new Error("Unknown node type: "+i.type)}var oc=mt;mt.default=mt;var ac=ji,lo=vr,lc=ao,uc=$e,Qi=qu,cc=gr,hc=oc,uo=Zi,fc=qn,co=Sr,ho=Ji,dc=Xi,pc=wr,mc=qi,gc=io,fo=Ki,po=Ct,yc=yr;function U(...i){return i.length===1&&Array.isArray(i[0])&&(i=i[0]),new Qi(i)}U.plugin=function(e,t){let r=!1;function s(...o){console&&console.warn&&!r&&(r=!0,console.warn(e+`: postcss.plugin was deprecated. Migration guide:
|
|
22
|
+
`),this.css+=t+"/*# sourceMappingURL="+e+" */"}applyPrevMaps(){for(let e of this.previous()){let t=this.toUrl(this.path(e.file)),r=e.root||Jt(e.file),s;this.mapOpts.sourcesContent===!1?(s=new kn(e.text),s.sourcesContent&&(s.sourcesContent=null)):s=e.consumer(),this.map.applySourceMap(s,t,this.toUrl(this.path(r)))}}clearAnnotation(){if(this.mapOpts.annotation!==!1)if(this.root){let e;for(let t=this.root.nodes.length-1;t>=0;t--)e=this.root.nodes[t],e.type==="comment"&&e.text.indexOf("# sourceMappingURL=")===0&&this.root.removeChild(t)}else this.css&&(this.css=this.css.replace(/\n*?\/\*#[\S\s]*?\*\/$/gm,""))}generate(){if(this.clearAnnotation(),Zl&&Yl&&this.isMap())return this.generateMap();{let e="";return this.stringify(this.root,t=>{e+=t}),[e]}}generateMap(){if(this.root)this.generateString();else if(this.previous().length===1){let e=this.previous()[0].consumer();e.file=this.outputFile(),this.map=Xt.fromSourceMap(e,{ignoreInvalidMapping:!0})}else this.map=new Xt({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 Xt({file:this.outputFile(),ignoreInvalidMapping:!0});let e=1,t=1,r="<no source>",s={generated:{column:0,line:0},original:{column:0,line:0},source:""},n,o;this.stringify(this.root,(l,a,u)=>{if(this.css+=l,a&&u!=="end"&&(s.generated.line=e,s.generated.column=t-1,a.source&&a.source.start?(s.source=this.sourcePath(a),s.original.line=a.source.start.line,s.original.column=a.source.start.column-1,this.map.addMapping(s)):(s.source=r,s.original.line=1,s.original.column=0,this.map.addMapping(s))),n=l.match(/\n/g),n?(e+=n.length,o=l.lastIndexOf(`
|
|
23
|
+
`),t=l.length-o):t+=l.length,a&&u!=="start"){let c=a.parent||{raws:{}};(!(a.type==="decl"||a.type==="atrule"&&!a.nodes)||a!==c.last||c.raws.semicolon)&&(a.source&&a.source.end?(s.source=this.sourcePath(a),s.original.line=a.source.end.line,s.original.column=a.source.end.column-1,s.generated.line=e,s.generated.column=t-2,this.map.addMapping(s)):(s.source=r,s.original.line=1,s.original.column=0,s.generated.line=e,s.generated.column=t-1,this.map.addMapping(s)))}})}isAnnotation(){return this.isInline()?!0:typeof this.mapOpts.annotation<"u"?this.mapOpts.annotation:this.previous().length?this.previous().some(e=>e.annotation):!0}isInline(){if(typeof this.mapOpts.inline<"u")return this.mapOpts.inline;let e=this.mapOpts.annotation;return typeof e<"u"&&e!==!0?!1:this.previous().length?this.previous().some(t=>t.inline):!0}isMap(){return typeof this.opts.map<"u"?!!this.opts.map:this.previous().length>0}isSourcesContent(){return typeof this.mapOpts.sourcesContent<"u"?this.mapOpts.sourcesContent:this.previous().length?this.previous().some(e=>e.withContent()):!0}outputFile(){return this.opts.to?this.path(this.opts.to):this.opts.from?this.path(this.opts.from):"to.css"}path(e){if(this.mapOpts.absolute||e.charCodeAt(0)===60||/^\w+:\/\//.test(e))return e;let t=this.memoizedPaths.get(e);if(t)return t;let r=this.opts.to?Jt(this.opts.to):".";typeof this.mapOpts.annotation=="string"&&(r=Jt(_n(r,this.mapOpts.annotation)));let s=$n(r,e);return this.memoizedPaths.set(e,s),s}previous(){if(!this.previousMaps)if(this.previousMaps=[],this.root)this.root.walk(e=>{if(e.source&&e.source.input.map){let t=e.source.input.map;this.previousMaps.includes(t)||this.previousMaps.push(t)}});else{let e=new Hl(this.originalCSS,this.opts);e.map&&this.previousMaps.push(e.map)}return this.previousMaps}setSourcesContent(){let e={};if(this.root)this.root.walk(t=>{if(t.source){let r=t.source.input.from;if(r&&!e[r]){e[r]=!0;let s=this.usesFileUrls?this.toFileUrl(r):this.toUrl(this.path(r));this.map.setSourceContent(s,t.source.input.css)}}});else if(this.css){let t=this.opts.from?this.toUrl(this.path(this.opts.from)):"<no source>";this.map.setSourceContent(t,this.css)}}sourcePath(e){return this.mapOpts.from?this.toUrl(this.mapOpts.from):this.usesFileUrls?this.toFileUrl(e.source.input.from):this.toUrl(this.path(e.source.input.from))}toBase64(e){return Buffer?Buffer.from(e).toString("base64"):window.btoa(unescape(encodeURIComponent(e)))}toFileUrl(e){let t=this.memoizedFileURLs.get(e);if(t)return t;if(Ls){let r=Ls(e).toString();return this.memoizedFileURLs.set(e,r),r}else throw new Error("`map.absolute` option is not available in this PostCSS build")}toUrl(e){let t=this.memoizedURLs.get(e);if(t)return t;Pn==="\\"&&(e=e.replace(/\\/g,"/"));let r=encodeURI(e).replace(/[#?]/g,encodeURIComponent);return this.memoizedURLs.set(e,r),r}},Ln=Xl,Jl=yr,ai=class extends Jl{constructor(e){super(e),this.type="comment"}},Sr=ai;ai.default=ai;var{isClean:Fn,my:Un}=bt,zn=vr,Bn=Sr,Kl=yr,Wn,Hi,Yi,Vn;function Gn(i){return i.map(e=>(e.nodes&&(e.nodes=Gn(e.nodes)),delete e.source,e))}function jn(i){if(i[Fn]=!1,i.proxyOf.nodes)for(let e of i.proxyOf.nodes)jn(e)}var Ee=class Hn extends Kl{append(...e){for(let t of e){let r=this.normalize(t,this.last);for(let s of r)this.proxyOf.nodes.push(s)}return this.markDirty(),this}cleanRaws(e){if(super.cleanRaws(e),this.nodes)for(let t of this.nodes)t.cleanRaws(e)}each(e){if(!this.proxyOf.nodes)return;let t=this.getIterator(),r,s;for(;this.indexes[t]<this.proxyOf.nodes.length&&(r=this.indexes[t],s=e(this.proxyOf.nodes[r],r),s!==!1);)this.indexes[t]+=1;return delete this.indexes[t],s}every(e){return this.nodes.every(e)}getIterator(){this.lastEach||(this.lastEach=0),this.indexes||(this.indexes={}),this.lastEach+=1;let e=this.lastEach;return this.indexes[e]=0,e}getProxyProcessor(){return{get(e,t){return t==="proxyOf"?e:e[t]?t==="each"||typeof t=="string"&&t.startsWith("walk")?(...r)=>e[t](...r.map(s=>typeof s=="function"?(n,o)=>s(n.toProxy(),o):s)):t==="every"||t==="some"?r=>e[t]((s,...n)=>r(s.toProxy(),...n)):t==="root"?()=>e.root().toProxy():t==="nodes"?e.nodes.map(r=>r.toProxy()):t==="first"||t==="last"?e[t].toProxy():e[t]:e[t]},set(e,t,r){return e[t]===r||(e[t]=r,(t==="name"||t==="params"||t==="selector")&&e.markDirty()),!0}}}index(e){return typeof e=="number"?e:(e.proxyOf&&(e=e.proxyOf),this.proxyOf.nodes.indexOf(e))}insertAfter(e,t){let r=this.index(e),s=this.normalize(t,this.proxyOf.nodes[r]).reverse();r=this.index(e);for(let o of s)this.proxyOf.nodes.splice(r+1,0,o);let n;for(let o in this.indexes)n=this.indexes[o],r<n&&(this.indexes[o]=n+s.length);return this.markDirty(),this}insertBefore(e,t){let r=this.index(e),s=r===0?"prepend":!1,n=this.normalize(t,this.proxyOf.nodes[r],s).reverse();r=this.index(e);for(let l of n)this.proxyOf.nodes.splice(r,0,l);let o;for(let l in this.indexes)o=this.indexes[l],r<=o&&(this.indexes[l]=o+n.length);return this.markDirty(),this}normalize(e,t){if(typeof e=="string")e=Gn(Wn(e).nodes);else if(typeof e>"u")e=[];else if(Array.isArray(e)){e=e.slice(0);for(let s of e)s.parent&&s.parent.removeChild(s,"ignore")}else if(e.type==="root"&&this.type!=="document"){e=e.nodes.slice(0);for(let s of e)s.parent&&s.parent.removeChild(s,"ignore")}else if(e.type)e=[e];else if(e.prop){if(typeof e.value>"u")throw new Error("Value field is missed in node creation");typeof e.value!="string"&&(e.value=String(e.value)),e=[new zn(e)]}else if(e.selector)e=[new Hi(e)];else if(e.name)e=[new Yi(e)];else if(e.text)e=[new Bn(e)];else throw new Error("Unknown node type in node creation");return e.map(s=>(s[Un]||Hn.rebuild(s),s=s.proxyOf,s.parent&&s.parent.removeChild(s),s[Fn]&&jn(s),typeof s.raws.before>"u"&&t&&typeof t.raws.before<"u"&&(s.raws.before=t.raws.before.replace(/\S/g,"")),s.parent=this.proxyOf,s))}prepend(...e){e=e.reverse();for(let t of e){let r=this.normalize(t,this.first,"prepend").reverse();for(let s of r)this.proxyOf.nodes.unshift(s);for(let s in this.indexes)this.indexes[s]=this.indexes[s]+r.length}return this.markDirty(),this}push(e){return e.parent=this,this.proxyOf.nodes.push(e),this}removeAll(){for(let e of this.proxyOf.nodes)e.parent=void 0;return this.proxyOf.nodes=[],this.markDirty(),this}removeChild(e){e=this.index(e),this.proxyOf.nodes[e].parent=void 0,this.proxyOf.nodes.splice(e,1);let t;for(let r in this.indexes)t=this.indexes[r],t>=e&&(this.indexes[r]=t-1);return this.markDirty(),this}replaceValues(e,t,r){return r||(r=t,t={}),this.walkDecls(s=>{t.props&&!t.props.includes(s.prop)||t.fast&&!s.value.includes(t.fast)||(s.value=s.value.replace(e,r))}),this.markDirty(),this}some(e){return this.nodes.some(e)}walk(e){return this.each((t,r)=>{let s;try{s=e(t,r)}catch(n){throw t.addToError(n)}return s!==!1&&t.walk&&(s=t.walk(e)),s})}walkAtRules(e,t){return t?e instanceof RegExp?this.walk((r,s)=>{if(r.type==="atrule"&&e.test(r.name))return t(r,s)}):this.walk((r,s)=>{if(r.type==="atrule"&&r.name===e)return t(r,s)}):(t=e,this.walk((r,s)=>{if(r.type==="atrule")return t(r,s)}))}walkComments(e){return this.walk((t,r)=>{if(t.type==="comment")return e(t,r)})}walkDecls(e,t){return t?e instanceof RegExp?this.walk((r,s)=>{if(r.type==="decl"&&e.test(r.prop))return t(r,s)}):this.walk((r,s)=>{if(r.type==="decl"&&r.prop===e)return t(r,s)}):(t=e,this.walk((r,s)=>{if(r.type==="decl")return t(r,s)}))}walkRules(e,t){return t?e instanceof RegExp?this.walk((r,s)=>{if(r.type==="rule"&&e.test(r.selector))return t(r,s)}):this.walk((r,s)=>{if(r.type==="rule"&&r.selector===e)return t(r,s)}):(t=e,this.walk((r,s)=>{if(r.type==="rule")return t(r,s)}))}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]}};Ee.registerParse=i=>{Wn=i};Ee.registerRule=i=>{Hi=i};Ee.registerAtRule=i=>{Yi=i};Ee.registerRoot=i=>{Vn=i};var Pe=Ee;Ee.default=Ee;Ee.rebuild=i=>{i.type==="atrule"?Object.setPrototypeOf(i,Yi.prototype):i.type==="rule"?Object.setPrototypeOf(i,Hi.prototype):i.type==="decl"?Object.setPrototypeOf(i,zn.prototype):i.type==="comment"?Object.setPrototypeOf(i,Bn.prototype):i.type==="root"&&Object.setPrototypeOf(i,Vn.prototype),i[Un]=!0,i.nodes&&i.nodes.forEach(e=>{Ee.rebuild(e)})};var ql=Pe,Yn,Zn,ft=class extends ql{constructor(e){super({type:"document",...e}),this.nodes||(this.nodes=[])}toResult(e={}){return new Yn(new Zn,this,e).stringify()}};ft.registerLazyResult=i=>{Yn=i};ft.registerProcessor=i=>{Zn=i};var Zi=ft;ft.default=ft;var li=class{constructor(e,t={}){if(this.type="warning",this.text=e,t.node&&t.node.source){let r=t.node.rangeBy(t);this.line=r.start.line,this.column=r.start.column,this.endLine=r.end.line,this.endColumn=r.end.column}for(let r in t)this[r]=t[r]}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}},Xn=li;li.default=li;var Ql=Xn,ui=class{constructor(e,t,r){this.processor=e,this.messages=[],this.root=t,this.opts=r,this.css=void 0,this.map=void 0}toString(){return this.css}warn(e,t={}){t.plugin||this.lastPlugin&&this.lastPlugin.postcssPlugin&&(t.plugin=this.lastPlugin.postcssPlugin);let r=new Ql(e,t);return this.messages.push(r),r}warnings(){return this.messages.filter(e=>e.type==="warning")}get content(){return this.css}},Xi=ui;ui.default=ui;var Wr=39,Fs=34,Ot=92,Us=47,Tt=10,it=32,Dt=12,kt=9,$t=13,eu=91,tu=93,ru=40,iu=41,su=123,nu=125,ou=59,au=42,lu=58,uu=64,_t=/[\t\n\f\r "#'()/;[\\\]{}]/g,Pt=/[\t\n\f\r !"#'():;@[\\\]{}]|\/(?=\*)/g,cu=/.[\r\n"'(/\\]/,zs=/[\da-f]/i,hu=function(e,t={}){let r=e.css.valueOf(),s=t.ignoreErrors,n,o,l,a,u,c,h,d,m,g,p=r.length,f=0,S=[],w=[];function y(){return f}function b(x){throw e.error("Unclosed "+x,f)}function I(){return w.length===0&&f>=p}function M(x){if(w.length)return w.pop();if(f>=p)return;let C=x?x.ignoreUnclosed:!1;switch(n=r.charCodeAt(f),n){case Tt:case it:case kt:case $t:case Dt:{o=f;do o+=1,n=r.charCodeAt(o);while(n===it||n===Tt||n===kt||n===$t||n===Dt);g=["space",r.slice(f,o)],f=o-1;break}case eu:case tu:case su:case nu:case lu:case ou:case iu:{let k=String.fromCharCode(n);g=[k,k,f];break}case ru:{if(d=S.length?S.pop()[1]:"",m=r.charCodeAt(f+1),d==="url"&&m!==Wr&&m!==Fs&&m!==it&&m!==Tt&&m!==kt&&m!==Dt&&m!==$t){o=f;do{if(c=!1,o=r.indexOf(")",o+1),o===-1)if(s||C){o=f;break}else b("bracket");for(h=o;r.charCodeAt(h-1)===Ot;)h-=1,c=!c}while(c);g=["brackets",r.slice(f,o+1),f,o],f=o}else o=r.indexOf(")",f+1),a=r.slice(f,o+1),o===-1||cu.test(a)?g=["(","(",f]:(g=["brackets",a,f,o],f=o);break}case Wr:case Fs:{l=n===Wr?"'":'"',o=f;do{if(c=!1,o=r.indexOf(l,o+1),o===-1)if(s||C){o=f+1;break}else b("string");for(h=o;r.charCodeAt(h-1)===Ot;)h-=1,c=!c}while(c);g=["string",r.slice(f,o+1),f,o],f=o;break}case uu:{_t.lastIndex=f+1,_t.test(r),_t.lastIndex===0?o=r.length-1:o=_t.lastIndex-2,g=["at-word",r.slice(f,o+1),f,o],f=o;break}case Ot:{for(o=f,u=!0;r.charCodeAt(o+1)===Ot;)o+=1,u=!u;if(n=r.charCodeAt(o+1),u&&n!==Us&&n!==it&&n!==Tt&&n!==kt&&n!==$t&&n!==Dt&&(o+=1,zs.test(r.charAt(o)))){for(;zs.test(r.charAt(o+1));)o+=1;r.charCodeAt(o+1)===it&&(o+=1)}g=["word",r.slice(f,o+1),f,o],f=o;break}default:{n===Us&&r.charCodeAt(f+1)===au?(o=r.indexOf("*/",f+2)+1,o===0&&(s||C?o=r.length:b("comment")),g=["comment",r.slice(f,o+1),f,o],f=o):(Pt.lastIndex=f+1,Pt.test(r),Pt.lastIndex===0?o=r.length-1:o=Pt.lastIndex-2,g=["word",r.slice(f,o+1),f,o],S.push(g),f=o);break}}return f++,g}function R(x){w.push(x)}return{back:R,endOfFile:I,nextToken:M,position:y}},Jn=Pe,nr=class extends Jn{constructor(e){super(e),this.type="atrule"}append(...e){return this.proxyOf.nodes||(this.nodes=[]),super.append(...e)}prepend(...e){return this.proxyOf.nodes||(this.nodes=[]),super.prepend(...e)}},Ji=nr;nr.default=nr;Jn.registerAtRule(nr);var Kn=Pe,qn,Qn,je=class extends Kn{constructor(e){super(e),this.type="root",this.nodes||(this.nodes=[])}normalize(e,t,r){let s=super.normalize(e);if(t){if(r==="prepend")this.nodes.length>1?t.raws.before=this.nodes[1].raws.before:delete t.raws.before;else if(this.first!==t)for(let n of s)n.raws.before=t.raws.before}return s}removeChild(e,t){let r=this.index(e);return!t&&r===0&&this.nodes.length>1&&(this.nodes[1].raws.before=this.nodes[r].raws.before),super.removeChild(e)}toResult(e={}){return new qn(new Qn,this,e).stringify()}};je.registerLazyResult=i=>{qn=i};je.registerProcessor=i=>{Qn=i};var Ct=je;je.default=je;Kn.registerRoot(je);var pt={comma(i){return pt.split(i,[","],!0)},space(i){let e=[" ",`
|
|
24
|
+
`," "];return pt.split(i,e)},split(i,e,t){let r=[],s="",n=!1,o=0,l=!1,a="",u=!1;for(let c of i)u?u=!1:c==="\\"?u=!0:l?c===a&&(l=!1):c==='"'||c==="'"?(l=!0,a=c):c==="("?o+=1:c===")"?o>0&&(o-=1):o===0&&e.includes(c)&&(n=!0),n?(s!==""&&r.push(s.trim()),s="",n=!1):s+=c;return(t||s!=="")&&r.push(s.trim()),r}},eo=pt;pt.default=pt;var to=Pe,fu=eo,or=class extends to{constructor(e){super(e),this.type="rule",this.nodes||(this.nodes=[])}get selectors(){return fu.comma(this.selector)}set selectors(e){let t=this.selector?this.selector.match(/,\s*/):null,r=t?t[0]:","+this.raw("between","beforeOpen");this.selector=e.join(r)}},Ki=or;or.default=or;to.registerRule(or);var pu=vr,du=hu,mu=Sr,gu=Ji,yu=Ct,Bs=Ki,Ws={empty:!0,space:!0};function vu(i){for(let e=i.length-1;e>=0;e--){let t=i[e],r=t[3]||t[2];if(r)return r}}var wu=class{constructor(e){this.input=e,this.root=new yu,this.current=this.root,this.spaces="",this.semicolon=!1,this.createTokenizer(),this.root.source={input:e,start:{column:1,line:1,offset:0}}}atrule(e){let t=new gu;t.name=e[1].slice(1),t.name===""&&this.unnamedAtrule(t,e),this.init(t,e[2]);let r,s,n,o=!1,l=!1,a=[],u=[];for(;!this.tokenizer.endOfFile();){if(e=this.tokenizer.nextToken(),r=e[0],r==="("||r==="["?u.push(r==="("?")":"]"):r==="{"&&u.length>0?u.push("}"):r===u[u.length-1]&&u.pop(),u.length===0)if(r===";"){t.source.end=this.getPosition(e[2]),t.source.end.offset++,this.semicolon=!0;break}else if(r==="{"){l=!0;break}else if(r==="}"){if(a.length>0){for(n=a.length-1,s=a[n];s&&s[0]==="space";)s=a[--n];s&&(t.source.end=this.getPosition(s[3]||s[2]),t.source.end.offset++)}this.end(e);break}else a.push(e);else a.push(e);if(this.tokenizer.endOfFile()){o=!0;break}}t.raws.between=this.spacesAndCommentsFromEnd(a),a.length?(t.raws.afterName=this.spacesAndCommentsFromStart(a),this.raw(t,"params",a),o&&(e=a[a.length-1],t.source.end=this.getPosition(e[3]||e[2]),t.source.end.offset++,this.spaces=t.raws.between,t.raws.between="")):(t.raws.afterName="",t.params=""),l&&(t.nodes=[],this.current=t)}checkMissedSemicolon(e){let t=this.colon(e);if(t===!1)return;let r=0,s;for(let n=t-1;n>=0&&(s=e[n],!(s[0]!=="space"&&(r+=1,r===2)));n--);throw this.input.error("Missed semicolon",s[0]==="word"?s[3]+1:s[2])}colon(e){let t=0,r,s,n;for(let[o,l]of e.entries()){if(r=l,s=r[0],s==="("&&(t+=1),s===")"&&(t-=1),t===0&&s===":")if(!n)this.doubleColon(r);else{if(n[0]==="word"&&n[1]==="progid")continue;return o}n=r}return!1}comment(e){let t=new mu;this.init(t,e[2]),t.source.end=this.getPosition(e[3]||e[2]),t.source.end.offset++;let r=e[1].slice(2,-2);if(/^\s*$/.test(r))t.text="",t.raws.left=r,t.raws.right="";else{let s=r.match(/^(\s*)([^]*\S)(\s*)$/);t.text=s[2],t.raws.left=s[1],t.raws.right=s[3]}}createTokenizer(){this.tokenizer=du(this.input)}decl(e,t){let r=new pu;this.init(r,e[0][2]);let s=e[e.length-1];for(s[0]===";"&&(this.semicolon=!0,e.pop()),r.source.end=this.getPosition(s[3]||s[2]||vu(e)),r.source.end.offset++;e[0][0]!=="word";)e.length===1&&this.unknownWord(e),r.raws.before+=e.shift()[1];for(r.source.start=this.getPosition(e[0][2]),r.prop="";e.length;){let u=e[0][0];if(u===":"||u==="space"||u==="comment")break;r.prop+=e.shift()[1]}r.raws.between="";let n;for(;e.length;)if(n=e.shift(),n[0]===":"){r.raws.between+=n[1];break}else n[0]==="word"&&/\w/.test(n[1])&&this.unknownWord([n]),r.raws.between+=n[1];(r.prop[0]==="_"||r.prop[0]==="*")&&(r.raws.before+=r.prop[0],r.prop=r.prop.slice(1));let o=[],l;for(;e.length&&(l=e[0][0],!(l!=="space"&&l!=="comment"));)o.push(e.shift());this.precheckMissedSemicolon(e);for(let u=e.length-1;u>=0;u--){if(n=e[u],n[1].toLowerCase()==="!important"){r.important=!0;let c=this.stringFrom(e,u);c=this.spacesFromEnd(e)+c,c!==" !important"&&(r.raws.important=c);break}else if(n[1].toLowerCase()==="important"){let c=e.slice(0),h="";for(let d=u;d>0;d--){let m=c[d][0];if(h.trim().indexOf("!")===0&&m!=="space")break;h=c.pop()[1]+h}h.trim().indexOf("!")===0&&(r.important=!0,r.raws.important=h,e=c)}if(n[0]!=="space"&&n[0]!=="comment")break}e.some(u=>u[0]!=="space"&&u[0]!=="comment")&&(r.raws.between+=o.map(u=>u[1]).join(""),o=[]),this.raw(r,"value",o.concat(e),t),r.value.includes(":")&&!t&&this.checkMissedSemicolon(e)}doubleColon(e){throw this.input.error("Double colon",{offset:e[2]},{offset:e[2]+e[1].length})}emptyRule(e){let t=new Bs;this.init(t,e[2]),t.selector="",t.raws.between="",this.current=t}end(e){this.current.nodes&&this.current.nodes.length&&(this.current.raws.semicolon=this.semicolon),this.semicolon=!1,this.current.raws.after=(this.current.raws.after||"")+this.spaces,this.spaces="",this.current.parent?(this.current.source.end=this.getPosition(e[2]),this.current.source.end.offset++,this.current=this.current.parent):this.unexpectedClose(e)}endFile(){this.current.parent&&this.unclosedBlock(),this.current.nodes&&this.current.nodes.length&&(this.current.raws.semicolon=this.semicolon),this.current.raws.after=(this.current.raws.after||"")+this.spaces,this.root.source.end=this.getPosition(this.tokenizer.position())}freeSemicolon(e){if(this.spaces+=e[1],this.current.nodes){let t=this.current.nodes[this.current.nodes.length-1];t&&t.type==="rule"&&!t.raws.ownSemicolon&&(t.raws.ownSemicolon=this.spaces,this.spaces="")}}getPosition(e){let t=this.input.fromOffset(e);return{column:t.col,line:t.line,offset:e}}init(e,t){this.current.push(e),e.source={input:this.input,start:this.getPosition(t)},e.raws.before=this.spaces,this.spaces="",e.type!=="comment"&&(this.semicolon=!1)}other(e){let t=!1,r=null,s=!1,n=null,o=[],l=e[1].startsWith("--"),a=[],u=e;for(;u;){if(r=u[0],a.push(u),r==="("||r==="[")n||(n=u),o.push(r==="("?")":"]");else if(l&&s&&r==="{")n||(n=u),o.push("}");else if(o.length===0)if(r===";")if(s){this.decl(a,l);return}else break;else if(r==="{"){this.rule(a);return}else if(r==="}"){this.tokenizer.back(a.pop()),t=!0;break}else r===":"&&(s=!0);else r===o[o.length-1]&&(o.pop(),o.length===0&&(n=null));u=this.tokenizer.nextToken()}if(this.tokenizer.endOfFile()&&(t=!0),o.length>0&&this.unclosedBracket(n),t&&s){if(!l)for(;a.length&&(u=a[a.length-1][0],!(u!=="space"&&u!=="comment"));)this.tokenizer.back(a.pop());this.decl(a,l)}else this.unknownWord(a)}parse(){let e;for(;!this.tokenizer.endOfFile();)switch(e=this.tokenizer.nextToken(),e[0]){case"space":this.spaces+=e[1];break;case";":this.freeSemicolon(e);break;case"}":this.end(e);break;case"comment":this.comment(e);break;case"at-word":this.atrule(e);break;case"{":this.emptyRule(e);break;default:this.other(e);break}this.endFile()}precheckMissedSemicolon(){}raw(e,t,r,s){let n,o,l=r.length,a="",u=!0,c,h;for(let d=0;d<l;d+=1)n=r[d],o=n[0],o==="space"&&d===l-1&&!s?u=!1:o==="comment"?(h=r[d-1]?r[d-1][0]:"empty",c=r[d+1]?r[d+1][0]:"empty",!Ws[h]&&!Ws[c]?a.slice(-1)===","?u=!1:a+=n[1]:u=!1):a+=n[1];if(!u){let d=r.reduce((m,g)=>m+g[1],"");e.raws[t]={raw:d,value:a}}e[t]=a}rule(e){e.pop();let t=new Bs;this.init(t,e[0][2]),t.raws.between=this.spacesAndCommentsFromEnd(e),this.raw(t,"selector",e),this.current=t}spacesAndCommentsFromEnd(e){let t,r="";for(;e.length&&(t=e[e.length-1][0],!(t!=="space"&&t!=="comment"));)r=e.pop()[1]+r;return r}spacesAndCommentsFromStart(e){let t,r="";for(;e.length&&(t=e[0][0],!(t!=="space"&&t!=="comment"));)r+=e.shift()[1];return r}spacesFromEnd(e){let t,r="";for(;e.length&&(t=e[e.length-1][0],t==="space");)r=e.pop()[1]+r;return r}stringFrom(e,t){let r="";for(let s=t;s<e.length;s++)r+=e[s][1];return e.splice(t,e.length-t),r}unclosedBlock(){let e=this.current.source.start;throw this.input.error("Unclosed block",e.line,e.column)}unclosedBracket(e){throw this.input.error("Unclosed bracket",{offset:e[2]},{offset:e[2]+1})}unexpectedClose(e){throw this.input.error("Unexpected }",{offset:e[2]},{offset:e[2]+1})}unknownWord(e){throw this.input.error("Unknown word",{offset:e[0][2]},{offset:e[0][2]+e[0][1].length})}unnamedAtrule(e,t){throw this.input.error("At-rule without name",{offset:t[2]},{offset:t[2]+t[1].length})}},Su=wu,bu=Pe,Cu=Su,xu=wr;function ar(i,e){let t=new xu(i,e),r=new Cu(t);try{r.parse()}catch(s){throw s}return r.root}var qi=ar;ar.default=ar;bu.registerParse(ar);var{isClean:we,my:Eu}=bt,Iu=Ln,Mu=gr,Nu=Pe,Au=Zi;var Vs=Xi,Ru=qi,Ou=Ct,Tu={atrule:"AtRule",comment:"Comment",decl:"Declaration",document:"Document",root:"Root",rule:"Rule"},Du={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},ku={Once:!0,postcssPlugin:!0,prepare:!0},He=0;function st(i){return typeof i=="object"&&typeof i.then=="function"}function ro(i){let e=!1,t=Tu[i.type];return i.type==="decl"?e=i.prop.toLowerCase():i.type==="atrule"&&(e=i.name.toLowerCase()),e&&i.append?[t,t+"-"+e,He,t+"Exit",t+"Exit-"+e]:e?[t,t+"-"+e,t+"Exit",t+"Exit-"+e]:i.append?[t,He,t+"Exit"]:[t,t+"Exit"]}function Gs(i){let e;return i.type==="document"?e=["Document",He,"DocumentExit"]:i.type==="root"?e=["Root",He,"RootExit"]:e=ro(i),{eventIndex:0,events:e,iterator:0,node:i,visitorIndex:0,visitors:[]}}function ci(i){return i[we]=!1,i.nodes&&i.nodes.forEach(e=>ci(e)),i}var hi={},Ye=class io{constructor(e,t,r){this.stringified=!1,this.processed=!1;let s;if(typeof t=="object"&&t!==null&&(t.type==="root"||t.type==="document"))s=ci(t);else if(t instanceof io||t instanceof Vs)s=ci(t.root),t.map&&(typeof r.map>"u"&&(r.map={}),r.map.inline||(r.map.inline=!1),r.map.prev=t.map);else{let n=Ru;r.syntax&&(n=r.syntax.parse),r.parser&&(n=r.parser),n.parse&&(n=n.parse);try{s=n(t,r)}catch(o){this.processed=!0,this.error=o}s&&!s[Eu]&&Nu.rebuild(s)}this.result=new Vs(e,s,r),this.helpers={...hi,postcss:hi,result:this.result},this.plugins=this.processor.plugins.map(n=>typeof n=="object"&&n.prepare?{...n,...n.prepare(this.result)}:n)}async(){return this.error?Promise.reject(this.error):this.processed?Promise.resolve(this.result):(this.processing||(this.processing=this.runAsync()),this.processing)}catch(e){return this.async().catch(e)}finally(e){return this.async().then(e,e)}getAsyncError(){throw new Error("Use process(css).then(cb) to work with async plugins")}handleError(e,t){let r=this.result.lastPlugin;try{t&&t.addToError(e),this.error=e,e.name==="CssSyntaxError"&&!e.plugin?(e.plugin=r.postcssPlugin,e.setMessage()):r.postcssVersion}catch(s){console&&console.error&&console.error(s)}return e}prepareVisitors(){this.listeners={};let e=(t,r,s)=>{this.listeners[r]||(this.listeners[r]=[]),this.listeners[r].push([t,s])};for(let t of this.plugins)if(typeof t=="object")for(let r in t){if(!Du[r]&&/^[A-Z]/.test(r))throw new Error(`Unknown event ${r} in ${t.postcssPlugin}. Try to update PostCSS (${this.processor.version} now).`);if(!ku[r])if(typeof t[r]=="object")for(let s in t[r])s==="*"?e(t,r,t[r][s]):e(t,r+"-"+s.toLowerCase(),t[r][s]);else typeof t[r]=="function"&&e(t,r,t[r])}this.hasListener=Object.keys(this.listeners).length>0}async runAsync(){this.plugin=0;for(let e=0;e<this.plugins.length;e++){let t=this.plugins[e],r=this.runOnRoot(t);if(st(r))try{await r}catch(s){throw this.handleError(s)}}if(this.prepareVisitors(),this.hasListener){let e=this.result.root;for(;!e[we];){e[we]=!0;let t=[Gs(e)];for(;t.length>0;){let r=this.visitTick(t);if(st(r))try{await r}catch(s){let n=t[t.length-1].node;throw this.handleError(s,n)}}}if(this.listeners.OnceExit)for(let[t,r]of this.listeners.OnceExit){this.result.lastPlugin=t;try{if(e.type==="document"){let s=e.nodes.map(n=>r(n,this.helpers));await Promise.all(s)}else await r(e,this.helpers)}catch(s){throw this.handleError(s)}}}return this.processed=!0,this.stringify()}runOnRoot(e){this.result.lastPlugin=e;try{if(typeof e=="object"&&e.Once){if(this.result.root.type==="document"){let t=this.result.root.nodes.map(r=>e.Once(r,this.helpers));return st(t[0])?Promise.all(t):t}return e.Once(this.result.root,this.helpers)}else if(typeof e=="function")return e(this.result.root,this.result)}catch(t){throw this.handleError(t)}}stringify(){if(this.error)throw this.error;if(this.stringified)return this.result;this.stringified=!0,this.sync();let e=this.result.opts,t=Mu;e.syntax&&(t=e.syntax.stringify),e.stringifier&&(t=e.stringifier),t.stringify&&(t=t.stringify);let s=new Iu(t,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 e of this.plugins){let t=this.runOnRoot(e);if(st(t))throw this.getAsyncError()}if(this.prepareVisitors(),this.hasListener){let e=this.result.root;for(;!e[we];)e[we]=!0,this.walkSync(e);if(this.listeners.OnceExit)if(e.type==="document")for(let t of e.nodes)this.visitSync(this.listeners.OnceExit,t);else this.visitSync(this.listeners.OnceExit,e)}return this.result}then(e,t){return this.async().then(e,t)}toString(){return this.css}visitSync(e,t){for(let[r,s]of e){this.result.lastPlugin=r;let n;try{n=s(t,this.helpers)}catch(o){throw this.handleError(o,t.proxyOf)}if(t.type!=="root"&&t.type!=="document"&&!t.parent)return!0;if(st(n))throw this.getAsyncError()}}visitTick(e){let t=e[e.length-1],{node:r,visitors:s}=t;if(r.type!=="root"&&r.type!=="document"&&!r.parent){e.pop();return}if(s.length>0&&t.visitorIndex<s.length){let[o,l]=s[t.visitorIndex];t.visitorIndex+=1,t.visitorIndex===s.length&&(t.visitors=[],t.visitorIndex=0),this.result.lastPlugin=o;try{return l(r.toProxy(),this.helpers)}catch(a){throw this.handleError(a,r)}}if(t.iterator!==0){let o=t.iterator,l;for(;l=r.nodes[r.indexes[o]];)if(r.indexes[o]+=1,!l[we]){l[we]=!0,e.push(Gs(l));return}t.iterator=0,delete r.indexes[o]}let n=t.events;for(;t.eventIndex<n.length;){let o=n[t.eventIndex];if(t.eventIndex+=1,o===He){r.nodes&&r.nodes.length&&(r[we]=!0,t.iterator=r.getIterator());return}else if(this.listeners[o]){t.visitors=this.listeners[o];return}}e.pop()}walkSync(e){e[we]=!0;let t=ro(e);for(let r of t)if(r===He)e.nodes&&e.each(s=>{s[we]||this.walkSync(s)});else{let s=this.listeners[r];if(s&&this.visitSync(s,e.toProxy()))return}}warnings(){return this.sync().warnings()}get content(){return this.stringify().content}get css(){return this.stringify().css}get map(){return this.stringify().map}get messages(){return this.sync().messages}get opts(){return this.result.opts}get processor(){return this.result.processor}get root(){return this.sync().root}get[Symbol.toStringTag](){return"LazyResult"}};Ye.registerPostcss=i=>{hi=i};var so=Ye;Ye.default=Ye;Ou.registerLazyResult(Ye);Au.registerLazyResult(Ye);var $u=Ln,_u=gr;var Pu=qi,Lu=Xi,fi=class{constructor(e,t,r){t=t.toString(),this.stringified=!1,this._processor=e,this._css=t,this._opts=r,this._map=void 0;let s,n=_u;this.result=new Lu(this._processor,s,this._opts),this.result.css=t;let o=this;Object.defineProperty(this.result,"root",{get(){return o.root}});let l=new $u(n,s,this._opts,t);if(l.isMap()){let[a,u]=l.generate();a&&(this.result.css=a),u&&(this.result.map=u)}else l.clearAnnotation(),this.result.css=l.css}async(){return this.error?Promise.reject(this.error):Promise.resolve(this.result)}catch(e){return this.async().catch(e)}finally(e){return this.async().then(e,e)}sync(){if(this.error)throw this.error;return this.result}then(e,t){return this.async().then(e,t)}toString(){return this._css}warnings(){return[]}get content(){return this.result.css}get css(){return this.result.css}get map(){return this.result.map}get messages(){return[]}get opts(){return this.result.opts}get processor(){return this.result.processor}get root(){if(this._root)return this._root;let e,t=Pu;try{e=t(this._css,this._opts)}catch(r){this.error=r}if(this.error)throw this.error;return this._root=e,e}get[Symbol.toStringTag](){return"NoWorkResult"}},Fu=fi;fi.default=fi;var Uu=Fu,zu=so,Bu=Zi,Wu=Ct,dt=class{constructor(e=[]){this.version="8.4.38",this.plugins=this.normalize(e)}normalize(e){let t=[];for(let r of e)if(r.postcss===!0?r=r():r.postcss&&(r=r.postcss),typeof r=="object"&&Array.isArray(r.plugins))t=t.concat(r.plugins);else if(typeof r=="object"&&r.postcssPlugin)t.push(r);else if(typeof r=="function")t.push(r);else if(!(typeof r=="object"&&(r.parse||r.stringify)))throw new Error(r+" is not a PostCSS plugin");return t}process(e,t={}){return!this.plugins.length&&!t.parser&&!t.stringifier&&!t.syntax?new Uu(this,e,t):new zu(this,e,t)}use(e){return this.plugins=this.plugins.concat(this.normalize([e])),this}},Vu=dt;dt.default=dt;Wu.registerProcessor(dt);Bu.registerProcessor(dt);var Gu=vr,ju=Dn,Hu=Sr,Yu=Ji,Zu=wr,Xu=Ct,Ju=Ki;function mt(i,e){if(Array.isArray(i))return i.map(s=>mt(s));let{inputs:t,...r}=i;if(t){e=[];for(let s of t){let n={...s,__proto__:Zu.prototype};n.map&&(n.map={...n.map,__proto__:ju.prototype}),e.push(n)}}if(r.nodes&&(r.nodes=i.nodes.map(s=>mt(s,e))),r.source){let{inputId:s,...n}=r.source;r.source=n,s!=null&&(r.source.input=e[s])}if(r.type==="root")return new Xu(r);if(r.type==="decl")return new Gu(r);if(r.type==="rule")return new Ju(r);if(r.type==="comment")return new Hu(r);if(r.type==="atrule")return new Yu(r);throw new Error("Unknown node type: "+i.type)}var Ku=mt;mt.default=mt;var qu=ji,no=vr,Qu=so,ec=Pe,Qi=Vu,tc=gr,rc=Ku,oo=Zi,ic=Xn,ao=Sr,lo=Ji,sc=Xi,nc=wr,oc=qi,ac=eo,uo=Ki,co=Ct,lc=yr;function U(...i){return i.length===1&&Array.isArray(i[0])&&(i=i[0]),new Qi(i)}U.plugin=function(e,t){let r=!1;function s(...o){console&&console.warn&&!r&&(r=!0,console.warn(e+`: postcss.plugin was deprecated. Migration guide:
|
|
28
25
|
https://evilmartians.com/chronicles/postcss-8-plugin-migration`),process.env.LANG&&process.env.LANG.startsWith("cn")&&console.warn(e+`: \u91CC\u9762 postcss.plugin \u88AB\u5F03\u7528. \u8FC1\u79FB\u6307\u5357:
|
|
29
|
-
https://www.w3ctech.com/topic/2226`));let l=t(...o);return l.postcssPlugin=e,l.postcssVersion=new Qi().version,l}let n;return Object.defineProperty(s,"postcss",{get(){return n||(n=s()),n}}),s.process=function(o,l,a){return U([s(a)]).process(o,l)},s};U.stringify=
|
|
30
|
-
`+m+l("^")}return" "+a(
|
|
26
|
+
https://www.w3ctech.com/topic/2226`));let l=t(...o);return l.postcssPlugin=e,l.postcssVersion=new Qi().version,l}let n;return Object.defineProperty(s,"postcss",{get(){return n||(n=s()),n}}),s.process=function(o,l,a){return U([s(a)]).process(o,l)},s};U.stringify=tc;U.parse=oc;U.fromJSON=rc;U.list=ac;U.comment=i=>new ao(i);U.atRule=i=>new lo(i);U.decl=i=>new no(i);U.rule=i=>new uo(i);U.root=i=>new co(i);U.document=i=>new oo(i);U.CssSyntaxError=qu;U.Declaration=no;U.Container=ec;U.Processor=Qi;U.Document=oo;U.Comment=ao;U.Warning=ic;U.AtRule=lo;U.Result=sc;U.Input=nc;U.Rule=uo;U.Root=co;U.Node=lc;Qu.registerPostcss(U);var uc=U;U.default=U;var Z=bl(uc);Z.stringify;Z.fromJSON;Z.plugin;Z.parse;Z.list;Z.document;Z.comment;Z.atRule;Z.rule;Z.decl;Z.root;Z.CssSyntaxError;Z.Declaration;Z.Container;Z.Processor;Z.Document;Z.Comment;Z.Warning;Z.AtRule;Z.Result;Z.Input;Z.Rule;Z.Root;Z.Node;var cc=Object.defineProperty,hc=(i,e,t)=>e in i?cc(i,e,{enumerable:!0,configurable:!0,writable:!0,value:t}):i[e]=t,ce=(i,e,t)=>hc(i,typeof e!="symbol"?e+"":e,t);function fc(i){return i&&i.__esModule&&Object.prototype.hasOwnProperty.call(i,"default")?i.default:i}function pc(i){if(i.__esModule)return i;var e=i.default;if(typeof e=="function"){var t=function r(){return this instanceof r?Reflect.construct(e,arguments,this.constructor):e.apply(this,arguments)};t.prototype=e.prototype}else t={};return Object.defineProperty(t,"__esModule",{value:!0}),Object.keys(i).forEach(function(r){var s=Object.getOwnPropertyDescriptor(i,r);Object.defineProperty(t,r,s.get?s:{enumerable:!0,get:function(){return i[r]}})}),t}var es={exports:{}},Y=String,ho=function(){return{isColorSupported:!1,reset:Y,bold:Y,dim:Y,italic:Y,underline:Y,inverse:Y,hidden:Y,strikethrough:Y,black:Y,red:Y,green:Y,yellow:Y,blue:Y,magenta:Y,cyan:Y,white:Y,gray:Y,bgBlack:Y,bgRed:Y,bgGreen:Y,bgYellow:Y,bgBlue:Y,bgMagenta:Y,bgCyan:Y,bgWhite:Y}};es.exports=ho();es.exports.createColors=ho;var dc=es.exports,mc={},gc=Object.freeze(Object.defineProperty({__proto__:null,default:mc},Symbol.toStringTag,{value:"Module"})),ge=pc(gc),js=dc,Hs=ge,pi=class fo extends Error{constructor(e,t,r,s,n,o){super(e),this.name="CssSyntaxError",this.reason=e,n&&(this.file=n),s&&(this.source=s),o&&(this.plugin=o),typeof t<"u"&&typeof r<"u"&&(typeof t=="number"?(this.line=t,this.column=r):(this.line=t.line,this.column=t.column,this.endLine=r.line,this.endColumn=r.column)),this.setMessage(),Error.captureStackTrace&&Error.captureStackTrace(this,fo)}setMessage(){this.message=this.plugin?this.plugin+": ":"",this.message+=this.file?this.file:"<css input>",typeof this.line<"u"&&(this.message+=":"+this.line+":"+this.column),this.message+=": "+this.reason}showSourceCode(e){if(!this.source)return"";let t=this.source;e==null&&(e=js.isColorSupported),Hs&&e&&(t=Hs(t));let r=t.split(/\r?\n/),s=Math.max(this.line-3,0),n=Math.min(this.line+2,r.length),o=String(n).length,l,a;if(e){let{bold:u,gray:c,red:h}=js.createColors(!0);l=d=>u(h(d)),a=d=>c(d)}else l=a=u=>u;return r.slice(s,n).map((u,c)=>{let h=s+1+c,d=" "+(" "+h).slice(-o)+" | ";if(h===this.line){let m=a(d.replace(/\d/g," "))+u.slice(0,this.column-1).replace(/[^\t]/g," ");return l(">")+a(d)+u+`
|
|
27
|
+
`+m+l("^")}return" "+a(d)+u}).join(`
|
|
31
28
|
`)}toString(){let e=this.showSourceCode();return e&&(e=`
|
|
32
29
|
|
|
33
30
|
`+e+`
|
|
34
|
-
`),this.name+": "+this.message+e}},ts=
|
|
31
|
+
`),this.name+": "+this.message+e}},ts=pi;pi.default=pi;var xt={};xt.isClean=Symbol("isClean");xt.my=Symbol("my");var Ys={after:`
|
|
35
32
|
`,beforeClose:`
|
|
36
33
|
`,beforeComment:`
|
|
37
34
|
`,beforeDecl:`
|
|
38
35
|
`,beforeOpen:" ",beforeRule:`
|
|
39
|
-
`,colon:": ",commentLeft:" ",commentRight:" ",emptyBody:"",indent:" ",semicolon:!1};function
|
|
40
|
-
`)){let o=this.raw(e,null,"indent");if(o.length)for(let l=0;l<n;l++)r+=o}return r}block(e,t){let r=this.raw(e,"between","beforeOpen");this.builder(t+r+"{",e,"start");let s;e.nodes&&e.nodes.length?(this.body(e),s=this.raw(e,"after")):s=this.raw(e,"after","emptyBody"),s&&this.builder(s),this.builder("}",e,"end")}body(e){let t=e.nodes.length-1;for(;t>0&&e.nodes[t].type==="comment";)t-=1;let r=this.raw(e,"semicolon");for(let s=0;s<e.nodes.length;s++){let n=e.nodes[s],o=this.raw(n,"before");o&&this.builder(o),this.stringify(n,t!==s||r)}}comment(e){let t=this.raw(e,"left","commentLeft"),r=this.raw(e,"right","commentRight");this.builder("/*"+t+e.text+r+"*/",e)}decl(e,t){let r=this.raw(e,"between","colon"),s=e.prop+r+this.rawValue(e,"value");e.important&&(s+=e.raws.important||" !important"),t&&(s+=";"),this.builder(s,e)}document(e){this.body(e)}raw(e,t,r){let s;if(r||(r=t),t&&(s=e.raws[t],typeof s<"u"))return s;let n=e.parent;if(r==="before"&&(!n||n.type==="root"&&n.first===e||n&&n.type==="document"))return"";if(!n)return
|
|
36
|
+
`,colon:": ",commentLeft:" ",commentRight:" ",emptyBody:"",indent:" ",semicolon:!1};function yc(i){return i[0].toUpperCase()+i.slice(1)}var di=class{constructor(e){this.builder=e}atrule(e,t){let r="@"+e.name,s=e.params?this.rawValue(e,"params"):"";if(typeof e.raws.afterName<"u"?r+=e.raws.afterName:s&&(r+=" "),e.nodes)this.block(e,r+s);else{let n=(e.raws.between||"")+(t?";":"");this.builder(r+s+n,e)}}beforeAfter(e,t){let r;e.type==="decl"?r=this.raw(e,null,"beforeDecl"):e.type==="comment"?r=this.raw(e,null,"beforeComment"):t==="before"?r=this.raw(e,null,"beforeRule"):r=this.raw(e,null,"beforeClose");let s=e.parent,n=0;for(;s&&s.type!=="root";)n+=1,s=s.parent;if(r.includes(`
|
|
37
|
+
`)){let o=this.raw(e,null,"indent");if(o.length)for(let l=0;l<n;l++)r+=o}return r}block(e,t){let r=this.raw(e,"between","beforeOpen");this.builder(t+r+"{",e,"start");let s;e.nodes&&e.nodes.length?(this.body(e),s=this.raw(e,"after")):s=this.raw(e,"after","emptyBody"),s&&this.builder(s),this.builder("}",e,"end")}body(e){let t=e.nodes.length-1;for(;t>0&&e.nodes[t].type==="comment";)t-=1;let r=this.raw(e,"semicolon");for(let s=0;s<e.nodes.length;s++){let n=e.nodes[s],o=this.raw(n,"before");o&&this.builder(o),this.stringify(n,t!==s||r)}}comment(e){let t=this.raw(e,"left","commentLeft"),r=this.raw(e,"right","commentRight");this.builder("/*"+t+e.text+r+"*/",e)}decl(e,t){let r=this.raw(e,"between","colon"),s=e.prop+r+this.rawValue(e,"value");e.important&&(s+=e.raws.important||" !important"),t&&(s+=";"),this.builder(s,e)}document(e){this.body(e)}raw(e,t,r){let s;if(r||(r=t),t&&(s=e.raws[t],typeof s<"u"))return s;let n=e.parent;if(r==="before"&&(!n||n.type==="root"&&n.first===e||n&&n.type==="document"))return"";if(!n)return Ys[r];let o=e.root();if(o.rawCache||(o.rawCache={}),typeof o.rawCache[r]<"u")return o.rawCache[r];if(r==="before"||r==="after")return this.beforeAfter(e,r);{let l="raw"+yc(r);this[l]?s=this[l](o,e):o.walk(a=>{if(s=a.raws[t],typeof s<"u")return!1})}return typeof s>"u"&&(s=Ys[r]),o.rawCache[r]=s,s}rawBeforeClose(e){let t;return e.walk(r=>{if(r.nodes&&r.nodes.length>0&&typeof r.raws.after<"u")return t=r.raws.after,t.includes(`
|
|
41
38
|
`)&&(t=t.replace(/[^\n]+$/,"")),!1}),t&&(t=t.replace(/\S/g,"")),t}rawBeforeComment(e,t){let r;return e.walkComments(s=>{if(typeof s.raws.before<"u")return r=s.raws.before,r.includes(`
|
|
42
39
|
`)&&(r=r.replace(/[^\n]+$/,"")),!1}),typeof r>"u"?r=this.raw(t,null,"beforeDecl"):r&&(r=r.replace(/\S/g,"")),r}rawBeforeDecl(e,t){let r;return e.walkDecls(s=>{if(typeof s.raws.before<"u")return r=s.raws.before,r.includes(`
|
|
43
40
|
`)&&(r=r.replace(/[^\n]+$/,"")),!1}),typeof r>"u"?r=this.raw(t,null,"beforeRule"):r&&(r=r.replace(/\S/g,"")),r}rawBeforeOpen(e){let t;return e.walk(r=>{if(r.type!=="decl"&&(t=r.raws.between,typeof t<"u"))return!1}),t}rawBeforeRule(e){let t;return e.walk(r=>{if(r.nodes&&(r.parent!==e||e.first!==r)&&typeof r.raws.before<"u")return t=r.raws.before,t.includes(`
|
|
44
41
|
`)&&(t=t.replace(/[^\n]+$/,"")),!1}),t&&(t=t.replace(/\S/g,"")),t}rawColon(e){let t;return e.walkDecls(r=>{if(typeof r.raws.between<"u")return t=r.raws.between.replace(/[^\s:]/g,""),!1}),t}rawEmptyBody(e){let t;return e.walk(r=>{if(r.nodes&&r.nodes.length===0&&(t=r.raws.after,typeof t<"u"))return!1}),t}rawIndent(e){if(e.raws.indent)return e.raws.indent;let t;return e.walk(r=>{let s=r.parent;if(s&&s!==e&&s.parent&&s.parent===e&&typeof r.raws.before<"u"){let n=r.raws.before.split(`
|
|
45
|
-
`);return t=n[n.length-1],t=t.replace(/\S/g,""),!1}}),t}rawSemicolon(e){let t;return e.walk(r=>{if(r.nodes&&r.nodes.length&&r.last.type==="decl"&&(t=r.raws.semicolon,typeof t<"u"))return!1}),t}rawValue(e,t){let r=e[t],s=e.raws[t];return s&&s.value===r?s.raw:r}root(e){this.body(e),e.raws.after&&this.builder(e.raws.after)}rule(e){this.block(e,this.rawValue(e,"selector")),e.raws.ownSemicolon&&this.builder(e.raws.ownSemicolon,e,"end")}stringify(e,t){if(!this[e.type])throw new Error("Unknown AST node type "+e.type+". Maybe you need to change PostCSS stringifier.");this[e.type](e,t)}},
|
|
46
|
-
`?(s=1,n+=1):s+=1;return{column:s,line:n}}prev(){if(!this.parent)return;let e=this.parent.index(this);return this.parent.nodes[e-1]}rangeBy(e){let t={column:this.source.start.column,line:this.source.start.line},r=this.source.end?{column:this.source.end.column+1,line:this.source.end.line}:{column:t.column+1,line:t.line};if(e.word){let s=this.toString(),n=s.indexOf(e.word);n!==-1&&(t=this.positionInside(n,s),r=this.positionInside(n+e.word.length,s))}else e.start?t={column:e.start.column,line:e.start.line}:e.index&&(t=this.positionInside(e.index)),e.end?r={column:e.end.column,line:e.end.line}:typeof e.endIndex=="number"?r=this.positionInside(e.endIndex):e.index&&(r=this.positionInside(e.index+1));return(r.line<t.line||r.line===t.line&&r.column<=t.column)&&(r={column:t.column+1,line:t.line}),{end:r,start:t}}raw(e,t){return new
|
|
47
|
-
`);r=new Array(n.length);let o=0;for(let l=0,a=n.length;l<a;l++)r[l]=o,o+=n[l].length+1;this[jr]=r}t=r[r.length-1];let s=0;if(e>=t)s=r.length-1;else{let n=r.length-2,o;for(;s<n;)if(o=s+(n-s>>1),e<r[o])n=o-1;else if(e>=r[o+1])s=o+1;else{s=o;break}}return{col:e-r[s]+1,line:s+1}}mapResolve(e){return/^\w+:\/\//.test(e)?e:bi(this.map.consumer().sourceRoot||this.map.root||".",e)}origin(e,t,r,s){if(!this.map)return!1;let n=this.map.consumer(),o=n.originalPositionFor({column:t,line:e});if(!o.source)return!1;let l;typeof r=="number"&&(l=n.originalPositionFor({column:s,line:r}));let a;Si(o.source)?a=Ft(o.source):a=new URL(o.source,this.map.consumer().sourceRoot||Ft(this.map.mapFile));let u={column:o.column,endColumn:l&&l.column,endLine:l&&l.line,line:o.line,url:a.toString()};if(a.protocol==="file:")if(
|
|
42
|
+
`);return t=n[n.length-1],t=t.replace(/\S/g,""),!1}}),t}rawSemicolon(e){let t;return e.walk(r=>{if(r.nodes&&r.nodes.length&&r.last.type==="decl"&&(t=r.raws.semicolon,typeof t<"u"))return!1}),t}rawValue(e,t){let r=e[t],s=e.raws[t];return s&&s.value===r?s.raw:r}root(e){this.body(e),e.raws.after&&this.builder(e.raws.after)}rule(e){this.block(e,this.rawValue(e,"selector")),e.raws.ownSemicolon&&this.builder(e.raws.ownSemicolon,e,"end")}stringify(e,t){if(!this[e.type])throw new Error("Unknown AST node type "+e.type+". Maybe you need to change PostCSS stringifier.");this[e.type](e,t)}},po=di;di.default=di;var vc=po;function mi(i,e){new vc(e).stringify(i)}var br=mi;mi.default=mi;var{isClean:Lt,my:wc}=xt,Sc=ts,bc=po,Cc=br;function gi(i,e){let t=new i.constructor;for(let r in i){if(!Object.prototype.hasOwnProperty.call(i,r)||r==="proxyCache")continue;let s=i[r],n=typeof s;r==="parent"&&n==="object"?e&&(t[r]=e):r==="source"?t[r]=s:Array.isArray(s)?t[r]=s.map(o=>gi(o,t)):(n==="object"&&s!==null&&(s=gi(s)),t[r]=s)}return t}var yi=class{constructor(e={}){this.raws={},this[Lt]=!1,this[wc]=!0;for(let t in e)if(t==="nodes"){this.nodes=[];for(let r of e[t])typeof r.clone=="function"?this.append(r.clone()):this.append(r)}else this[t]=e[t]}addToError(e){if(e.postcssNode=this,e.stack&&this.source&&/\n\s{4}at /.test(e.stack)){let t=this.source;e.stack=e.stack.replace(/\n\s{4}at /,`$&${t.input.from}:${t.start.line}:${t.start.column}$&`)}return e}after(e){return this.parent.insertAfter(this,e),this}assign(e={}){for(let t in e)this[t]=e[t];return this}before(e){return this.parent.insertBefore(this,e),this}cleanRaws(e){delete this.raws.before,delete this.raws.after,e||delete this.raws.between}clone(e={}){let t=gi(this);for(let r in e)t[r]=e[r];return t}cloneAfter(e={}){let t=this.clone(e);return this.parent.insertAfter(this,t),t}cloneBefore(e={}){let t=this.clone(e);return this.parent.insertBefore(this,t),t}error(e,t={}){if(this.source){let{end:r,start:s}=this.rangeBy(t);return this.source.input.error(e,{column:s.column,line:s.line},{column:r.column,line:r.line},t)}return new Sc(e)}getProxyProcessor(){return{get(e,t){return t==="proxyOf"?e:t==="root"?()=>e.root().toProxy():e[t]},set(e,t,r){return e[t]===r||(e[t]=r,(t==="prop"||t==="value"||t==="name"||t==="params"||t==="important"||t==="text")&&e.markDirty()),!0}}}markDirty(){if(this[Lt]){this[Lt]=!1;let e=this;for(;e=e.parent;)e[Lt]=!1}}next(){if(!this.parent)return;let e=this.parent.index(this);return this.parent.nodes[e+1]}positionBy(e,t){let r=this.source.start;if(e.index)r=this.positionInside(e.index,t);else if(e.word){t=this.toString();let s=t.indexOf(e.word);s!==-1&&(r=this.positionInside(s,t))}return r}positionInside(e,t){let r=t||this.toString(),s=this.source.start.column,n=this.source.start.line;for(let o=0;o<e;o++)r[o]===`
|
|
43
|
+
`?(s=1,n+=1):s+=1;return{column:s,line:n}}prev(){if(!this.parent)return;let e=this.parent.index(this);return this.parent.nodes[e-1]}rangeBy(e){let t={column:this.source.start.column,line:this.source.start.line},r=this.source.end?{column:this.source.end.column+1,line:this.source.end.line}:{column:t.column+1,line:t.line};if(e.word){let s=this.toString(),n=s.indexOf(e.word);n!==-1&&(t=this.positionInside(n,s),r=this.positionInside(n+e.word.length,s))}else e.start?t={column:e.start.column,line:e.start.line}:e.index&&(t=this.positionInside(e.index)),e.end?r={column:e.end.column,line:e.end.line}:typeof e.endIndex=="number"?r=this.positionInside(e.endIndex):e.index&&(r=this.positionInside(e.index+1));return(r.line<t.line||r.line===t.line&&r.column<=t.column)&&(r={column:t.column+1,line:t.line}),{end:r,start:t}}raw(e,t){return new bc().raw(this,e,t)}remove(){return this.parent&&this.parent.removeChild(this),this.parent=void 0,this}replaceWith(...e){if(this.parent){let t=this,r=!1;for(let s of e)s===this?r=!0:r?(this.parent.insertAfter(t,s),t=s):this.parent.insertBefore(t,s);r||this.remove()}return this}root(){let e=this;for(;e.parent&&e.parent.type!=="document";)e=e.parent;return e}toJSON(e,t){let r={},s=t==null;t=t||new Map;let n=0;for(let o in this){if(!Object.prototype.hasOwnProperty.call(this,o)||o==="parent"||o==="proxyCache")continue;let l=this[o];if(Array.isArray(l))r[o]=l.map(a=>typeof a=="object"&&a.toJSON?a.toJSON(null,t):a);else if(typeof l=="object"&&l.toJSON)r[o]=l.toJSON(null,t);else if(o==="source"){let a=t.get(l.input);a==null&&(a=n,t.set(l.input,n),n++),r[o]={end:l.end,inputId:a,start:l.start}}else r[o]=l}return s&&(r.inputs=[...t.keys()].map(o=>o.toJSON())),r}toProxy(){return this.proxyCache||(this.proxyCache=new Proxy(this,this.getProxyProcessor())),this.proxyCache}toString(e=Cc){e.stringify&&(e=e.stringify);let t="";return e(this,r=>{t+=r}),t}warn(e,t,r){let s={node:this};for(let n in r)s[n]=r[n];return e.warn(t,s)}get proxyOf(){return this}},Cr=yi;yi.default=yi;var xc=Cr,vi=class extends xc{constructor(e){e&&typeof e.value<"u"&&typeof e.value!="string"&&(e={...e,value:String(e.value)}),super(e),this.type="decl"}get variable(){return this.prop.startsWith("--")||this.prop[0]==="$"}},xr=vi;vi.default=vi;var Ec="useandom-26T198340PX75pxJACKVERYMINDBUSHWOLF_GQZbfghjklqvwyzrict",Ic=(i,e=21)=>(t=e)=>{let r="",s=t;for(;s--;)r+=i[Math.random()*i.length|0];return r},Mc=(i=21)=>{let e="",t=i;for(;t--;)e+=Ec[Math.random()*64|0];return e},Nc={nanoid:Mc,customAlphabet:Ic},{SourceMapConsumer:Zs,SourceMapGenerator:Xs}=ge,{existsSync:Ac,readFileSync:Rc}=ge,{dirname:Vr,join:Oc}=ge;function Tc(i){return Buffer?Buffer.from(i,"base64").toString():window.atob(i)}var wi=class{constructor(e,t){if(t.map===!1)return;this.loadAnnotation(e),this.inline=this.startWith(this.annotation,"data:");let r=t.map?t.map.prev:void 0,s=this.loadMap(t.from,r);!this.mapFile&&t.from&&(this.mapFile=t.from),this.mapFile&&(this.root=Vr(this.mapFile)),s&&(this.text=s)}consumer(){return this.consumerCache||(this.consumerCache=new Zs(this.text)),this.consumerCache}decodeInline(e){let t=/^data:application\/json;charset=utf-?8;base64,/,r=/^data:application\/json;base64,/,s=/^data:application\/json;charset=utf-?8,/,n=/^data:application\/json,/;if(s.test(e)||n.test(e))return decodeURIComponent(e.substr(RegExp.lastMatch.length));if(t.test(e)||r.test(e))return Tc(e.substr(RegExp.lastMatch.length));let o=e.match(/data:application\/json;([^,]+),/)[1];throw new Error("Unsupported source map encoding "+o)}getAnnotationURL(e){return e.replace(/^\/\*\s*# sourceMappingURL=/,"").trim()}isMap(e){return typeof e!="object"?!1:typeof e.mappings=="string"||typeof e._mappings=="string"||Array.isArray(e.sections)}loadAnnotation(e){let t=e.match(/\/\*\s*# sourceMappingURL=/gm);if(!t)return;let r=e.lastIndexOf(t.pop()),s=e.indexOf("*/",r);r>-1&&s>-1&&(this.annotation=this.getAnnotationURL(e.substring(r,s)))}loadFile(e){if(this.root=Vr(e),Ac(e))return this.mapFile=e,Rc(e,"utf-8").toString().trim()}loadMap(e,t){if(t===!1)return!1;if(t){if(typeof t=="string")return t;if(typeof t=="function"){let r=t(e);if(r){let s=this.loadFile(r);if(!s)throw new Error("Unable to load previous source map: "+r.toString());return s}}else{if(t instanceof Zs)return Xs.fromSourceMap(t).toString();if(t instanceof Xs)return t.toString();if(this.isMap(t))return JSON.stringify(t);throw new Error("Unsupported previous source map format: "+t.toString())}}else{if(this.inline)return this.decodeInline(this.annotation);if(this.annotation){let r=this.annotation;return e&&(r=Oc(Vr(e),r)),this.loadFile(r)}}}startWith(e,t){return e?e.substr(0,t.length)===t:!1}withContent(){return!!(this.consumer().sourcesContent&&this.consumer().sourcesContent.length>0)}},mo=wi;wi.default=wi;var{SourceMapConsumer:Dc,SourceMapGenerator:kc}=ge,{fileURLToPath:Js,pathToFileURL:Ft}=ge,{isAbsolute:Si,resolve:bi}=ge,{nanoid:$c}=Nc,Gr=ge,Ks=ts,_c=mo,jr=Symbol("fromOffsetCache"),Pc=!!(Dc&&kc),qs=!!(bi&&Si),lr=class{constructor(e,t={}){if(e===null||typeof e>"u"||typeof e=="object"&&!e.toString)throw new Error(`PostCSS received ${e} instead of CSS string`);if(this.css=e.toString(),this.css[0]==="\uFEFF"||this.css[0]==="\uFFFE"?(this.hasBOM=!0,this.css=this.css.slice(1)):this.hasBOM=!1,t.from&&(!qs||/^\w+:\/\//.test(t.from)||Si(t.from)?this.file=t.from:this.file=bi(t.from)),qs&&Pc){let r=new _c(this.css,t);if(r.text){this.map=r;let s=r.consumer().file;!this.file&&s&&(this.file=this.mapResolve(s))}}this.file||(this.id="<input css "+$c(6)+">"),this.map&&(this.map.file=this.from)}error(e,t,r,s={}){let n,o,l;if(t&&typeof t=="object"){let u=t,c=r;if(typeof u.offset=="number"){let h=this.fromOffset(u.offset);t=h.line,r=h.col}else t=u.line,r=u.column;if(typeof c.offset=="number"){let h=this.fromOffset(c.offset);o=h.line,l=h.col}else o=c.line,l=c.column}else if(!r){let u=this.fromOffset(t);t=u.line,r=u.col}let a=this.origin(t,r,o,l);return a?n=new Ks(e,a.endLine===void 0?a.line:{column:a.column,line:a.line},a.endLine===void 0?a.column:{column:a.endColumn,line:a.endLine},a.source,a.file,s.plugin):n=new Ks(e,o===void 0?t:{column:r,line:t},o===void 0?r:{column:l,line:o},this.css,this.file,s.plugin),n.input={column:r,endColumn:l,endLine:o,line:t,source:this.css},this.file&&(Ft&&(n.input.url=Ft(this.file).toString()),n.input.file=this.file),n}fromOffset(e){let t,r;if(this[jr])r=this[jr];else{let n=this.css.split(`
|
|
44
|
+
`);r=new Array(n.length);let o=0;for(let l=0,a=n.length;l<a;l++)r[l]=o,o+=n[l].length+1;this[jr]=r}t=r[r.length-1];let s=0;if(e>=t)s=r.length-1;else{let n=r.length-2,o;for(;s<n;)if(o=s+(n-s>>1),e<r[o])n=o-1;else if(e>=r[o+1])s=o+1;else{s=o;break}}return{col:e-r[s]+1,line:s+1}}mapResolve(e){return/^\w+:\/\//.test(e)?e:bi(this.map.consumer().sourceRoot||this.map.root||".",e)}origin(e,t,r,s){if(!this.map)return!1;let n=this.map.consumer(),o=n.originalPositionFor({column:t,line:e});if(!o.source)return!1;let l;typeof r=="number"&&(l=n.originalPositionFor({column:s,line:r}));let a;Si(o.source)?a=Ft(o.source):a=new URL(o.source,this.map.consumer().sourceRoot||Ft(this.map.mapFile));let u={column:o.column,endColumn:l&&l.column,endLine:l&&l.line,line:o.line,url:a.toString()};if(a.protocol==="file:")if(Js)u.file=Js(a);else throw new Error("file: protocol is not available in this PostCSS build");let c=n.sourceContentFor(o.source);return c&&(u.source=c),u}toJSON(){let e={};for(let t of["hasBOM","css","file","id"])this[t]!=null&&(e[t]=this[t]);return this.map&&(e.map={...this.map},e.map.consumerCache&&(e.map.consumerCache=void 0)),e}get from(){return this.file||this.id}},Er=lr;lr.default=lr;Gr&&Gr.registerInput&&Gr.registerInput(lr);var{SourceMapConsumer:go,SourceMapGenerator:Kt}=ge,{dirname:qt,relative:yo,resolve:vo,sep:wo}=ge,{pathToFileURL:Qs}=ge,Lc=Er,Fc=!!(go&&Kt),Uc=!!(qt&&vo&&yo&&wo),zc=class{constructor(e,t,r,s){this.stringify=e,this.mapOpts=r.map||{},this.root=t,this.opts=r,this.css=s,this.originalCSS=s,this.usesFileUrls=!this.mapOpts.from&&this.mapOpts.absolute,this.memoizedFileURLs=new Map,this.memoizedPaths=new Map,this.memoizedURLs=new Map}addAnnotation(){let e;this.isInline()?e="data:application/json;base64,"+this.toBase64(this.map.toString()):typeof this.mapOpts.annotation=="string"?e=this.mapOpts.annotation:typeof this.mapOpts.annotation=="function"?e=this.mapOpts.annotation(this.opts.to,this.root):e=this.outputFile()+".map";let t=`
|
|
48
45
|
`;this.css.includes(`\r
|
|
49
46
|
`)&&(t=`\r
|
|
50
|
-
`),this.css+=t+"/*# sourceMappingURL="+e+" */"}applyPrevMaps(){for(let e of this.previous()){let t=this.toUrl(this.path(e.file)),r=e.root||qt(e.file),s;this.mapOpts.sourcesContent===!1?(s=new
|
|
51
|
-
`),t=l.length-o):t+=l.length,a&&u!=="start"){let c=a.parent||{raws:{}};(!(a.type==="decl"||a.type==="atrule"&&!a.nodes)||a!==c.last||c.raws.semicolon)&&(a.source&&a.source.end?(s.source=this.sourcePath(a),s.original.line=a.source.end.line,s.original.column=a.source.end.column-1,s.generated.line=e,s.generated.column=t-2,this.map.addMapping(s)):(s.source=r,s.original.line=1,s.original.column=0,s.generated.line=e,s.generated.column=t-1,this.map.addMapping(s)))}})}isAnnotation(){return this.isInline()?!0:typeof this.mapOpts.annotation<"u"?this.mapOpts.annotation:this.previous().length?this.previous().some(e=>e.annotation):!0}isInline(){if(typeof this.mapOpts.inline<"u")return this.mapOpts.inline;let e=this.mapOpts.annotation;return typeof e<"u"&&e!==!0?!1:this.previous().length?this.previous().some(t=>t.inline):!0}isMap(){return typeof this.opts.map<"u"?!!this.opts.map:this.previous().length>0}isSourcesContent(){return typeof this.mapOpts.sourcesContent<"u"?this.mapOpts.sourcesContent:this.previous().length?this.previous().some(e=>e.withContent()):!0}outputFile(){return this.opts.to?this.path(this.opts.to):this.opts.from?this.path(this.opts.from):"to.css"}path(e){if(this.mapOpts.absolute||e.charCodeAt(0)===60||/^\w+:\/\//.test(e))return e;let t=this.memoizedPaths.get(e);if(t)return t;let r=this.opts.to?qt(this.opts.to):".";typeof this.mapOpts.annotation=="string"&&(r=qt(bo(r,this.mapOpts.annotation)));let s=So(r,e);return this.memoizedPaths.set(e,s),s}previous(){if(!this.previousMaps)if(this.previousMaps=[],this.root)this.root.walk(e=>{if(e.source&&e.source.input.map){let t=e.source.input.map;this.previousMaps.includes(t)||this.previousMaps.push(t)}});else{let e=new Hc(this.originalCSS,this.opts);e.map&&this.previousMaps.push(e.map)}return this.previousMaps}setSourcesContent(){let e={};if(this.root)this.root.walk(t=>{if(t.source){let r=t.source.input.from;if(r&&!e[r]){e[r]=!0;let s=this.usesFileUrls?this.toFileUrl(r):this.toUrl(this.path(r));this.map.setSourceContent(s,t.source.input.css)}}});else if(this.css){let t=this.opts.from?this.toUrl(this.path(this.opts.from)):"<no source>";this.map.setSourceContent(t,this.css)}}sourcePath(e){return this.mapOpts.from?this.toUrl(this.mapOpts.from):this.usesFileUrls?this.toFileUrl(e.source.input.from):this.toUrl(this.path(e.source.input.from))}toBase64(e){return Buffer?Buffer.from(e).toString("base64"):window.btoa(unescape(encodeURIComponent(e)))}toFileUrl(e){let t=this.memoizedFileURLs.get(e);if(t)return t;if(en){let r=en(e).toString();return this.memoizedFileURLs.set(e,r),r}else throw new Error("`map.absolute` option is not available in this PostCSS build")}toUrl(e){let t=this.memoizedURLs.get(e);if(t)return t;Co==="\\"&&(e=e.replace(/\\/g,"/"));let r=encodeURI(e).replace(/[#?]/g,encodeURIComponent);return this.memoizedURLs.set(e,r),r}},xo=Xc,Jc=Cr,Ci=class extends Jc{constructor(e){super(e),this.type="comment"}},Er=Ci;Ci.default=Ci;var{isClean:Io,my:Eo}=xt,Mo=xr,No=Er,Kc=Cr,Ao,rs,is,Ro;function Oo(i){return i.map(e=>(e.nodes&&(e.nodes=Oo(e.nodes)),delete e.source,e))}function To(i){if(i[Io]=!1,i.proxyOf.nodes)for(let e of i.proxyOf.nodes)To(e)}var Ee=class Do extends Kc{append(...e){for(let t of e){let r=this.normalize(t,this.last);for(let s of r)this.proxyOf.nodes.push(s)}return this.markDirty(),this}cleanRaws(e){if(super.cleanRaws(e),this.nodes)for(let t of this.nodes)t.cleanRaws(e)}each(e){if(!this.proxyOf.nodes)return;let t=this.getIterator(),r,s;for(;this.indexes[t]<this.proxyOf.nodes.length&&(r=this.indexes[t],s=e(this.proxyOf.nodes[r],r),s!==!1);)this.indexes[t]+=1;return delete this.indexes[t],s}every(e){return this.nodes.every(e)}getIterator(){this.lastEach||(this.lastEach=0),this.indexes||(this.indexes={}),this.lastEach+=1;let e=this.lastEach;return this.indexes[e]=0,e}getProxyProcessor(){return{get(e,t){return t==="proxyOf"?e:e[t]?t==="each"||typeof t=="string"&&t.startsWith("walk")?(...r)=>e[t](...r.map(s=>typeof s=="function"?(n,o)=>s(n.toProxy(),o):s)):t==="every"||t==="some"?r=>e[t]((s,...n)=>r(s.toProxy(),...n)):t==="root"?()=>e.root().toProxy():t==="nodes"?e.nodes.map(r=>r.toProxy()):t==="first"||t==="last"?e[t].toProxy():e[t]:e[t]},set(e,t,r){return e[t]===r||(e[t]=r,(t==="name"||t==="params"||t==="selector")&&e.markDirty()),!0}}}index(e){return typeof e=="number"?e:(e.proxyOf&&(e=e.proxyOf),this.proxyOf.nodes.indexOf(e))}insertAfter(e,t){let r=this.index(e),s=this.normalize(t,this.proxyOf.nodes[r]).reverse();r=this.index(e);for(let o of s)this.proxyOf.nodes.splice(r+1,0,o);let n;for(let o in this.indexes)n=this.indexes[o],r<n&&(this.indexes[o]=n+s.length);return this.markDirty(),this}insertBefore(e,t){let r=this.index(e),s=r===0?"prepend":!1,n=this.normalize(t,this.proxyOf.nodes[r],s).reverse();r=this.index(e);for(let l of n)this.proxyOf.nodes.splice(r,0,l);let o;for(let l in this.indexes)o=this.indexes[l],r<=o&&(this.indexes[l]=o+n.length);return this.markDirty(),this}normalize(e,t){if(typeof e=="string")e=Oo(Ao(e).nodes);else if(typeof e>"u")e=[];else if(Array.isArray(e)){e=e.slice(0);for(let s of e)s.parent&&s.parent.removeChild(s,"ignore")}else if(e.type==="root"&&this.type!=="document"){e=e.nodes.slice(0);for(let s of e)s.parent&&s.parent.removeChild(s,"ignore")}else if(e.type)e=[e];else if(e.prop){if(typeof e.value>"u")throw new Error("Value field is missed in node creation");typeof e.value!="string"&&(e.value=String(e.value)),e=[new Mo(e)]}else if(e.selector)e=[new rs(e)];else if(e.name)e=[new is(e)];else if(e.text)e=[new No(e)];else throw new Error("Unknown node type in node creation");return e.map(s=>(s[Eo]||Do.rebuild(s),s=s.proxyOf,s.parent&&s.parent.removeChild(s),s[Io]&&To(s),typeof s.raws.before>"u"&&t&&typeof t.raws.before<"u"&&(s.raws.before=t.raws.before.replace(/\S/g,"")),s.parent=this.proxyOf,s))}prepend(...e){e=e.reverse();for(let t of e){let r=this.normalize(t,this.first,"prepend").reverse();for(let s of r)this.proxyOf.nodes.unshift(s);for(let s in this.indexes)this.indexes[s]=this.indexes[s]+r.length}return this.markDirty(),this}push(e){return e.parent=this,this.proxyOf.nodes.push(e),this}removeAll(){for(let e of this.proxyOf.nodes)e.parent=void 0;return this.proxyOf.nodes=[],this.markDirty(),this}removeChild(e){e=this.index(e),this.proxyOf.nodes[e].parent=void 0,this.proxyOf.nodes.splice(e,1);let t;for(let r in this.indexes)t=this.indexes[r],t>=e&&(this.indexes[r]=t-1);return this.markDirty(),this}replaceValues(e,t,r){return r||(r=t,t={}),this.walkDecls(s=>{t.props&&!t.props.includes(s.prop)||t.fast&&!s.value.includes(t.fast)||(s.value=s.value.replace(e,r))}),this.markDirty(),this}some(e){return this.nodes.some(e)}walk(e){return this.each((t,r)=>{let s;try{s=e(t,r)}catch(n){throw t.addToError(n)}return s!==!1&&t.walk&&(s=t.walk(e)),s})}walkAtRules(e,t){return t?e instanceof RegExp?this.walk((r,s)=>{if(r.type==="atrule"&&e.test(r.name))return t(r,s)}):this.walk((r,s)=>{if(r.type==="atrule"&&r.name===e)return t(r,s)}):(t=e,this.walk((r,s)=>{if(r.type==="atrule")return t(r,s)}))}walkComments(e){return this.walk((t,r)=>{if(t.type==="comment")return e(t,r)})}walkDecls(e,t){return t?e instanceof RegExp?this.walk((r,s)=>{if(r.type==="decl"&&e.test(r.prop))return t(r,s)}):this.walk((r,s)=>{if(r.type==="decl"&&r.prop===e)return t(r,s)}):(t=e,this.walk((r,s)=>{if(r.type==="decl")return t(r,s)}))}walkRules(e,t){return t?e instanceof RegExp?this.walk((r,s)=>{if(r.type==="rule"&&e.test(r.selector))return t(r,s)}):this.walk((r,s)=>{if(r.type==="rule"&&r.selector===e)return t(r,s)}):(t=e,this.walk((r,s)=>{if(r.type==="rule")return t(r,s)}))}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]}};Ee.registerParse=i=>{Ao=i};Ee.registerRule=i=>{rs=i};Ee.registerAtRule=i=>{is=i};Ee.registerRoot=i=>{Ro=i};var Le=Ee;Ee.default=Ee;Ee.rebuild=i=>{i.type==="atrule"?Object.setPrototypeOf(i,is.prototype):i.type==="rule"?Object.setPrototypeOf(i,rs.prototype):i.type==="decl"?Object.setPrototypeOf(i,Mo.prototype):i.type==="comment"?Object.setPrototypeOf(i,No.prototype):i.type==="root"&&Object.setPrototypeOf(i,Ro.prototype),i[Eo]=!0,i.nodes&&i.nodes.forEach(e=>{Ee.rebuild(e)})};var qc=Le,ko,_o,gt=class extends qc{constructor(e){super({type:"document",...e}),this.nodes||(this.nodes=[])}toResult(e={}){return new ko(new _o,this,e).stringify()}};gt.registerLazyResult=i=>{ko=i};gt.registerProcessor=i=>{_o=i};var ss=gt;gt.default=gt;var tn={},Po=function(e){tn[e]||(tn[e]=!0,typeof console<"u"&&console.warn&&console.warn(e))},xi=class{constructor(e,t={}){if(this.type="warning",this.text=e,t.node&&t.node.source){let r=t.node.rangeBy(t);this.line=r.start.line,this.column=r.start.column,this.endLine=r.end.line,this.endColumn=r.end.column}for(let r in t)this[r]=t[r]}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}},$o=xi;xi.default=xi;var Qc=$o,Ii=class{constructor(e,t,r){this.processor=e,this.messages=[],this.root=t,this.opts=r,this.css=void 0,this.map=void 0}toString(){return this.css}warn(e,t={}){t.plugin||this.lastPlugin&&this.lastPlugin.postcssPlugin&&(t.plugin=this.lastPlugin.postcssPlugin);let r=new Qc(e,t);return this.messages.push(r),r}warnings(){return this.messages.filter(e=>e.type==="warning")}get content(){return this.css}},ns=Ii;Ii.default=Ii;var Hr=39,rn=34,Ut=92,sn=47,zt=10,nt=32,Bt=12,Wt=9,Vt=13,eh=91,th=93,rh=40,ih=41,sh=123,nh=125,oh=59,ah=42,lh=58,uh=64,Gt=/[\t\n\f\r "#'()/;[\\\]{}]/g,jt=/[\t\n\f\r !"#'():;@[\\\]{}]|\/(?=\*)/g,ch=/.[\r\n"'(/\\]/,nn=/[\da-f]/i,hh=function(e,t={}){let r=e.css.valueOf(),s=t.ignoreErrors,n,o,l,a,u,c,h,p,m,g,d=r.length,f=0,S=[],w=[];function y(){return f}function b(x){throw e.error("Unclosed "+x,f)}function E(){return w.length===0&&f>=d}function M(x){if(w.length)return w.pop();if(f>=d)return;let C=x?x.ignoreUnclosed:!1;switch(n=r.charCodeAt(f),n){case zt:case nt:case Wt:case Vt:case Bt:{o=f;do o+=1,n=r.charCodeAt(o);while(n===nt||n===zt||n===Wt||n===Vt||n===Bt);g=["space",r.slice(f,o)],f=o-1;break}case eh:case th:case sh:case nh:case lh:case oh:case ih:{let k=String.fromCharCode(n);g=[k,k,f];break}case rh:{if(p=S.length?S.pop()[1]:"",m=r.charCodeAt(f+1),p==="url"&&m!==Hr&&m!==rn&&m!==nt&&m!==zt&&m!==Wt&&m!==Bt&&m!==Vt){o=f;do{if(c=!1,o=r.indexOf(")",o+1),o===-1)if(s||C){o=f;break}else b("bracket");for(h=o;r.charCodeAt(h-1)===Ut;)h-=1,c=!c}while(c);g=["brackets",r.slice(f,o+1),f,o],f=o}else o=r.indexOf(")",f+1),a=r.slice(f,o+1),o===-1||ch.test(a)?g=["(","(",f]:(g=["brackets",a,f,o],f=o);break}case Hr:case rn:{l=n===Hr?"'":'"',o=f;do{if(c=!1,o=r.indexOf(l,o+1),o===-1)if(s||C){o=f+1;break}else b("string");for(h=o;r.charCodeAt(h-1)===Ut;)h-=1,c=!c}while(c);g=["string",r.slice(f,o+1),f,o],f=o;break}case uh:{Gt.lastIndex=f+1,Gt.test(r),Gt.lastIndex===0?o=r.length-1:o=Gt.lastIndex-2,g=["at-word",r.slice(f,o+1),f,o],f=o;break}case Ut:{for(o=f,u=!0;r.charCodeAt(o+1)===Ut;)o+=1,u=!u;if(n=r.charCodeAt(o+1),u&&n!==sn&&n!==nt&&n!==zt&&n!==Wt&&n!==Vt&&n!==Bt&&(o+=1,nn.test(r.charAt(o)))){for(;nn.test(r.charAt(o+1));)o+=1;r.charCodeAt(o+1)===nt&&(o+=1)}g=["word",r.slice(f,o+1),f,o],f=o;break}default:{n===sn&&r.charCodeAt(f+1)===ah?(o=r.indexOf("*/",f+2)+1,o===0&&(s||C?o=r.length:b("comment")),g=["comment",r.slice(f,o+1),f,o],f=o):(jt.lastIndex=f+1,jt.test(r),jt.lastIndex===0?o=r.length-1:o=jt.lastIndex-2,g=["word",r.slice(f,o+1),f,o],S.push(g),f=o);break}}return f++,g}function R(x){w.push(x)}return{back:R,endOfFile:E,nextToken:M,position:y}},Lo=Le,ur=class extends Lo{constructor(e){super(e),this.type="atrule"}append(...e){return this.proxyOf.nodes||(this.nodes=[]),super.append(...e)}prepend(...e){return this.proxyOf.nodes||(this.nodes=[]),super.prepend(...e)}},os=ur;ur.default=ur;Lo.registerAtRule(ur);var Fo=Le,Uo,zo,Ze=class extends Fo{constructor(e){super(e),this.type="root",this.nodes||(this.nodes=[])}normalize(e,t,r){let s=super.normalize(e);if(t){if(r==="prepend")this.nodes.length>1?t.raws.before=this.nodes[1].raws.before:delete t.raws.before;else if(this.first!==t)for(let n of s)n.raws.before=t.raws.before}return s}removeChild(e,t){let r=this.index(e);return!t&&r===0&&this.nodes.length>1&&(this.nodes[1].raws.before=this.nodes[r].raws.before),super.removeChild(e)}toResult(e={}){return new Uo(new zo,this,e).stringify()}};Ze.registerLazyResult=i=>{Uo=i};Ze.registerProcessor=i=>{zo=i};var It=Ze;Ze.default=Ze;Fo.registerRoot(Ze);var yt={comma(i){return yt.split(i,[","],!0)},space(i){let e=[" ",`
|
|
52
|
-
`," "];return yt.split(i,e)},split(i,e,t){let r=[],s="",n=!1,o=0,l=!1,a="",u=!1;for(let c of i)u?u=!1:c==="\\"?u=!0:l?c===a&&(l=!1):c==='"'||c==="'"?(l=!0,a=c):c==="("?o+=1:c===")"?o>0&&(o-=1):o===0&&e.includes(c)&&(n=!0),n?(s!==""&&r.push(s.trim()),s="",n=!1):s+=c;return(t||s!=="")&&r.push(s.trim()),r}},Bo=yt;yt.default=yt;var Wo=Le,fh=Bo,cr=class extends Wo{constructor(e){super(e),this.type="rule",this.nodes||(this.nodes=[])}get selectors(){return fh.comma(this.selector)}set selectors(e){let t=this.selector?this.selector.match(/,\s*/):null,r=t?t[0]:","+this.raw("between","beforeOpen");this.selector=e.join(r)}},as=cr;cr.default=cr;Wo.registerRule(cr);var dh=xr,ph=hh,mh=Er,gh=os,yh=It,on=as,an={empty:!0,space:!0};function vh(i){for(let e=i.length-1;e>=0;e--){let t=i[e],r=t[3]||t[2];if(r)return r}}var wh=class{constructor(e){this.input=e,this.root=new yh,this.current=this.root,this.spaces="",this.semicolon=!1,this.createTokenizer(),this.root.source={input:e,start:{column:1,line:1,offset:0}}}atrule(e){let t=new gh;t.name=e[1].slice(1),t.name===""&&this.unnamedAtrule(t,e),this.init(t,e[2]);let r,s,n,o=!1,l=!1,a=[],u=[];for(;!this.tokenizer.endOfFile();){if(e=this.tokenizer.nextToken(),r=e[0],r==="("||r==="["?u.push(r==="("?")":"]"):r==="{"&&u.length>0?u.push("}"):r===u[u.length-1]&&u.pop(),u.length===0)if(r===";"){t.source.end=this.getPosition(e[2]),t.source.end.offset++,this.semicolon=!0;break}else if(r==="{"){l=!0;break}else if(r==="}"){if(a.length>0){for(n=a.length-1,s=a[n];s&&s[0]==="space";)s=a[--n];s&&(t.source.end=this.getPosition(s[3]||s[2]),t.source.end.offset++)}this.end(e);break}else a.push(e);else a.push(e);if(this.tokenizer.endOfFile()){o=!0;break}}t.raws.between=this.spacesAndCommentsFromEnd(a),a.length?(t.raws.afterName=this.spacesAndCommentsFromStart(a),this.raw(t,"params",a),o&&(e=a[a.length-1],t.source.end=this.getPosition(e[3]||e[2]),t.source.end.offset++,this.spaces=t.raws.between,t.raws.between="")):(t.raws.afterName="",t.params=""),l&&(t.nodes=[],this.current=t)}checkMissedSemicolon(e){let t=this.colon(e);if(t===!1)return;let r=0,s;for(let n=t-1;n>=0&&(s=e[n],!(s[0]!=="space"&&(r+=1,r===2)));n--);throw this.input.error("Missed semicolon",s[0]==="word"?s[3]+1:s[2])}colon(e){let t=0,r,s,n;for(let[o,l]of e.entries()){if(r=l,s=r[0],s==="("&&(t+=1),s===")"&&(t-=1),t===0&&s===":")if(!n)this.doubleColon(r);else{if(n[0]==="word"&&n[1]==="progid")continue;return o}n=r}return!1}comment(e){let t=new mh;this.init(t,e[2]),t.source.end=this.getPosition(e[3]||e[2]),t.source.end.offset++;let r=e[1].slice(2,-2);if(/^\s*$/.test(r))t.text="",t.raws.left=r,t.raws.right="";else{let s=r.match(/^(\s*)([^]*\S)(\s*)$/);t.text=s[2],t.raws.left=s[1],t.raws.right=s[3]}}createTokenizer(){this.tokenizer=ph(this.input)}decl(e,t){let r=new dh;this.init(r,e[0][2]);let s=e[e.length-1];for(s[0]===";"&&(this.semicolon=!0,e.pop()),r.source.end=this.getPosition(s[3]||s[2]||vh(e)),r.source.end.offset++;e[0][0]!=="word";)e.length===1&&this.unknownWord(e),r.raws.before+=e.shift()[1];for(r.source.start=this.getPosition(e[0][2]),r.prop="";e.length;){let u=e[0][0];if(u===":"||u==="space"||u==="comment")break;r.prop+=e.shift()[1]}r.raws.between="";let n;for(;e.length;)if(n=e.shift(),n[0]===":"){r.raws.between+=n[1];break}else n[0]==="word"&&/\w/.test(n[1])&&this.unknownWord([n]),r.raws.between+=n[1];(r.prop[0]==="_"||r.prop[0]==="*")&&(r.raws.before+=r.prop[0],r.prop=r.prop.slice(1));let o=[],l;for(;e.length&&(l=e[0][0],!(l!=="space"&&l!=="comment"));)o.push(e.shift());this.precheckMissedSemicolon(e);for(let u=e.length-1;u>=0;u--){if(n=e[u],n[1].toLowerCase()==="!important"){r.important=!0;let c=this.stringFrom(e,u);c=this.spacesFromEnd(e)+c,c!==" !important"&&(r.raws.important=c);break}else if(n[1].toLowerCase()==="important"){let c=e.slice(0),h="";for(let p=u;p>0;p--){let m=c[p][0];if(h.trim().indexOf("!")===0&&m!=="space")break;h=c.pop()[1]+h}h.trim().indexOf("!")===0&&(r.important=!0,r.raws.important=h,e=c)}if(n[0]!=="space"&&n[0]!=="comment")break}e.some(u=>u[0]!=="space"&&u[0]!=="comment")&&(r.raws.between+=o.map(u=>u[1]).join(""),o=[]),this.raw(r,"value",o.concat(e),t),r.value.includes(":")&&!t&&this.checkMissedSemicolon(e)}doubleColon(e){throw this.input.error("Double colon",{offset:e[2]},{offset:e[2]+e[1].length})}emptyRule(e){let t=new on;this.init(t,e[2]),t.selector="",t.raws.between="",this.current=t}end(e){this.current.nodes&&this.current.nodes.length&&(this.current.raws.semicolon=this.semicolon),this.semicolon=!1,this.current.raws.after=(this.current.raws.after||"")+this.spaces,this.spaces="",this.current.parent?(this.current.source.end=this.getPosition(e[2]),this.current.source.end.offset++,this.current=this.current.parent):this.unexpectedClose(e)}endFile(){this.current.parent&&this.unclosedBlock(),this.current.nodes&&this.current.nodes.length&&(this.current.raws.semicolon=this.semicolon),this.current.raws.after=(this.current.raws.after||"")+this.spaces,this.root.source.end=this.getPosition(this.tokenizer.position())}freeSemicolon(e){if(this.spaces+=e[1],this.current.nodes){let t=this.current.nodes[this.current.nodes.length-1];t&&t.type==="rule"&&!t.raws.ownSemicolon&&(t.raws.ownSemicolon=this.spaces,this.spaces="")}}getPosition(e){let t=this.input.fromOffset(e);return{column:t.col,line:t.line,offset:e}}init(e,t){this.current.push(e),e.source={input:this.input,start:this.getPosition(t)},e.raws.before=this.spaces,this.spaces="",e.type!=="comment"&&(this.semicolon=!1)}other(e){let t=!1,r=null,s=!1,n=null,o=[],l=e[1].startsWith("--"),a=[],u=e;for(;u;){if(r=u[0],a.push(u),r==="("||r==="[")n||(n=u),o.push(r==="("?")":"]");else if(l&&s&&r==="{")n||(n=u),o.push("}");else if(o.length===0)if(r===";")if(s){this.decl(a,l);return}else break;else if(r==="{"){this.rule(a);return}else if(r==="}"){this.tokenizer.back(a.pop()),t=!0;break}else r===":"&&(s=!0);else r===o[o.length-1]&&(o.pop(),o.length===0&&(n=null));u=this.tokenizer.nextToken()}if(this.tokenizer.endOfFile()&&(t=!0),o.length>0&&this.unclosedBracket(n),t&&s){if(!l)for(;a.length&&(u=a[a.length-1][0],!(u!=="space"&&u!=="comment"));)this.tokenizer.back(a.pop());this.decl(a,l)}else this.unknownWord(a)}parse(){let e;for(;!this.tokenizer.endOfFile();)switch(e=this.tokenizer.nextToken(),e[0]){case"space":this.spaces+=e[1];break;case";":this.freeSemicolon(e);break;case"}":this.end(e);break;case"comment":this.comment(e);break;case"at-word":this.atrule(e);break;case"{":this.emptyRule(e);break;default:this.other(e);break}this.endFile()}precheckMissedSemicolon(){}raw(e,t,r,s){let n,o,l=r.length,a="",u=!0,c,h;for(let p=0;p<l;p+=1)n=r[p],o=n[0],o==="space"&&p===l-1&&!s?u=!1:o==="comment"?(h=r[p-1]?r[p-1][0]:"empty",c=r[p+1]?r[p+1][0]:"empty",!an[h]&&!an[c]?a.slice(-1)===","?u=!1:a+=n[1]:u=!1):a+=n[1];if(!u){let p=r.reduce((m,g)=>m+g[1],"");e.raws[t]={raw:p,value:a}}e[t]=a}rule(e){e.pop();let t=new on;this.init(t,e[0][2]),t.raws.between=this.spacesAndCommentsFromEnd(e),this.raw(t,"selector",e),this.current=t}spacesAndCommentsFromEnd(e){let t,r="";for(;e.length&&(t=e[e.length-1][0],!(t!=="space"&&t!=="comment"));)r=e.pop()[1]+r;return r}spacesAndCommentsFromStart(e){let t,r="";for(;e.length&&(t=e[0][0],!(t!=="space"&&t!=="comment"));)r+=e.shift()[1];return r}spacesFromEnd(e){let t,r="";for(;e.length&&(t=e[e.length-1][0],t==="space");)r=e.pop()[1]+r;return r}stringFrom(e,t){let r="";for(let s=t;s<e.length;s++)r+=e[s][1];return e.splice(t,e.length-t),r}unclosedBlock(){let e=this.current.source.start;throw this.input.error("Unclosed block",e.line,e.column)}unclosedBracket(e){throw this.input.error("Unclosed bracket",{offset:e[2]},{offset:e[2]+1})}unexpectedClose(e){throw this.input.error("Unexpected }",{offset:e[2]},{offset:e[2]+1})}unknownWord(e){throw this.input.error("Unknown word",{offset:e[0][2]},{offset:e[0][2]+e[0][1].length})}unnamedAtrule(e,t){throw this.input.error("At-rule without name",{offset:t[2]},{offset:t[2]+t[1].length})}},Sh=wh,bh=Le,Ch=Sh,xh=Ir;function hr(i,e){let t=new xh(i,e),r=new Ch(t);try{r.parse()}catch(s){throw process.env.NODE_ENV!=="production"&&s.name==="CssSyntaxError"&&e&&e.from&&(/\.scss$/i.test(e.from)?s.message+=`
|
|
53
|
-
You tried to parse SCSS with the standard CSS parser; try again with the postcss-scss parser`:/\.sass/i.test(e.from)?s.message+=`
|
|
54
|
-
You tried to parse Sass with the standard CSS parser; try again with the postcss-sass parser`:/\.less$/i.test(e.from)&&(s.message+=`
|
|
55
|
-
You tried to parse Less with the standard CSS parser; try again with the postcss-less parser`)),s}return r.root}var ls=hr;hr.default=hr;bh.registerParse(hr);var{isClean:Se,my:Ih}=xt,Eh=xo,Mh=br,Nh=Le,Ah=ss,Rh=Po,ln=ns,Oh=ls,Th=It,Dh={atrule:"AtRule",comment:"Comment",decl:"Declaration",document:"Document",root:"Root",rule:"Rule"},kh={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},_h={Once:!0,postcssPlugin:!0,prepare:!0},Xe=0;function ot(i){return typeof i=="object"&&typeof i.then=="function"}function Vo(i){let e=!1,t=Dh[i.type];return i.type==="decl"?e=i.prop.toLowerCase():i.type==="atrule"&&(e=i.name.toLowerCase()),e&&i.append?[t,t+"-"+e,Xe,t+"Exit",t+"Exit-"+e]:e?[t,t+"-"+e,t+"Exit",t+"Exit-"+e]:i.append?[t,Xe,t+"Exit"]:[t,t+"Exit"]}function un(i){let e;return i.type==="document"?e=["Document",Xe,"DocumentExit"]:i.type==="root"?e=["Root",Xe,"RootExit"]:e=Vo(i),{eventIndex:0,events:e,iterator:0,node:i,visitorIndex:0,visitors:[]}}function Ei(i){return i[Se]=!1,i.nodes&&i.nodes.forEach(e=>Ei(e)),i}var Mi={},Je=class Go{constructor(e,t,r){this.stringified=!1,this.processed=!1;let s;if(typeof t=="object"&&t!==null&&(t.type==="root"||t.type==="document"))s=Ei(t);else if(t instanceof Go||t instanceof ln)s=Ei(t.root),t.map&&(typeof r.map>"u"&&(r.map={}),r.map.inline||(r.map.inline=!1),r.map.prev=t.map);else{let n=Oh;r.syntax&&(n=r.syntax.parse),r.parser&&(n=r.parser),n.parse&&(n=n.parse);try{s=n(t,r)}catch(o){this.processed=!0,this.error=o}s&&!s[Ih]&&Nh.rebuild(s)}this.result=new ln(e,s,r),this.helpers={...Mi,postcss:Mi,result:this.result},this.plugins=this.processor.plugins.map(n=>typeof n=="object"&&n.prepare?{...n,...n.prepare(this.result)}:n)}async(){return this.error?Promise.reject(this.error):this.processed?Promise.resolve(this.result):(this.processing||(this.processing=this.runAsync()),this.processing)}catch(e){return this.async().catch(e)}finally(e){return this.async().then(e,e)}getAsyncError(){throw new Error("Use process(css).then(cb) to work with async plugins")}handleError(e,t){let r=this.result.lastPlugin;try{if(t&&t.addToError(e),this.error=e,e.name==="CssSyntaxError"&&!e.plugin)e.plugin=r.postcssPlugin,e.setMessage();else if(r.postcssVersion&&process.env.NODE_ENV!=="production"){let s=r.postcssPlugin,n=r.postcssVersion,o=this.result.processor.version,l=n.split("."),a=o.split(".");(l[0]!==a[0]||parseInt(l[1])>parseInt(a[1]))&&console.error("Unknown error from PostCSS plugin. Your current PostCSS version is "+o+", but "+s+" uses "+n+". Perhaps this is the source of the error below.")}}catch(s){console&&console.error&&console.error(s)}return e}prepareVisitors(){this.listeners={};let e=(t,r,s)=>{this.listeners[r]||(this.listeners[r]=[]),this.listeners[r].push([t,s])};for(let t of this.plugins)if(typeof t=="object")for(let r in t){if(!kh[r]&&/^[A-Z]/.test(r))throw new Error(`Unknown event ${r} in ${t.postcssPlugin}. Try to update PostCSS (${this.processor.version} now).`);if(!_h[r])if(typeof t[r]=="object")for(let s in t[r])s==="*"?e(t,r,t[r][s]):e(t,r+"-"+s.toLowerCase(),t[r][s]);else typeof t[r]=="function"&&e(t,r,t[r])}this.hasListener=Object.keys(this.listeners).length>0}async runAsync(){this.plugin=0;for(let e=0;e<this.plugins.length;e++){let t=this.plugins[e],r=this.runOnRoot(t);if(ot(r))try{await r}catch(s){throw this.handleError(s)}}if(this.prepareVisitors(),this.hasListener){let e=this.result.root;for(;!e[Se];){e[Se]=!0;let t=[un(e)];for(;t.length>0;){let r=this.visitTick(t);if(ot(r))try{await r}catch(s){let n=t[t.length-1].node;throw this.handleError(s,n)}}}if(this.listeners.OnceExit)for(let[t,r]of this.listeners.OnceExit){this.result.lastPlugin=t;try{if(e.type==="document"){let s=e.nodes.map(n=>r(n,this.helpers));await Promise.all(s)}else await r(e,this.helpers)}catch(s){throw this.handleError(s)}}}return this.processed=!0,this.stringify()}runOnRoot(e){this.result.lastPlugin=e;try{if(typeof e=="object"&&e.Once){if(this.result.root.type==="document"){let t=this.result.root.nodes.map(r=>e.Once(r,this.helpers));return ot(t[0])?Promise.all(t):t}return e.Once(this.result.root,this.helpers)}else if(typeof e=="function")return e(this.result.root,this.result)}catch(t){throw this.handleError(t)}}stringify(){if(this.error)throw this.error;if(this.stringified)return this.result;this.stringified=!0,this.sync();let e=this.result.opts,t=Mh;e.syntax&&(t=e.syntax.stringify),e.stringifier&&(t=e.stringifier),t.stringify&&(t=t.stringify);let s=new Eh(t,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 e of this.plugins){let t=this.runOnRoot(e);if(ot(t))throw this.getAsyncError()}if(this.prepareVisitors(),this.hasListener){let e=this.result.root;for(;!e[Se];)e[Se]=!0,this.walkSync(e);if(this.listeners.OnceExit)if(e.type==="document")for(let t of e.nodes)this.visitSync(this.listeners.OnceExit,t);else this.visitSync(this.listeners.OnceExit,e)}return this.result}then(e,t){return process.env.NODE_ENV!=="production"&&("from"in this.opts||Rh("Without `from` option PostCSS could generate wrong source map and will not find Browserslist config. Set it to CSS file path or to `undefined` to prevent this warning.")),this.async().then(e,t)}toString(){return this.css}visitSync(e,t){for(let[r,s]of e){this.result.lastPlugin=r;let n;try{n=s(t,this.helpers)}catch(o){throw this.handleError(o,t.proxyOf)}if(t.type!=="root"&&t.type!=="document"&&!t.parent)return!0;if(ot(n))throw this.getAsyncError()}}visitTick(e){let t=e[e.length-1],{node:r,visitors:s}=t;if(r.type!=="root"&&r.type!=="document"&&!r.parent){e.pop();return}if(s.length>0&&t.visitorIndex<s.length){let[o,l]=s[t.visitorIndex];t.visitorIndex+=1,t.visitorIndex===s.length&&(t.visitors=[],t.visitorIndex=0),this.result.lastPlugin=o;try{return l(r.toProxy(),this.helpers)}catch(a){throw this.handleError(a,r)}}if(t.iterator!==0){let o=t.iterator,l;for(;l=r.nodes[r.indexes[o]];)if(r.indexes[o]+=1,!l[Se]){l[Se]=!0,e.push(un(l));return}t.iterator=0,delete r.indexes[o]}let n=t.events;for(;t.eventIndex<n.length;){let o=n[t.eventIndex];if(t.eventIndex+=1,o===Xe){r.nodes&&r.nodes.length&&(r[Se]=!0,t.iterator=r.getIterator());return}else if(this.listeners[o]){t.visitors=this.listeners[o];return}}e.pop()}walkSync(e){e[Se]=!0;let t=Vo(e);for(let r of t)if(r===Xe)e.nodes&&e.each(s=>{s[Se]||this.walkSync(s)});else{let s=this.listeners[r];if(s&&this.visitSync(s,e.toProxy()))return}}warnings(){return this.sync().warnings()}get content(){return this.stringify().content}get css(){return this.stringify().css}get map(){return this.stringify().map}get messages(){return this.sync().messages}get opts(){return this.result.opts}get processor(){return this.result.processor}get root(){return this.sync().root}get[Symbol.toStringTag](){return"LazyResult"}};Je.registerPostcss=i=>{Mi=i};var jo=Je;Je.default=Je;Th.registerLazyResult(Je);Ah.registerLazyResult(Je);var Ph=xo,$h=br,Lh=Po,Fh=ls,Uh=ns,Ni=class{constructor(e,t,r){t=t.toString(),this.stringified=!1,this._processor=e,this._css=t,this._opts=r,this._map=void 0;let s,n=$h;this.result=new Uh(this._processor,s,this._opts),this.result.css=t;let o=this;Object.defineProperty(this.result,"root",{get(){return o.root}});let l=new Ph(n,s,this._opts,t);if(l.isMap()){let[a,u]=l.generate();a&&(this.result.css=a),u&&(this.result.map=u)}else l.clearAnnotation(),this.result.css=l.css}async(){return this.error?Promise.reject(this.error):Promise.resolve(this.result)}catch(e){return this.async().catch(e)}finally(e){return this.async().then(e,e)}sync(){if(this.error)throw this.error;return this.result}then(e,t){return process.env.NODE_ENV!=="production"&&("from"in this._opts||Lh("Without `from` option PostCSS could generate wrong source map and will not find Browserslist config. Set it to CSS file path or to `undefined` to prevent this warning.")),this.async().then(e,t)}toString(){return this._css}warnings(){return[]}get content(){return this.result.css}get css(){return this.result.css}get map(){return this.result.map}get messages(){return[]}get opts(){return this.result.opts}get processor(){return this.result.processor}get root(){if(this._root)return this._root;let e,t=Fh;try{e=t(this._css,this._opts)}catch(r){this.error=r}if(this.error)throw this.error;return this._root=e,e}get[Symbol.toStringTag](){return"NoWorkResult"}},zh=Ni;Ni.default=Ni;var Bh=zh,Wh=jo,Vh=ss,Gh=It,vt=class{constructor(e=[]){this.version="8.4.38",this.plugins=this.normalize(e)}normalize(e){let t=[];for(let r of e)if(r.postcss===!0?r=r():r.postcss&&(r=r.postcss),typeof r=="object"&&Array.isArray(r.plugins))t=t.concat(r.plugins);else if(typeof r=="object"&&r.postcssPlugin)t.push(r);else if(typeof r=="function")t.push(r);else if(typeof r=="object"&&(r.parse||r.stringify)){if(process.env.NODE_ENV!=="production")throw new Error("PostCSS syntaxes cannot be used as plugins. Instead, please use one of the syntax/parser/stringifier options as outlined in your PostCSS runner documentation.")}else throw new Error(r+" is not a PostCSS plugin");return t}process(e,t={}){return!this.plugins.length&&!t.parser&&!t.stringifier&&!t.syntax?new Bh(this,e,t):new Wh(this,e,t)}use(e){return this.plugins=this.plugins.concat(this.normalize([e])),this}},jh=vt;vt.default=vt;Gh.registerProcessor(vt);Vh.registerProcessor(vt);var Hh=xr,Yh=vo,Zh=Er,Xh=os,Jh=Ir,Kh=It,qh=as;function wt(i,e){if(Array.isArray(i))return i.map(s=>wt(s));let{inputs:t,...r}=i;if(t){e=[];for(let s of t){let n={...s,__proto__:Jh.prototype};n.map&&(n.map={...n.map,__proto__:Yh.prototype}),e.push(n)}}if(r.nodes&&(r.nodes=i.nodes.map(s=>wt(s,e))),r.source){let{inputId:s,...n}=r.source;r.source=n,s!=null&&(r.source.input=e[s])}if(r.type==="root")return new Kh(r);if(r.type==="decl")return new Hh(r);if(r.type==="rule")return new qh(r);if(r.type==="comment")return new Zh(r);if(r.type==="atrule")return new Xh(r);throw new Error("Unknown node type: "+i.type)}var Qh=wt;wt.default=wt;var ef=ts,Ho=xr,tf=jo,rf=Le,us=jh,sf=br,nf=Qh,Yo=ss,of=$o,Zo=Er,Xo=os,af=ns,lf=Ir,uf=ls,cf=Bo,Jo=as,Ko=It,hf=Cr;function z(...i){return i.length===1&&Array.isArray(i[0])&&(i=i[0]),new us(i)}z.plugin=function(e,t){let r=!1;function s(...o){console&&console.warn&&!r&&(r=!0,console.warn(e+`: postcss.plugin was deprecated. Migration guide:
|
|
47
|
+
`),this.css+=t+"/*# sourceMappingURL="+e+" */"}applyPrevMaps(){for(let e of this.previous()){let t=this.toUrl(this.path(e.file)),r=e.root||qt(e.file),s;this.mapOpts.sourcesContent===!1?(s=new go(e.text),s.sourcesContent&&(s.sourcesContent=null)):s=e.consumer(),this.map.applySourceMap(s,t,this.toUrl(this.path(r)))}}clearAnnotation(){if(this.mapOpts.annotation!==!1)if(this.root){let e;for(let t=this.root.nodes.length-1;t>=0;t--)e=this.root.nodes[t],e.type==="comment"&&e.text.indexOf("# sourceMappingURL=")===0&&this.root.removeChild(t)}else this.css&&(this.css=this.css.replace(/\n*?\/\*#[\S\s]*?\*\/$/gm,""))}generate(){if(this.clearAnnotation(),Uc&&Fc&&this.isMap())return this.generateMap();{let e="";return this.stringify(this.root,t=>{e+=t}),[e]}}generateMap(){if(this.root)this.generateString();else if(this.previous().length===1){let e=this.previous()[0].consumer();e.file=this.outputFile(),this.map=Kt.fromSourceMap(e,{ignoreInvalidMapping:!0})}else this.map=new Kt({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 Kt({file:this.outputFile(),ignoreInvalidMapping:!0});let e=1,t=1,r="<no source>",s={generated:{column:0,line:0},original:{column:0,line:0},source:""},n,o;this.stringify(this.root,(l,a,u)=>{if(this.css+=l,a&&u!=="end"&&(s.generated.line=e,s.generated.column=t-1,a.source&&a.source.start?(s.source=this.sourcePath(a),s.original.line=a.source.start.line,s.original.column=a.source.start.column-1,this.map.addMapping(s)):(s.source=r,s.original.line=1,s.original.column=0,this.map.addMapping(s))),n=l.match(/\n/g),n?(e+=n.length,o=l.lastIndexOf(`
|
|
48
|
+
`),t=l.length-o):t+=l.length,a&&u!=="start"){let c=a.parent||{raws:{}};(!(a.type==="decl"||a.type==="atrule"&&!a.nodes)||a!==c.last||c.raws.semicolon)&&(a.source&&a.source.end?(s.source=this.sourcePath(a),s.original.line=a.source.end.line,s.original.column=a.source.end.column-1,s.generated.line=e,s.generated.column=t-2,this.map.addMapping(s)):(s.source=r,s.original.line=1,s.original.column=0,s.generated.line=e,s.generated.column=t-1,this.map.addMapping(s)))}})}isAnnotation(){return this.isInline()?!0:typeof this.mapOpts.annotation<"u"?this.mapOpts.annotation:this.previous().length?this.previous().some(e=>e.annotation):!0}isInline(){if(typeof this.mapOpts.inline<"u")return this.mapOpts.inline;let e=this.mapOpts.annotation;return typeof e<"u"&&e!==!0?!1:this.previous().length?this.previous().some(t=>t.inline):!0}isMap(){return typeof this.opts.map<"u"?!!this.opts.map:this.previous().length>0}isSourcesContent(){return typeof this.mapOpts.sourcesContent<"u"?this.mapOpts.sourcesContent:this.previous().length?this.previous().some(e=>e.withContent()):!0}outputFile(){return this.opts.to?this.path(this.opts.to):this.opts.from?this.path(this.opts.from):"to.css"}path(e){if(this.mapOpts.absolute||e.charCodeAt(0)===60||/^\w+:\/\//.test(e))return e;let t=this.memoizedPaths.get(e);if(t)return t;let r=this.opts.to?qt(this.opts.to):".";typeof this.mapOpts.annotation=="string"&&(r=qt(vo(r,this.mapOpts.annotation)));let s=yo(r,e);return this.memoizedPaths.set(e,s),s}previous(){if(!this.previousMaps)if(this.previousMaps=[],this.root)this.root.walk(e=>{if(e.source&&e.source.input.map){let t=e.source.input.map;this.previousMaps.includes(t)||this.previousMaps.push(t)}});else{let e=new Lc(this.originalCSS,this.opts);e.map&&this.previousMaps.push(e.map)}return this.previousMaps}setSourcesContent(){let e={};if(this.root)this.root.walk(t=>{if(t.source){let r=t.source.input.from;if(r&&!e[r]){e[r]=!0;let s=this.usesFileUrls?this.toFileUrl(r):this.toUrl(this.path(r));this.map.setSourceContent(s,t.source.input.css)}}});else if(this.css){let t=this.opts.from?this.toUrl(this.path(this.opts.from)):"<no source>";this.map.setSourceContent(t,this.css)}}sourcePath(e){return this.mapOpts.from?this.toUrl(this.mapOpts.from):this.usesFileUrls?this.toFileUrl(e.source.input.from):this.toUrl(this.path(e.source.input.from))}toBase64(e){return Buffer?Buffer.from(e).toString("base64"):window.btoa(unescape(encodeURIComponent(e)))}toFileUrl(e){let t=this.memoizedFileURLs.get(e);if(t)return t;if(Qs){let r=Qs(e).toString();return this.memoizedFileURLs.set(e,r),r}else throw new Error("`map.absolute` option is not available in this PostCSS build")}toUrl(e){let t=this.memoizedURLs.get(e);if(t)return t;wo==="\\"&&(e=e.replace(/\\/g,"/"));let r=encodeURI(e).replace(/[#?]/g,encodeURIComponent);return this.memoizedURLs.set(e,r),r}},So=zc,Bc=Cr,Ci=class extends Bc{constructor(e){super(e),this.type="comment"}},Ir=Ci;Ci.default=Ci;var{isClean:bo,my:Co}=xt,xo=xr,Eo=Ir,Wc=Cr,Io,rs,is,Mo;function No(i){return i.map(e=>(e.nodes&&(e.nodes=No(e.nodes)),delete e.source,e))}function Ao(i){if(i[bo]=!1,i.proxyOf.nodes)for(let e of i.proxyOf.nodes)Ao(e)}var Ie=class Ro extends Wc{append(...e){for(let t of e){let r=this.normalize(t,this.last);for(let s of r)this.proxyOf.nodes.push(s)}return this.markDirty(),this}cleanRaws(e){if(super.cleanRaws(e),this.nodes)for(let t of this.nodes)t.cleanRaws(e)}each(e){if(!this.proxyOf.nodes)return;let t=this.getIterator(),r,s;for(;this.indexes[t]<this.proxyOf.nodes.length&&(r=this.indexes[t],s=e(this.proxyOf.nodes[r],r),s!==!1);)this.indexes[t]+=1;return delete this.indexes[t],s}every(e){return this.nodes.every(e)}getIterator(){this.lastEach||(this.lastEach=0),this.indexes||(this.indexes={}),this.lastEach+=1;let e=this.lastEach;return this.indexes[e]=0,e}getProxyProcessor(){return{get(e,t){return t==="proxyOf"?e:e[t]?t==="each"||typeof t=="string"&&t.startsWith("walk")?(...r)=>e[t](...r.map(s=>typeof s=="function"?(n,o)=>s(n.toProxy(),o):s)):t==="every"||t==="some"?r=>e[t]((s,...n)=>r(s.toProxy(),...n)):t==="root"?()=>e.root().toProxy():t==="nodes"?e.nodes.map(r=>r.toProxy()):t==="first"||t==="last"?e[t].toProxy():e[t]:e[t]},set(e,t,r){return e[t]===r||(e[t]=r,(t==="name"||t==="params"||t==="selector")&&e.markDirty()),!0}}}index(e){return typeof e=="number"?e:(e.proxyOf&&(e=e.proxyOf),this.proxyOf.nodes.indexOf(e))}insertAfter(e,t){let r=this.index(e),s=this.normalize(t,this.proxyOf.nodes[r]).reverse();r=this.index(e);for(let o of s)this.proxyOf.nodes.splice(r+1,0,o);let n;for(let o in this.indexes)n=this.indexes[o],r<n&&(this.indexes[o]=n+s.length);return this.markDirty(),this}insertBefore(e,t){let r=this.index(e),s=r===0?"prepend":!1,n=this.normalize(t,this.proxyOf.nodes[r],s).reverse();r=this.index(e);for(let l of n)this.proxyOf.nodes.splice(r,0,l);let o;for(let l in this.indexes)o=this.indexes[l],r<=o&&(this.indexes[l]=o+n.length);return this.markDirty(),this}normalize(e,t){if(typeof e=="string")e=No(Io(e).nodes);else if(typeof e>"u")e=[];else if(Array.isArray(e)){e=e.slice(0);for(let s of e)s.parent&&s.parent.removeChild(s,"ignore")}else if(e.type==="root"&&this.type!=="document"){e=e.nodes.slice(0);for(let s of e)s.parent&&s.parent.removeChild(s,"ignore")}else if(e.type)e=[e];else if(e.prop){if(typeof e.value>"u")throw new Error("Value field is missed in node creation");typeof e.value!="string"&&(e.value=String(e.value)),e=[new xo(e)]}else if(e.selector)e=[new rs(e)];else if(e.name)e=[new is(e)];else if(e.text)e=[new Eo(e)];else throw new Error("Unknown node type in node creation");return e.map(s=>(s[Co]||Ro.rebuild(s),s=s.proxyOf,s.parent&&s.parent.removeChild(s),s[bo]&&Ao(s),typeof s.raws.before>"u"&&t&&typeof t.raws.before<"u"&&(s.raws.before=t.raws.before.replace(/\S/g,"")),s.parent=this.proxyOf,s))}prepend(...e){e=e.reverse();for(let t of e){let r=this.normalize(t,this.first,"prepend").reverse();for(let s of r)this.proxyOf.nodes.unshift(s);for(let s in this.indexes)this.indexes[s]=this.indexes[s]+r.length}return this.markDirty(),this}push(e){return e.parent=this,this.proxyOf.nodes.push(e),this}removeAll(){for(let e of this.proxyOf.nodes)e.parent=void 0;return this.proxyOf.nodes=[],this.markDirty(),this}removeChild(e){e=this.index(e),this.proxyOf.nodes[e].parent=void 0,this.proxyOf.nodes.splice(e,1);let t;for(let r in this.indexes)t=this.indexes[r],t>=e&&(this.indexes[r]=t-1);return this.markDirty(),this}replaceValues(e,t,r){return r||(r=t,t={}),this.walkDecls(s=>{t.props&&!t.props.includes(s.prop)||t.fast&&!s.value.includes(t.fast)||(s.value=s.value.replace(e,r))}),this.markDirty(),this}some(e){return this.nodes.some(e)}walk(e){return this.each((t,r)=>{let s;try{s=e(t,r)}catch(n){throw t.addToError(n)}return s!==!1&&t.walk&&(s=t.walk(e)),s})}walkAtRules(e,t){return t?e instanceof RegExp?this.walk((r,s)=>{if(r.type==="atrule"&&e.test(r.name))return t(r,s)}):this.walk((r,s)=>{if(r.type==="atrule"&&r.name===e)return t(r,s)}):(t=e,this.walk((r,s)=>{if(r.type==="atrule")return t(r,s)}))}walkComments(e){return this.walk((t,r)=>{if(t.type==="comment")return e(t,r)})}walkDecls(e,t){return t?e instanceof RegExp?this.walk((r,s)=>{if(r.type==="decl"&&e.test(r.prop))return t(r,s)}):this.walk((r,s)=>{if(r.type==="decl"&&r.prop===e)return t(r,s)}):(t=e,this.walk((r,s)=>{if(r.type==="decl")return t(r,s)}))}walkRules(e,t){return t?e instanceof RegExp?this.walk((r,s)=>{if(r.type==="rule"&&e.test(r.selector))return t(r,s)}):this.walk((r,s)=>{if(r.type==="rule"&&r.selector===e)return t(r,s)}):(t=e,this.walk((r,s)=>{if(r.type==="rule")return t(r,s)}))}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]}};Ie.registerParse=i=>{Io=i};Ie.registerRule=i=>{rs=i};Ie.registerAtRule=i=>{is=i};Ie.registerRoot=i=>{Mo=i};var Le=Ie;Ie.default=Ie;Ie.rebuild=i=>{i.type==="atrule"?Object.setPrototypeOf(i,is.prototype):i.type==="rule"?Object.setPrototypeOf(i,rs.prototype):i.type==="decl"?Object.setPrototypeOf(i,xo.prototype):i.type==="comment"?Object.setPrototypeOf(i,Eo.prototype):i.type==="root"&&Object.setPrototypeOf(i,Mo.prototype),i[Co]=!0,i.nodes&&i.nodes.forEach(e=>{Ie.rebuild(e)})};var Vc=Le,Oo,To,gt=class extends Vc{constructor(e){super({type:"document",...e}),this.nodes||(this.nodes=[])}toResult(e={}){return new Oo(new To,this,e).stringify()}};gt.registerLazyResult=i=>{Oo=i};gt.registerProcessor=i=>{To=i};var ss=gt;gt.default=gt;var xi=class{constructor(e,t={}){if(this.type="warning",this.text=e,t.node&&t.node.source){let r=t.node.rangeBy(t);this.line=r.start.line,this.column=r.start.column,this.endLine=r.end.line,this.endColumn=r.end.column}for(let r in t)this[r]=t[r]}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}},Do=xi;xi.default=xi;var Gc=Do,Ei=class{constructor(e,t,r){this.processor=e,this.messages=[],this.root=t,this.opts=r,this.css=void 0,this.map=void 0}toString(){return this.css}warn(e,t={}){t.plugin||this.lastPlugin&&this.lastPlugin.postcssPlugin&&(t.plugin=this.lastPlugin.postcssPlugin);let r=new Gc(e,t);return this.messages.push(r),r}warnings(){return this.messages.filter(e=>e.type==="warning")}get content(){return this.css}},ns=Ei;Ei.default=Ei;var Hr=39,en=34,Ut=92,tn=47,zt=10,nt=32,Bt=12,Wt=9,Vt=13,jc=91,Hc=93,Yc=40,Zc=41,Xc=123,Jc=125,Kc=59,qc=42,Qc=58,eh=64,Gt=/[\t\n\f\r "#'()/;[\\\]{}]/g,jt=/[\t\n\f\r !"#'():;@[\\\]{}]|\/(?=\*)/g,th=/.[\r\n"'(/\\]/,rn=/[\da-f]/i,rh=function(e,t={}){let r=e.css.valueOf(),s=t.ignoreErrors,n,o,l,a,u,c,h,d,m,g,p=r.length,f=0,S=[],w=[];function y(){return f}function b(x){throw e.error("Unclosed "+x,f)}function I(){return w.length===0&&f>=p}function M(x){if(w.length)return w.pop();if(f>=p)return;let C=x?x.ignoreUnclosed:!1;switch(n=r.charCodeAt(f),n){case zt:case nt:case Wt:case Vt:case Bt:{o=f;do o+=1,n=r.charCodeAt(o);while(n===nt||n===zt||n===Wt||n===Vt||n===Bt);g=["space",r.slice(f,o)],f=o-1;break}case jc:case Hc:case Xc:case Jc:case Qc:case Kc:case Zc:{let k=String.fromCharCode(n);g=[k,k,f];break}case Yc:{if(d=S.length?S.pop()[1]:"",m=r.charCodeAt(f+1),d==="url"&&m!==Hr&&m!==en&&m!==nt&&m!==zt&&m!==Wt&&m!==Bt&&m!==Vt){o=f;do{if(c=!1,o=r.indexOf(")",o+1),o===-1)if(s||C){o=f;break}else b("bracket");for(h=o;r.charCodeAt(h-1)===Ut;)h-=1,c=!c}while(c);g=["brackets",r.slice(f,o+1),f,o],f=o}else o=r.indexOf(")",f+1),a=r.slice(f,o+1),o===-1||th.test(a)?g=["(","(",f]:(g=["brackets",a,f,o],f=o);break}case Hr:case en:{l=n===Hr?"'":'"',o=f;do{if(c=!1,o=r.indexOf(l,o+1),o===-1)if(s||C){o=f+1;break}else b("string");for(h=o;r.charCodeAt(h-1)===Ut;)h-=1,c=!c}while(c);g=["string",r.slice(f,o+1),f,o],f=o;break}case eh:{Gt.lastIndex=f+1,Gt.test(r),Gt.lastIndex===0?o=r.length-1:o=Gt.lastIndex-2,g=["at-word",r.slice(f,o+1),f,o],f=o;break}case Ut:{for(o=f,u=!0;r.charCodeAt(o+1)===Ut;)o+=1,u=!u;if(n=r.charCodeAt(o+1),u&&n!==tn&&n!==nt&&n!==zt&&n!==Wt&&n!==Vt&&n!==Bt&&(o+=1,rn.test(r.charAt(o)))){for(;rn.test(r.charAt(o+1));)o+=1;r.charCodeAt(o+1)===nt&&(o+=1)}g=["word",r.slice(f,o+1),f,o],f=o;break}default:{n===tn&&r.charCodeAt(f+1)===qc?(o=r.indexOf("*/",f+2)+1,o===0&&(s||C?o=r.length:b("comment")),g=["comment",r.slice(f,o+1),f,o],f=o):(jt.lastIndex=f+1,jt.test(r),jt.lastIndex===0?o=r.length-1:o=jt.lastIndex-2,g=["word",r.slice(f,o+1),f,o],S.push(g),f=o);break}}return f++,g}function R(x){w.push(x)}return{back:R,endOfFile:I,nextToken:M,position:y}},ko=Le,ur=class extends ko{constructor(e){super(e),this.type="atrule"}append(...e){return this.proxyOf.nodes||(this.nodes=[]),super.append(...e)}prepend(...e){return this.proxyOf.nodes||(this.nodes=[]),super.prepend(...e)}},os=ur;ur.default=ur;ko.registerAtRule(ur);var $o=Le,_o,Po,Ze=class extends $o{constructor(e){super(e),this.type="root",this.nodes||(this.nodes=[])}normalize(e,t,r){let s=super.normalize(e);if(t){if(r==="prepend")this.nodes.length>1?t.raws.before=this.nodes[1].raws.before:delete t.raws.before;else if(this.first!==t)for(let n of s)n.raws.before=t.raws.before}return s}removeChild(e,t){let r=this.index(e);return!t&&r===0&&this.nodes.length>1&&(this.nodes[1].raws.before=this.nodes[r].raws.before),super.removeChild(e)}toResult(e={}){return new _o(new Po,this,e).stringify()}};Ze.registerLazyResult=i=>{_o=i};Ze.registerProcessor=i=>{Po=i};var Et=Ze;Ze.default=Ze;$o.registerRoot(Ze);var yt={comma(i){return yt.split(i,[","],!0)},space(i){let e=[" ",`
|
|
49
|
+
`," "];return yt.split(i,e)},split(i,e,t){let r=[],s="",n=!1,o=0,l=!1,a="",u=!1;for(let c of i)u?u=!1:c==="\\"?u=!0:l?c===a&&(l=!1):c==='"'||c==="'"?(l=!0,a=c):c==="("?o+=1:c===")"?o>0&&(o-=1):o===0&&e.includes(c)&&(n=!0),n?(s!==""&&r.push(s.trim()),s="",n=!1):s+=c;return(t||s!=="")&&r.push(s.trim()),r}},Lo=yt;yt.default=yt;var Fo=Le,ih=Lo,cr=class extends Fo{constructor(e){super(e),this.type="rule",this.nodes||(this.nodes=[])}get selectors(){return ih.comma(this.selector)}set selectors(e){let t=this.selector?this.selector.match(/,\s*/):null,r=t?t[0]:","+this.raw("between","beforeOpen");this.selector=e.join(r)}},as=cr;cr.default=cr;Fo.registerRule(cr);var sh=xr,nh=rh,oh=Ir,ah=os,lh=Et,sn=as,nn={empty:!0,space:!0};function uh(i){for(let e=i.length-1;e>=0;e--){let t=i[e],r=t[3]||t[2];if(r)return r}}var ch=class{constructor(e){this.input=e,this.root=new lh,this.current=this.root,this.spaces="",this.semicolon=!1,this.createTokenizer(),this.root.source={input:e,start:{column:1,line:1,offset:0}}}atrule(e){let t=new ah;t.name=e[1].slice(1),t.name===""&&this.unnamedAtrule(t,e),this.init(t,e[2]);let r,s,n,o=!1,l=!1,a=[],u=[];for(;!this.tokenizer.endOfFile();){if(e=this.tokenizer.nextToken(),r=e[0],r==="("||r==="["?u.push(r==="("?")":"]"):r==="{"&&u.length>0?u.push("}"):r===u[u.length-1]&&u.pop(),u.length===0)if(r===";"){t.source.end=this.getPosition(e[2]),t.source.end.offset++,this.semicolon=!0;break}else if(r==="{"){l=!0;break}else if(r==="}"){if(a.length>0){for(n=a.length-1,s=a[n];s&&s[0]==="space";)s=a[--n];s&&(t.source.end=this.getPosition(s[3]||s[2]),t.source.end.offset++)}this.end(e);break}else a.push(e);else a.push(e);if(this.tokenizer.endOfFile()){o=!0;break}}t.raws.between=this.spacesAndCommentsFromEnd(a),a.length?(t.raws.afterName=this.spacesAndCommentsFromStart(a),this.raw(t,"params",a),o&&(e=a[a.length-1],t.source.end=this.getPosition(e[3]||e[2]),t.source.end.offset++,this.spaces=t.raws.between,t.raws.between="")):(t.raws.afterName="",t.params=""),l&&(t.nodes=[],this.current=t)}checkMissedSemicolon(e){let t=this.colon(e);if(t===!1)return;let r=0,s;for(let n=t-1;n>=0&&(s=e[n],!(s[0]!=="space"&&(r+=1,r===2)));n--);throw this.input.error("Missed semicolon",s[0]==="word"?s[3]+1:s[2])}colon(e){let t=0,r,s,n;for(let[o,l]of e.entries()){if(r=l,s=r[0],s==="("&&(t+=1),s===")"&&(t-=1),t===0&&s===":")if(!n)this.doubleColon(r);else{if(n[0]==="word"&&n[1]==="progid")continue;return o}n=r}return!1}comment(e){let t=new oh;this.init(t,e[2]),t.source.end=this.getPosition(e[3]||e[2]),t.source.end.offset++;let r=e[1].slice(2,-2);if(/^\s*$/.test(r))t.text="",t.raws.left=r,t.raws.right="";else{let s=r.match(/^(\s*)([^]*\S)(\s*)$/);t.text=s[2],t.raws.left=s[1],t.raws.right=s[3]}}createTokenizer(){this.tokenizer=nh(this.input)}decl(e,t){let r=new sh;this.init(r,e[0][2]);let s=e[e.length-1];for(s[0]===";"&&(this.semicolon=!0,e.pop()),r.source.end=this.getPosition(s[3]||s[2]||uh(e)),r.source.end.offset++;e[0][0]!=="word";)e.length===1&&this.unknownWord(e),r.raws.before+=e.shift()[1];for(r.source.start=this.getPosition(e[0][2]),r.prop="";e.length;){let u=e[0][0];if(u===":"||u==="space"||u==="comment")break;r.prop+=e.shift()[1]}r.raws.between="";let n;for(;e.length;)if(n=e.shift(),n[0]===":"){r.raws.between+=n[1];break}else n[0]==="word"&&/\w/.test(n[1])&&this.unknownWord([n]),r.raws.between+=n[1];(r.prop[0]==="_"||r.prop[0]==="*")&&(r.raws.before+=r.prop[0],r.prop=r.prop.slice(1));let o=[],l;for(;e.length&&(l=e[0][0],!(l!=="space"&&l!=="comment"));)o.push(e.shift());this.precheckMissedSemicolon(e);for(let u=e.length-1;u>=0;u--){if(n=e[u],n[1].toLowerCase()==="!important"){r.important=!0;let c=this.stringFrom(e,u);c=this.spacesFromEnd(e)+c,c!==" !important"&&(r.raws.important=c);break}else if(n[1].toLowerCase()==="important"){let c=e.slice(0),h="";for(let d=u;d>0;d--){let m=c[d][0];if(h.trim().indexOf("!")===0&&m!=="space")break;h=c.pop()[1]+h}h.trim().indexOf("!")===0&&(r.important=!0,r.raws.important=h,e=c)}if(n[0]!=="space"&&n[0]!=="comment")break}e.some(u=>u[0]!=="space"&&u[0]!=="comment")&&(r.raws.between+=o.map(u=>u[1]).join(""),o=[]),this.raw(r,"value",o.concat(e),t),r.value.includes(":")&&!t&&this.checkMissedSemicolon(e)}doubleColon(e){throw this.input.error("Double colon",{offset:e[2]},{offset:e[2]+e[1].length})}emptyRule(e){let t=new sn;this.init(t,e[2]),t.selector="",t.raws.between="",this.current=t}end(e){this.current.nodes&&this.current.nodes.length&&(this.current.raws.semicolon=this.semicolon),this.semicolon=!1,this.current.raws.after=(this.current.raws.after||"")+this.spaces,this.spaces="",this.current.parent?(this.current.source.end=this.getPosition(e[2]),this.current.source.end.offset++,this.current=this.current.parent):this.unexpectedClose(e)}endFile(){this.current.parent&&this.unclosedBlock(),this.current.nodes&&this.current.nodes.length&&(this.current.raws.semicolon=this.semicolon),this.current.raws.after=(this.current.raws.after||"")+this.spaces,this.root.source.end=this.getPosition(this.tokenizer.position())}freeSemicolon(e){if(this.spaces+=e[1],this.current.nodes){let t=this.current.nodes[this.current.nodes.length-1];t&&t.type==="rule"&&!t.raws.ownSemicolon&&(t.raws.ownSemicolon=this.spaces,this.spaces="")}}getPosition(e){let t=this.input.fromOffset(e);return{column:t.col,line:t.line,offset:e}}init(e,t){this.current.push(e),e.source={input:this.input,start:this.getPosition(t)},e.raws.before=this.spaces,this.spaces="",e.type!=="comment"&&(this.semicolon=!1)}other(e){let t=!1,r=null,s=!1,n=null,o=[],l=e[1].startsWith("--"),a=[],u=e;for(;u;){if(r=u[0],a.push(u),r==="("||r==="[")n||(n=u),o.push(r==="("?")":"]");else if(l&&s&&r==="{")n||(n=u),o.push("}");else if(o.length===0)if(r===";")if(s){this.decl(a,l);return}else break;else if(r==="{"){this.rule(a);return}else if(r==="}"){this.tokenizer.back(a.pop()),t=!0;break}else r===":"&&(s=!0);else r===o[o.length-1]&&(o.pop(),o.length===0&&(n=null));u=this.tokenizer.nextToken()}if(this.tokenizer.endOfFile()&&(t=!0),o.length>0&&this.unclosedBracket(n),t&&s){if(!l)for(;a.length&&(u=a[a.length-1][0],!(u!=="space"&&u!=="comment"));)this.tokenizer.back(a.pop());this.decl(a,l)}else this.unknownWord(a)}parse(){let e;for(;!this.tokenizer.endOfFile();)switch(e=this.tokenizer.nextToken(),e[0]){case"space":this.spaces+=e[1];break;case";":this.freeSemicolon(e);break;case"}":this.end(e);break;case"comment":this.comment(e);break;case"at-word":this.atrule(e);break;case"{":this.emptyRule(e);break;default:this.other(e);break}this.endFile()}precheckMissedSemicolon(){}raw(e,t,r,s){let n,o,l=r.length,a="",u=!0,c,h;for(let d=0;d<l;d+=1)n=r[d],o=n[0],o==="space"&&d===l-1&&!s?u=!1:o==="comment"?(h=r[d-1]?r[d-1][0]:"empty",c=r[d+1]?r[d+1][0]:"empty",!nn[h]&&!nn[c]?a.slice(-1)===","?u=!1:a+=n[1]:u=!1):a+=n[1];if(!u){let d=r.reduce((m,g)=>m+g[1],"");e.raws[t]={raw:d,value:a}}e[t]=a}rule(e){e.pop();let t=new sn;this.init(t,e[0][2]),t.raws.between=this.spacesAndCommentsFromEnd(e),this.raw(t,"selector",e),this.current=t}spacesAndCommentsFromEnd(e){let t,r="";for(;e.length&&(t=e[e.length-1][0],!(t!=="space"&&t!=="comment"));)r=e.pop()[1]+r;return r}spacesAndCommentsFromStart(e){let t,r="";for(;e.length&&(t=e[0][0],!(t!=="space"&&t!=="comment"));)r+=e.shift()[1];return r}spacesFromEnd(e){let t,r="";for(;e.length&&(t=e[e.length-1][0],t==="space");)r=e.pop()[1]+r;return r}stringFrom(e,t){let r="";for(let s=t;s<e.length;s++)r+=e[s][1];return e.splice(t,e.length-t),r}unclosedBlock(){let e=this.current.source.start;throw this.input.error("Unclosed block",e.line,e.column)}unclosedBracket(e){throw this.input.error("Unclosed bracket",{offset:e[2]},{offset:e[2]+1})}unexpectedClose(e){throw this.input.error("Unexpected }",{offset:e[2]},{offset:e[2]+1})}unknownWord(e){throw this.input.error("Unknown word",{offset:e[0][2]},{offset:e[0][2]+e[0][1].length})}unnamedAtrule(e,t){throw this.input.error("At-rule without name",{offset:t[2]},{offset:t[2]+t[1].length})}},hh=ch,fh=Le,ph=hh,dh=Er;function hr(i,e){let t=new dh(i,e),r=new ph(t);try{r.parse()}catch(s){throw s}return r.root}var ls=hr;hr.default=hr;fh.registerParse(hr);var{isClean:Se,my:mh}=xt,gh=So,yh=br,vh=Le,wh=ss;var on=ns,Sh=ls,bh=Et,Ch={atrule:"AtRule",comment:"Comment",decl:"Declaration",document:"Document",root:"Root",rule:"Rule"},xh={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},Eh={Once:!0,postcssPlugin:!0,prepare:!0},Xe=0;function ot(i){return typeof i=="object"&&typeof i.then=="function"}function Uo(i){let e=!1,t=Ch[i.type];return i.type==="decl"?e=i.prop.toLowerCase():i.type==="atrule"&&(e=i.name.toLowerCase()),e&&i.append?[t,t+"-"+e,Xe,t+"Exit",t+"Exit-"+e]:e?[t,t+"-"+e,t+"Exit",t+"Exit-"+e]:i.append?[t,Xe,t+"Exit"]:[t,t+"Exit"]}function an(i){let e;return i.type==="document"?e=["Document",Xe,"DocumentExit"]:i.type==="root"?e=["Root",Xe,"RootExit"]:e=Uo(i),{eventIndex:0,events:e,iterator:0,node:i,visitorIndex:0,visitors:[]}}function Ii(i){return i[Se]=!1,i.nodes&&i.nodes.forEach(e=>Ii(e)),i}var Mi={},Je=class zo{constructor(e,t,r){this.stringified=!1,this.processed=!1;let s;if(typeof t=="object"&&t!==null&&(t.type==="root"||t.type==="document"))s=Ii(t);else if(t instanceof zo||t instanceof on)s=Ii(t.root),t.map&&(typeof r.map>"u"&&(r.map={}),r.map.inline||(r.map.inline=!1),r.map.prev=t.map);else{let n=Sh;r.syntax&&(n=r.syntax.parse),r.parser&&(n=r.parser),n.parse&&(n=n.parse);try{s=n(t,r)}catch(o){this.processed=!0,this.error=o}s&&!s[mh]&&vh.rebuild(s)}this.result=new on(e,s,r),this.helpers={...Mi,postcss:Mi,result:this.result},this.plugins=this.processor.plugins.map(n=>typeof n=="object"&&n.prepare?{...n,...n.prepare(this.result)}:n)}async(){return this.error?Promise.reject(this.error):this.processed?Promise.resolve(this.result):(this.processing||(this.processing=this.runAsync()),this.processing)}catch(e){return this.async().catch(e)}finally(e){return this.async().then(e,e)}getAsyncError(){throw new Error("Use process(css).then(cb) to work with async plugins")}handleError(e,t){let r=this.result.lastPlugin;try{t&&t.addToError(e),this.error=e,e.name==="CssSyntaxError"&&!e.plugin?(e.plugin=r.postcssPlugin,e.setMessage()):r.postcssVersion}catch(s){console&&console.error&&console.error(s)}return e}prepareVisitors(){this.listeners={};let e=(t,r,s)=>{this.listeners[r]||(this.listeners[r]=[]),this.listeners[r].push([t,s])};for(let t of this.plugins)if(typeof t=="object")for(let r in t){if(!xh[r]&&/^[A-Z]/.test(r))throw new Error(`Unknown event ${r} in ${t.postcssPlugin}. Try to update PostCSS (${this.processor.version} now).`);if(!Eh[r])if(typeof t[r]=="object")for(let s in t[r])s==="*"?e(t,r,t[r][s]):e(t,r+"-"+s.toLowerCase(),t[r][s]);else typeof t[r]=="function"&&e(t,r,t[r])}this.hasListener=Object.keys(this.listeners).length>0}async runAsync(){this.plugin=0;for(let e=0;e<this.plugins.length;e++){let t=this.plugins[e],r=this.runOnRoot(t);if(ot(r))try{await r}catch(s){throw this.handleError(s)}}if(this.prepareVisitors(),this.hasListener){let e=this.result.root;for(;!e[Se];){e[Se]=!0;let t=[an(e)];for(;t.length>0;){let r=this.visitTick(t);if(ot(r))try{await r}catch(s){let n=t[t.length-1].node;throw this.handleError(s,n)}}}if(this.listeners.OnceExit)for(let[t,r]of this.listeners.OnceExit){this.result.lastPlugin=t;try{if(e.type==="document"){let s=e.nodes.map(n=>r(n,this.helpers));await Promise.all(s)}else await r(e,this.helpers)}catch(s){throw this.handleError(s)}}}return this.processed=!0,this.stringify()}runOnRoot(e){this.result.lastPlugin=e;try{if(typeof e=="object"&&e.Once){if(this.result.root.type==="document"){let t=this.result.root.nodes.map(r=>e.Once(r,this.helpers));return ot(t[0])?Promise.all(t):t}return e.Once(this.result.root,this.helpers)}else if(typeof e=="function")return e(this.result.root,this.result)}catch(t){throw this.handleError(t)}}stringify(){if(this.error)throw this.error;if(this.stringified)return this.result;this.stringified=!0,this.sync();let e=this.result.opts,t=yh;e.syntax&&(t=e.syntax.stringify),e.stringifier&&(t=e.stringifier),t.stringify&&(t=t.stringify);let s=new gh(t,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 e of this.plugins){let t=this.runOnRoot(e);if(ot(t))throw this.getAsyncError()}if(this.prepareVisitors(),this.hasListener){let e=this.result.root;for(;!e[Se];)e[Se]=!0,this.walkSync(e);if(this.listeners.OnceExit)if(e.type==="document")for(let t of e.nodes)this.visitSync(this.listeners.OnceExit,t);else this.visitSync(this.listeners.OnceExit,e)}return this.result}then(e,t){return this.async().then(e,t)}toString(){return this.css}visitSync(e,t){for(let[r,s]of e){this.result.lastPlugin=r;let n;try{n=s(t,this.helpers)}catch(o){throw this.handleError(o,t.proxyOf)}if(t.type!=="root"&&t.type!=="document"&&!t.parent)return!0;if(ot(n))throw this.getAsyncError()}}visitTick(e){let t=e[e.length-1],{node:r,visitors:s}=t;if(r.type!=="root"&&r.type!=="document"&&!r.parent){e.pop();return}if(s.length>0&&t.visitorIndex<s.length){let[o,l]=s[t.visitorIndex];t.visitorIndex+=1,t.visitorIndex===s.length&&(t.visitors=[],t.visitorIndex=0),this.result.lastPlugin=o;try{return l(r.toProxy(),this.helpers)}catch(a){throw this.handleError(a,r)}}if(t.iterator!==0){let o=t.iterator,l;for(;l=r.nodes[r.indexes[o]];)if(r.indexes[o]+=1,!l[Se]){l[Se]=!0,e.push(an(l));return}t.iterator=0,delete r.indexes[o]}let n=t.events;for(;t.eventIndex<n.length;){let o=n[t.eventIndex];if(t.eventIndex+=1,o===Xe){r.nodes&&r.nodes.length&&(r[Se]=!0,t.iterator=r.getIterator());return}else if(this.listeners[o]){t.visitors=this.listeners[o];return}}e.pop()}walkSync(e){e[Se]=!0;let t=Uo(e);for(let r of t)if(r===Xe)e.nodes&&e.each(s=>{s[Se]||this.walkSync(s)});else{let s=this.listeners[r];if(s&&this.visitSync(s,e.toProxy()))return}}warnings(){return this.sync().warnings()}get content(){return this.stringify().content}get css(){return this.stringify().css}get map(){return this.stringify().map}get messages(){return this.sync().messages}get opts(){return this.result.opts}get processor(){return this.result.processor}get root(){return this.sync().root}get[Symbol.toStringTag](){return"LazyResult"}};Je.registerPostcss=i=>{Mi=i};var Bo=Je;Je.default=Je;bh.registerLazyResult(Je);wh.registerLazyResult(Je);var Ih=So,Mh=br;var Nh=ls,Ah=ns,Ni=class{constructor(e,t,r){t=t.toString(),this.stringified=!1,this._processor=e,this._css=t,this._opts=r,this._map=void 0;let s,n=Mh;this.result=new Ah(this._processor,s,this._opts),this.result.css=t;let o=this;Object.defineProperty(this.result,"root",{get(){return o.root}});let l=new Ih(n,s,this._opts,t);if(l.isMap()){let[a,u]=l.generate();a&&(this.result.css=a),u&&(this.result.map=u)}else l.clearAnnotation(),this.result.css=l.css}async(){return this.error?Promise.reject(this.error):Promise.resolve(this.result)}catch(e){return this.async().catch(e)}finally(e){return this.async().then(e,e)}sync(){if(this.error)throw this.error;return this.result}then(e,t){return this.async().then(e,t)}toString(){return this._css}warnings(){return[]}get content(){return this.result.css}get css(){return this.result.css}get map(){return this.result.map}get messages(){return[]}get opts(){return this.result.opts}get processor(){return this.result.processor}get root(){if(this._root)return this._root;let e,t=Nh;try{e=t(this._css,this._opts)}catch(r){this.error=r}if(this.error)throw this.error;return this._root=e,e}get[Symbol.toStringTag](){return"NoWorkResult"}},Rh=Ni;Ni.default=Ni;var Oh=Rh,Th=Bo,Dh=ss,kh=Et,vt=class{constructor(e=[]){this.version="8.4.38",this.plugins=this.normalize(e)}normalize(e){let t=[];for(let r of e)if(r.postcss===!0?r=r():r.postcss&&(r=r.postcss),typeof r=="object"&&Array.isArray(r.plugins))t=t.concat(r.plugins);else if(typeof r=="object"&&r.postcssPlugin)t.push(r);else if(typeof r=="function")t.push(r);else if(!(typeof r=="object"&&(r.parse||r.stringify)))throw new Error(r+" is not a PostCSS plugin");return t}process(e,t={}){return!this.plugins.length&&!t.parser&&!t.stringifier&&!t.syntax?new Oh(this,e,t):new Th(this,e,t)}use(e){return this.plugins=this.plugins.concat(this.normalize([e])),this}},$h=vt;vt.default=vt;kh.registerProcessor(vt);Dh.registerProcessor(vt);var _h=xr,Ph=mo,Lh=Ir,Fh=os,Uh=Er,zh=Et,Bh=as;function wt(i,e){if(Array.isArray(i))return i.map(s=>wt(s));let{inputs:t,...r}=i;if(t){e=[];for(let s of t){let n={...s,__proto__:Uh.prototype};n.map&&(n.map={...n.map,__proto__:Ph.prototype}),e.push(n)}}if(r.nodes&&(r.nodes=i.nodes.map(s=>wt(s,e))),r.source){let{inputId:s,...n}=r.source;r.source=n,s!=null&&(r.source.input=e[s])}if(r.type==="root")return new zh(r);if(r.type==="decl")return new _h(r);if(r.type==="rule")return new Bh(r);if(r.type==="comment")return new Lh(r);if(r.type==="atrule")return new Fh(r);throw new Error("Unknown node type: "+i.type)}var Wh=wt;wt.default=wt;var Vh=ts,Wo=xr,Gh=Bo,jh=Le,us=$h,Hh=br,Yh=Wh,Vo=ss,Zh=Do,Go=Ir,jo=os,Xh=ns,Jh=Er,Kh=ls,qh=Lo,Ho=as,Yo=Et,Qh=Cr;function z(...i){return i.length===1&&Array.isArray(i[0])&&(i=i[0]),new us(i)}z.plugin=function(e,t){let r=!1;function s(...o){console&&console.warn&&!r&&(r=!0,console.warn(e+`: postcss.plugin was deprecated. Migration guide:
|
|
56
50
|
https://evilmartians.com/chronicles/postcss-8-plugin-migration`),process.env.LANG&&process.env.LANG.startsWith("cn")&&console.warn(e+`: \u91CC\u9762 postcss.plugin \u88AB\u5F03\u7528. \u8FC1\u79FB\u6307\u5357:
|
|
57
|
-
https://www.w3ctech.com/topic/2226`));let l=t(...o);return l.postcssPlugin=e,l.postcssVersion=new us().version,l}let n;return Object.defineProperty(s,"postcss",{get(){return n||(n=s()),n}}),s.process=function(o,l,a){return z([s(a)]).process(o,l)},s};z.stringify=
|
|
51
|
+
https://www.w3ctech.com/topic/2226`));let l=t(...o);return l.postcssPlugin=e,l.postcssVersion=new us().version,l}let n;return Object.defineProperty(s,"postcss",{get(){return n||(n=s()),n}}),s.process=function(o,l,a){return z([s(a)]).process(o,l)},s};z.stringify=Hh;z.parse=Kh;z.fromJSON=Yh;z.list=qh;z.comment=i=>new Go(i);z.atRule=i=>new jo(i);z.decl=i=>new Wo(i);z.rule=i=>new Ho(i);z.root=i=>new Yo(i);z.document=i=>new Vo(i);z.CssSyntaxError=Vh;z.Declaration=Wo;z.Container=jh;z.Processor=us;z.Document=Vo;z.Comment=Go;z.Warning=Zh;z.AtRule=jo;z.Result=Xh;z.Input=Jh;z.Rule=Ho;z.Root=Yo;z.Node=Qh;Gh.registerPostcss(z);var ef=z;z.default=z;var X=fc(ef);X.stringify;X.fromJSON;X.plugin;X.parse;X.list;X.document;X.comment;X.atRule;X.rule;X.decl;X.root;X.CssSyntaxError;X.Declaration;X.Container;X.Processor;X.Document;X.Comment;X.Warning;X.AtRule;X.Result;X.Input;X.Rule;X.Root;X.Node;var Ai=class i{constructor(...e){ce(this,"parentElement",null),ce(this,"parentNode",null),ce(this,"ownerDocument"),ce(this,"firstChild",null),ce(this,"lastChild",null),ce(this,"previousSibling",null),ce(this,"nextSibling",null),ce(this,"ELEMENT_NODE",1),ce(this,"TEXT_NODE",3),ce(this,"nodeType"),ce(this,"nodeName"),ce(this,"RRNodeType")}get childNodes(){let e=[],t=this.firstChild;for(;t;)e.push(t),t=t.nextSibling;return e}contains(e){if(e instanceof i){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,t){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"}};var ln={Node:["childNodes","parentNode","parentElement","textContent"],ShadowRoot:["host","styleSheets"],Element:["shadowRoot","querySelector","querySelectorAll"],MutationObserver:[]},un={Node:["contains","getRootNode"],ShadowRoot:["getSelection"],Element:[],MutationObserver:["constructor"]},Ht={},tf=()=>!!globalThis.Zone;function cs(i){if(Ht[i])return Ht[i];let e=globalThis[i],t=e.prototype,r=i in ln?ln[i]:void 0,s=!!(r&&r.every(l=>{var a,u;return!!((u=(a=Object.getOwnPropertyDescriptor(t,l))==null?void 0:a.get)!=null&&u.toString().includes("[native code]"))})),n=i in un?un[i]:void 0,o=!!(n&&n.every(l=>{var a;return typeof t[l]=="function"&&((a=t[l])==null?void 0:a.toString().includes("[native code]"))}));if(s&&o&&!tf())return Ht[i]=e.prototype,e.prototype;try{let l=document.createElement("iframe");document.body.appendChild(l);let a=l.contentWindow;if(!a)return e.prototype;let u=a[i].prototype;return document.body.removeChild(l),u?Ht[i]=u:t}catch{return t}}var Yr={};function Te(i,e,t){var r;let s=`${i}.${String(t)}`;if(Yr[s])return Yr[s].call(e);let n=cs(i),o=(r=Object.getOwnPropertyDescriptor(n,t))==null?void 0:r.get;return o?(Yr[s]=o,o.call(e)):e[t]}var Zr={};function Zo(i,e,t){let r=`${i}.${String(t)}`;if(Zr[r])return Zr[r].bind(e);let n=cs(i)[t];return typeof n!="function"?e[t]:(Zr[r]=n,n.bind(e))}function rf(i){return Te("Node",i,"childNodes")}function sf(i){return Te("Node",i,"parentNode")}function nf(i){return Te("Node",i,"parentElement")}function of(i){return Te("Node",i,"textContent")}function af(i,e){return Zo("Node",i,"contains")(e)}function lf(i){return Zo("Node",i,"getRootNode")()}function uf(i){return!i||!("host"in i)?null:Te("ShadowRoot",i,"host")}function cf(i){return i.styleSheets}function hf(i){return!i||!("shadowRoot"in i)?null:Te("Element",i,"shadowRoot")}function ff(i,e){return Te("Element",i,"querySelector")(e)}function pf(i,e){return Te("Element",i,"querySelectorAll")(e)}function Xo(){return cs("MutationObserver").constructor}var A={childNodes:rf,parentNode:sf,parentElement:nf,textContent:of,contains:af,getRootNode:lf,host:uf,styleSheets:cf,shadowRoot:hf,querySelector:ff,querySelectorAll:pf,mutationObserver:Xo};function ie(i,e,t=document){let r={capture:!0,passive:!0};return t.addEventListener(i,e,r),()=>t.removeEventListener(i,e,r)}var ze=`Please stop import mirror directly. Instead of that,\r
|
|
58
52
|
now you can use replayer.getMirror() to access the mirror instance of a replayer,\r
|
|
59
|
-
or you can use record.mirror to access the mirror instance during recording.`,fn={map:{},getId(){return console.error(ze),-1},getNode(){return console.error(ze),null},removeNodeFromMap(){console.error(ze)},has(){return console.error(ze),!1},reset(){console.error(ze)}};typeof window<"u"&&window.Proxy&&window.Reflect&&(fn=new Proxy(fn,{get(i,e,t){return e==="map"&&console.error(ze),Reflect.get(i,e,t)}}));function St(i,e,t={}){let r=null,s=0;return function(...n){let o=Date.now();!s&&t.leading===!1&&(s=o);let l=e-(o-s),a=this;l<=0||l>e?(r&&(clearTimeout(r),r=null),s=o,i.apply(a,n)):!r&&t.trailing!==!1&&(r=setTimeout(()=>{s=t.leading===!1?0:Date.now(),r=null,i.apply(a,n)},l))}}function Mr(i,e,t,r,s=window){let n=s.Object.getOwnPropertyDescriptor(i,e);return s.Object.defineProperty(i,e,r?t:{set(o){setTimeout(()=>{t.set.call(this,o)},0),n&&n.set&&n.set.call(this,o)}}),()=>Mr(i,e,n||{},!0)}function qe(i,e,t){try{if(!(e in i))return()=>{};let r=i[e],s=t(r);return typeof s=="function"&&(s.prototype=s.prototype||{},Object.defineProperties(s,{__rrweb_original__:{enumerable:!1,value:r}})),i[e]=s,()=>{i[e]=r}}catch{return()=>{}}}var fr=Date.now;/[1-9][0-9]{12}/.test(Date.now().toString())||(fr=()=>new Date().getTime());function ea(i){var e,t,r,s;let n=i.document;return{left:n.scrollingElement?n.scrollingElement.scrollLeft:i.pageXOffset!==void 0?i.pageXOffset:n.documentElement.scrollLeft||n?.body&&((e=A.parentElement(n.body))==null?void 0:e.scrollLeft)||((t=n?.body)==null?void 0:t.scrollLeft)||0,top:n.scrollingElement?n.scrollingElement.scrollTop:i.pageYOffset!==void 0?i.pageYOffset:n?.documentElement.scrollTop||n?.body&&((r=A.parentElement(n.body))==null?void 0:r.scrollTop)||((s=n?.body)==null?void 0:s.scrollTop)||0}}function ta(){return window.innerHeight||document.documentElement&&document.documentElement.clientHeight||document.body&&document.body.clientHeight}function ra(){return window.innerWidth||document.documentElement&&document.documentElement.clientWidth||document.body&&document.body.clientWidth}function ia(i){return i?i.nodeType===i.ELEMENT_NODE?i:A.parentElement(i):null}function se(i,e,t,r){if(!i)return!1;let s=ia(i);if(!s)return!1;try{if(typeof e=="string"){if(s.classList.contains(e)||r&&s.closest("."+e)!==null)return!0}else if(ir(s,e,r))return!0}catch{}return!!(t&&(s.matches(t)||r&&s.closest(t)!==null))}function Ef(i,e){return e.getId(i)!==-1}function Xr(i,e,t){return i.tagName==="TITLE"&&t.headTitleMutations?!0:e.getId(i)===ht}function sa(i,e){if(lt(i))return!1;let t=e.getId(i);if(!e.has(t))return!0;let r=A.parentNode(i);return r&&r.nodeType===i.DOCUMENT_NODE?!1:r?sa(r,e):!0}function Ri(i){return!!i.changedTouches}function Mf(i=window){"NodeList"in i&&!i.NodeList.prototype.forEach&&(i.NodeList.prototype.forEach=Array.prototype.forEach),"DOMTokenList"in i&&!i.DOMTokenList.prototype.forEach&&(i.DOMTokenList.prototype.forEach=Array.prototype.forEach)}function na(i,e){return!!(i.nodeName==="IFRAME"&&e.getMeta(i))}function oa(i,e){return!!(i.nodeName==="LINK"&&i.nodeType===i.ELEMENT_NODE&&i.getAttribute&&i.getAttribute("rel")==="stylesheet"&&e.getMeta(i))}function Oi(i){return i?i instanceof Ai&&"shadowRoot"in i?!!i.shadowRoot:!!A.shadowRoot(i):!1}var Ti=class{constructor(){v(this,"id",1),v(this,"styleIDMap",new WeakMap),v(this,"idStyleMap",new Map)}getId(e){return this.styleIDMap.get(e)??-1}has(e){return this.styleIDMap.has(e)}add(e,t){if(this.has(e))return this.getId(e);let r;return t===void 0?r=this.id++:r=t,this.styleIDMap.set(e,r),this.idStyleMap.set(r,e),r}getStyle(e){return this.idStyleMap.get(e)||null}reset(){this.styleIDMap=new WeakMap,this.idStyleMap=new Map,this.id=1}generateId(){return this.id++}};function aa(i){var e;let t=null;return"getRootNode"in i&&((e=A.getRootNode(i))==null?void 0:e.nodeType)===Node.DOCUMENT_FRAGMENT_NODE&&A.host(A.getRootNode(i))&&(t=A.host(A.getRootNode(i))),t}function Nf(i){let e=i,t;for(;t=aa(e);)e=t;return e}function Af(i){let e=i.ownerDocument;if(!e)return!1;let t=Nf(i);return A.contains(e,t)}function la(i){let e=i.ownerDocument;return e?A.contains(e,i)||Af(i):!1}var P=(i=>(i[i.DomContentLoaded=0]="DomContentLoaded",i[i.Load=1]="Load",i[i.FullSnapshot=2]="FullSnapshot",i[i.IncrementalSnapshot=3]="IncrementalSnapshot",i[i.Meta=4]="Meta",i[i.Custom=5]="Custom",i[i.Plugin=6]="Plugin",i))(P||{}),T=(i=>(i[i.Mutation=0]="Mutation",i[i.MouseMove=1]="MouseMove",i[i.MouseInteraction=2]="MouseInteraction",i[i.Scroll=3]="Scroll",i[i.ViewportResize=4]="ViewportResize",i[i.Input=5]="Input",i[i.TouchMove=6]="TouchMove",i[i.MediaInteraction=7]="MediaInteraction",i[i.StyleSheetRule=8]="StyleSheetRule",i[i.CanvasMutation=9]="CanvasMutation",i[i.Font=10]="Font",i[i.Log=11]="Log",i[i.Drag=12]="Drag",i[i.StyleDeclaration=13]="StyleDeclaration",i[i.Selection=14]="Selection",i[i.AdoptedStyleSheet=15]="AdoptedStyleSheet",i[i.CustomElement=16]="CustomElement",i))(T||{}),ae=(i=>(i[i.MouseUp=0]="MouseUp",i[i.MouseDown=1]="MouseDown",i[i.Click=2]="Click",i[i.ContextMenu=3]="ContextMenu",i[i.DblClick=4]="DblClick",i[i.Focus=5]="Focus",i[i.Blur=6]="Blur",i[i.TouchStart=7]="TouchStart",i[i.TouchMove_Departed=8]="TouchMove_Departed",i[i.TouchEnd=9]="TouchEnd",i[i.TouchCancel=10]="TouchCancel",i))(ae||{}),xe=(i=>(i[i.Mouse=0]="Mouse",i[i.Pen=1]="Pen",i[i.Touch=2]="Touch",i))(xe||{}),Ke=(i=>(i[i["2D"]=0]="2D",i[i.WebGL=1]="WebGL",i[i.WebGL2=2]="WebGL2",i))(Ke||{}),Be=(i=>(i[i.Play=0]="Play",i[i.Pause=1]="Pause",i[i.Seeked=2]="Seeked",i[i.VolumeChange=3]="VolumeChange",i[i.RateChange=4]="RateChange",i))(Be||{});var ua=(i=>(i[i.Document=0]="Document",i[i.DocumentType=1]="DocumentType",i[i.Element=2]="Element",i[i.Text=3]="Text",i[i.CDATA=4]="CDATA",i[i.Comment=5]="Comment",i))(ua||{});function dn(i){return"__ln"in i}var Di=class{constructor(){v(this,"length",0),v(this,"head",null),v(this,"tail",null)}get(e){if(e>=this.length)throw new Error("Position outside of list range");let t=this.head;for(let r=0;r<e;r++)t=t?.next||null;return t}addNode(e){let t={value:e,previous:null,next:null};if(e.__ln=t,e.previousSibling&&dn(e.previousSibling)){let r=e.previousSibling.__ln.next;t.next=r,t.previous=e.previousSibling.__ln,e.previousSibling.__ln.next=t,r&&(r.previous=t)}else if(e.nextSibling&&dn(e.nextSibling)&&e.nextSibling.__ln.previous){let r=e.nextSibling.__ln.previous;t.previous=r,t.next=e.nextSibling.__ln,e.nextSibling.__ln.previous=t,r&&(r.next=t)}else this.head&&(this.head.previous=t),t.next=this.head,this.head=t;t.next===null&&(this.tail=t),this.length++}removeNode(e){let t=e.__ln;this.head&&(t.previous?(t.previous.next=t.next,t.next?t.next.previous=t.previous:this.tail=t.previous):(this.head=t.next,this.head?this.head.previous=null:this.tail=null),e.__ln&&delete e.__ln,this.length--)}},pn=(i,e)=>`${i}@${e}`,ki=class{constructor(){v(this,"frozen",!1),v(this,"locked",!1),v(this,"texts",[]),v(this,"attributes",[]),v(this,"attributeMap",new WeakMap),v(this,"removes",[]),v(this,"mapRemoves",[]),v(this,"movedMap",{}),v(this,"addedSet",new Set),v(this,"movedSet",new Set),v(this,"droppedSet",new Set),v(this,"removesSubTreeCache",new Set),v(this,"mutationCb"),v(this,"blockClass"),v(this,"blockSelector"),v(this,"maskTextClass"),v(this,"maskTextSelector"),v(this,"inlineStylesheet"),v(this,"maskInputOptions"),v(this,"maskTextFn"),v(this,"maskInputFn"),v(this,"keepIframeSrcFn"),v(this,"recordCanvas"),v(this,"inlineImages"),v(this,"slimDOMOptions"),v(this,"dataURLOptions"),v(this,"doc"),v(this,"mirror"),v(this,"iframeManager"),v(this,"stylesheetManager"),v(this,"shadowDomManager"),v(this,"canvasManager"),v(this,"processedNodeManager"),v(this,"unattachedDoc"),v(this,"processMutations",e=>{e.forEach(this.processMutation),this.emit()}),v(this,"emit",()=>{if(this.frozen||this.locked)return;let e=[],t=new Set,r=new Di,s=a=>{let u=a,c=ht;for(;c===ht;)u=u&&u.nextSibling,c=u&&this.mirror.getId(u);return c},n=a=>{let u=A.parentNode(a);if(!u||!la(a))return;let c=!1;if(a.nodeType===Node.TEXT_NODE){let g=u.tagName;if(g==="TEXTAREA")return;g==="STYLE"&&this.addedSet.has(u)&&(c=!0)}let h=lt(u)?this.mirror.getId(aa(a)):this.mirror.getId(u),p=s(a);if(h===-1||p===-1)return r.addNode(a);let m=Ve(a,{doc:this.doc,mirror:this.mirror,blockClass:this.blockClass,blockSelector:this.blockSelector,maskTextClass:this.maskTextClass,maskTextSelector:this.maskTextSelector,skipChild:!0,newlyAddedElement:!0,inlineStylesheet:this.inlineStylesheet,maskInputOptions:this.maskInputOptions,maskTextFn:this.maskTextFn,maskInputFn:this.maskInputFn,slimDOMOptions:this.slimDOMOptions,dataURLOptions:this.dataURLOptions,recordCanvas:this.recordCanvas,inlineImages:this.inlineImages,onSerialize:g=>{na(g,this.mirror)&&this.iframeManager.addIframe(g),oa(g,this.mirror)&&this.stylesheetManager.trackLinkElement(g),Oi(a)&&this.shadowDomManager.addShadowRoot(A.shadowRoot(a),this.doc)},onIframeLoad:(g,d)=>{this.iframeManager.attachIframe(g,d),this.shadowDomManager.observeAttachShadow(g)},onStylesheetLoad:(g,d)=>{this.stylesheetManager.attachLinkElement(g,d)},cssCaptured:c});m&&(e.push({parentId:h,nextId:p,node:m}),t.add(m.id))};for(;this.mapRemoves.length;)this.mirror.removeNodeFromMap(this.mapRemoves.shift());for(let a of this.movedSet)mn(this.removesSubTreeCache,a,this.mirror)&&!this.movedSet.has(A.parentNode(a))||n(a);for(let a of this.addedSet)!gn(this.droppedSet,a)&&!mn(this.removesSubTreeCache,a,this.mirror)||gn(this.movedSet,a)?n(a):this.droppedSet.add(a);let o=null;for(;r.length;){let a=null;if(o){let u=this.mirror.getId(A.parentNode(o.value)),c=s(o.value);u!==-1&&c!==-1&&(a=o)}if(!a){let u=r.tail;for(;u;){let c=u;if(u=u.previous,c){let h=this.mirror.getId(A.parentNode(c.value));if(s(c.value)===-1)continue;if(h!==-1){a=c;break}else{let m=c.value,g=A.parentNode(m);if(g&&g.nodeType===Node.DOCUMENT_FRAGMENT_NODE){let d=A.host(g);if(this.mirror.getId(d)!==-1){a=c;break}}}}}}if(!a){for(;r.head;)r.removeNode(r.head.value);break}o=a.previous,r.removeNode(a.value),n(a.value)}let l={texts:this.texts.map(a=>{let u=a.node,c=A.parentNode(u);return c&&c.tagName==="TEXTAREA"&&this.genTextAreaValueMutation(c),{id:this.mirror.getId(u),value:a.value}}).filter(a=>!t.has(a.id)).filter(a=>this.mirror.has(a.id)),attributes:this.attributes.map(a=>{let{attributes:u}=a;if(typeof u.style=="string"){let c=JSON.stringify(a.styleDiff),h=JSON.stringify(a._unchangedStyles);c.length<u.style.length&&(c+h).split("var(").length===u.style.split("var(").length&&(u.style=a.styleDiff)}return{id:this.mirror.getId(a.node),attributes:u}}).filter(a=>!t.has(a.id)).filter(a=>this.mirror.has(a.id)),removes:this.removes,adds:e};!l.texts.length&&!l.attributes.length&&!l.removes.length&&!l.adds.length||(this.texts=[],this.attributes=[],this.attributeMap=new WeakMap,this.removes=[],this.addedSet=new Set,this.movedSet=new Set,this.droppedSet=new Set,this.removesSubTreeCache=new Set,this.movedMap={},this.mutationCb(l))}),v(this,"genTextAreaValueMutation",e=>{let t=this.attributeMap.get(e);t||(t={node:e,attributes:{},styleDiff:{},_unchangedStyles:{}},this.attributes.push(t),this.attributeMap.set(e,t)),t.attributes.value=Array.from(A.childNodes(e),r=>A.textContent(r)||"").join("")}),v(this,"processMutation",e=>{if(!Xr(e.target,this.mirror,this.slimDOMOptions))switch(e.type){case"characterData":{let t=A.textContent(e.target);!se(e.target,this.blockClass,this.blockSelector,!1)&&t!==e.oldValue&&this.texts.push({value:On(e.target,this.maskTextClass,this.maskTextSelector,!0)&&t?this.maskTextFn?this.maskTextFn(t,ia(e.target)):t.replace(/[\S]/g,"*"):t,node:e.target});break}case"attributes":{let t=e.target,r=e.attributeName,s=e.target.getAttribute(r);if(r==="value"){let o=Wi(t);s=Bi({element:t,maskInputOptions:this.maskInputOptions,tagName:t.tagName,type:o,value:s,maskInputFn:this.maskInputFn})}if(se(e.target,this.blockClass,this.blockSelector,!1)||s===e.oldValue)return;let n=this.attributeMap.get(e.target);if(t.tagName==="IFRAME"&&r==="src"&&!this.keepIframeSrcFn(s))if(!t.contentDocument)r="rr_src";else return;if(n||(n={node:e.target,attributes:{},styleDiff:{},_unchangedStyles:{}},this.attributes.push(n),this.attributeMap.set(e.target,n)),r==="type"&&t.tagName==="INPUT"&&(e.oldValue||"").toLowerCase()==="password"&&t.setAttribute("data-rr-is-password","true"),!Rn(t.tagName,r))if(n.attributes[r]=An(this.doc,Pe(t.tagName),Pe(r),s),r==="style"){if(!this.unattachedDoc)try{this.unattachedDoc=document.implementation.createHTMLDocument()}catch{this.unattachedDoc=this.doc}let o=this.unattachedDoc.createElement("span");e.oldValue&&o.setAttribute("style",e.oldValue);for(let l of Array.from(t.style)){let a=t.style.getPropertyValue(l),u=t.style.getPropertyPriority(l);a!==o.style.getPropertyValue(l)||u!==o.style.getPropertyPriority(l)?u===""?n.styleDiff[l]=a:n.styleDiff[l]=[a,u]:n._unchangedStyles[l]=[a,u]}for(let l of Array.from(o.style))t.style.getPropertyValue(l)===""&&(n.styleDiff[l]=!1)}else r==="open"&&t.tagName==="DIALOG"&&(t.matches("dialog:modal")?n.attributes.rr_open_mode="modal":n.attributes.rr_open_mode="non-modal");break}case"childList":{if(se(e.target,this.blockClass,this.blockSelector,!0))return;if(e.target.tagName==="TEXTAREA"){this.genTextAreaValueMutation(e.target);return}e.addedNodes.forEach(t=>this.genAdds(t,e.target)),e.removedNodes.forEach(t=>{let r=this.mirror.getId(t),s=lt(e.target)?this.mirror.getId(A.host(e.target)):this.mirror.getId(e.target);se(e.target,this.blockClass,this.blockSelector,!1)||Xr(t,this.mirror,this.slimDOMOptions)||!Ef(t,this.mirror)||(this.addedSet.has(t)?(_i(this.addedSet,t),this.droppedSet.add(t)):this.addedSet.has(e.target)&&r===-1||sa(e.target,this.mirror)||(this.movedSet.has(t)&&this.movedMap[pn(r,s)]?_i(this.movedSet,t):(this.removes.push({parentId:s,id:r,isShadow:lt(e.target)&&ut(e.target)?!0:void 0}),Rf(t,this.removesSubTreeCache))),this.mapRemoves.push(t))});break}}}),v(this,"genAdds",(e,t)=>{if(!this.processedNodeManager.inOtherBuffer(e,this)&&!(this.addedSet.has(e)||this.movedSet.has(e))){if(this.mirror.hasNode(e)){if(Xr(e,this.mirror,this.slimDOMOptions))return;this.movedSet.add(e);let r=null;t&&this.mirror.hasNode(t)&&(r=this.mirror.getId(t)),r&&r!==-1&&(this.movedMap[pn(this.mirror.getId(e),r)]=!0)}else this.addedSet.add(e),this.droppedSet.delete(e);se(e,this.blockClass,this.blockSelector,!1)||(A.childNodes(e).forEach(r=>this.genAdds(r)),Oi(e)&&A.childNodes(A.shadowRoot(e)).forEach(r=>{this.processedNodeManager.add(r,this),this.genAdds(r,e)}))}})}init(e){["mutationCb","blockClass","blockSelector","maskTextClass","maskTextSelector","inlineStylesheet","maskInputOptions","maskTextFn","maskInputFn","keepIframeSrcFn","recordCanvas","inlineImages","slimDOMOptions","dataURLOptions","doc","mirror","iframeManager","stylesheetManager","shadowDomManager","canvasManager","processedNodeManager"].forEach(t=>{this[t]=e[t]})}freeze(){this.frozen=!0,this.canvasManager.freeze()}unfreeze(){this.frozen=!1,this.canvasManager.unfreeze(),this.emit()}isFrozen(){return this.frozen}lock(){this.locked=!0,this.canvasManager.lock()}unlock(){this.locked=!1,this.canvasManager.unlock(),this.emit()}reset(){this.shadowDomManager.reset(),this.canvasManager.reset()}};function _i(i,e){i.delete(e),A.childNodes(e).forEach(t=>_i(i,t))}function Rf(i,e){let t=[i];for(;t.length;){let r=t.pop();e.has(r)||(e.add(r),A.childNodes(r).forEach(s=>t.push(s)))}}function mn(i,e,t){return i.size===0?!1:Of(i,e)}function Of(i,e,t){let r=A.parentNode(e);return r?i.has(r):!1}function gn(i,e){return i.size===0?!1:ca(i,e)}function ca(i,e){let t=A.parentNode(e);return t?i.has(t)?!0:ca(i,t):!1}var ct;function Tf(i){ct=i}function Df(){ct=void 0}var D=i=>ct?(...t)=>{try{return i(...t)}catch(r){if(ct&&ct(r)===!0)return;throw r}}:i,_e=[];function Et(i){try{if("composedPath"in i){let e=i.composedPath();if(e.length)return e[0]}else if("path"in i&&i.path.length)return i.path[0]}catch{}return i&&i.target}function ha(i,e){let t=new ki;_e.push(t),t.init(i);let r=new(Qo())(D(t.processMutations.bind(t)));return r.observe(e,{attributes:!0,attributeOldValue:!0,characterData:!0,characterDataOldValue:!0,childList:!0,subtree:!0}),r}function kf({mousemoveCb:i,sampling:e,doc:t,mirror:r}){if(e.mousemove===!1)return()=>{};let s=typeof e.mousemove=="number"?e.mousemove:50,n=typeof e.mousemoveCallback=="number"?e.mousemoveCallback:500,o=[],l,a=St(D(h=>{let p=Date.now()-l;i(o.map(m=>(m.timeOffset-=p,m)),h),o=[],l=null}),n),u=D(St(D(h=>{let p=Et(h),{clientX:m,clientY:g}=Ri(h)?h.changedTouches[0]:h;l||(l=fr()),o.push({x:m,y:g,id:r.getId(p),timeOffset:fr()-l}),a(typeof DragEvent<"u"&&h instanceof DragEvent?T.Drag:h instanceof MouseEvent?T.MouseMove:T.TouchMove)}),s,{trailing:!1})),c=[ie("mousemove",u,t),ie("touchmove",u,t),ie("drag",u,t)];return D(()=>{c.forEach(h=>h())})}function _f({mouseInteractionCb:i,doc:e,mirror:t,blockClass:r,blockSelector:s,sampling:n}){if(n.mouseInteraction===!1)return()=>{};let o=n.mouseInteraction===!0||n.mouseInteraction===void 0?{}:n.mouseInteraction,l=[],a=null,u=c=>h=>{let p=Et(h);if(se(p,r,s,!0))return;let m=null,g=c;if("pointerType"in h){switch(h.pointerType){case"mouse":m=xe.Mouse;break;case"touch":m=xe.Touch;break;case"pen":m=xe.Pen;break}m===xe.Touch?ae[c]===ae.MouseDown?g="TouchStart":ae[c]===ae.MouseUp&&(g="TouchEnd"):xe.Pen}else Ri(h)&&(m=xe.Touch);m!==null?(a=m,(g.startsWith("Touch")&&m===xe.Touch||g.startsWith("Mouse")&&m===xe.Mouse)&&(m=null)):ae[c]===ae.Click&&(m=a,a=null);let d=Ri(h)?h.changedTouches[0]:h;if(!d)return;let f=t.getId(p),{clientX:S,clientY:w}=d;D(i)({type:ae[g],id:f,x:S,y:w,...m!==null&&{pointerType:m}})};return Object.keys(ae).filter(c=>Number.isNaN(Number(c))&&!c.endsWith("_Departed")&&o[c]!==!1).forEach(c=>{let h=Pe(c),p=u(c);if(window.PointerEvent)switch(ae[c]){case ae.MouseDown:case ae.MouseUp:h=h.replace("mouse","pointer");break;case ae.TouchStart:case ae.TouchEnd:return}l.push(ie(h,p,e))}),D(()=>{l.forEach(c=>c())})}function fa({scrollCb:i,doc:e,mirror:t,blockClass:r,blockSelector:s,sampling:n}){let o=D(St(D(l=>{let a=Et(l);if(!a||se(a,r,s,!0))return;let u=t.getId(a);if(a===e&&e.defaultView){let c=ea(e.defaultView);i({id:u,x:c.left,y:c.top})}else i({id:u,x:a.scrollLeft,y:a.scrollTop})}),n.scroll||100));return ie("scroll",o,e)}function Pf({viewportResizeCb:i},{win:e}){let t=-1,r=-1,s=D(St(D(()=>{let n=ta(),o=ra();(t!==n||r!==o)&&(i({width:Number(o),height:Number(n)}),t=n,r=o)}),200));return ie("resize",s,e)}var $f=["INPUT","TEXTAREA","SELECT"],yn=new WeakMap;function Lf({inputCb:i,doc:e,mirror:t,blockClass:r,blockSelector:s,ignoreClass:n,ignoreSelector:o,maskInputOptions:l,maskInputFn:a,sampling:u,userTriggeredOnInput:c}){function h(w){let y=Et(w),b=w.isTrusted,E=y&&y.tagName;if(y&&E==="OPTION"&&(y=A.parentElement(y)),!y||!E||$f.indexOf(E)<0||se(y,r,s,!0)||y.classList.contains(n)||o&&y.matches(o))return;let M=y.value,R=!1,x=Wi(y)||"";x==="radio"||x==="checkbox"?R=y.checked:(l[E.toLowerCase()]||l[x])&&(M=Bi({element:y,maskInputOptions:l,tagName:E,type:x,value:M,maskInputFn:a})),p(y,c?{text:M,isChecked:R,userTriggered:b}:{text:M,isChecked:R});let C=y.name;x==="radio"&&C&&R&&e.querySelectorAll(`input[type="radio"][name="${C}"]`).forEach(k=>{if(k!==y){let N=k.value;p(k,c?{text:N,isChecked:!R,userTriggered:!1}:{text:N,isChecked:!R})}})}function p(w,y){let b=yn.get(w);if(!b||b.text!==y.text||b.isChecked!==y.isChecked){yn.set(w,y);let E=t.getId(w);D(i)({...y,id:E})}}let g=(u.input==="last"?["change"]:["input","change"]).map(w=>ie(w,D(h),e)),d=e.defaultView;if(!d)return()=>{g.forEach(w=>w())};let f=d.Object.getOwnPropertyDescriptor(d.HTMLInputElement.prototype,"value"),S=[[d.HTMLInputElement.prototype,"value"],[d.HTMLInputElement.prototype,"checked"],[d.HTMLSelectElement.prototype,"value"],[d.HTMLTextAreaElement.prototype,"value"],[d.HTMLSelectElement.prototype,"selectedIndex"],[d.HTMLOptionElement.prototype,"selected"]];return f&&f.set&&g.push(...S.map(w=>Mr(w[0],w[1],{set(){D(h)({target:this,isTrusted:!1})}},!1,d))),D(()=>{g.forEach(w=>w())})}function dr(i){let e=[];function t(r,s){if(Yt("CSSGroupingRule")&&r.parentRule instanceof CSSGroupingRule||Yt("CSSMediaRule")&&r.parentRule instanceof CSSMediaRule||Yt("CSSSupportsRule")&&r.parentRule instanceof CSSSupportsRule||Yt("CSSConditionRule")&&r.parentRule instanceof CSSConditionRule){let o=Array.from(r.parentRule.cssRules).indexOf(r);s.unshift(o)}else if(r.parentStyleSheet){let o=Array.from(r.parentStyleSheet.cssRules).indexOf(r);s.unshift(o)}return s}return t(i,e)}function Re(i,e,t){let r,s;return i?(i.ownerNode?r=e.getId(i.ownerNode):s=t.getId(i),{styleId:s,id:r}):{}}function Ff({styleSheetRuleCb:i,mirror:e,stylesheetManager:t},{win:r}){if(!r.CSSStyleSheet||!r.CSSStyleSheet.prototype)return()=>{};let s=r.CSSStyleSheet.prototype.insertRule;r.CSSStyleSheet.prototype.insertRule=new Proxy(s,{apply:D((c,h,p)=>{let[m,g]=p,{id:d,styleId:f}=Re(h,e,t.styleMirror);return(d&&d!==-1||f&&f!==-1)&&i({id:d,styleId:f,adds:[{rule:m,index:g}]}),c.apply(h,p)})}),r.CSSStyleSheet.prototype.addRule=function(c,h,p=this.cssRules.length){let m=`${c} { ${h} }`;return r.CSSStyleSheet.prototype.insertRule.apply(this,[m,p])};let n=r.CSSStyleSheet.prototype.deleteRule;r.CSSStyleSheet.prototype.deleteRule=new Proxy(n,{apply:D((c,h,p)=>{let[m]=p,{id:g,styleId:d}=Re(h,e,t.styleMirror);return(g&&g!==-1||d&&d!==-1)&&i({id:g,styleId:d,removes:[{index:m}]}),c.apply(h,p)})}),r.CSSStyleSheet.prototype.removeRule=function(c){return r.CSSStyleSheet.prototype.deleteRule.apply(this,[c])};let o;r.CSSStyleSheet.prototype.replace&&(o=r.CSSStyleSheet.prototype.replace,r.CSSStyleSheet.prototype.replace=new Proxy(o,{apply:D((c,h,p)=>{let[m]=p,{id:g,styleId:d}=Re(h,e,t.styleMirror);return(g&&g!==-1||d&&d!==-1)&&i({id:g,styleId:d,replace:m}),c.apply(h,p)})}));let l;r.CSSStyleSheet.prototype.replaceSync&&(l=r.CSSStyleSheet.prototype.replaceSync,r.CSSStyleSheet.prototype.replaceSync=new Proxy(l,{apply:D((c,h,p)=>{let[m]=p,{id:g,styleId:d}=Re(h,e,t.styleMirror);return(g&&g!==-1||d&&d!==-1)&&i({id:g,styleId:d,replaceSync:m}),c.apply(h,p)})}));let a={};Zt("CSSGroupingRule")?a.CSSGroupingRule=r.CSSGroupingRule:(Zt("CSSMediaRule")&&(a.CSSMediaRule=r.CSSMediaRule),Zt("CSSConditionRule")&&(a.CSSConditionRule=r.CSSConditionRule),Zt("CSSSupportsRule")&&(a.CSSSupportsRule=r.CSSSupportsRule));let u={};return Object.entries(a).forEach(([c,h])=>{u[c]={insertRule:h.prototype.insertRule,deleteRule:h.prototype.deleteRule},h.prototype.insertRule=new Proxy(u[c].insertRule,{apply:D((p,m,g)=>{let[d,f]=g,{id:S,styleId:w}=Re(m.parentStyleSheet,e,t.styleMirror);return(S&&S!==-1||w&&w!==-1)&&i({id:S,styleId:w,adds:[{rule:d,index:[...dr(m),f||0]}]}),p.apply(m,g)})}),h.prototype.deleteRule=new Proxy(u[c].deleteRule,{apply:D((p,m,g)=>{let[d]=g,{id:f,styleId:S}=Re(m.parentStyleSheet,e,t.styleMirror);return(f&&f!==-1||S&&S!==-1)&&i({id:f,styleId:S,removes:[{index:[...dr(m),d]}]}),p.apply(m,g)})})}),D(()=>{r.CSSStyleSheet.prototype.insertRule=s,r.CSSStyleSheet.prototype.deleteRule=n,o&&(r.CSSStyleSheet.prototype.replace=o),l&&(r.CSSStyleSheet.prototype.replaceSync=l),Object.entries(a).forEach(([c,h])=>{h.prototype.insertRule=u[c].insertRule,h.prototype.deleteRule=u[c].deleteRule})})}function da({mirror:i,stylesheetManager:e},t){var r,s,n;let o=null;t.nodeName==="#document"?o=i.getId(t):o=i.getId(A.host(t));let l=t.nodeName==="#document"?(r=t.defaultView)==null?void 0:r.Document:(n=(s=t.ownerDocument)==null?void 0:s.defaultView)==null?void 0:n.ShadowRoot,a=l?.prototype?Object.getOwnPropertyDescriptor(l?.prototype,"adoptedStyleSheets"):void 0;return o===null||o===-1||!l||!a?()=>{}:(Object.defineProperty(t,"adoptedStyleSheets",{configurable:a.configurable,enumerable:a.enumerable,get(){var u;return(u=a.get)==null?void 0:u.call(this)},set(u){var c;let h=(c=a.set)==null?void 0:c.call(this,u);if(o!==null&&o!==-1)try{e.adoptStyleSheets(u,o)}catch{}return h}}),D(()=>{Object.defineProperty(t,"adoptedStyleSheets",{configurable:a.configurable,enumerable:a.enumerable,get:a.get,set:a.set})}))}function Uf({styleDeclarationCb:i,mirror:e,ignoreCSSAttributes:t,stylesheetManager:r},{win:s}){let n=s.CSSStyleDeclaration.prototype.setProperty;s.CSSStyleDeclaration.prototype.setProperty=new Proxy(n,{apply:D((l,a,u)=>{var c;let[h,p,m]=u;if(t.has(h))return n.apply(a,[h,p,m]);let{id:g,styleId:d}=Re((c=a.parentRule)==null?void 0:c.parentStyleSheet,e,r.styleMirror);return(g&&g!==-1||d&&d!==-1)&&i({id:g,styleId:d,set:{property:h,value:p,priority:m},index:dr(a.parentRule)}),l.apply(a,u)})});let o=s.CSSStyleDeclaration.prototype.removeProperty;return s.CSSStyleDeclaration.prototype.removeProperty=new Proxy(o,{apply:D((l,a,u)=>{var c;let[h]=u;if(t.has(h))return o.apply(a,[h]);let{id:p,styleId:m}=Re((c=a.parentRule)==null?void 0:c.parentStyleSheet,e,r.styleMirror);return(p&&p!==-1||m&&m!==-1)&&i({id:p,styleId:m,remove:{property:h},index:dr(a.parentRule)}),l.apply(a,u)})}),D(()=>{s.CSSStyleDeclaration.prototype.setProperty=n,s.CSSStyleDeclaration.prototype.removeProperty=o})}function zf({mediaInteractionCb:i,blockClass:e,blockSelector:t,mirror:r,sampling:s,doc:n}){let o=D(a=>St(D(u=>{let c=Et(u);if(!c||se(c,e,t,!0))return;let{currentTime:h,volume:p,muted:m,playbackRate:g,loop:d}=c;i({type:a,id:r.getId(c),currentTime:h,volume:p,muted:m,playbackRate:g,loop:d})}),s.media||500)),l=[ie("play",o(Be.Play),n),ie("pause",o(Be.Pause),n),ie("seeked",o(Be.Seeked),n),ie("volumechange",o(Be.VolumeChange),n),ie("ratechange",o(Be.RateChange),n)];return D(()=>{l.forEach(a=>a())})}function Bf({fontCb:i,doc:e}){let t=e.defaultView;if(!t)return()=>{};let r=[],s=new WeakMap,n=t.FontFace;t.FontFace=function(a,u,c){let h=new n(a,u,c);return s.set(h,{family:a,buffer:typeof u!="string",descriptors:c,fontSource:typeof u=="string"?u:JSON.stringify(Array.from(new Uint8Array(u)))}),h};let o=qe(e.fonts,"add",function(l){return function(a){return setTimeout(D(()=>{let u=s.get(a);u&&(i(u),s.delete(a))}),0),l.apply(this,[a])}});return r.push(()=>{t.FontFace=n}),r.push(o),D(()=>{r.forEach(l=>l())})}function Wf(i){let{doc:e,mirror:t,blockClass:r,blockSelector:s,selectionCb:n}=i,o=!0,l=D(()=>{let a=e.getSelection();if(!a||o&&a?.isCollapsed)return;o=a.isCollapsed||!1;let u=[],c=a.rangeCount||0;for(let h=0;h<c;h++){let p=a.getRangeAt(h),{startContainer:m,startOffset:g,endContainer:d,endOffset:f}=p;se(m,r,s,!0)||se(d,r,s,!0)||u.push({start:t.getId(m),startOffset:g,end:t.getId(d),endOffset:f})}n({ranges:u})});return l(),ie("selectionchange",l)}function Vf({doc:i,customElementCb:e}){let t=i.defaultView;return!t||!t.customElements?()=>{}:qe(t.customElements,"define",function(s){return function(n,o,l){try{e({define:{name:n}})}catch{console.warn(`Custom element callback failed for ${n}`)}return s.apply(this,[n,o,l])}})}function Gf(i,e){let{mutationCb:t,mousemoveCb:r,mouseInteractionCb:s,scrollCb:n,viewportResizeCb:o,inputCb:l,mediaInteractionCb:a,styleSheetRuleCb:u,styleDeclarationCb:c,canvasMutationCb:h,fontCb:p,selectionCb:m,customElementCb:g}=i;i.mutationCb=(...d)=>{e.mutation&&e.mutation(...d),t(...d)},i.mousemoveCb=(...d)=>{e.mousemove&&e.mousemove(...d),r(...d)},i.mouseInteractionCb=(...d)=>{e.mouseInteraction&&e.mouseInteraction(...d),s(...d)},i.scrollCb=(...d)=>{e.scroll&&e.scroll(...d),n(...d)},i.viewportResizeCb=(...d)=>{e.viewportResize&&e.viewportResize(...d),o(...d)},i.inputCb=(...d)=>{e.input&&e.input(...d),l(...d)},i.mediaInteractionCb=(...d)=>{e.mediaInteaction&&e.mediaInteaction(...d),a(...d)},i.styleSheetRuleCb=(...d)=>{e.styleSheetRule&&e.styleSheetRule(...d),u(...d)},i.styleDeclarationCb=(...d)=>{e.styleDeclaration&&e.styleDeclaration(...d),c(...d)},i.canvasMutationCb=(...d)=>{e.canvasMutation&&e.canvasMutation(...d),h(...d)},i.fontCb=(...d)=>{e.font&&e.font(...d),p(...d)},i.selectionCb=(...d)=>{e.selection&&e.selection(...d),m(...d)},i.customElementCb=(...d)=>{e.customElement&&e.customElement(...d),g(...d)}}function jf(i,e={}){let t=i.doc.defaultView;if(!t)return()=>{};Gf(i,e);let r;i.recordDOM&&(r=ha(i,i.doc));let s=kf(i),n=_f(i),o=fa(i),l=Pf(i,{win:t}),a=Lf(i),u=zf(i),c=()=>{},h=()=>{},p=()=>{},m=()=>{};i.recordDOM&&(c=Ff(i,{win:t}),h=da(i,i.doc),p=Uf(i,{win:t}),i.collectFonts&&(m=Bf(i)));let g=Wf(i),d=Vf(i),f=[];for(let S of i.plugins)f.push(S.observer(S.callback,t,S.options));return D(()=>{_e.forEach(S=>S.reset()),r?.disconnect(),s(),n(),o(),l(),a(),u(),c(),h(),p(),m(),g(),d(),f.forEach(S=>S())})}function Yt(i){return typeof window[i]<"u"}function Zt(i){return!!(typeof window[i]<"u"&&window[i].prototype&&"insertRule"in window[i].prototype&&"deleteRule"in window[i].prototype)}var pr=class{constructor(e){v(this,"iframeIdToRemoteIdMap",new WeakMap),v(this,"iframeRemoteIdToIdMap",new WeakMap),this.generateIdFn=e}getId(e,t,r,s){let n=r||this.getIdToRemoteIdMap(e),o=s||this.getRemoteIdToIdMap(e),l=n.get(t);return l||(l=this.generateIdFn(),n.set(t,l),o.set(l,t)),l}getIds(e,t){let r=this.getIdToRemoteIdMap(e),s=this.getRemoteIdToIdMap(e);return t.map(n=>this.getId(e,n,r,s))}getRemoteId(e,t,r){let s=r||this.getRemoteIdToIdMap(e);if(typeof t!="number")return t;let n=s.get(t);return n||-1}getRemoteIds(e,t){let r=this.getRemoteIdToIdMap(e);return t.map(s=>this.getRemoteId(e,s,r))}reset(e){if(!e){this.iframeIdToRemoteIdMap=new WeakMap,this.iframeRemoteIdToIdMap=new WeakMap;return}this.iframeIdToRemoteIdMap.delete(e),this.iframeRemoteIdToIdMap.delete(e)}getIdToRemoteIdMap(e){let t=this.iframeIdToRemoteIdMap.get(e);return t||(t=new Map,this.iframeIdToRemoteIdMap.set(e,t)),t}getRemoteIdToIdMap(e){let t=this.iframeRemoteIdToIdMap.get(e);return t||(t=new Map,this.iframeRemoteIdToIdMap.set(e,t)),t}},Pi=class{constructor(e){v(this,"iframes",new WeakMap),v(this,"crossOriginIframeMap",new WeakMap),v(this,"crossOriginIframeMirror",new pr(Nn)),v(this,"crossOriginIframeStyleMirror"),v(this,"crossOriginIframeRootIdMap",new WeakMap),v(this,"mirror"),v(this,"mutationCb"),v(this,"wrappedEmit"),v(this,"loadListener"),v(this,"stylesheetManager"),v(this,"recordCrossOriginIframes"),this.mutationCb=e.mutationCb,this.wrappedEmit=e.wrappedEmit,this.stylesheetManager=e.stylesheetManager,this.recordCrossOriginIframes=e.recordCrossOriginIframes,this.crossOriginIframeStyleMirror=new pr(this.stylesheetManager.styleMirror.generateId.bind(this.stylesheetManager.styleMirror)),this.mirror=e.mirror,this.recordCrossOriginIframes&&window.addEventListener("message",this.handleMessage.bind(this))}addIframe(e){this.iframes.set(e,!0),e.contentWindow&&this.crossOriginIframeMap.set(e.contentWindow,e)}addLoadListener(e){this.loadListener=e}attachIframe(e,t){var r,s;this.mutationCb({adds:[{parentId:this.mirror.getId(e),nextId:null,node:t}],removes:[],texts:[],attributes:[],isAttachIframe:!0}),this.recordCrossOriginIframes&&((r=e.contentWindow)==null||r.addEventListener("message",this.handleMessage.bind(this))),(s=this.loadListener)==null||s.call(this,e),e.contentDocument&&e.contentDocument.adoptedStyleSheets&&e.contentDocument.adoptedStyleSheets.length>0&&this.stylesheetManager.adoptStyleSheets(e.contentDocument.adoptedStyleSheets,this.mirror.getId(e.contentDocument))}handleMessage(e){let t=e;if(t.data.type!=="rrweb"||t.origin!==t.data.origin||!e.source)return;let s=this.crossOriginIframeMap.get(e.source);if(!s)return;let n=this.transformCrossOriginEvent(s,t.data.event);n&&this.wrappedEmit(n,t.data.isCheckout)}transformCrossOriginEvent(e,t){var r;switch(t.type){case P.FullSnapshot:{this.crossOriginIframeMirror.reset(e),this.crossOriginIframeStyleMirror.reset(e),this.replaceIdOnNode(t.data.node,e);let s=t.data.node.id;return this.crossOriginIframeRootIdMap.set(e,s),this.patchRootIdOnNode(t.data.node,s),{timestamp:t.timestamp,type:P.IncrementalSnapshot,data:{source:T.Mutation,adds:[{parentId:this.mirror.getId(e),nextId:null,node:t.data.node}],removes:[],texts:[],attributes:[],isAttachIframe:!0}}}case P.Meta:case P.Load:case P.DomContentLoaded:return!1;case P.Plugin:return t;case P.Custom:return this.replaceIds(t.data.payload,e,["id","parentId","previousId","nextId"]),t;case P.IncrementalSnapshot:switch(t.data.source){case T.Mutation:return t.data.adds.forEach(s=>{this.replaceIds(s,e,["parentId","nextId","previousId"]),this.replaceIdOnNode(s.node,e);let n=this.crossOriginIframeRootIdMap.get(e);n&&this.patchRootIdOnNode(s.node,n)}),t.data.removes.forEach(s=>{this.replaceIds(s,e,["parentId","id"])}),t.data.attributes.forEach(s=>{this.replaceIds(s,e,["id"])}),t.data.texts.forEach(s=>{this.replaceIds(s,e,["id"])}),t;case T.Drag:case T.TouchMove:case T.MouseMove:return t.data.positions.forEach(s=>{this.replaceIds(s,e,["id"])}),t;case T.ViewportResize:return!1;case T.MediaInteraction:case T.MouseInteraction:case T.Scroll:case T.CanvasMutation:case T.Input:return this.replaceIds(t.data,e,["id"]),t;case T.StyleSheetRule:case T.StyleDeclaration:return this.replaceIds(t.data,e,["id"]),this.replaceStyleIds(t.data,e,["styleId"]),t;case T.Font:return t;case T.Selection:return t.data.ranges.forEach(s=>{this.replaceIds(s,e,["start","end"])}),t;case T.AdoptedStyleSheet:return this.replaceIds(t.data,e,["id"]),this.replaceStyleIds(t.data,e,["styleIds"]),(r=t.data.styles)==null||r.forEach(s=>{this.replaceStyleIds(s,e,["styleId"])}),t}}return!1}replace(e,t,r,s){for(let n of s)!Array.isArray(t[n])&&typeof t[n]!="number"||(Array.isArray(t[n])?t[n]=e.getIds(r,t[n]):t[n]=e.getId(r,t[n]));return t}replaceIds(e,t,r){return this.replace(this.crossOriginIframeMirror,e,t,r)}replaceStyleIds(e,t,r){return this.replace(this.crossOriginIframeStyleMirror,e,t,r)}replaceIdOnNode(e,t){this.replaceIds(e,t,["id","rootId"]),"childNodes"in e&&e.childNodes.forEach(r=>{this.replaceIdOnNode(r,t)})}patchRootIdOnNode(e,t){e.type!==ua.Document&&!e.rootId&&(e.rootId=t),"childNodes"in e&&e.childNodes.forEach(r=>{this.patchRootIdOnNode(r,t)})}},$i=class{constructor(e){v(this,"shadowDoms",new WeakSet),v(this,"mutationCb"),v(this,"scrollCb"),v(this,"bypassOptions"),v(this,"mirror"),v(this,"restoreHandlers",[]),this.mutationCb=e.mutationCb,this.scrollCb=e.scrollCb,this.bypassOptions=e.bypassOptions,this.mirror=e.mirror,this.init()}init(){this.reset(),this.patchAttachShadow(Element,document)}addShadowRoot(e,t){if(!ut(e)||this.shadowDoms.has(e))return;this.shadowDoms.add(e);let r=ha({...this.bypassOptions,doc:t,mutationCb:this.mutationCb,mirror:this.mirror,shadowDomManager:this},e);this.restoreHandlers.push(()=>r.disconnect()),this.restoreHandlers.push(fa({...this.bypassOptions,scrollCb:this.scrollCb,doc:e,mirror:this.mirror})),setTimeout(()=>{e.adoptedStyleSheets&&e.adoptedStyleSheets.length>0&&this.bypassOptions.stylesheetManager.adoptStyleSheets(e.adoptedStyleSheets,this.mirror.getId(A.host(e))),this.restoreHandlers.push(da({mirror:this.mirror,stylesheetManager:this.bypassOptions.stylesheetManager},e))},0)}observeAttachShadow(e){!e.contentWindow||!e.contentDocument||this.patchAttachShadow(e.contentWindow.Element,e.contentDocument)}patchAttachShadow(e,t){let r=this;this.restoreHandlers.push(qe(e.prototype,"attachShadow",function(s){return function(n){let o=s.call(this,n),l=A.shadowRoot(this);return l&&la(this)&&r.addShadowRoot(l,t),o}}))}reset(){this.restoreHandlers.forEach(e=>{try{e()}catch{}}),this.restoreHandlers=[],this.shadowDoms=new WeakSet}},Ge="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",Hf=typeof Uint8Array>"u"?[]:new Uint8Array(256);for(at=0;at<Ge.length;at++)Hf[Ge.charCodeAt(at)]=at;var at,Yf=function(i){var e=new Uint8Array(i),t,r=e.length,s="";for(t=0;t<r;t+=3)s+=Ge[e[t]>>2],s+=Ge[(e[t]&3)<<4|e[t+1]>>4],s+=Ge[(e[t+1]&15)<<2|e[t+2]>>6],s+=Ge[e[t+2]&63];return r%3===2?s=s.substring(0,s.length-1)+"=":r%3===1&&(s=s.substring(0,s.length-2)+"=="),s};var vn=new Map;function Zf(i,e){let t=vn.get(i);return t||(t=new Map,vn.set(i,t)),t.has(e)||t.set(e,[]),t.get(e)}var pa=(i,e,t)=>{if(!i||!(ga(i,e)||typeof i=="object"))return;let r=i.constructor.name,s=Zf(t,r),n=s.indexOf(i);return n===-1&&(n=s.length,s.push(i)),n};function Qt(i,e,t){if(i instanceof Array)return i.map(r=>Qt(r,e,t));if(i===null)return i;if(i instanceof Float32Array||i instanceof Float64Array||i instanceof Int32Array||i instanceof Uint32Array||i instanceof Uint8Array||i instanceof Uint16Array||i instanceof Int16Array||i instanceof Int8Array||i instanceof Uint8ClampedArray)return{rr_type:i.constructor.name,args:[Object.values(i)]};if(i instanceof ArrayBuffer){let r=i.constructor.name,s=Yf(i);return{rr_type:r,base64:s}}else{if(i instanceof DataView)return{rr_type:i.constructor.name,args:[Qt(i.buffer,e,t),i.byteOffset,i.byteLength]};if(i instanceof HTMLImageElement){let r=i.constructor.name,{src:s}=i;return{rr_type:r,src:s}}else if(i instanceof HTMLCanvasElement){let r="HTMLImageElement",s=i.toDataURL();return{rr_type:r,src:s}}else{if(i instanceof ImageData)return{rr_type:i.constructor.name,args:[Qt(i.data,e,t),i.width,i.height]};if(ga(i,e)||typeof i=="object"){let r=i.constructor.name,s=pa(i,e,t);return{rr_type:r,index:s}}}}return i}var ma=(i,e,t)=>i.map(r=>Qt(r,e,t)),ga=(i,e)=>!!["WebGLActiveInfo","WebGLBuffer","WebGLFramebuffer","WebGLProgram","WebGLRenderbuffer","WebGLShader","WebGLShaderPrecisionFormat","WebGLTexture","WebGLUniformLocation","WebGLVertexArrayObject","WebGLVertexArrayObjectOES"].filter(s=>typeof e[s]=="function").find(s=>i instanceof e[s]);function Xf(i,e,t,r){let s=[],n=Object.getOwnPropertyNames(e.CanvasRenderingContext2D.prototype);for(let o of n)try{if(typeof e.CanvasRenderingContext2D.prototype[o]!="function")continue;let l=qe(e.CanvasRenderingContext2D.prototype,o,function(a){return function(...u){return se(this.canvas,t,r,!0)||setTimeout(()=>{let c=ma(u,e,this);i(this.canvas,{type:Ke["2D"],property:o,args:c})},0),a.apply(this,u)}});s.push(l)}catch{let l=Mr(e.CanvasRenderingContext2D.prototype,o,{set(a){i(this.canvas,{type:Ke["2D"],property:o,args:[a],setter:!0})}});s.push(l)}return()=>{s.forEach(o=>o())}}function Jf(i){return i==="experimental-webgl"?"webgl":i}function wn(i,e,t,r){let s=[];try{let n=qe(i.HTMLCanvasElement.prototype,"getContext",function(o){return function(l,...a){if(!se(this,e,t,!0)){let u=Jf(l);if("__context"in this||(this.__context=u),r&&["webgl","webgl2"].includes(u))if(a[0]&&typeof a[0]=="object"){let c=a[0];c.preserveDrawingBuffer||(c.preserveDrawingBuffer=!0)}else a.splice(0,1,{preserveDrawingBuffer:!0})}return o.apply(this,[l,...a])}});s.push(n)}catch{console.error("failed to patch HTMLCanvasElement.prototype.getContext")}return()=>{s.forEach(n=>n())}}function Sn(i,e,t,r,s,n){let o=[],l=Object.getOwnPropertyNames(i);for(let a of l)if(!["isContextLost","canvas","drawingBufferWidth","drawingBufferHeight"].includes(a))try{if(typeof i[a]!="function")continue;let u=qe(i,a,function(c){return function(...h){let p=c.apply(this,h);if(pa(p,n,this),"tagName"in this.canvas&&!se(this.canvas,r,s,!0)){let m=ma(h,n,this),g={type:e,property:a,args:m};t(this.canvas,g)}return p}});o.push(u)}catch{let u=Mr(i,a,{set(c){t(this.canvas,{type:e,property:a,args:[c],setter:!0})}});o.push(u)}return o}function Kf(i,e,t,r){let s=[];return s.push(...Sn(e.WebGLRenderingContext.prototype,Ke.WebGL,i,t,r,e)),typeof e.WebGL2RenderingContext<"u"&&s.push(...Sn(e.WebGL2RenderingContext.prototype,Ke.WebGL2,i,t,r,e)),()=>{s.forEach(n=>n())}}var ya="KGZ1bmN0aW9uKCkgewogICJ1c2Ugc3RyaWN0IjsKICB2YXIgY2hhcnMgPSAiQUJDREVGR0hJSktMTU5PUFFSU1RVVldYWVphYmNkZWZnaGlqa2xtbm9wcXJzdHV2d3h5ejAxMjM0NTY3ODkrLyI7CiAgdmFyIGxvb2t1cCA9IHR5cGVvZiBVaW50OEFycmF5ID09PSAidW5kZWZpbmVkIiA/IFtdIDogbmV3IFVpbnQ4QXJyYXkoMjU2KTsKICBmb3IgKHZhciBpID0gMDsgaSA8IGNoYXJzLmxlbmd0aDsgaSsrKSB7CiAgICBsb29rdXBbY2hhcnMuY2hhckNvZGVBdChpKV0gPSBpOwogIH0KICB2YXIgZW5jb2RlID0gZnVuY3Rpb24oYXJyYXlidWZmZXIpIHsKICAgIHZhciBieXRlcyA9IG5ldyBVaW50OEFycmF5KGFycmF5YnVmZmVyKSwgaTIsIGxlbiA9IGJ5dGVzLmxlbmd0aCwgYmFzZTY0ID0gIiI7CiAgICBmb3IgKGkyID0gMDsgaTIgPCBsZW47IGkyICs9IDMpIHsKICAgICAgYmFzZTY0ICs9IGNoYXJzW2J5dGVzW2kyXSA+PiAyXTsKICAgICAgYmFzZTY0ICs9IGNoYXJzWyhieXRlc1tpMl0gJiAzKSA8PCA0IHwgYnl0ZXNbaTIgKyAxXSA+PiA0XTsKICAgICAgYmFzZTY0ICs9IGNoYXJzWyhieXRlc1tpMiArIDFdICYgMTUpIDw8IDIgfCBieXRlc1tpMiArIDJdID4+IDZdOwogICAgICBiYXNlNjQgKz0gY2hhcnNbYnl0ZXNbaTIgKyAyXSAmIDYzXTsKICAgIH0KICAgIGlmIChsZW4gJSAzID09PSAyKSB7CiAgICAgIGJhc2U2NCA9IGJhc2U2NC5zdWJzdHJpbmcoMCwgYmFzZTY0Lmxlbmd0aCAtIDEpICsgIj0iOwogICAgfSBlbHNlIGlmIChsZW4gJSAzID09PSAxKSB7CiAgICAgIGJhc2U2NCA9IGJhc2U2NC5zdWJzdHJpbmcoMCwgYmFzZTY0Lmxlbmd0aCAtIDIpICsgIj09IjsKICAgIH0KICAgIHJldHVybiBiYXNlNjQ7CiAgfTsKICBjb25zdCBsYXN0QmxvYk1hcCA9IC8qIEBfX1BVUkVfXyAqLyBuZXcgTWFwKCk7CiAgY29uc3QgdHJhbnNwYXJlbnRCbG9iTWFwID0gLyogQF9fUFVSRV9fICovIG5ldyBNYXAoKTsKICBhc3luYyBmdW5jdGlvbiBnZXRUcmFuc3BhcmVudEJsb2JGb3Iod2lkdGgsIGhlaWdodCwgZGF0YVVSTE9wdGlvbnMpIHsKICAgIGNvbnN0IGlkID0gYCR7d2lkdGh9LSR7aGVpZ2h0fWA7CiAgICBpZiAoIk9mZnNjcmVlbkNhbnZhcyIgaW4gZ2xvYmFsVGhpcykgewogICAgICBpZiAodHJhbnNwYXJlbnRCbG9iTWFwLmhhcyhpZCkpIHJldHVybiB0cmFuc3BhcmVudEJsb2JNYXAuZ2V0KGlkKTsKICAgICAgY29uc3Qgb2Zmc2NyZWVuID0gbmV3IE9mZnNjcmVlbkNhbnZhcyh3aWR0aCwgaGVpZ2h0KTsKICAgICAgb2Zmc2NyZWVuLmdldENvbnRleHQoIjJkIik7CiAgICAgIGNvbnN0IGJsb2IgPSBhd2FpdCBvZmZzY3JlZW4uY29udmVydFRvQmxvYihkYXRhVVJMT3B0aW9ucyk7CiAgICAgIGNvbnN0IGFycmF5QnVmZmVyID0gYXdhaXQgYmxvYi5hcnJheUJ1ZmZlcigpOwogICAgICBjb25zdCBiYXNlNjQgPSBlbmNvZGUoYXJyYXlCdWZmZXIpOwogICAgICB0cmFuc3BhcmVudEJsb2JNYXAuc2V0KGlkLCBiYXNlNjQpOwogICAgICByZXR1cm4gYmFzZTY0OwogICAgfSBlbHNlIHsKICAgICAgcmV0dXJuICIiOwogICAgfQogIH0KICBjb25zdCB3b3JrZXIgPSBzZWxmOwogIHdvcmtlci5vbm1lc3NhZ2UgPSBhc3luYyBmdW5jdGlvbihlKSB7CiAgICBpZiAoIk9mZnNjcmVlbkNhbnZhcyIgaW4gZ2xvYmFsVGhpcykgewogICAgICBjb25zdCB7IGlkLCBiaXRtYXAsIHdpZHRoLCBoZWlnaHQsIGRhdGFVUkxPcHRpb25zIH0gPSBlLmRhdGE7CiAgICAgIGNvbnN0IHRyYW5zcGFyZW50QmFzZTY0ID0gZ2V0VHJhbnNwYXJlbnRCbG9iRm9yKAogICAgICAgIHdpZHRoLAogICAgICAgIGhlaWdodCwKICAgICAgICBkYXRhVVJMT3B0aW9ucwogICAgICApOwogICAgICBjb25zdCBvZmZzY3JlZW4gPSBuZXcgT2Zmc2NyZWVuQ2FudmFzKHdpZHRoLCBoZWlnaHQpOwogICAgICBjb25zdCBjdHggPSBvZmZzY3JlZW4uZ2V0Q29udGV4dCgiMmQiKTsKICAgICAgY3R4LmRyYXdJbWFnZShiaXRtYXAsIDAsIDApOwogICAgICBiaXRtYXAuY2xvc2UoKTsKICAgICAgY29uc3QgYmxvYiA9IGF3YWl0IG9mZnNjcmVlbi5jb252ZXJ0VG9CbG9iKGRhdGFVUkxPcHRpb25zKTsKICAgICAgY29uc3QgdHlwZSA9IGJsb2IudHlwZTsKICAgICAgY29uc3QgYXJyYXlCdWZmZXIgPSBhd2FpdCBibG9iLmFycmF5QnVmZmVyKCk7CiAgICAgIGNvbnN0IGJhc2U2NCA9IGVuY29kZShhcnJheUJ1ZmZlcik7CiAgICAgIGlmICghbGFzdEJsb2JNYXAuaGFzKGlkKSAmJiBhd2FpdCB0cmFuc3BhcmVudEJhc2U2NCA9PT0gYmFzZTY0KSB7CiAgICAgICAgbGFzdEJsb2JNYXAuc2V0KGlkLCBiYXNlNjQpOwogICAgICAgIHJldHVybiB3b3JrZXIucG9zdE1lc3NhZ2UoeyBpZCB9KTsKICAgICAgfQogICAgICBpZiAobGFzdEJsb2JNYXAuZ2V0KGlkKSA9PT0gYmFzZTY0KSByZXR1cm4gd29ya2VyLnBvc3RNZXNzYWdlKHsgaWQgfSk7CiAgICAgIHdvcmtlci5wb3N0TWVzc2FnZSh7CiAgICAgICAgaWQsCiAgICAgICAgdHlwZSwKICAgICAgICBiYXNlNjQsCiAgICAgICAgd2lkdGgsCiAgICAgICAgaGVpZ2h0CiAgICAgIH0pOwogICAgICBsYXN0QmxvYk1hcC5zZXQoaWQsIGJhc2U2NCk7CiAgICB9IGVsc2UgewogICAgICByZXR1cm4gd29ya2VyLnBvc3RNZXNzYWdlKHsgaWQ6IGUuZGF0YS5pZCB9KTsKICAgIH0KICB9Owp9KSgpOwovLyMgc291cmNlTWFwcGluZ1VSTD1pbWFnZS1iaXRtYXAtZGF0YS11cmwtd29ya2VyLUlKcEM3Z19iLmpzLm1hcAo=",qf=i=>Uint8Array.from(atob(i),e=>e.charCodeAt(0)),bn=typeof window<"u"&&window.Blob&&new Blob([qf(ya)],{type:"text/javascript;charset=utf-8"});function Qf(i){let e;try{if(e=bn&&(window.URL||window.webkitURL).createObjectURL(bn),!e)throw"";let t=new Worker(e,{name:i?.name});return t.addEventListener("error",()=>{(window.URL||window.webkitURL).revokeObjectURL(e)}),t}catch{return new Worker("data:text/javascript;base64,"+ya,{name:i?.name})}finally{e&&(window.URL||window.webkitURL).revokeObjectURL(e)}}var Li=class{constructor(e){v(this,"pendingCanvasMutations",new Map),v(this,"rafStamps",{latestId:0,invokeId:null}),v(this,"mirror"),v(this,"mutationCb"),v(this,"resetObservers"),v(this,"frozen",!1),v(this,"locked",!1),v(this,"processMutation",(a,u)=>{(this.rafStamps.invokeId&&this.rafStamps.latestId!==this.rafStamps.invokeId||!this.rafStamps.invokeId)&&(this.rafStamps.invokeId=this.rafStamps.latestId),this.pendingCanvasMutations.has(a)||this.pendingCanvasMutations.set(a,[]),this.pendingCanvasMutations.get(a).push(u)});let{sampling:t="all",win:r,blockClass:s,blockSelector:n,recordCanvas:o,dataURLOptions:l}=e;this.mutationCb=e.mutationCb,this.mirror=e.mirror,o&&t==="all"&&this.initCanvasMutationObserver(r,s,n),o&&typeof t=="number"&&this.initCanvasFPSObserver(t,r,s,n,{dataURLOptions:l})}reset(){this.pendingCanvasMutations.clear(),this.resetObservers&&this.resetObservers()}freeze(){this.frozen=!0}unfreeze(){this.frozen=!1}lock(){this.locked=!0}unlock(){this.locked=!1}initCanvasFPSObserver(e,t,r,s,n){let o=wn(t,r,s,!0),l=new Map,a=new Qf;a.onmessage=g=>{let{id:d}=g.data;if(l.set(d,!1),!("base64"in g.data))return;let{base64:f,type:S,width:w,height:y}=g.data;this.mutationCb({id:d,type:Ke["2D"],commands:[{property:"clearRect",args:[0,0,w,y]},{property:"drawImage",args:[{rr_type:"ImageBitmap",args:[{rr_type:"Blob",data:[{rr_type:"ArrayBuffer",base64:f}],type:S}]},0,0]}]})};let u=1e3/e,c=0,h,p=()=>{let g=[];return t.document.querySelectorAll("canvas").forEach(d=>{se(d,r,s,!0)||g.push(d)}),g},m=g=>{if(c&&g-c<u){h=requestAnimationFrame(m);return}c=g,p().forEach(async d=>{var f;let S=this.mirror.getId(d);if(l.get(S)||d.width===0||d.height===0)return;if(l.set(S,!0),["webgl","webgl2"].includes(d.__context)){let y=d.getContext(d.__context);((f=y?.getContextAttributes())==null?void 0:f.preserveDrawingBuffer)===!1&&y.clear(y.COLOR_BUFFER_BIT)}let w=await createImageBitmap(d);a.postMessage({id:S,bitmap:w,width:d.width,height:d.height,dataURLOptions:n.dataURLOptions},[w])}),h=requestAnimationFrame(m)};h=requestAnimationFrame(m),this.resetObservers=()=>{o(),cancelAnimationFrame(h)}}initCanvasMutationObserver(e,t,r){this.startRAFTimestamping(),this.startPendingCanvasMutationFlusher();let s=wn(e,t,r,!1),n=Xf(this.processMutation.bind(this),e,t,r),o=Kf(this.processMutation.bind(this),e,t,r);this.resetObservers=()=>{s(),n(),o()}}startPendingCanvasMutationFlusher(){requestAnimationFrame(()=>this.flushPendingCanvasMutations())}startRAFTimestamping(){let e=t=>{this.rafStamps.latestId=t,requestAnimationFrame(e)};requestAnimationFrame(e)}flushPendingCanvasMutations(){this.pendingCanvasMutations.forEach((e,t)=>{let r=this.mirror.getId(t);this.flushPendingCanvasMutationFor(t,r)}),requestAnimationFrame(()=>this.flushPendingCanvasMutations())}flushPendingCanvasMutationFor(e,t){if(this.frozen||this.locked)return;let r=this.pendingCanvasMutations.get(e);if(!r||t===-1)return;let s=r.map(o=>{let{type:l,...a}=o;return a}),{type:n}=r[0];this.mutationCb({id:t,type:n,commands:s}),this.pendingCanvasMutations.delete(e)}},Fi=class{constructor(e){v(this,"trackedLinkElements",new WeakSet),v(this,"mutationCb"),v(this,"adoptedStyleSheetCb"),v(this,"styleMirror",new Ti),this.mutationCb=e.mutationCb,this.adoptedStyleSheetCb=e.adoptedStyleSheetCb}attachLinkElement(e,t){"_cssText"in t.attributes&&this.mutationCb({adds:[],removes:[],texts:[],attributes:[{id:t.id,attributes:t.attributes}]}),this.trackLinkElement(e)}trackLinkElement(e){this.trackedLinkElements.has(e)||(this.trackedLinkElements.add(e),this.trackStylesheetInLinkElement(e))}adoptStyleSheets(e,t){if(e.length===0)return;let r={id:t,styleIds:[]},s=[];for(let n of e){let o;this.styleMirror.has(n)?o=this.styleMirror.getId(n):(o=this.styleMirror.add(n),s.push({styleId:o,rules:Array.from(n.rules||CSSRule,(l,a)=>({rule:En(l,n.href),index:a}))})),r.styleIds.push(o)}s.length>0&&(r.styles=s),this.adoptedStyleSheetCb(r)}reset(){this.styleMirror.reset(),this.trackedLinkElements=new WeakSet}trackStylesheetInLinkElement(e){}},Ui=class{constructor(){v(this,"nodeMap",new WeakMap),v(this,"active",!1)}inOtherBuffer(e,t){let r=this.nodeMap.get(e);return r&&Array.from(r).some(s=>s!==t)}add(e,t){this.active||(this.active=!0,requestAnimationFrame(()=>{this.nodeMap=new WeakMap,this.active=!1})),this.nodeMap.set(e,(this.nodeMap.get(e)||new Set).add(t))}destroy(){}},J,er,Jr,mr=!1;try{if(Array.from([1],i=>i*2)[0]!==2){let i=document.createElement("iframe");document.body.appendChild(i),Array.from=((Cs=i.contentWindow)==null?void 0:Cs.Array.from)||Array.from,document.body.removeChild(i)}}catch(i){console.debug("Unable to override Array.from",i)}var pe=rl();function Me(i={}){let{emit:e,checkoutEveryNms:t,checkoutEveryNth:r,blockClass:s="rr-block",blockSelector:n=null,ignoreClass:o="rr-ignore",ignoreSelector:l=null,maskTextClass:a="rr-mask",maskTextSelector:u=null,inlineStylesheet:c=!0,maskAllInputs:h,maskInputOptions:p,slimDOMOptions:m,maskInputFn:g,maskTextFn:d,hooks:f,packFn:S,sampling:w={},dataURLOptions:y={},mousemoveWait:b,recordDOM:E=!0,recordCanvas:M=!1,recordCrossOriginIframes:R=!1,recordAfter:x=i.recordAfter==="DOMContentLoaded"?i.recordAfter:"load",userTriggeredOnInput:C=!1,collectFonts:k=!1,inlineImages:N=!1,plugins:O,keepIframeSrcFn:I=()=>!1,ignoreCSSAttributes:j=new Set([]),errorHandler:K}=i;Tf(K);let L=R?window.parent===window:!0,F=!1;if(!L)try{window.parent.document&&(F=!1)}catch{F=!0}if(L&&!e)throw new Error("emit function is required");if(!L&&!F)return()=>{};b!==void 0&&w.mousemove===void 0&&(w.mousemove=b),pe.reset();let q=h===!0?{color:!0,date:!0,"datetime-local":!0,email:!0,month:!0,number:!0,range:!0,search:!0,tel:!0,text:!0,time:!0,url:!0,week:!0,textarea:!0,select:!0,password:!0}:p!==void 0?p:{password:!0},Q=m===!0||m==="all"?{script:!0,comment:!0,headFavicon:!0,headWhitespace:!0,headMetaSocial:!0,headMetaRobots:!0,headMetaHttpEquiv:!0,headMetaVerification:!0,headMetaAuthorship:m==="all",headMetaDescKeywords:m==="all",headTitleMutations:m==="all"}:m||{};Mf();let Fe,ne=0,Ne=_=>{for(let oe of O||[])oe.eventProcessor&&(_=oe.eventProcessor(_));return S&&!F&&(_=S(_)),_};J=(_,oe)=>{var W;let V=_;if(V.timestamp=fr(),(W=_e[0])!=null&&W.isFrozen()&&V.type!==P.FullSnapshot&&!(V.type===P.IncrementalSnapshot&&V.data.source===T.Mutation)&&_e.forEach(ve=>ve.unfreeze()),L)e?.(Ne(V),oe);else if(F){let ve={type:"rrweb",event:Ne(V),origin:window.location.origin,isCheckout:oe};window.parent.postMessage(ve,"*")}if(V.type===P.FullSnapshot)Fe=V,ne=0;else if(V.type===P.IncrementalSnapshot){if(V.data.source===T.Mutation&&V.data.isAttachIframe)return;ne++;let ve=r&&ne>=r,B=t&&V.timestamp-Fe.timestamp>t;(ve||B)&&er(!0)}};let he=_=>{J({type:P.IncrementalSnapshot,data:{source:T.Mutation,..._}})},le=_=>J({type:P.IncrementalSnapshot,data:{source:T.Scroll,..._}}),ee=_=>J({type:P.IncrementalSnapshot,data:{source:T.CanvasMutation,..._}}),Ae=_=>J({type:P.IncrementalSnapshot,data:{source:T.AdoptedStyleSheet,..._}}),ye=new Fi({mutationCb:he,adoptedStyleSheetCb:Ae}),fe=new Pi({mirror:pe,mutationCb:he,stylesheetManager:ye,recordCrossOriginIframes:R,wrappedEmit:J});for(let _ of O||[])_.getMirror&&_.getMirror({nodeMirror:pe,crossOriginIframeMirror:fe.crossOriginIframeMirror,crossOriginIframeStyleMirror:fe.crossOriginIframeStyleMirror});let Qe=new Ui;Jr=new Li({recordCanvas:M,mutationCb:ee,win:window,blockClass:s,blockSelector:n,mirror:pe,sampling:w.canvas,dataURLOptions:y});let De=new $i({mutationCb:he,scrollCb:le,bypassOptions:{blockClass:s,blockSelector:n,maskTextClass:a,maskTextSelector:u,inlineStylesheet:c,maskInputOptions:q,dataURLOptions:y,maskTextFn:d,maskInputFn:g,recordCanvas:M,inlineImages:N,sampling:w,slimDOMOptions:Q,iframeManager:fe,stylesheetManager:ye,canvasManager:Jr,keepIframeSrcFn:I,processedNodeManager:Qe},mirror:pe});er=(_=!1)=>{if(!E)return;J({type:P.Meta,data:{href:window.location.href,width:ra(),height:ta()}},_),ye.reset(),De.init(),_e.forEach(W=>W.lock());let oe=Ml(document,{mirror:pe,blockClass:s,blockSelector:n,maskTextClass:a,maskTextSelector:u,inlineStylesheet:c,maskAllInputs:q,maskTextFn:d,maskInputFn:g,slimDOM:Q,dataURLOptions:y,recordCanvas:M,inlineImages:N,onSerialize:W=>{na(W,pe)&&fe.addIframe(W),oa(W,pe)&&ye.trackLinkElement(W),Oi(W)&&De.addShadowRoot(A.shadowRoot(W),document)},onIframeLoad:(W,V)=>{fe.attachIframe(W,V),De.observeAttachShadow(W)},onStylesheetLoad:(W,V)=>{ye.attachLinkElement(W,V)},keepIframeSrcFn:I});if(!oe)return console.warn("Failed to snapshot the document");J({type:P.FullSnapshot,data:{node:oe,initialOffset:ea(window)}},_),_e.forEach(W=>W.unlock()),document.adoptedStyleSheets&&document.adoptedStyleSheets.length>0&&ye.adoptStyleSheets(document.adoptedStyleSheets,pe.getId(document))};try{let _=[],oe=V=>{var ve;return D(jf)({mutationCb:he,mousemoveCb:(B,Nr)=>J({type:P.IncrementalSnapshot,data:{source:Nr,positions:B}}),mouseInteractionCb:B=>J({type:P.IncrementalSnapshot,data:{source:T.MouseInteraction,...B}}),scrollCb:le,viewportResizeCb:B=>J({type:P.IncrementalSnapshot,data:{source:T.ViewportResize,...B}}),inputCb:B=>J({type:P.IncrementalSnapshot,data:{source:T.Input,...B}}),mediaInteractionCb:B=>J({type:P.IncrementalSnapshot,data:{source:T.MediaInteraction,...B}}),styleSheetRuleCb:B=>J({type:P.IncrementalSnapshot,data:{source:T.StyleSheetRule,...B}}),styleDeclarationCb:B=>J({type:P.IncrementalSnapshot,data:{source:T.StyleDeclaration,...B}}),canvasMutationCb:ee,fontCb:B=>J({type:P.IncrementalSnapshot,data:{source:T.Font,...B}}),selectionCb:B=>{J({type:P.IncrementalSnapshot,data:{source:T.Selection,...B}})},customElementCb:B=>{J({type:P.IncrementalSnapshot,data:{source:T.CustomElement,...B}})},blockClass:s,ignoreClass:o,ignoreSelector:l,maskTextClass:a,maskTextSelector:u,maskInputOptions:q,inlineStylesheet:c,sampling:w,recordDOM:E,recordCanvas:M,inlineImages:N,userTriggeredOnInput:C,collectFonts:k,doc:V,maskInputFn:g,maskTextFn:d,keepIframeSrcFn:I,blockSelector:n,slimDOMOptions:Q,dataURLOptions:y,mirror:pe,iframeManager:fe,stylesheetManager:ye,shadowDomManager:De,processedNodeManager:Qe,canvasManager:Jr,ignoreCSSAttributes:j,plugins:((ve=O?.filter(B=>B.observer))==null?void 0:ve.map(B=>({observer:B.observer,options:B.options,callback:Nr=>J({type:P.Plugin,data:{plugin:B.name,payload:Nr}})})))||[]},f)};fe.addLoadListener(V=>{try{_.push(oe(V.contentDocument))}catch(ve){console.warn(ve)}});let W=()=>{er(),_.push(oe(document)),mr=!0};return document.readyState==="interactive"||document.readyState==="complete"?W():(_.push(ie("DOMContentLoaded",()=>{J({type:P.DomContentLoaded,data:{}}),x==="DOMContentLoaded"&&W()})),_.push(ie("load",()=>{J({type:P.Load,data:{}}),x==="load"&&W()},window))),()=>{_.forEach(V=>V()),Qe.destroy(),mr=!1,Df()}}catch(_){console.warn(_)}}Me.addCustomEvent=(i,e)=>{if(!mr)throw new Error("please add custom event after start recording");J({type:P.Custom,data:{tag:i,payload:e}})};Me.freezePage=()=>{_e.forEach(i=>i.freeze())};Me.takeFullSnapshot=i=>{if(!mr)throw new Error("please take full snapshot after start recording");er(i)};Me.mirror=pe;var Cn;(function(i){i[i.NotStarted=0]="NotStarted",i[i.Running=1]="Running",i[i.Stopped=2]="Stopped"})(Cn||(Cn={}));var Gd=5*1e3;var{addCustomEvent:jd}=Me,{freezePage:Hd}=Me,{takeFullSnapshot:Yd}=Me;var ed=64*1024,td=5e3,rd=6e4,id=1e4,sd="[data-sw-block], .rr-block",nd="[data-sw-mask], .rr-mask",od="[data-sw-unmask]";function ad(i){let e="";for(let t of i)e+=String.fromCharCode(t);return btoa(e)}function Kd(i,e,t){let r=[],s=0,n=0,o=null,l=null,a=!1,u=null,c=!1,h="buffer",p=Math.random()<(i.sampleRate??.1),m=!1;function g(){let N=i.privacyMode??"strict",O=N!=="permissive",I=N==="strict";return{emit:d,sampling:{mousemove:!0,mouseInteraction:!0,scroll:150,input:"last"},maskAllInputs:O,maskAllText:I,maskTextSelector:I?void 0:nd,unmaskTextSelector:I?od:void 0,blockSelector:sd,slimDOMOptions:{script:!0,comment:!0,headFavicon:!0,headWhitespace:!0,headMetaSocial:!0,headMetaRobots:!0,headMetaHttpEquiv:!0,headMetaVerification:!0,headMetaAuthorship:!0},errorHandler:j=>{let K=j instanceof Error?j.message:String(j);K.includes("matches is not a function")||console.warn("[Vident Replay] Recording error:",K)}}}function d(N){r.push(N),s+=JSON.stringify(N).length+1,h==="upload"&&(s>=ed?w():f())}function f(){o||h!=="upload"||(o=setTimeout(()=>{o=null,w()},td))}function S(N){let O=bs(new TextEncoder().encode(JSON.stringify(N)));return JSON.stringify({sessionId:e.sessionId,chunkIndex:n,data:ad(O),isFullSnapshot:n===0,timestamp:Date.now(),hasErrors:c})}async function w(){if(r.length===0||h!=="upload")return;let N=r.splice(0);s=0;let O=new AbortController,I=setTimeout(()=>O.abort(),1e4);try{await fetch(`${e.baseUrl}/v1/ingest/replays`,{method:"POST",headers:{"Content-Type":"application/json","x-api-key":e.apiKey},body:S(N),signal:O.signal}),n++}catch(j){console.warn("[Vident Replay] Failed to send chunk:",j)}finally{clearTimeout(I)}}function y(){if(r.length===0||h!=="upload")return;let N=r.splice(0);s=0;try{fetch(`${e.baseUrl}/v1/ingest/replays`,{method:"POST",headers:{"Content-Type":"application/json","x-api-key":e.apiKey},body:S(N),keepalive:!0}).catch(()=>{}),n++}catch{}}function b(){if(h!=="buffer"||r.length===0)return;let N=Date.now()-rd,O=0;for(let I of r)if(I.timestamp<N)O++;else break;O>0&&(r.splice(0,O),s=r.reduce((I,j)=>I+JSON.stringify(j).length+1,0))}function E(){h!=="upload"&&(h="upload",l&&(clearInterval(l),l=null),r.length>0&&w())}function M(){if(a)return;a=!0,p?h="upload":(h="buffer",l=setInterval(b,id)),u=Me(g())??null,window.addEventListener("visibilitychange",x),window.addEventListener("pagehide",C)}function R(){a&&(a=!1,u&&(u(),u=null),o&&(clearTimeout(o),o=null),l&&(clearInterval(l),l=null),h==="upload"&&w(),window.removeEventListener("visibilitychange",x),window.removeEventListener("pagehide",C))}function x(){document.visibilityState==="hidden"&&h==="upload"&&y()}function C(){h==="upload"&&y()}function k(){if(c=!0,h==="upload")return;let N=i.onErrorSampleRate??1;Math.random()<N&&(m=!0,E(),t?.())}return i.enabled&&setTimeout(M,0),{start:M,stop:R,markError:k,isRecording:()=>a,isUploading:()=>h==="upload",wasUpgradedByError:()=>m,startUploading:E}}export{Kd as createReplayRecorder};
|
|
53
|
+
or you can use record.mirror to access the mirror instance during recording.`,cn={map:{},getId(){return console.error(ze),-1},getNode(){return console.error(ze),null},removeNodeFromMap(){console.error(ze)},has(){return console.error(ze),!1},reset(){console.error(ze)}};typeof window<"u"&&window.Proxy&&window.Reflect&&(cn=new Proxy(cn,{get(i,e,t){return e==="map"&&console.error(ze),Reflect.get(i,e,t)}}));function St(i,e,t={}){let r=null,s=0;return function(...n){let o=Date.now();!s&&t.leading===!1&&(s=o);let l=e-(o-s),a=this;l<=0||l>e?(r&&(clearTimeout(r),r=null),s=o,i.apply(a,n)):!r&&t.trailing!==!1&&(r=setTimeout(()=>{s=t.leading===!1?0:Date.now(),r=null,i.apply(a,n)},l))}}function Mr(i,e,t,r,s=window){let n=s.Object.getOwnPropertyDescriptor(i,e);return s.Object.defineProperty(i,e,r?t:{set(o){setTimeout(()=>{t.set.call(this,o)},0),n&&n.set&&n.set.call(this,o)}}),()=>Mr(i,e,n||{},!0)}function qe(i,e,t){try{if(!(e in i))return()=>{};let r=i[e],s=t(r);return typeof s=="function"&&(s.prototype=s.prototype||{},Object.defineProperties(s,{__rrweb_original__:{enumerable:!1,value:r}})),i[e]=s,()=>{i[e]=r}}catch{return()=>{}}}var fr=Date.now;/[1-9][0-9]{12}/.test(Date.now().toString())||(fr=()=>new Date().getTime());function Jo(i){var e,t,r,s;let n=i.document;return{left:n.scrollingElement?n.scrollingElement.scrollLeft:i.pageXOffset!==void 0?i.pageXOffset:n.documentElement.scrollLeft||n?.body&&((e=A.parentElement(n.body))==null?void 0:e.scrollLeft)||((t=n?.body)==null?void 0:t.scrollLeft)||0,top:n.scrollingElement?n.scrollingElement.scrollTop:i.pageYOffset!==void 0?i.pageYOffset:n?.documentElement.scrollTop||n?.body&&((r=A.parentElement(n.body))==null?void 0:r.scrollTop)||((s=n?.body)==null?void 0:s.scrollTop)||0}}function Ko(){return window.innerHeight||document.documentElement&&document.documentElement.clientHeight||document.body&&document.body.clientHeight}function qo(){return window.innerWidth||document.documentElement&&document.documentElement.clientWidth||document.body&&document.body.clientWidth}function Qo(i){return i?i.nodeType===i.ELEMENT_NODE?i:A.parentElement(i):null}function se(i,e,t,r){if(!i)return!1;let s=Qo(i);if(!s)return!1;try{if(typeof e=="string"){if(s.classList.contains(e)||r&&s.closest("."+e)!==null)return!0}else if(ir(s,e,r))return!0}catch{}return!!(t&&(s.matches(t)||r&&s.closest(t)!==null))}function df(i,e){return e.getId(i)!==-1}function Xr(i,e,t){return i.tagName==="TITLE"&&t.headTitleMutations?!0:e.getId(i)===ht}function ea(i,e){if(lt(i))return!1;let t=e.getId(i);if(!e.has(t))return!0;let r=A.parentNode(i);return r&&r.nodeType===i.DOCUMENT_NODE?!1:r?ea(r,e):!0}function Ri(i){return!!i.changedTouches}function mf(i=window){"NodeList"in i&&!i.NodeList.prototype.forEach&&(i.NodeList.prototype.forEach=Array.prototype.forEach),"DOMTokenList"in i&&!i.DOMTokenList.prototype.forEach&&(i.DOMTokenList.prototype.forEach=Array.prototype.forEach)}function ta(i,e){return!!(i.nodeName==="IFRAME"&&e.getMeta(i))}function ra(i,e){return!!(i.nodeName==="LINK"&&i.nodeType===i.ELEMENT_NODE&&i.getAttribute&&i.getAttribute("rel")==="stylesheet"&&e.getMeta(i))}function Oi(i){return i?i instanceof Ai&&"shadowRoot"in i?!!i.shadowRoot:!!A.shadowRoot(i):!1}var Ti=class{constructor(){v(this,"id",1),v(this,"styleIDMap",new WeakMap),v(this,"idStyleMap",new Map)}getId(e){return this.styleIDMap.get(e)??-1}has(e){return this.styleIDMap.has(e)}add(e,t){if(this.has(e))return this.getId(e);let r;return t===void 0?r=this.id++:r=t,this.styleIDMap.set(e,r),this.idStyleMap.set(r,e),r}getStyle(e){return this.idStyleMap.get(e)||null}reset(){this.styleIDMap=new WeakMap,this.idStyleMap=new Map,this.id=1}generateId(){return this.id++}};function ia(i){var e;let t=null;return"getRootNode"in i&&((e=A.getRootNode(i))==null?void 0:e.nodeType)===Node.DOCUMENT_FRAGMENT_NODE&&A.host(A.getRootNode(i))&&(t=A.host(A.getRootNode(i))),t}function gf(i){let e=i,t;for(;t=ia(e);)e=t;return e}function yf(i){let e=i.ownerDocument;if(!e)return!1;let t=gf(i);return A.contains(e,t)}function sa(i){let e=i.ownerDocument;return e?A.contains(e,i)||yf(i):!1}var _=(i=>(i[i.DomContentLoaded=0]="DomContentLoaded",i[i.Load=1]="Load",i[i.FullSnapshot=2]="FullSnapshot",i[i.IncrementalSnapshot=3]="IncrementalSnapshot",i[i.Meta=4]="Meta",i[i.Custom=5]="Custom",i[i.Plugin=6]="Plugin",i))(_||{}),T=(i=>(i[i.Mutation=0]="Mutation",i[i.MouseMove=1]="MouseMove",i[i.MouseInteraction=2]="MouseInteraction",i[i.Scroll=3]="Scroll",i[i.ViewportResize=4]="ViewportResize",i[i.Input=5]="Input",i[i.TouchMove=6]="TouchMove",i[i.MediaInteraction=7]="MediaInteraction",i[i.StyleSheetRule=8]="StyleSheetRule",i[i.CanvasMutation=9]="CanvasMutation",i[i.Font=10]="Font",i[i.Log=11]="Log",i[i.Drag=12]="Drag",i[i.StyleDeclaration=13]="StyleDeclaration",i[i.Selection=14]="Selection",i[i.AdoptedStyleSheet=15]="AdoptedStyleSheet",i[i.CustomElement=16]="CustomElement",i))(T||{}),ae=(i=>(i[i.MouseUp=0]="MouseUp",i[i.MouseDown=1]="MouseDown",i[i.Click=2]="Click",i[i.ContextMenu=3]="ContextMenu",i[i.DblClick=4]="DblClick",i[i.Focus=5]="Focus",i[i.Blur=6]="Blur",i[i.TouchStart=7]="TouchStart",i[i.TouchMove_Departed=8]="TouchMove_Departed",i[i.TouchEnd=9]="TouchEnd",i[i.TouchCancel=10]="TouchCancel",i))(ae||{}),xe=(i=>(i[i.Mouse=0]="Mouse",i[i.Pen=1]="Pen",i[i.Touch=2]="Touch",i))(xe||{}),Ke=(i=>(i[i["2D"]=0]="2D",i[i.WebGL=1]="WebGL",i[i.WebGL2=2]="WebGL2",i))(Ke||{}),Be=(i=>(i[i.Play=0]="Play",i[i.Pause=1]="Pause",i[i.Seeked=2]="Seeked",i[i.VolumeChange=3]="VolumeChange",i[i.RateChange=4]="RateChange",i))(Be||{});var na=(i=>(i[i.Document=0]="Document",i[i.DocumentType=1]="DocumentType",i[i.Element=2]="Element",i[i.Text=3]="Text",i[i.CDATA=4]="CDATA",i[i.Comment=5]="Comment",i))(na||{});function hn(i){return"__ln"in i}var Di=class{constructor(){v(this,"length",0),v(this,"head",null),v(this,"tail",null)}get(e){if(e>=this.length)throw new Error("Position outside of list range");let t=this.head;for(let r=0;r<e;r++)t=t?.next||null;return t}addNode(e){let t={value:e,previous:null,next:null};if(e.__ln=t,e.previousSibling&&hn(e.previousSibling)){let r=e.previousSibling.__ln.next;t.next=r,t.previous=e.previousSibling.__ln,e.previousSibling.__ln.next=t,r&&(r.previous=t)}else if(e.nextSibling&&hn(e.nextSibling)&&e.nextSibling.__ln.previous){let r=e.nextSibling.__ln.previous;t.previous=r,t.next=e.nextSibling.__ln,e.nextSibling.__ln.previous=t,r&&(r.next=t)}else this.head&&(this.head.previous=t),t.next=this.head,this.head=t;t.next===null&&(this.tail=t),this.length++}removeNode(e){let t=e.__ln;this.head&&(t.previous?(t.previous.next=t.next,t.next?t.next.previous=t.previous:this.tail=t.previous):(this.head=t.next,this.head?this.head.previous=null:this.tail=null),e.__ln&&delete e.__ln,this.length--)}},fn=(i,e)=>`${i}@${e}`,ki=class{constructor(){v(this,"frozen",!1),v(this,"locked",!1),v(this,"texts",[]),v(this,"attributes",[]),v(this,"attributeMap",new WeakMap),v(this,"removes",[]),v(this,"mapRemoves",[]),v(this,"movedMap",{}),v(this,"addedSet",new Set),v(this,"movedSet",new Set),v(this,"droppedSet",new Set),v(this,"removesSubTreeCache",new Set),v(this,"mutationCb"),v(this,"blockClass"),v(this,"blockSelector"),v(this,"maskTextClass"),v(this,"maskTextSelector"),v(this,"inlineStylesheet"),v(this,"maskInputOptions"),v(this,"maskTextFn"),v(this,"maskInputFn"),v(this,"keepIframeSrcFn"),v(this,"recordCanvas"),v(this,"inlineImages"),v(this,"slimDOMOptions"),v(this,"dataURLOptions"),v(this,"doc"),v(this,"mirror"),v(this,"iframeManager"),v(this,"stylesheetManager"),v(this,"shadowDomManager"),v(this,"canvasManager"),v(this,"processedNodeManager"),v(this,"unattachedDoc"),v(this,"processMutations",e=>{e.forEach(this.processMutation),this.emit()}),v(this,"emit",()=>{if(this.frozen||this.locked)return;let e=[],t=new Set,r=new Di,s=a=>{let u=a,c=ht;for(;c===ht;)u=u&&u.nextSibling,c=u&&this.mirror.getId(u);return c},n=a=>{let u=A.parentNode(a);if(!u||!sa(a))return;let c=!1;if(a.nodeType===Node.TEXT_NODE){let g=u.tagName;if(g==="TEXTAREA")return;g==="STYLE"&&this.addedSet.has(u)&&(c=!0)}let h=lt(u)?this.mirror.getId(ia(a)):this.mirror.getId(u),d=s(a);if(h===-1||d===-1)return r.addNode(a);let m=Ve(a,{doc:this.doc,mirror:this.mirror,blockClass:this.blockClass,blockSelector:this.blockSelector,maskTextClass:this.maskTextClass,maskTextSelector:this.maskTextSelector,skipChild:!0,newlyAddedElement:!0,inlineStylesheet:this.inlineStylesheet,maskInputOptions:this.maskInputOptions,maskTextFn:this.maskTextFn,maskInputFn:this.maskInputFn,slimDOMOptions:this.slimDOMOptions,dataURLOptions:this.dataURLOptions,recordCanvas:this.recordCanvas,inlineImages:this.inlineImages,onSerialize:g=>{ta(g,this.mirror)&&this.iframeManager.addIframe(g),ra(g,this.mirror)&&this.stylesheetManager.trackLinkElement(g),Oi(a)&&this.shadowDomManager.addShadowRoot(A.shadowRoot(a),this.doc)},onIframeLoad:(g,p)=>{this.iframeManager.attachIframe(g,p),this.shadowDomManager.observeAttachShadow(g)},onStylesheetLoad:(g,p)=>{this.stylesheetManager.attachLinkElement(g,p)},cssCaptured:c});m&&(e.push({parentId:h,nextId:d,node:m}),t.add(m.id))};for(;this.mapRemoves.length;)this.mirror.removeNodeFromMap(this.mapRemoves.shift());for(let a of this.movedSet)pn(this.removesSubTreeCache,a,this.mirror)&&!this.movedSet.has(A.parentNode(a))||n(a);for(let a of this.addedSet)!dn(this.droppedSet,a)&&!pn(this.removesSubTreeCache,a,this.mirror)||dn(this.movedSet,a)?n(a):this.droppedSet.add(a);let o=null;for(;r.length;){let a=null;if(o){let u=this.mirror.getId(A.parentNode(o.value)),c=s(o.value);u!==-1&&c!==-1&&(a=o)}if(!a){let u=r.tail;for(;u;){let c=u;if(u=u.previous,c){let h=this.mirror.getId(A.parentNode(c.value));if(s(c.value)===-1)continue;if(h!==-1){a=c;break}else{let m=c.value,g=A.parentNode(m);if(g&&g.nodeType===Node.DOCUMENT_FRAGMENT_NODE){let p=A.host(g);if(this.mirror.getId(p)!==-1){a=c;break}}}}}}if(!a){for(;r.head;)r.removeNode(r.head.value);break}o=a.previous,r.removeNode(a.value),n(a.value)}let l={texts:this.texts.map(a=>{let u=a.node,c=A.parentNode(u);return c&&c.tagName==="TEXTAREA"&&this.genTextAreaValueMutation(c),{id:this.mirror.getId(u),value:a.value}}).filter(a=>!t.has(a.id)).filter(a=>this.mirror.has(a.id)),attributes:this.attributes.map(a=>{let{attributes:u}=a;if(typeof u.style=="string"){let c=JSON.stringify(a.styleDiff),h=JSON.stringify(a._unchangedStyles);c.length<u.style.length&&(c+h).split("var(").length===u.style.split("var(").length&&(u.style=a.styleDiff)}return{id:this.mirror.getId(a.node),attributes:u}}).filter(a=>!t.has(a.id)).filter(a=>this.mirror.has(a.id)),removes:this.removes,adds:e};!l.texts.length&&!l.attributes.length&&!l.removes.length&&!l.adds.length||(this.texts=[],this.attributes=[],this.attributeMap=new WeakMap,this.removes=[],this.addedSet=new Set,this.movedSet=new Set,this.droppedSet=new Set,this.removesSubTreeCache=new Set,this.movedMap={},this.mutationCb(l))}),v(this,"genTextAreaValueMutation",e=>{let t=this.attributeMap.get(e);t||(t={node:e,attributes:{},styleDiff:{},_unchangedStyles:{}},this.attributes.push(t),this.attributeMap.set(e,t)),t.attributes.value=Array.from(A.childNodes(e),r=>A.textContent(r)||"").join("")}),v(this,"processMutation",e=>{if(!Xr(e.target,this.mirror,this.slimDOMOptions))switch(e.type){case"characterData":{let t=A.textContent(e.target);!se(e.target,this.blockClass,this.blockSelector,!1)&&t!==e.oldValue&&this.texts.push({value:An(e.target,this.maskTextClass,this.maskTextSelector,!0)&&t?this.maskTextFn?this.maskTextFn(t,Qo(e.target)):t.replace(/[\S]/g,"*"):t,node:e.target});break}case"attributes":{let t=e.target,r=e.attributeName,s=e.target.getAttribute(r);if(r==="value"){let o=Wi(t);s=Bi({element:t,maskInputOptions:this.maskInputOptions,tagName:t.tagName,type:o,value:s,maskInputFn:this.maskInputFn})}if(se(e.target,this.blockClass,this.blockSelector,!1)||s===e.oldValue)return;let n=this.attributeMap.get(e.target);if(t.tagName==="IFRAME"&&r==="src"&&!this.keepIframeSrcFn(s))if(!t.contentDocument)r="rr_src";else return;if(n||(n={node:e.target,attributes:{},styleDiff:{},_unchangedStyles:{}},this.attributes.push(n),this.attributeMap.set(e.target,n)),r==="type"&&t.tagName==="INPUT"&&(e.oldValue||"").toLowerCase()==="password"&&t.setAttribute("data-rr-is-password","true"),!Nn(t.tagName,r))if(n.attributes[r]=Mn(this.doc,_e(t.tagName),_e(r),s),r==="style"){if(!this.unattachedDoc)try{this.unattachedDoc=document.implementation.createHTMLDocument()}catch{this.unattachedDoc=this.doc}let o=this.unattachedDoc.createElement("span");e.oldValue&&o.setAttribute("style",e.oldValue);for(let l of Array.from(t.style)){let a=t.style.getPropertyValue(l),u=t.style.getPropertyPriority(l);a!==o.style.getPropertyValue(l)||u!==o.style.getPropertyPriority(l)?u===""?n.styleDiff[l]=a:n.styleDiff[l]=[a,u]:n._unchangedStyles[l]=[a,u]}for(let l of Array.from(o.style))t.style.getPropertyValue(l)===""&&(n.styleDiff[l]=!1)}else r==="open"&&t.tagName==="DIALOG"&&(t.matches("dialog:modal")?n.attributes.rr_open_mode="modal":n.attributes.rr_open_mode="non-modal");break}case"childList":{if(se(e.target,this.blockClass,this.blockSelector,!0))return;if(e.target.tagName==="TEXTAREA"){this.genTextAreaValueMutation(e.target);return}e.addedNodes.forEach(t=>this.genAdds(t,e.target)),e.removedNodes.forEach(t=>{let r=this.mirror.getId(t),s=lt(e.target)?this.mirror.getId(A.host(e.target)):this.mirror.getId(e.target);se(e.target,this.blockClass,this.blockSelector,!1)||Xr(t,this.mirror,this.slimDOMOptions)||!df(t,this.mirror)||(this.addedSet.has(t)?($i(this.addedSet,t),this.droppedSet.add(t)):this.addedSet.has(e.target)&&r===-1||ea(e.target,this.mirror)||(this.movedSet.has(t)&&this.movedMap[fn(r,s)]?$i(this.movedSet,t):(this.removes.push({parentId:s,id:r,isShadow:lt(e.target)&&ut(e.target)?!0:void 0}),vf(t,this.removesSubTreeCache))),this.mapRemoves.push(t))});break}}}),v(this,"genAdds",(e,t)=>{if(!this.processedNodeManager.inOtherBuffer(e,this)&&!(this.addedSet.has(e)||this.movedSet.has(e))){if(this.mirror.hasNode(e)){if(Xr(e,this.mirror,this.slimDOMOptions))return;this.movedSet.add(e);let r=null;t&&this.mirror.hasNode(t)&&(r=this.mirror.getId(t)),r&&r!==-1&&(this.movedMap[fn(this.mirror.getId(e),r)]=!0)}else this.addedSet.add(e),this.droppedSet.delete(e);se(e,this.blockClass,this.blockSelector,!1)||(A.childNodes(e).forEach(r=>this.genAdds(r)),Oi(e)&&A.childNodes(A.shadowRoot(e)).forEach(r=>{this.processedNodeManager.add(r,this),this.genAdds(r,e)}))}})}init(e){["mutationCb","blockClass","blockSelector","maskTextClass","maskTextSelector","inlineStylesheet","maskInputOptions","maskTextFn","maskInputFn","keepIframeSrcFn","recordCanvas","inlineImages","slimDOMOptions","dataURLOptions","doc","mirror","iframeManager","stylesheetManager","shadowDomManager","canvasManager","processedNodeManager"].forEach(t=>{this[t]=e[t]})}freeze(){this.frozen=!0,this.canvasManager.freeze()}unfreeze(){this.frozen=!1,this.canvasManager.unfreeze(),this.emit()}isFrozen(){return this.frozen}lock(){this.locked=!0,this.canvasManager.lock()}unlock(){this.locked=!1,this.canvasManager.unlock(),this.emit()}reset(){this.shadowDomManager.reset(),this.canvasManager.reset()}};function $i(i,e){i.delete(e),A.childNodes(e).forEach(t=>$i(i,t))}function vf(i,e){let t=[i];for(;t.length;){let r=t.pop();e.has(r)||(e.add(r),A.childNodes(r).forEach(s=>t.push(s)))}}function pn(i,e,t){return i.size===0?!1:wf(i,e)}function wf(i,e,t){let r=A.parentNode(e);return r?i.has(r):!1}function dn(i,e){return i.size===0?!1:oa(i,e)}function oa(i,e){let t=A.parentNode(e);return t?i.has(t)?!0:oa(i,t):!1}var ct;function Sf(i){ct=i}function bf(){ct=void 0}var D=i=>ct?(...t)=>{try{return i(...t)}catch(r){if(ct&&ct(r)===!0)return;throw r}}:i,$e=[];function It(i){try{if("composedPath"in i){let e=i.composedPath();if(e.length)return e[0]}else if("path"in i&&i.path.length)return i.path[0]}catch{}return i&&i.target}function aa(i,e){let t=new ki;$e.push(t),t.init(i);let r=new(Xo())(D(t.processMutations.bind(t)));return r.observe(e,{attributes:!0,attributeOldValue:!0,characterData:!0,characterDataOldValue:!0,childList:!0,subtree:!0}),r}function Cf({mousemoveCb:i,sampling:e,doc:t,mirror:r}){if(e.mousemove===!1)return()=>{};let s=typeof e.mousemove=="number"?e.mousemove:50,n=typeof e.mousemoveCallback=="number"?e.mousemoveCallback:500,o=[],l,a=St(D(h=>{let d=Date.now()-l;i(o.map(m=>(m.timeOffset-=d,m)),h),o=[],l=null}),n),u=D(St(D(h=>{let d=It(h),{clientX:m,clientY:g}=Ri(h)?h.changedTouches[0]:h;l||(l=fr()),o.push({x:m,y:g,id:r.getId(d),timeOffset:fr()-l}),a(typeof DragEvent<"u"&&h instanceof DragEvent?T.Drag:h instanceof MouseEvent?T.MouseMove:T.TouchMove)}),s,{trailing:!1})),c=[ie("mousemove",u,t),ie("touchmove",u,t),ie("drag",u,t)];return D(()=>{c.forEach(h=>h())})}function xf({mouseInteractionCb:i,doc:e,mirror:t,blockClass:r,blockSelector:s,sampling:n}){if(n.mouseInteraction===!1)return()=>{};let o=n.mouseInteraction===!0||n.mouseInteraction===void 0?{}:n.mouseInteraction,l=[],a=null,u=c=>h=>{let d=It(h);if(se(d,r,s,!0))return;let m=null,g=c;if("pointerType"in h){switch(h.pointerType){case"mouse":m=xe.Mouse;break;case"touch":m=xe.Touch;break;case"pen":m=xe.Pen;break}m===xe.Touch?ae[c]===ae.MouseDown?g="TouchStart":ae[c]===ae.MouseUp&&(g="TouchEnd"):xe.Pen}else Ri(h)&&(m=xe.Touch);m!==null?(a=m,(g.startsWith("Touch")&&m===xe.Touch||g.startsWith("Mouse")&&m===xe.Mouse)&&(m=null)):ae[c]===ae.Click&&(m=a,a=null);let p=Ri(h)?h.changedTouches[0]:h;if(!p)return;let f=t.getId(d),{clientX:S,clientY:w}=p;D(i)({type:ae[g],id:f,x:S,y:w,...m!==null&&{pointerType:m}})};return Object.keys(ae).filter(c=>Number.isNaN(Number(c))&&!c.endsWith("_Departed")&&o[c]!==!1).forEach(c=>{let h=_e(c),d=u(c);if(window.PointerEvent)switch(ae[c]){case ae.MouseDown:case ae.MouseUp:h=h.replace("mouse","pointer");break;case ae.TouchStart:case ae.TouchEnd:return}l.push(ie(h,d,e))}),D(()=>{l.forEach(c=>c())})}function la({scrollCb:i,doc:e,mirror:t,blockClass:r,blockSelector:s,sampling:n}){let o=D(St(D(l=>{let a=It(l);if(!a||se(a,r,s,!0))return;let u=t.getId(a);if(a===e&&e.defaultView){let c=Jo(e.defaultView);i({id:u,x:c.left,y:c.top})}else i({id:u,x:a.scrollLeft,y:a.scrollTop})}),n.scroll||100));return ie("scroll",o,e)}function Ef({viewportResizeCb:i},{win:e}){let t=-1,r=-1,s=D(St(D(()=>{let n=Ko(),o=qo();(t!==n||r!==o)&&(i({width:Number(o),height:Number(n)}),t=n,r=o)}),200));return ie("resize",s,e)}var If=["INPUT","TEXTAREA","SELECT"],mn=new WeakMap;function Mf({inputCb:i,doc:e,mirror:t,blockClass:r,blockSelector:s,ignoreClass:n,ignoreSelector:o,maskInputOptions:l,maskInputFn:a,sampling:u,userTriggeredOnInput:c}){function h(w){let y=It(w),b=w.isTrusted,I=y&&y.tagName;if(y&&I==="OPTION"&&(y=A.parentElement(y)),!y||!I||If.indexOf(I)<0||se(y,r,s,!0)||y.classList.contains(n)||o&&y.matches(o))return;let M=y.value,R=!1,x=Wi(y)||"";x==="radio"||x==="checkbox"?R=y.checked:(l[I.toLowerCase()]||l[x])&&(M=Bi({element:y,maskInputOptions:l,tagName:I,type:x,value:M,maskInputFn:a})),d(y,c?{text:M,isChecked:R,userTriggered:b}:{text:M,isChecked:R});let C=y.name;x==="radio"&&C&&R&&e.querySelectorAll(`input[type="radio"][name="${C}"]`).forEach(k=>{if(k!==y){let N=k.value;d(k,c?{text:N,isChecked:!R,userTriggered:!1}:{text:N,isChecked:!R})}})}function d(w,y){let b=mn.get(w);if(!b||b.text!==y.text||b.isChecked!==y.isChecked){mn.set(w,y);let I=t.getId(w);D(i)({...y,id:I})}}let g=(u.input==="last"?["change"]:["input","change"]).map(w=>ie(w,D(h),e)),p=e.defaultView;if(!p)return()=>{g.forEach(w=>w())};let f=p.Object.getOwnPropertyDescriptor(p.HTMLInputElement.prototype,"value"),S=[[p.HTMLInputElement.prototype,"value"],[p.HTMLInputElement.prototype,"checked"],[p.HTMLSelectElement.prototype,"value"],[p.HTMLTextAreaElement.prototype,"value"],[p.HTMLSelectElement.prototype,"selectedIndex"],[p.HTMLOptionElement.prototype,"selected"]];return f&&f.set&&g.push(...S.map(w=>Mr(w[0],w[1],{set(){D(h)({target:this,isTrusted:!1})}},!1,p))),D(()=>{g.forEach(w=>w())})}function pr(i){let e=[];function t(r,s){if(Yt("CSSGroupingRule")&&r.parentRule instanceof CSSGroupingRule||Yt("CSSMediaRule")&&r.parentRule instanceof CSSMediaRule||Yt("CSSSupportsRule")&&r.parentRule instanceof CSSSupportsRule||Yt("CSSConditionRule")&&r.parentRule instanceof CSSConditionRule){let o=Array.from(r.parentRule.cssRules).indexOf(r);s.unshift(o)}else if(r.parentStyleSheet){let o=Array.from(r.parentStyleSheet.cssRules).indexOf(r);s.unshift(o)}return s}return t(i,e)}function Re(i,e,t){let r,s;return i?(i.ownerNode?r=e.getId(i.ownerNode):s=t.getId(i),{styleId:s,id:r}):{}}function Nf({styleSheetRuleCb:i,mirror:e,stylesheetManager:t},{win:r}){if(!r.CSSStyleSheet||!r.CSSStyleSheet.prototype)return()=>{};let s=r.CSSStyleSheet.prototype.insertRule;r.CSSStyleSheet.prototype.insertRule=new Proxy(s,{apply:D((c,h,d)=>{let[m,g]=d,{id:p,styleId:f}=Re(h,e,t.styleMirror);return(p&&p!==-1||f&&f!==-1)&&i({id:p,styleId:f,adds:[{rule:m,index:g}]}),c.apply(h,d)})}),r.CSSStyleSheet.prototype.addRule=function(c,h,d=this.cssRules.length){let m=`${c} { ${h} }`;return r.CSSStyleSheet.prototype.insertRule.apply(this,[m,d])};let n=r.CSSStyleSheet.prototype.deleteRule;r.CSSStyleSheet.prototype.deleteRule=new Proxy(n,{apply:D((c,h,d)=>{let[m]=d,{id:g,styleId:p}=Re(h,e,t.styleMirror);return(g&&g!==-1||p&&p!==-1)&&i({id:g,styleId:p,removes:[{index:m}]}),c.apply(h,d)})}),r.CSSStyleSheet.prototype.removeRule=function(c){return r.CSSStyleSheet.prototype.deleteRule.apply(this,[c])};let o;r.CSSStyleSheet.prototype.replace&&(o=r.CSSStyleSheet.prototype.replace,r.CSSStyleSheet.prototype.replace=new Proxy(o,{apply:D((c,h,d)=>{let[m]=d,{id:g,styleId:p}=Re(h,e,t.styleMirror);return(g&&g!==-1||p&&p!==-1)&&i({id:g,styleId:p,replace:m}),c.apply(h,d)})}));let l;r.CSSStyleSheet.prototype.replaceSync&&(l=r.CSSStyleSheet.prototype.replaceSync,r.CSSStyleSheet.prototype.replaceSync=new Proxy(l,{apply:D((c,h,d)=>{let[m]=d,{id:g,styleId:p}=Re(h,e,t.styleMirror);return(g&&g!==-1||p&&p!==-1)&&i({id:g,styleId:p,replaceSync:m}),c.apply(h,d)})}));let a={};Zt("CSSGroupingRule")?a.CSSGroupingRule=r.CSSGroupingRule:(Zt("CSSMediaRule")&&(a.CSSMediaRule=r.CSSMediaRule),Zt("CSSConditionRule")&&(a.CSSConditionRule=r.CSSConditionRule),Zt("CSSSupportsRule")&&(a.CSSSupportsRule=r.CSSSupportsRule));let u={};return Object.entries(a).forEach(([c,h])=>{u[c]={insertRule:h.prototype.insertRule,deleteRule:h.prototype.deleteRule},h.prototype.insertRule=new Proxy(u[c].insertRule,{apply:D((d,m,g)=>{let[p,f]=g,{id:S,styleId:w}=Re(m.parentStyleSheet,e,t.styleMirror);return(S&&S!==-1||w&&w!==-1)&&i({id:S,styleId:w,adds:[{rule:p,index:[...pr(m),f||0]}]}),d.apply(m,g)})}),h.prototype.deleteRule=new Proxy(u[c].deleteRule,{apply:D((d,m,g)=>{let[p]=g,{id:f,styleId:S}=Re(m.parentStyleSheet,e,t.styleMirror);return(f&&f!==-1||S&&S!==-1)&&i({id:f,styleId:S,removes:[{index:[...pr(m),p]}]}),d.apply(m,g)})})}),D(()=>{r.CSSStyleSheet.prototype.insertRule=s,r.CSSStyleSheet.prototype.deleteRule=n,o&&(r.CSSStyleSheet.prototype.replace=o),l&&(r.CSSStyleSheet.prototype.replaceSync=l),Object.entries(a).forEach(([c,h])=>{h.prototype.insertRule=u[c].insertRule,h.prototype.deleteRule=u[c].deleteRule})})}function ua({mirror:i,stylesheetManager:e},t){var r,s,n;let o=null;t.nodeName==="#document"?o=i.getId(t):o=i.getId(A.host(t));let l=t.nodeName==="#document"?(r=t.defaultView)==null?void 0:r.Document:(n=(s=t.ownerDocument)==null?void 0:s.defaultView)==null?void 0:n.ShadowRoot,a=l?.prototype?Object.getOwnPropertyDescriptor(l?.prototype,"adoptedStyleSheets"):void 0;return o===null||o===-1||!l||!a?()=>{}:(Object.defineProperty(t,"adoptedStyleSheets",{configurable:a.configurable,enumerable:a.enumerable,get(){var u;return(u=a.get)==null?void 0:u.call(this)},set(u){var c;let h=(c=a.set)==null?void 0:c.call(this,u);if(o!==null&&o!==-1)try{e.adoptStyleSheets(u,o)}catch{}return h}}),D(()=>{Object.defineProperty(t,"adoptedStyleSheets",{configurable:a.configurable,enumerable:a.enumerable,get:a.get,set:a.set})}))}function Af({styleDeclarationCb:i,mirror:e,ignoreCSSAttributes:t,stylesheetManager:r},{win:s}){let n=s.CSSStyleDeclaration.prototype.setProperty;s.CSSStyleDeclaration.prototype.setProperty=new Proxy(n,{apply:D((l,a,u)=>{var c;let[h,d,m]=u;if(t.has(h))return n.apply(a,[h,d,m]);let{id:g,styleId:p}=Re((c=a.parentRule)==null?void 0:c.parentStyleSheet,e,r.styleMirror);return(g&&g!==-1||p&&p!==-1)&&i({id:g,styleId:p,set:{property:h,value:d,priority:m},index:pr(a.parentRule)}),l.apply(a,u)})});let o=s.CSSStyleDeclaration.prototype.removeProperty;return s.CSSStyleDeclaration.prototype.removeProperty=new Proxy(o,{apply:D((l,a,u)=>{var c;let[h]=u;if(t.has(h))return o.apply(a,[h]);let{id:d,styleId:m}=Re((c=a.parentRule)==null?void 0:c.parentStyleSheet,e,r.styleMirror);return(d&&d!==-1||m&&m!==-1)&&i({id:d,styleId:m,remove:{property:h},index:pr(a.parentRule)}),l.apply(a,u)})}),D(()=>{s.CSSStyleDeclaration.prototype.setProperty=n,s.CSSStyleDeclaration.prototype.removeProperty=o})}function Rf({mediaInteractionCb:i,blockClass:e,blockSelector:t,mirror:r,sampling:s,doc:n}){let o=D(a=>St(D(u=>{let c=It(u);if(!c||se(c,e,t,!0))return;let{currentTime:h,volume:d,muted:m,playbackRate:g,loop:p}=c;i({type:a,id:r.getId(c),currentTime:h,volume:d,muted:m,playbackRate:g,loop:p})}),s.media||500)),l=[ie("play",o(Be.Play),n),ie("pause",o(Be.Pause),n),ie("seeked",o(Be.Seeked),n),ie("volumechange",o(Be.VolumeChange),n),ie("ratechange",o(Be.RateChange),n)];return D(()=>{l.forEach(a=>a())})}function Of({fontCb:i,doc:e}){let t=e.defaultView;if(!t)return()=>{};let r=[],s=new WeakMap,n=t.FontFace;t.FontFace=function(a,u,c){let h=new n(a,u,c);return s.set(h,{family:a,buffer:typeof u!="string",descriptors:c,fontSource:typeof u=="string"?u:JSON.stringify(Array.from(new Uint8Array(u)))}),h};let o=qe(e.fonts,"add",function(l){return function(a){return setTimeout(D(()=>{let u=s.get(a);u&&(i(u),s.delete(a))}),0),l.apply(this,[a])}});return r.push(()=>{t.FontFace=n}),r.push(o),D(()=>{r.forEach(l=>l())})}function Tf(i){let{doc:e,mirror:t,blockClass:r,blockSelector:s,selectionCb:n}=i,o=!0,l=D(()=>{let a=e.getSelection();if(!a||o&&a?.isCollapsed)return;o=a.isCollapsed||!1;let u=[],c=a.rangeCount||0;for(let h=0;h<c;h++){let d=a.getRangeAt(h),{startContainer:m,startOffset:g,endContainer:p,endOffset:f}=d;se(m,r,s,!0)||se(p,r,s,!0)||u.push({start:t.getId(m),startOffset:g,end:t.getId(p),endOffset:f})}n({ranges:u})});return l(),ie("selectionchange",l)}function Df({doc:i,customElementCb:e}){let t=i.defaultView;return!t||!t.customElements?()=>{}:qe(t.customElements,"define",function(s){return function(n,o,l){try{e({define:{name:n}})}catch{console.warn(`Custom element callback failed for ${n}`)}return s.apply(this,[n,o,l])}})}function kf(i,e){let{mutationCb:t,mousemoveCb:r,mouseInteractionCb:s,scrollCb:n,viewportResizeCb:o,inputCb:l,mediaInteractionCb:a,styleSheetRuleCb:u,styleDeclarationCb:c,canvasMutationCb:h,fontCb:d,selectionCb:m,customElementCb:g}=i;i.mutationCb=(...p)=>{e.mutation&&e.mutation(...p),t(...p)},i.mousemoveCb=(...p)=>{e.mousemove&&e.mousemove(...p),r(...p)},i.mouseInteractionCb=(...p)=>{e.mouseInteraction&&e.mouseInteraction(...p),s(...p)},i.scrollCb=(...p)=>{e.scroll&&e.scroll(...p),n(...p)},i.viewportResizeCb=(...p)=>{e.viewportResize&&e.viewportResize(...p),o(...p)},i.inputCb=(...p)=>{e.input&&e.input(...p),l(...p)},i.mediaInteractionCb=(...p)=>{e.mediaInteaction&&e.mediaInteaction(...p),a(...p)},i.styleSheetRuleCb=(...p)=>{e.styleSheetRule&&e.styleSheetRule(...p),u(...p)},i.styleDeclarationCb=(...p)=>{e.styleDeclaration&&e.styleDeclaration(...p),c(...p)},i.canvasMutationCb=(...p)=>{e.canvasMutation&&e.canvasMutation(...p),h(...p)},i.fontCb=(...p)=>{e.font&&e.font(...p),d(...p)},i.selectionCb=(...p)=>{e.selection&&e.selection(...p),m(...p)},i.customElementCb=(...p)=>{e.customElement&&e.customElement(...p),g(...p)}}function $f(i,e={}){let t=i.doc.defaultView;if(!t)return()=>{};kf(i,e);let r;i.recordDOM&&(r=aa(i,i.doc));let s=Cf(i),n=xf(i),o=la(i),l=Ef(i,{win:t}),a=Mf(i),u=Rf(i),c=()=>{},h=()=>{},d=()=>{},m=()=>{};i.recordDOM&&(c=Nf(i,{win:t}),h=ua(i,i.doc),d=Af(i,{win:t}),i.collectFonts&&(m=Of(i)));let g=Tf(i),p=Df(i),f=[];for(let S of i.plugins)f.push(S.observer(S.callback,t,S.options));return D(()=>{$e.forEach(S=>S.reset()),r?.disconnect(),s(),n(),o(),l(),a(),u(),c(),h(),d(),m(),g(),p(),f.forEach(S=>S())})}function Yt(i){return typeof window[i]<"u"}function Zt(i){return!!(typeof window[i]<"u"&&window[i].prototype&&"insertRule"in window[i].prototype&&"deleteRule"in window[i].prototype)}var dr=class{constructor(e){v(this,"iframeIdToRemoteIdMap",new WeakMap),v(this,"iframeRemoteIdToIdMap",new WeakMap),this.generateIdFn=e}getId(e,t,r,s){let n=r||this.getIdToRemoteIdMap(e),o=s||this.getRemoteIdToIdMap(e),l=n.get(t);return l||(l=this.generateIdFn(),n.set(t,l),o.set(l,t)),l}getIds(e,t){let r=this.getIdToRemoteIdMap(e),s=this.getRemoteIdToIdMap(e);return t.map(n=>this.getId(e,n,r,s))}getRemoteId(e,t,r){let s=r||this.getRemoteIdToIdMap(e);if(typeof t!="number")return t;let n=s.get(t);return n||-1}getRemoteIds(e,t){let r=this.getRemoteIdToIdMap(e);return t.map(s=>this.getRemoteId(e,s,r))}reset(e){if(!e){this.iframeIdToRemoteIdMap=new WeakMap,this.iframeRemoteIdToIdMap=new WeakMap;return}this.iframeIdToRemoteIdMap.delete(e),this.iframeRemoteIdToIdMap.delete(e)}getIdToRemoteIdMap(e){let t=this.iframeIdToRemoteIdMap.get(e);return t||(t=new Map,this.iframeIdToRemoteIdMap.set(e,t)),t}getRemoteIdToIdMap(e){let t=this.iframeRemoteIdToIdMap.get(e);return t||(t=new Map,this.iframeRemoteIdToIdMap.set(e,t)),t}},_i=class{constructor(e){v(this,"iframes",new WeakMap),v(this,"crossOriginIframeMap",new WeakMap),v(this,"crossOriginIframeMirror",new dr(In)),v(this,"crossOriginIframeStyleMirror"),v(this,"crossOriginIframeRootIdMap",new WeakMap),v(this,"mirror"),v(this,"mutationCb"),v(this,"wrappedEmit"),v(this,"loadListener"),v(this,"stylesheetManager"),v(this,"recordCrossOriginIframes"),this.mutationCb=e.mutationCb,this.wrappedEmit=e.wrappedEmit,this.stylesheetManager=e.stylesheetManager,this.recordCrossOriginIframes=e.recordCrossOriginIframes,this.crossOriginIframeStyleMirror=new dr(this.stylesheetManager.styleMirror.generateId.bind(this.stylesheetManager.styleMirror)),this.mirror=e.mirror,this.recordCrossOriginIframes&&window.addEventListener("message",this.handleMessage.bind(this))}addIframe(e){this.iframes.set(e,!0),e.contentWindow&&this.crossOriginIframeMap.set(e.contentWindow,e)}addLoadListener(e){this.loadListener=e}attachIframe(e,t){var r,s;this.mutationCb({adds:[{parentId:this.mirror.getId(e),nextId:null,node:t}],removes:[],texts:[],attributes:[],isAttachIframe:!0}),this.recordCrossOriginIframes&&((r=e.contentWindow)==null||r.addEventListener("message",this.handleMessage.bind(this))),(s=this.loadListener)==null||s.call(this,e),e.contentDocument&&e.contentDocument.adoptedStyleSheets&&e.contentDocument.adoptedStyleSheets.length>0&&this.stylesheetManager.adoptStyleSheets(e.contentDocument.adoptedStyleSheets,this.mirror.getId(e.contentDocument))}handleMessage(e){let t=e;if(t.data.type!=="rrweb"||t.origin!==t.data.origin||!e.source)return;let s=this.crossOriginIframeMap.get(e.source);if(!s)return;let n=this.transformCrossOriginEvent(s,t.data.event);n&&this.wrappedEmit(n,t.data.isCheckout)}transformCrossOriginEvent(e,t){var r;switch(t.type){case _.FullSnapshot:{this.crossOriginIframeMirror.reset(e),this.crossOriginIframeStyleMirror.reset(e),this.replaceIdOnNode(t.data.node,e);let s=t.data.node.id;return this.crossOriginIframeRootIdMap.set(e,s),this.patchRootIdOnNode(t.data.node,s),{timestamp:t.timestamp,type:_.IncrementalSnapshot,data:{source:T.Mutation,adds:[{parentId:this.mirror.getId(e),nextId:null,node:t.data.node}],removes:[],texts:[],attributes:[],isAttachIframe:!0}}}case _.Meta:case _.Load:case _.DomContentLoaded:return!1;case _.Plugin:return t;case _.Custom:return this.replaceIds(t.data.payload,e,["id","parentId","previousId","nextId"]),t;case _.IncrementalSnapshot:switch(t.data.source){case T.Mutation:return t.data.adds.forEach(s=>{this.replaceIds(s,e,["parentId","nextId","previousId"]),this.replaceIdOnNode(s.node,e);let n=this.crossOriginIframeRootIdMap.get(e);n&&this.patchRootIdOnNode(s.node,n)}),t.data.removes.forEach(s=>{this.replaceIds(s,e,["parentId","id"])}),t.data.attributes.forEach(s=>{this.replaceIds(s,e,["id"])}),t.data.texts.forEach(s=>{this.replaceIds(s,e,["id"])}),t;case T.Drag:case T.TouchMove:case T.MouseMove:return t.data.positions.forEach(s=>{this.replaceIds(s,e,["id"])}),t;case T.ViewportResize:return!1;case T.MediaInteraction:case T.MouseInteraction:case T.Scroll:case T.CanvasMutation:case T.Input:return this.replaceIds(t.data,e,["id"]),t;case T.StyleSheetRule:case T.StyleDeclaration:return this.replaceIds(t.data,e,["id"]),this.replaceStyleIds(t.data,e,["styleId"]),t;case T.Font:return t;case T.Selection:return t.data.ranges.forEach(s=>{this.replaceIds(s,e,["start","end"])}),t;case T.AdoptedStyleSheet:return this.replaceIds(t.data,e,["id"]),this.replaceStyleIds(t.data,e,["styleIds"]),(r=t.data.styles)==null||r.forEach(s=>{this.replaceStyleIds(s,e,["styleId"])}),t}}return!1}replace(e,t,r,s){for(let n of s)!Array.isArray(t[n])&&typeof t[n]!="number"||(Array.isArray(t[n])?t[n]=e.getIds(r,t[n]):t[n]=e.getId(r,t[n]));return t}replaceIds(e,t,r){return this.replace(this.crossOriginIframeMirror,e,t,r)}replaceStyleIds(e,t,r){return this.replace(this.crossOriginIframeStyleMirror,e,t,r)}replaceIdOnNode(e,t){this.replaceIds(e,t,["id","rootId"]),"childNodes"in e&&e.childNodes.forEach(r=>{this.replaceIdOnNode(r,t)})}patchRootIdOnNode(e,t){e.type!==na.Document&&!e.rootId&&(e.rootId=t),"childNodes"in e&&e.childNodes.forEach(r=>{this.patchRootIdOnNode(r,t)})}},Pi=class{constructor(e){v(this,"shadowDoms",new WeakSet),v(this,"mutationCb"),v(this,"scrollCb"),v(this,"bypassOptions"),v(this,"mirror"),v(this,"restoreHandlers",[]),this.mutationCb=e.mutationCb,this.scrollCb=e.scrollCb,this.bypassOptions=e.bypassOptions,this.mirror=e.mirror,this.init()}init(){this.reset(),this.patchAttachShadow(Element,document)}addShadowRoot(e,t){if(!ut(e)||this.shadowDoms.has(e))return;this.shadowDoms.add(e);let r=aa({...this.bypassOptions,doc:t,mutationCb:this.mutationCb,mirror:this.mirror,shadowDomManager:this},e);this.restoreHandlers.push(()=>r.disconnect()),this.restoreHandlers.push(la({...this.bypassOptions,scrollCb:this.scrollCb,doc:e,mirror:this.mirror})),setTimeout(()=>{e.adoptedStyleSheets&&e.adoptedStyleSheets.length>0&&this.bypassOptions.stylesheetManager.adoptStyleSheets(e.adoptedStyleSheets,this.mirror.getId(A.host(e))),this.restoreHandlers.push(ua({mirror:this.mirror,stylesheetManager:this.bypassOptions.stylesheetManager},e))},0)}observeAttachShadow(e){!e.contentWindow||!e.contentDocument||this.patchAttachShadow(e.contentWindow.Element,e.contentDocument)}patchAttachShadow(e,t){let r=this;this.restoreHandlers.push(qe(e.prototype,"attachShadow",function(s){return function(n){let o=s.call(this,n),l=A.shadowRoot(this);return l&&sa(this)&&r.addShadowRoot(l,t),o}}))}reset(){this.restoreHandlers.forEach(e=>{try{e()}catch{}}),this.restoreHandlers=[],this.shadowDoms=new WeakSet}},Ge="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",_f=typeof Uint8Array>"u"?[]:new Uint8Array(256);for(at=0;at<Ge.length;at++)_f[Ge.charCodeAt(at)]=at;var at,Pf=function(i){var e=new Uint8Array(i),t,r=e.length,s="";for(t=0;t<r;t+=3)s+=Ge[e[t]>>2],s+=Ge[(e[t]&3)<<4|e[t+1]>>4],s+=Ge[(e[t+1]&15)<<2|e[t+2]>>6],s+=Ge[e[t+2]&63];return r%3===2?s=s.substring(0,s.length-1)+"=":r%3===1&&(s=s.substring(0,s.length-2)+"=="),s};var gn=new Map;function Lf(i,e){let t=gn.get(i);return t||(t=new Map,gn.set(i,t)),t.has(e)||t.set(e,[]),t.get(e)}var ca=(i,e,t)=>{if(!i||!(fa(i,e)||typeof i=="object"))return;let r=i.constructor.name,s=Lf(t,r),n=s.indexOf(i);return n===-1&&(n=s.length,s.push(i)),n};function Qt(i,e,t){if(i instanceof Array)return i.map(r=>Qt(r,e,t));if(i===null)return i;if(i instanceof Float32Array||i instanceof Float64Array||i instanceof Int32Array||i instanceof Uint32Array||i instanceof Uint8Array||i instanceof Uint16Array||i instanceof Int16Array||i instanceof Int8Array||i instanceof Uint8ClampedArray)return{rr_type:i.constructor.name,args:[Object.values(i)]};if(i instanceof ArrayBuffer){let r=i.constructor.name,s=Pf(i);return{rr_type:r,base64:s}}else{if(i instanceof DataView)return{rr_type:i.constructor.name,args:[Qt(i.buffer,e,t),i.byteOffset,i.byteLength]};if(i instanceof HTMLImageElement){let r=i.constructor.name,{src:s}=i;return{rr_type:r,src:s}}else if(i instanceof HTMLCanvasElement){let r="HTMLImageElement",s=i.toDataURL();return{rr_type:r,src:s}}else{if(i instanceof ImageData)return{rr_type:i.constructor.name,args:[Qt(i.data,e,t),i.width,i.height]};if(fa(i,e)||typeof i=="object"){let r=i.constructor.name,s=ca(i,e,t);return{rr_type:r,index:s}}}}return i}var ha=(i,e,t)=>i.map(r=>Qt(r,e,t)),fa=(i,e)=>!!["WebGLActiveInfo","WebGLBuffer","WebGLFramebuffer","WebGLProgram","WebGLRenderbuffer","WebGLShader","WebGLShaderPrecisionFormat","WebGLTexture","WebGLUniformLocation","WebGLVertexArrayObject","WebGLVertexArrayObjectOES"].filter(s=>typeof e[s]=="function").find(s=>i instanceof e[s]);function Ff(i,e,t,r){let s=[],n=Object.getOwnPropertyNames(e.CanvasRenderingContext2D.prototype);for(let o of n)try{if(typeof e.CanvasRenderingContext2D.prototype[o]!="function")continue;let l=qe(e.CanvasRenderingContext2D.prototype,o,function(a){return function(...u){return se(this.canvas,t,r,!0)||setTimeout(()=>{let c=ha(u,e,this);i(this.canvas,{type:Ke["2D"],property:o,args:c})},0),a.apply(this,u)}});s.push(l)}catch{let l=Mr(e.CanvasRenderingContext2D.prototype,o,{set(a){i(this.canvas,{type:Ke["2D"],property:o,args:[a],setter:!0})}});s.push(l)}return()=>{s.forEach(o=>o())}}function Uf(i){return i==="experimental-webgl"?"webgl":i}function yn(i,e,t,r){let s=[];try{let n=qe(i.HTMLCanvasElement.prototype,"getContext",function(o){return function(l,...a){if(!se(this,e,t,!0)){let u=Uf(l);if("__context"in this||(this.__context=u),r&&["webgl","webgl2"].includes(u))if(a[0]&&typeof a[0]=="object"){let c=a[0];c.preserveDrawingBuffer||(c.preserveDrawingBuffer=!0)}else a.splice(0,1,{preserveDrawingBuffer:!0})}return o.apply(this,[l,...a])}});s.push(n)}catch{console.error("failed to patch HTMLCanvasElement.prototype.getContext")}return()=>{s.forEach(n=>n())}}function vn(i,e,t,r,s,n){let o=[],l=Object.getOwnPropertyNames(i);for(let a of l)if(!["isContextLost","canvas","drawingBufferWidth","drawingBufferHeight"].includes(a))try{if(typeof i[a]!="function")continue;let u=qe(i,a,function(c){return function(...h){let d=c.apply(this,h);if(ca(d,n,this),"tagName"in this.canvas&&!se(this.canvas,r,s,!0)){let m=ha(h,n,this),g={type:e,property:a,args:m};t(this.canvas,g)}return d}});o.push(u)}catch{let u=Mr(i,a,{set(c){t(this.canvas,{type:e,property:a,args:[c],setter:!0})}});o.push(u)}return o}function zf(i,e,t,r){let s=[];return s.push(...vn(e.WebGLRenderingContext.prototype,Ke.WebGL,i,t,r,e)),typeof e.WebGL2RenderingContext<"u"&&s.push(...vn(e.WebGL2RenderingContext.prototype,Ke.WebGL2,i,t,r,e)),()=>{s.forEach(n=>n())}}var pa="KGZ1bmN0aW9uKCkgewogICJ1c2Ugc3RyaWN0IjsKICB2YXIgY2hhcnMgPSAiQUJDREVGR0hJSktMTU5PUFFSU1RVVldYWVphYmNkZWZnaGlqa2xtbm9wcXJzdHV2d3h5ejAxMjM0NTY3ODkrLyI7CiAgdmFyIGxvb2t1cCA9IHR5cGVvZiBVaW50OEFycmF5ID09PSAidW5kZWZpbmVkIiA/IFtdIDogbmV3IFVpbnQ4QXJyYXkoMjU2KTsKICBmb3IgKHZhciBpID0gMDsgaSA8IGNoYXJzLmxlbmd0aDsgaSsrKSB7CiAgICBsb29rdXBbY2hhcnMuY2hhckNvZGVBdChpKV0gPSBpOwogIH0KICB2YXIgZW5jb2RlID0gZnVuY3Rpb24oYXJyYXlidWZmZXIpIHsKICAgIHZhciBieXRlcyA9IG5ldyBVaW50OEFycmF5KGFycmF5YnVmZmVyKSwgaTIsIGxlbiA9IGJ5dGVzLmxlbmd0aCwgYmFzZTY0ID0gIiI7CiAgICBmb3IgKGkyID0gMDsgaTIgPCBsZW47IGkyICs9IDMpIHsKICAgICAgYmFzZTY0ICs9IGNoYXJzW2J5dGVzW2kyXSA+PiAyXTsKICAgICAgYmFzZTY0ICs9IGNoYXJzWyhieXRlc1tpMl0gJiAzKSA8PCA0IHwgYnl0ZXNbaTIgKyAxXSA+PiA0XTsKICAgICAgYmFzZTY0ICs9IGNoYXJzWyhieXRlc1tpMiArIDFdICYgMTUpIDw8IDIgfCBieXRlc1tpMiArIDJdID4+IDZdOwogICAgICBiYXNlNjQgKz0gY2hhcnNbYnl0ZXNbaTIgKyAyXSAmIDYzXTsKICAgIH0KICAgIGlmIChsZW4gJSAzID09PSAyKSB7CiAgICAgIGJhc2U2NCA9IGJhc2U2NC5zdWJzdHJpbmcoMCwgYmFzZTY0Lmxlbmd0aCAtIDEpICsgIj0iOwogICAgfSBlbHNlIGlmIChsZW4gJSAzID09PSAxKSB7CiAgICAgIGJhc2U2NCA9IGJhc2U2NC5zdWJzdHJpbmcoMCwgYmFzZTY0Lmxlbmd0aCAtIDIpICsgIj09IjsKICAgIH0KICAgIHJldHVybiBiYXNlNjQ7CiAgfTsKICBjb25zdCBsYXN0QmxvYk1hcCA9IC8qIEBfX1BVUkVfXyAqLyBuZXcgTWFwKCk7CiAgY29uc3QgdHJhbnNwYXJlbnRCbG9iTWFwID0gLyogQF9fUFVSRV9fICovIG5ldyBNYXAoKTsKICBhc3luYyBmdW5jdGlvbiBnZXRUcmFuc3BhcmVudEJsb2JGb3Iod2lkdGgsIGhlaWdodCwgZGF0YVVSTE9wdGlvbnMpIHsKICAgIGNvbnN0IGlkID0gYCR7d2lkdGh9LSR7aGVpZ2h0fWA7CiAgICBpZiAoIk9mZnNjcmVlbkNhbnZhcyIgaW4gZ2xvYmFsVGhpcykgewogICAgICBpZiAodHJhbnNwYXJlbnRCbG9iTWFwLmhhcyhpZCkpIHJldHVybiB0cmFuc3BhcmVudEJsb2JNYXAuZ2V0KGlkKTsKICAgICAgY29uc3Qgb2Zmc2NyZWVuID0gbmV3IE9mZnNjcmVlbkNhbnZhcyh3aWR0aCwgaGVpZ2h0KTsKICAgICAgb2Zmc2NyZWVuLmdldENvbnRleHQoIjJkIik7CiAgICAgIGNvbnN0IGJsb2IgPSBhd2FpdCBvZmZzY3JlZW4uY29udmVydFRvQmxvYihkYXRhVVJMT3B0aW9ucyk7CiAgICAgIGNvbnN0IGFycmF5QnVmZmVyID0gYXdhaXQgYmxvYi5hcnJheUJ1ZmZlcigpOwogICAgICBjb25zdCBiYXNlNjQgPSBlbmNvZGUoYXJyYXlCdWZmZXIpOwogICAgICB0cmFuc3BhcmVudEJsb2JNYXAuc2V0KGlkLCBiYXNlNjQpOwogICAgICByZXR1cm4gYmFzZTY0OwogICAgfSBlbHNlIHsKICAgICAgcmV0dXJuICIiOwogICAgfQogIH0KICBjb25zdCB3b3JrZXIgPSBzZWxmOwogIHdvcmtlci5vbm1lc3NhZ2UgPSBhc3luYyBmdW5jdGlvbihlKSB7CiAgICBpZiAoIk9mZnNjcmVlbkNhbnZhcyIgaW4gZ2xvYmFsVGhpcykgewogICAgICBjb25zdCB7IGlkLCBiaXRtYXAsIHdpZHRoLCBoZWlnaHQsIGRhdGFVUkxPcHRpb25zIH0gPSBlLmRhdGE7CiAgICAgIGNvbnN0IHRyYW5zcGFyZW50QmFzZTY0ID0gZ2V0VHJhbnNwYXJlbnRCbG9iRm9yKAogICAgICAgIHdpZHRoLAogICAgICAgIGhlaWdodCwKICAgICAgICBkYXRhVVJMT3B0aW9ucwogICAgICApOwogICAgICBjb25zdCBvZmZzY3JlZW4gPSBuZXcgT2Zmc2NyZWVuQ2FudmFzKHdpZHRoLCBoZWlnaHQpOwogICAgICBjb25zdCBjdHggPSBvZmZzY3JlZW4uZ2V0Q29udGV4dCgiMmQiKTsKICAgICAgY3R4LmRyYXdJbWFnZShiaXRtYXAsIDAsIDApOwogICAgICBiaXRtYXAuY2xvc2UoKTsKICAgICAgY29uc3QgYmxvYiA9IGF3YWl0IG9mZnNjcmVlbi5jb252ZXJ0VG9CbG9iKGRhdGFVUkxPcHRpb25zKTsKICAgICAgY29uc3QgdHlwZSA9IGJsb2IudHlwZTsKICAgICAgY29uc3QgYXJyYXlCdWZmZXIgPSBhd2FpdCBibG9iLmFycmF5QnVmZmVyKCk7CiAgICAgIGNvbnN0IGJhc2U2NCA9IGVuY29kZShhcnJheUJ1ZmZlcik7CiAgICAgIGlmICghbGFzdEJsb2JNYXAuaGFzKGlkKSAmJiBhd2FpdCB0cmFuc3BhcmVudEJhc2U2NCA9PT0gYmFzZTY0KSB7CiAgICAgICAgbGFzdEJsb2JNYXAuc2V0KGlkLCBiYXNlNjQpOwogICAgICAgIHJldHVybiB3b3JrZXIucG9zdE1lc3NhZ2UoeyBpZCB9KTsKICAgICAgfQogICAgICBpZiAobGFzdEJsb2JNYXAuZ2V0KGlkKSA9PT0gYmFzZTY0KSByZXR1cm4gd29ya2VyLnBvc3RNZXNzYWdlKHsgaWQgfSk7CiAgICAgIHdvcmtlci5wb3N0TWVzc2FnZSh7CiAgICAgICAgaWQsCiAgICAgICAgdHlwZSwKICAgICAgICBiYXNlNjQsCiAgICAgICAgd2lkdGgsCiAgICAgICAgaGVpZ2h0CiAgICAgIH0pOwogICAgICBsYXN0QmxvYk1hcC5zZXQoaWQsIGJhc2U2NCk7CiAgICB9IGVsc2UgewogICAgICByZXR1cm4gd29ya2VyLnBvc3RNZXNzYWdlKHsgaWQ6IGUuZGF0YS5pZCB9KTsKICAgIH0KICB9Owp9KSgpOwovLyMgc291cmNlTWFwcGluZ1VSTD1pbWFnZS1iaXRtYXAtZGF0YS11cmwtd29ya2VyLUlKcEM3Z19iLmpzLm1hcAo=",Bf=i=>Uint8Array.from(atob(i),e=>e.charCodeAt(0)),wn=typeof window<"u"&&window.Blob&&new Blob([Bf(pa)],{type:"text/javascript;charset=utf-8"});function Wf(i){let e;try{if(e=wn&&(window.URL||window.webkitURL).createObjectURL(wn),!e)throw"";let t=new Worker(e,{name:i?.name});return t.addEventListener("error",()=>{(window.URL||window.webkitURL).revokeObjectURL(e)}),t}catch{return new Worker("data:text/javascript;base64,"+pa,{name:i?.name})}finally{e&&(window.URL||window.webkitURL).revokeObjectURL(e)}}var Li=class{constructor(e){v(this,"pendingCanvasMutations",new Map),v(this,"rafStamps",{latestId:0,invokeId:null}),v(this,"mirror"),v(this,"mutationCb"),v(this,"resetObservers"),v(this,"frozen",!1),v(this,"locked",!1),v(this,"processMutation",(a,u)=>{(this.rafStamps.invokeId&&this.rafStamps.latestId!==this.rafStamps.invokeId||!this.rafStamps.invokeId)&&(this.rafStamps.invokeId=this.rafStamps.latestId),this.pendingCanvasMutations.has(a)||this.pendingCanvasMutations.set(a,[]),this.pendingCanvasMutations.get(a).push(u)});let{sampling:t="all",win:r,blockClass:s,blockSelector:n,recordCanvas:o,dataURLOptions:l}=e;this.mutationCb=e.mutationCb,this.mirror=e.mirror,o&&t==="all"&&this.initCanvasMutationObserver(r,s,n),o&&typeof t=="number"&&this.initCanvasFPSObserver(t,r,s,n,{dataURLOptions:l})}reset(){this.pendingCanvasMutations.clear(),this.resetObservers&&this.resetObservers()}freeze(){this.frozen=!0}unfreeze(){this.frozen=!1}lock(){this.locked=!0}unlock(){this.locked=!1}initCanvasFPSObserver(e,t,r,s,n){let o=yn(t,r,s,!0),l=new Map,a=new Wf;a.onmessage=g=>{let{id:p}=g.data;if(l.set(p,!1),!("base64"in g.data))return;let{base64:f,type:S,width:w,height:y}=g.data;this.mutationCb({id:p,type:Ke["2D"],commands:[{property:"clearRect",args:[0,0,w,y]},{property:"drawImage",args:[{rr_type:"ImageBitmap",args:[{rr_type:"Blob",data:[{rr_type:"ArrayBuffer",base64:f}],type:S}]},0,0]}]})};let u=1e3/e,c=0,h,d=()=>{let g=[];return t.document.querySelectorAll("canvas").forEach(p=>{se(p,r,s,!0)||g.push(p)}),g},m=g=>{if(c&&g-c<u){h=requestAnimationFrame(m);return}c=g,d().forEach(async p=>{var f;let S=this.mirror.getId(p);if(l.get(S)||p.width===0||p.height===0)return;if(l.set(S,!0),["webgl","webgl2"].includes(p.__context)){let y=p.getContext(p.__context);((f=y?.getContextAttributes())==null?void 0:f.preserveDrawingBuffer)===!1&&y.clear(y.COLOR_BUFFER_BIT)}let w=await createImageBitmap(p);a.postMessage({id:S,bitmap:w,width:p.width,height:p.height,dataURLOptions:n.dataURLOptions},[w])}),h=requestAnimationFrame(m)};h=requestAnimationFrame(m),this.resetObservers=()=>{o(),cancelAnimationFrame(h)}}initCanvasMutationObserver(e,t,r){this.startRAFTimestamping(),this.startPendingCanvasMutationFlusher();let s=yn(e,t,r,!1),n=Ff(this.processMutation.bind(this),e,t,r),o=zf(this.processMutation.bind(this),e,t,r);this.resetObservers=()=>{s(),n(),o()}}startPendingCanvasMutationFlusher(){requestAnimationFrame(()=>this.flushPendingCanvasMutations())}startRAFTimestamping(){let e=t=>{this.rafStamps.latestId=t,requestAnimationFrame(e)};requestAnimationFrame(e)}flushPendingCanvasMutations(){this.pendingCanvasMutations.forEach((e,t)=>{let r=this.mirror.getId(t);this.flushPendingCanvasMutationFor(t,r)}),requestAnimationFrame(()=>this.flushPendingCanvasMutations())}flushPendingCanvasMutationFor(e,t){if(this.frozen||this.locked)return;let r=this.pendingCanvasMutations.get(e);if(!r||t===-1)return;let s=r.map(o=>{let{type:l,...a}=o;return a}),{type:n}=r[0];this.mutationCb({id:t,type:n,commands:s}),this.pendingCanvasMutations.delete(e)}},Fi=class{constructor(e){v(this,"trackedLinkElements",new WeakSet),v(this,"mutationCb"),v(this,"adoptedStyleSheetCb"),v(this,"styleMirror",new Ti),this.mutationCb=e.mutationCb,this.adoptedStyleSheetCb=e.adoptedStyleSheetCb}attachLinkElement(e,t){"_cssText"in t.attributes&&this.mutationCb({adds:[],removes:[],texts:[],attributes:[{id:t.id,attributes:t.attributes}]}),this.trackLinkElement(e)}trackLinkElement(e){this.trackedLinkElements.has(e)||(this.trackedLinkElements.add(e),this.trackStylesheetInLinkElement(e))}adoptStyleSheets(e,t){if(e.length===0)return;let r={id:t,styleIds:[]},s=[];for(let n of e){let o;this.styleMirror.has(n)?o=this.styleMirror.getId(n):(o=this.styleMirror.add(n),s.push({styleId:o,rules:Array.from(n.rules||CSSRule,(l,a)=>({rule:xn(l,n.href),index:a}))})),r.styleIds.push(o)}s.length>0&&(r.styles=s),this.adoptedStyleSheetCb(r)}reset(){this.styleMirror.reset(),this.trackedLinkElements=new WeakSet}trackStylesheetInLinkElement(e){}},Ui=class{constructor(){v(this,"nodeMap",new WeakMap),v(this,"active",!1)}inOtherBuffer(e,t){let r=this.nodeMap.get(e);return r&&Array.from(r).some(s=>s!==t)}add(e,t){this.active||(this.active=!0,requestAnimationFrame(()=>{this.nodeMap=new WeakMap,this.active=!1})),this.nodeMap.set(e,(this.nodeMap.get(e)||new Set).add(t))}destroy(){}},J,er,Jr,mr=!1;try{if(Array.from([1],i=>i*2)[0]!==2){let i=document.createElement("iframe");document.body.appendChild(i),Array.from=((Cs=i.contentWindow)==null?void 0:Cs.Array.from)||Array.from,document.body.removeChild(i)}}catch(i){console.debug("Unable to override Array.from",i)}var de=Xa();function Me(i={}){let{emit:e,checkoutEveryNms:t,checkoutEveryNth:r,blockClass:s="rr-block",blockSelector:n=null,ignoreClass:o="rr-ignore",ignoreSelector:l=null,maskTextClass:a="rr-mask",maskTextSelector:u=null,inlineStylesheet:c=!0,maskAllInputs:h,maskInputOptions:d,slimDOMOptions:m,maskInputFn:g,maskTextFn:p,hooks:f,packFn:S,sampling:w={},dataURLOptions:y={},mousemoveWait:b,recordDOM:I=!0,recordCanvas:M=!1,recordCrossOriginIframes:R=!1,recordAfter:x=i.recordAfter==="DOMContentLoaded"?i.recordAfter:"load",userTriggeredOnInput:C=!1,collectFonts:k=!1,inlineImages:N=!1,plugins:O,keepIframeSrcFn:E=()=>!1,ignoreCSSAttributes:j=new Set([]),errorHandler:K}=i;Sf(K);let L=R?window.parent===window:!0,F=!1;if(!L)try{window.parent.document&&(F=!1)}catch{F=!0}if(L&&!e)throw new Error("emit function is required");if(!L&&!F)return()=>{};b!==void 0&&w.mousemove===void 0&&(w.mousemove=b),de.reset();let q=h===!0?{color:!0,date:!0,"datetime-local":!0,email:!0,month:!0,number:!0,range:!0,search:!0,tel:!0,text:!0,time:!0,url:!0,week:!0,textarea:!0,select:!0,password:!0}:d!==void 0?d:{password:!0},Q=m===!0||m==="all"?{script:!0,comment:!0,headFavicon:!0,headWhitespace:!0,headMetaSocial:!0,headMetaRobots:!0,headMetaHttpEquiv:!0,headMetaVerification:!0,headMetaAuthorship:m==="all",headMetaDescKeywords:m==="all",headTitleMutations:m==="all"}:m||{};mf();let Fe,ne=0,Ne=$=>{for(let oe of O||[])oe.eventProcessor&&($=oe.eventProcessor($));return S&&!F&&($=S($)),$};J=($,oe)=>{var W;let V=$;if(V.timestamp=fr(),(W=$e[0])!=null&&W.isFrozen()&&V.type!==_.FullSnapshot&&!(V.type===_.IncrementalSnapshot&&V.data.source===T.Mutation)&&$e.forEach(ve=>ve.unfreeze()),L)e?.(Ne(V),oe);else if(F){let ve={type:"rrweb",event:Ne(V),origin:window.location.origin,isCheckout:oe};window.parent.postMessage(ve,"*")}if(V.type===_.FullSnapshot)Fe=V,ne=0;else if(V.type===_.IncrementalSnapshot){if(V.data.source===T.Mutation&&V.data.isAttachIframe)return;ne++;let ve=r&&ne>=r,B=t&&V.timestamp-Fe.timestamp>t;(ve||B)&&er(!0)}};let he=$=>{J({type:_.IncrementalSnapshot,data:{source:T.Mutation,...$}})},le=$=>J({type:_.IncrementalSnapshot,data:{source:T.Scroll,...$}}),ee=$=>J({type:_.IncrementalSnapshot,data:{source:T.CanvasMutation,...$}}),Ae=$=>J({type:_.IncrementalSnapshot,data:{source:T.AdoptedStyleSheet,...$}}),ye=new Fi({mutationCb:he,adoptedStyleSheetCb:Ae}),fe=new _i({mirror:de,mutationCb:he,stylesheetManager:ye,recordCrossOriginIframes:R,wrappedEmit:J});for(let $ of O||[])$.getMirror&&$.getMirror({nodeMirror:de,crossOriginIframeMirror:fe.crossOriginIframeMirror,crossOriginIframeStyleMirror:fe.crossOriginIframeStyleMirror});let Qe=new Ui;Jr=new Li({recordCanvas:M,mutationCb:ee,win:window,blockClass:s,blockSelector:n,mirror:de,sampling:w.canvas,dataURLOptions:y});let De=new Pi({mutationCb:he,scrollCb:le,bypassOptions:{blockClass:s,blockSelector:n,maskTextClass:a,maskTextSelector:u,inlineStylesheet:c,maskInputOptions:q,dataURLOptions:y,maskTextFn:p,maskInputFn:g,recordCanvas:M,inlineImages:N,sampling:w,slimDOMOptions:Q,iframeManager:fe,stylesheetManager:ye,canvasManager:Jr,keepIframeSrcFn:E,processedNodeManager:Qe},mirror:de});er=($=!1)=>{if(!I)return;J({type:_.Meta,data:{href:window.location.href,width:qo(),height:Ko()}},$),ye.reset(),De.init(),$e.forEach(W=>W.lock());let oe=wl(document,{mirror:de,blockClass:s,blockSelector:n,maskTextClass:a,maskTextSelector:u,inlineStylesheet:c,maskAllInputs:q,maskTextFn:p,maskInputFn:g,slimDOM:Q,dataURLOptions:y,recordCanvas:M,inlineImages:N,onSerialize:W=>{ta(W,de)&&fe.addIframe(W),ra(W,de)&&ye.trackLinkElement(W),Oi(W)&&De.addShadowRoot(A.shadowRoot(W),document)},onIframeLoad:(W,V)=>{fe.attachIframe(W,V),De.observeAttachShadow(W)},onStylesheetLoad:(W,V)=>{ye.attachLinkElement(W,V)},keepIframeSrcFn:E});if(!oe)return console.warn("Failed to snapshot the document");J({type:_.FullSnapshot,data:{node:oe,initialOffset:Jo(window)}},$),$e.forEach(W=>W.unlock()),document.adoptedStyleSheets&&document.adoptedStyleSheets.length>0&&ye.adoptStyleSheets(document.adoptedStyleSheets,de.getId(document))};try{let $=[],oe=V=>{var ve;return D($f)({mutationCb:he,mousemoveCb:(B,Nr)=>J({type:_.IncrementalSnapshot,data:{source:Nr,positions:B}}),mouseInteractionCb:B=>J({type:_.IncrementalSnapshot,data:{source:T.MouseInteraction,...B}}),scrollCb:le,viewportResizeCb:B=>J({type:_.IncrementalSnapshot,data:{source:T.ViewportResize,...B}}),inputCb:B=>J({type:_.IncrementalSnapshot,data:{source:T.Input,...B}}),mediaInteractionCb:B=>J({type:_.IncrementalSnapshot,data:{source:T.MediaInteraction,...B}}),styleSheetRuleCb:B=>J({type:_.IncrementalSnapshot,data:{source:T.StyleSheetRule,...B}}),styleDeclarationCb:B=>J({type:_.IncrementalSnapshot,data:{source:T.StyleDeclaration,...B}}),canvasMutationCb:ee,fontCb:B=>J({type:_.IncrementalSnapshot,data:{source:T.Font,...B}}),selectionCb:B=>{J({type:_.IncrementalSnapshot,data:{source:T.Selection,...B}})},customElementCb:B=>{J({type:_.IncrementalSnapshot,data:{source:T.CustomElement,...B}})},blockClass:s,ignoreClass:o,ignoreSelector:l,maskTextClass:a,maskTextSelector:u,maskInputOptions:q,inlineStylesheet:c,sampling:w,recordDOM:I,recordCanvas:M,inlineImages:N,userTriggeredOnInput:C,collectFonts:k,doc:V,maskInputFn:g,maskTextFn:p,keepIframeSrcFn:E,blockSelector:n,slimDOMOptions:Q,dataURLOptions:y,mirror:de,iframeManager:fe,stylesheetManager:ye,shadowDomManager:De,processedNodeManager:Qe,canvasManager:Jr,ignoreCSSAttributes:j,plugins:((ve=O?.filter(B=>B.observer))==null?void 0:ve.map(B=>({observer:B.observer,options:B.options,callback:Nr=>J({type:_.Plugin,data:{plugin:B.name,payload:Nr}})})))||[]},f)};fe.addLoadListener(V=>{try{$.push(oe(V.contentDocument))}catch(ve){console.warn(ve)}});let W=()=>{er(),$.push(oe(document)),mr=!0};return document.readyState==="interactive"||document.readyState==="complete"?W():($.push(ie("DOMContentLoaded",()=>{J({type:_.DomContentLoaded,data:{}}),x==="DOMContentLoaded"&&W()})),$.push(ie("load",()=>{J({type:_.Load,data:{}}),x==="load"&&W()},window))),()=>{$.forEach(V=>V()),Qe.destroy(),mr=!1,bf()}}catch($){console.warn($)}}Me.addCustomEvent=(i,e)=>{if(!mr)throw new Error("please add custom event after start recording");J({type:_.Custom,data:{tag:i,payload:e}})};Me.freezePage=()=>{$e.forEach(i=>i.freeze())};Me.takeFullSnapshot=i=>{if(!mr)throw new Error("please take full snapshot after start recording");er(i)};Me.mirror=de;var Sn;(function(i){i[i.NotStarted=0]="NotStarted",i[i.Running=1]="Running",i[i.Stopped=2]="Stopped"})(Sn||(Sn={}));var Dp=5*1e3;var{addCustomEvent:kp}=Me,{freezePage:$p}=Me,{takeFullSnapshot:_p}=Me;var Vf=64*1024,Gf=5e3,jf=6e4,Hf=1e4,Yf="[data-sw-block], .rr-block",Zf="[data-sw-mask], .rr-mask",Xf="[data-sw-unmask]";function Jf(i){let e="";for(let t of i)e+=String.fromCharCode(t);return btoa(e)}function Up(i,e,t){let r=[],s=0,n=0,o=null,l=null,a=!1,u=null,c=!1,h="buffer",d=Math.random()<(i.sampleRate??.1),m=!1;function g(){let N=i.privacyMode??"strict",O=N!=="permissive",E=N==="strict";return{emit:p,sampling:{mousemove:!0,mouseInteraction:!0,scroll:150,input:"last"},maskAllInputs:O,maskAllText:E,maskTextSelector:E?void 0:Zf,unmaskTextSelector:E?Xf:void 0,blockSelector:Yf,slimDOMOptions:{script:!0,comment:!0,headFavicon:!0,headWhitespace:!0,headMetaSocial:!0,headMetaRobots:!0,headMetaHttpEquiv:!0,headMetaVerification:!0,headMetaAuthorship:!0},errorHandler:j=>{let K=j instanceof Error?j.message:String(j);K.includes("matches is not a function")||console.warn("[Vident Replay] Recording error:",K)}}}function p(N){r.push(N),s+=JSON.stringify(N).length+1,h==="upload"&&(s>=Vf?w():f())}function f(){o||h!=="upload"||(o=setTimeout(()=>{o=null,w()},Gf))}function S(N){let O=bs(new TextEncoder().encode(JSON.stringify(N)));return JSON.stringify({sessionId:e.sessionId,chunkIndex:n,data:Jf(O),isFullSnapshot:n===0,timestamp:Date.now(),hasErrors:c})}async function w(){if(r.length===0||h!=="upload")return;let N=r.splice(0);s=0;let O=new AbortController,E=setTimeout(()=>O.abort(),1e4);try{await fetch(`${e.baseUrl}/v1/ingest/replays`,{method:"POST",headers:{"Content-Type":"application/json","x-api-key":e.apiKey},body:S(N),signal:O.signal}),n++}catch(j){console.warn("[Vident Replay] Failed to send chunk:",j)}finally{clearTimeout(E)}}function y(){if(r.length===0||h!=="upload")return;let N=r.splice(0);s=0;try{fetch(`${e.baseUrl}/v1/ingest/replays`,{method:"POST",headers:{"Content-Type":"application/json","x-api-key":e.apiKey},body:S(N),keepalive:!0}).catch(()=>{}),n++}catch{}}function b(){if(h!=="buffer"||r.length===0)return;let N=Date.now()-jf,O=0;for(let E of r)if(E.timestamp<N)O++;else break;O>0&&(r.splice(0,O),s=r.reduce((E,j)=>E+JSON.stringify(j).length+1,0))}function I(){h!=="upload"&&(h="upload",l&&(clearInterval(l),l=null),r.length>0&&w())}function M(){if(a)return;a=!0,d?h="upload":(h="buffer",l=setInterval(b,Hf)),u=Me(g())??null,window.addEventListener("visibilitychange",x),window.addEventListener("pagehide",C)}function R(){a&&(a=!1,u&&(u(),u=null),o&&(clearTimeout(o),o=null),l&&(clearInterval(l),l=null),h==="upload"&&w(),window.removeEventListener("visibilitychange",x),window.removeEventListener("pagehide",C))}function x(){document.visibilityState==="hidden"&&h==="upload"&&y()}function C(){h==="upload"&&y()}function k(){if(c=!0,h==="upload")return;let N=i.onErrorSampleRate??1;Math.random()<N&&(m=!0,I(),t?.())}return i.enabled&&setTimeout(M,0),{start:M,stop:R,markError:k,isRecording:()=>a,isUploading:()=>h==="upload",wasUpgradedByError:()=>m,startUploading:I}}export{Up as createReplayRecorder};
|
|
60
54
|
/*! Bundled license information:
|
|
61
55
|
|
|
62
56
|
rrweb/dist/rrweb.js:
|
|
@@ -75,4 +69,4 @@ rrweb/dist/rrweb.js:
|
|
|
75
69
|
PERFORMANCE OF THIS SOFTWARE.
|
|
76
70
|
***************************************************************************** *)
|
|
77
71
|
*/
|
|
78
|
-
//# sourceMappingURL=replay-
|
|
72
|
+
//# sourceMappingURL=replay-B4V6GD22.js.map
|