@obsrviq/tracker 0.7.0 → 0.7.1

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,56 +1,56 @@
1
- var ObsrviqSDK=(function(exports){'use strict';var be=Uint8Array,de=Uint16Array,sr=Int32Array,or=new be([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]),ar=new be([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]),ii=new be([16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15]),li=function(e,t){for(var r=new de(31),i=0;i<31;++i)r[i]=t+=1<<e[i-1];for(var n=new sr(r[30]),i=1;i<30;++i)for(var o=r[i];o<r[i+1];++o)n[o]=o-r[i]<<5|i;return {b:r,r:n}},ui=li(or,2),Ea=ui.b,tr=ui.r;Ea[28]=258,tr[258]=28;var ci=li(ar,0),si=ci.r,rr=new de(32768);for(W=0;W<32768;++W)Me=(W&43690)>>1|(W&21845)<<1,Me=(Me&52428)>>2|(Me&13107)<<2,Me=(Me&61680)>>4|(Me&3855)<<4,rr[W]=((Me&65280)>>8|(Me&255)<<8)>>1;var Me,W,Ke=(function(e,t,r){for(var i=e.length,n=0,o=new de(t);n<i;++n)e[n]&&++o[e[n]-1];var l=new de(t);for(n=1;n<t;++n)l[n]=l[n-1]+o[n-1]<<1;var p;for(p=new de(i),n=0;n<i;++n)e[n]&&(p[n]=rr[l[e[n]-1]++]>>15-e[n]);return p}),De=new be(288);for(W=0;W<144;++W)De[W]=8;var W;for(W=144;W<256;++W)De[W]=9;var W;for(W=256;W<280;++W)De[W]=7;var W;for(W=280;W<288;++W)De[W]=8;var W,dt=new be(32);for(W=0;W<32;++W)dt[W]=5;var W,xa=Ke(De,9);var Ra=Ke(dt,5);var fi=function(e){return (e+7)/8|0},Ma=function(e,t,r){return (r==null||r>e.length)&&(r=e.length),new be(e.subarray(t,r))};var Ie=function(e,t,r){r<<=t&7;var i=t/8|0;e[i]|=r,e[i+1]|=r>>8;},Xe=function(e,t,r){r<<=t&7;var i=t/8|0;e[i]|=r,e[i+1]|=r>>8,e[i+2]|=r>>16;},er=function(e,t){for(var r=[],i=0;i<e.length;++i)e[i]&&r.push({s:i,f:e[i]});var n=r.length,o=r.slice();if(!n)return {t:di,l:0};if(n==1){var l=new be(r[0].s+1);return l[r[0].s]=1,{t:l,l:1}}r.sort(function(w,v){return w.f-v.f}),r.push({s:-1,f:25001});var p=r[0],a=r[1],h=0,s=1,f=2;for(r[0]={s:-1,f:p.f+a.f,l:p,r:a};s!=n-1;)p=r[r[h].f<r[f].f?h++:f++],a=r[h!=s&&r[h].f<r[f].f?h++:f++],r[s++]={s:-1,f:p.f+a.f,l:p,r:a};for(var c=o[0].s,i=1;i<n;++i)o[i].s>c&&(c=o[i].s);var u=new de(c+1),m=nr(r[s-1],u,0);if(m>t){var i=0,d=0,g=m-t,S=1<<g;for(o.sort(function(v,C){return u[C.s]-u[v.s]||v.f-C.f});i<n;++i){var y=o[i].s;if(u[y]>t)d+=S-(1<<m-u[y]),u[y]=t;else break}for(d>>=g;d>0;){var b=o[i].s;u[b]<t?d-=1<<t-u[b]++-1:++i;}for(;i>=0&&d;--i){var E=o[i].s;u[E]==t&&(--u[E],++d);}m=t;}return {t:new be(u),l:m}},nr=function(e,t,r){return e.s==-1?Math.max(nr(e.l,t,r+1),nr(e.r,t,r+1)):t[e.s]=r},oi=function(e){for(var t=e.length;t&&!e[--t];);for(var r=new de(++t),i=0,n=e[0],o=1,l=function(a){r[i++]=a;},p=1;p<=t;++p)if(e[p]==n&&p!=t)++o;else {if(!n&&o>2){for(;o>138;o-=138)l(32754);o>2&&(l(o>10?o-11<<5|28690:o-3<<5|12305),o=0);}else if(o>3){for(l(n),--o;o>6;o-=6)l(8304);o>2&&(l(o-3<<5|8208),o=0);}for(;o--;)l(n);o=1,n=e[p];}return {c:r.subarray(0,i),n:t}},Je=function(e,t){for(var r=0,i=0;i<t.length;++i)r+=e[i]*t[i];return r},hi=function(e,t,r){var i=r.length,n=fi(t+2);e[n]=i&255,e[n+1]=i>>8,e[n+2]=e[n]^255,e[n+3]=e[n+1]^255;for(var o=0;o<i;++o)e[n+o+4]=r[o];return (n+4+i)*8},ai=function(e,t,r,i,n,o,l,p,a,h,s){Ie(t,s++,r),++n[256];for(var f=er(n,15),c=f.t,u=f.l,m=er(o,15),d=m.t,g=m.l,S=oi(c),y=S.c,b=S.n,E=oi(d),w=E.c,v=E.n,C=new de(19),R=0;R<y.length;++R)++C[y[R]&31];for(var R=0;R<w.length;++R)++C[w[R]&31];for(var I=er(C,7),M=I.t,O=I.l,k=19;k>4&&!M[ii[k-1]];--k);var x=h+5<<3,Q=Je(n,De)+Je(o,dt)+l,Y=Je(n,c)+Je(o,d)+l+14+3*k+Je(C,M)+2*C[16]+3*C[17]+7*C[18];if(a>=0&&x<=Q&&x<=Y)return hi(t,s,e.subarray(a,a+h));var L,A,B,X;if(Ie(t,s,1+(Y<Q)),s+=2,Y<Q){L=Ke(c,u),A=c,B=Ke(d,g),X=d;var J=Ke(M,O);Ie(t,s,b-257),Ie(t,s+5,v-1),Ie(t,s+10,k-4),s+=14;for(var R=0;R<k;++R)Ie(t,s+3*R,M[ii[R]]);s+=3*k;for(var P=[y,w],ce=0;ce<2;++ce)for(var N=P[ce],R=0;R<N.length;++R){var re=N[R]&31;Ie(t,s,J[re]),s+=M[re],re>15&&(Ie(t,s,N[R]>>5&127),s+=N[R]>>12);}}else L=xa,A=De,B=Ra,X=dt;for(var R=0;R<p;++R){var H=i[R];if(H>255){var re=H>>18&31;Xe(t,s,L[re+257]),s+=A[re+257],re>7&&(Ie(t,s,H>>23&31),s+=or[re]);var me=H&31;Xe(t,s,B[me]),s+=X[me],me>3&&(Xe(t,s,H>>5&8191),s+=ar[me]);}else Xe(t,s,L[H]),s+=A[H];}return Xe(t,s,L[256]),s+A[256]},Ia=new sr([65540,131080,131088,131104,262176,1048704,1048832,2114560,2117632]),di=new be(0),Na=function(e,t,r,i,n,o){var l=o.z||e.length,p=new be(i+l+5*(1+Math.ceil(l/7e3))+n),a=p.subarray(i,p.length-n),h=o.l,s=(o.r||0)&7;if(t){s&&(a[0]=o.r>>3);for(var f=Ia[t-1],c=f>>13,u=f&8191,m=(1<<r)-1,d=o.p||new de(32768),g=o.h||new de(m+1),S=Math.ceil(r/3),y=2*S,b=function(V){return (e[V]^e[V+1]<<S^e[V+2]<<y)&m},E=new sr(25e3),w=new de(288),v=new de(32),C=0,R=0,I=o.i||0,M=0,O=o.w||0,k=0;I+2<l;++I){var x=b(I),Q=I&32767,Y=g[x];if(d[Q]=Y,g[x]=Q,O<=I){var L=l-I;if((C>7e3||M>24576)&&(L>423||!h)){s=ai(e,a,0,E,w,v,R,M,k,I-k,s),M=C=R=0,k=I;for(var A=0;A<286;++A)w[A]=0;for(var A=0;A<30;++A)v[A]=0;}var B=2,X=0,J=u,P=Q-Y&32767;if(L>2&&x==b(I-P))for(var ce=Math.min(c,L)-1,N=Math.min(32767,I),re=Math.min(258,L);P<=N&&--J&&Q!=Y;){if(e[I+B]==e[I+B-P]){for(var H=0;H<re&&e[I+H]==e[I+H-P];++H);if(H>B){if(B=H,X=P,H>ce)break;for(var me=Math.min(P,H-2),ie=0,A=0;A<me;++A){var oe=I-P+A&32767,Re=d[oe],we=oe-Re&32767;we>ie&&(ie=we,Y=oe);}}}Q=Y,Y=d[Q],P+=Q-Y&32767;}if(X){E[M++]=268435456|tr[B]<<18|si[X];var D=tr[B]&31,ee=si[X]&31;R+=or[D]+ar[ee],++w[257+D],++v[ee],O=I+B,++C;}else E[M++]=e[I],++w[e[I]];}}for(I=Math.max(I,O);I<l;++I)E[M++]=e[I],++w[e[I]];s=ai(e,a,h,E,w,v,R,M,k,I-k,s),h||(o.r=s&7|a[s/8|0]<<3,s-=7,o.h=g,o.p=d,o.i=I,o.w=O);}else {for(var I=o.w||0;I<l+h;I+=65535){var z=I+65535;z>=l&&(a[s/8|0]=h,z=l),s=hi(a,s+1,e.subarray(I,z));}o.i=l;}return Ma(p,0,i+fi(s)+n)},Ta=(function(){for(var e=new Int32Array(256),t=0;t<256;++t){for(var r=t,i=9;--i;)r=(r&1&&-306674912)^r>>>1;e[t]=r;}return e})(),ka=function(){var e=-1;return {p:function(t){for(var r=e,i=0;i<t.length;++i)r=Ta[r&255^t[i]]^r>>>8;e=r;},d:function(){return ~e}}};var Aa=function(e,t,r,i,n){if(!n&&(n={l:1},t.dictionary)){var o=t.dictionary.subarray(-32768),l=new be(o.length+e.length);l.set(o),l.set(e,o.length),e=l,n.w=o.length;}return Na(e,t.level==null?6:t.level,t.mem==null?n.l?Math.ceil(Math.max(8,Math.min(13,Math.log(e.length)))*1.5):20:12+t.mem,r,i,n)};var ir=function(e,t,r){for(;r;++t)e[t]=r,r>>>=8;},Oa=function(e,t){var r=t.filename;if(e[0]=31,e[1]=139,e[2]=8,e[8]=t.level<2?4:t.level==9?2:0,e[9]=3,t.mtime!=0&&ir(e,4,Math.floor(new Date(t.mtime||Date.now())/1e3)),r){e[3]=8;for(var i=0;i<=r.length;++i)e[i+10]=r.charCodeAt(i);}};var Da=function(e){return 10+(e.filename?e.filename.length+1:0)};function lr(e,t){t||(t={});var r=ka(),i=e.length;r.p(e);var n=Aa(e,t,Da(t),8),o=n.length;return Oa(n,t),ir(n,o-8,r.d()),ir(n,o-4,i),n}var La=typeof TextDecoder<"u"&&new TextDecoder,Pa=0;try{La.decode(di,{stream:!0}),Pa=1;}catch{}var _a=/[a-z0-9._%+-]+@[a-z0-9.-]+\.[a-z]{2,}/gi,Fa=/\b(?:\d[ -]*?){13,19}\b/g,Ua=/\b\d{3}-\d{2}-\d{4}\b/g,Ba=/\b\d{9,}\b/g,qa=/(password|passwd|passphrase|secret|token|authoriz|apikey|api[_-]key|creditcard|cardnumber|cardholder|cookie|cvv|cvc)/i,za=new Set(["pass","pwd","auth","card","pin","otp","ssn","cvv","cvc"]);function $a(e){return e.replace(/([a-z0-9])([A-Z])/g,"$1 $2").replace(/([A-Z]+)([A-Z][a-z])/g,"$1 $2").split(/[^A-Za-z0-9]+/).filter(Boolean).map(t=>t.toLowerCase())}function ge(e){return e.replace(_a,"\xABemail\xBB").replace(Fa,t=>Wa(t)?"\xABcard\xBB":t).replace(Ua,"\xABssn\xBB").replace(Ba,"\xABnumber\xBB")}function Wa(e){let t=e.replace(/\D/g,"");return t.length>=13&&t.length<=19}var pi=new Set;function ur(e){pi=new Set(e.map(t=>String(t).trim().toLowerCase()).filter(Boolean));}var mi=false;function cr(){mi=true;}function gi(){return !mi}function Ha(e){return pi.has(e.toLowerCase())}function Ze(e){return Ha(e)||qa.test(e)?true:$a(e).some(t=>za.has(t))}function mt(e,t=0){if(t>24||e===null||typeof e!="object")return e;if(Array.isArray(e))return e.map(i=>mt(i,t+1));let r={};for(let[i,n]of Object.entries(e))r[i]=Ze(i)?"\xABredacted\xBB":mt(n,t+1);return r}function ja(e){let t=e.replace(/"([A-Za-z0-9_.\-]+)"\s*:\s*("(?:[^"\\]|\\.)*"|[^,}\]\s]+)/g,(r,i)=>Ze(i)?'"'+i+'": "\xABredacted\xBB"':r);return t=t.replace(/(^|[?&])([A-Za-z0-9_.\-[\]]+)=([^&\s]*)/g,(r,i,n)=>Ze(n)?i+n+"=\xABredacted\xBB":r),t}function pt(e){if(!e)return e;let t=e.trim();if(t[0]==="{"||t[0]==="[")try{return JSON.stringify(mt(JSON.parse(t)))}catch{}return ja(e)}function fr(e){for(let t of e)if(t.type==="network"||t.type==="ws"){let r=t;r.requestBody?.preview&&(r.requestBody.preview=pt(r.requestBody.preview)),r.responseBody?.preview&&(r.responseBody.preview=pt(r.responseBody.preview)),r.body?.preview&&(r.body.preview=pt(r.body.preview));}else if(t.type==="custom"){let r=t;r.props&&(r.props=mt(r.props));}else if(t.type==="console"){let r=t.args;if(r)for(let i of r)i.kind==="object"&&i.json&&(i.json=pt(i.json));}}var ze=5e3,Va=4*1024*1024,yi=56*1024,Qe="obsrviq.spill",Ga=15e5,Ya=1440*60*1e3,Xa=2,Ja=4,gt=class{constructor(t){this.opts=t;this.buffer=[];this.seqFloor=0;this.sending=false;this.retryDelay=1e3;this.stopped=false;this.onVisibility=()=>{document.visibilityState==="hidden"&&this.flush("hidden");};this.onPageHide=()=>{this.flush("pagehide");};this.seq=t.startSeq??0;}start(){this.timer=setInterval(()=>{this.flush("timer");},this.opts.flushIntervalMs),document.addEventListener("visibilitychange",this.onVisibility,{capture:true}),window.addEventListener("pagehide",this.onPageHide,{capture:true}),this.resendSpill();}enqueue(t){this.stopped||(this.buffer.push(t),this.buffer.length>=ze&&(this.flush("backpressure"),this.buffer.length>=ze&&this.shedDomBacklog()));}shedDomBacklog(){let t=-1;for(let r=this.buffer.length-1;r>=0;r--){let i=this.buffer[r];if(i?.type==="dom"&&i.data?.type===Xa){t=r;break}}if(t>0){let r=t,i=this.buffer[t-1];i?.type==="dom"&&i.data?.type===Ja&&(r=t-1);let n=this.buffer.filter((o,l)=>o.type!=="dom"||l>=r);if(n.length<this.buffer.length&&(this.buffer=n,this.buffer.length<ze))return}this.buffer=this.buffer.filter(r=>r.type!=="dom"),this.buffer.length>=ze&&(this.buffer=this.buffer.slice(-Math.floor(ze/2))),this.opts.onDomDrop?.();}async flush(t){if(t==="pagehide"||t==="hidden")return this.flushUnload();if(this.sending||this.buffer.length===0)return true;if(gi()&&!this.stopped)return setTimeout(()=>{this.flush("timer");},200),true;this.sending=true;let r=this.buffer;this.buffer=[],fr(r);let i;try{i=await this.sendEvents(r);}finally{this.sending=false;}return i&&this.stopped&&this.buffer.length>0&&this.flush("manual"),i}async sendEvents(t){let r=[t];for(;r.length>0;){let i=r[0],n=await this.dispatch(i);if(n==="ok"){r.shift();continue}if(n==="too_large"&&i.length>1){let o=Math.ceil(i.length/2);r.splice(0,1,i.slice(0,o),i.slice(o));continue}if(n==="fatal"||n==="too_large"){r.shift();continue}if(this.buffer=[].concat(...r,this.buffer),this.buffer.length>=ze&&this.shedDomBacklog(),!this.stopped){let o=this.retryDelay*(.5+Math.random());this.retryDelay=Math.min(this.retryDelay*2,3e4),setTimeout(()=>{this.flush("timer");},o);}return false}return this.retryDelay=1e3,true}async dispatch(t){this.seqFloor>this.seq&&(this.seq=this.seqFloor);let r={siteKey:this.opts.siteKey,sessionId:this.opts.sessionId,seq:this.seq,meta:this.opts.getMeta(),events:t};if(this.opts.beforeSend)try{r=this.opts.beforeSend(r);}catch{r=null;}if(!r)return "ok";let i=JSON.stringify(r);if(i.length>Va&&t.length>1)return "too_large";this.opts.onSeqDispatch?.(this.seq+1);let n=await Ka(new TextEncoder().encode(i)),o=await this.send(n);return this.opts.onFlush?.({bytes:n.byteLength,events:t.length,ok:o==="ok"}),o==="ok"&&(this.seq=Math.max(this.seq+1,this.seqFloor)),o}async send(t){let r=`${this.opts.endpoint.replace(/\/$/,"")}/v1/batch`,i=new AbortController,n=setTimeout(()=>i.abort(),15e3);try{let o=await fetch(r,{method:"POST",body:t,headers:{"content-type":"application/octet-stream","x-obsrviq-key":this.opts.siteKey},credentials:"omit",mode:"cors",signal:i.signal});return o.ok?"ok":o.status===413?"too_large":o.status>=400&&o.status<500&&o.status!==408&&o.status!==429?"fatal":"retry"}catch{return "retry"}finally{clearTimeout(n);}}flushUnload(){if(this.buffer.length===0)return true;let t=this.buffer;this.buffer=[],fr(t);let r=Math.max(this.sending?this.seq+1:this.seq,this.seqFloor),i=[],n=[t];for(;n.length>0;){let o=n.shift(),l={siteKey:this.opts.siteKey,sessionId:this.opts.sessionId,seq:r,meta:this.opts.getMeta(),events:o};if(this.opts.beforeSend)try{l=this.opts.beforeSend(l);}catch{l=null;}if(!l)continue;let p=lr(new TextEncoder().encode(JSON.stringify(l)));if(p.byteLength>yi&&o.length>1){let a=Math.ceil(o.length/2);n.unshift(o.slice(0,a),o.slice(a));continue}i.push({gz:p,count:o.length}),r++;}this.seqFloor=r,this.opts.onSeqDispatch?.(r);for(let{gz:o,count:l}of i){let p=o.byteLength<=yi&&this.sendUnload(o);p||this.spill(o),this.opts.onFlush?.({bytes:o.byteLength,events:l,ok:p});}return true}sendUnload(t){let r=`${this.opts.endpoint.replace(/\/$/,"")}/v1/batch`,i=new Blob([t],{type:"application/octet-stream"});if(typeof navigator.sendBeacon=="function")try{if(navigator.sendBeacon(r,i))return !0}catch{}try{return fetch(r,{method:"POST",body:t,headers:{"content-type":"application/octet-stream","x-obsrviq-key":this.opts.siteKey},keepalive:!0,credentials:"omit",mode:"cors"}).catch(()=>{}),!0}catch{return false}}spill(t){try{let r=window.localStorage.getItem(Qe),i=r?JSON.parse(r):[];i.push({k:this.opts.siteKey,b:Za(t),ts:Date.now()});let n=i.reduce((o,l)=>o+l.b.length,0);for(;i.length>0&&n>Ga;)n-=i[0].b.length,i.shift();window.localStorage.setItem(Qe,JSON.stringify(i));}catch{}}resendSpill(){let t=[];try{let r=window.localStorage.getItem(Qe);if(!r)return;let i=JSON.parse(r),n=Date.now(),o=i.filter(p=>p&&typeof p.b=="string"&&n-p.ts<Ya);t=o.filter(p=>p.k===this.opts.siteKey);let l=o.filter(p=>p.k!==this.opts.siteKey);l.length>0?window.localStorage.setItem(Qe,JSON.stringify(l)):window.localStorage.removeItem(Qe);}catch{return}t.length!==0&&(async()=>{for(let r of t)try{await this.send(vi(r.b))==="retry"&&this.spill(vi(r.b));}catch{}})();}stop(){this.stopped=true,this.timer&&clearInterval(this.timer),document.removeEventListener("visibilitychange",this.onVisibility,{capture:true}),window.removeEventListener("pagehide",this.onPageHide,{capture:true}),this.flush("manual");}};async function Ka(e){if(typeof CompressionStream<"u")try{let t=new Blob([e]).stream().pipeThrough(new CompressionStream("gzip"));return new Uint8Array(await new Response(t).arrayBuffer())}catch{}return lr(e)}function Za(e){let t="";for(let r=0;r<e.length;r+=32768)t+=String.fromCharCode(...e.subarray(r,r+32768));return btoa(t)}function vi(e){let t=atob(e),r=new Uint8Array(t.length);for(let i=0;i<t.length;i++)r[i]=t.charCodeAt(i);return r}var Qa=Object.defineProperty,el=(e,t,r)=>t in e?Qa(e,t,{enumerable:true,configurable:true,writable:true,value:r}):e[t]=r,T=(e,t,r)=>el(e,typeof t!="symbol"?t+"":t,r),wi,tl=Object.defineProperty,rl=(e,t,r)=>t in e?tl(e,t,{enumerable:true,configurable:true,writable:true,value:r}):e[t]=r,bi=(e,t,r)=>rl(e,typeof t!="symbol"?t+"":t,r),ne=(e=>(e[e.Document=0]="Document",e[e.DocumentType=1]="DocumentType",e[e.Element=2]="Element",e[e.Text=3]="Text",e[e.CDATA=4]="CDATA",e[e.Comment=5]="Comment",e))(ne||{}),Si={Node:["childNodes","parentNode","parentElement","textContent","ownerDocument"],ShadowRoot:["host","styleSheets"],Element:["shadowRoot","querySelector","querySelectorAll"],MutationObserver:[]},Ci={Node:["contains","getRootNode"],ShadowRoot:["getSelection"],Element:[],MutationObserver:["constructor"]},yt={},Ws={},nl=()=>!!globalThis.Zone;function On(e){if(yt[e])return yt[e];let t=globalThis[e],r=t.prototype,i=e in Si?Si[e]:void 0,n=!!(i&&i.every(p=>{var a,h;return !!((h=(a=Object.getOwnPropertyDescriptor(r,p))==null?void 0:a.get)!=null&&h.toString().includes("[native code]"))})),o=e in Ci?Ci[e]:void 0,l=!!(o&&o.every(p=>{var a;return typeof r[p]=="function"&&((a=r[p])==null?void 0:a.toString().includes("[native code]"))}));if(n&&l&&!nl())return yt[e]=t.prototype,t.prototype;try{let p=document.createElement("iframe");p.style.display="none",document.body.appendChild(p);let a=p.contentWindow;if(!a)return t.prototype;let h=a[e].prototype;if(!h)return p.remove(),r;let s=navigator.userAgent;return s.includes("Safari")&&!s.includes("Chrome")?(p.classList.add("rr-block"),p.setAttribute("__rrwebUntaintedMutationObserver",""),Ws[e]=()=>p.remove()):p.remove(),yt[e]=h}catch{return r}}var hr={};function Te(e,t,r){var i;let n=`${e}.${String(r)}`;if(hr[n])return hr[n].call(t);let o=On(e),l=(i=Object.getOwnPropertyDescriptor(o,r))==null?void 0:i.get;return l?(hr[n]=l,l.call(t)):t[r]}var dr={};function Hs(e,t,r){let i=`${e}.${String(r)}`;if(dr[i])return dr[i].bind(t);let o=On(e)[r];return typeof o!="function"?t[r]:(dr[i]=o,o.bind(t))}function il(e){return Te("Node",e,"ownerDocument")}function sl(e){return Te("Node",e,"childNodes")}function ol(e){return Te("Node",e,"parentNode")}function al(e){return Te("Node",e,"parentElement")}function ll(e){return Te("Node",e,"textContent")}function ul(e,t){return Hs("Node",e,"contains")(t)}function cl(e){return Hs("Node",e,"getRootNode")()}function fl(e){return !e||!("host"in e)?null:Te("ShadowRoot",e,"host")}function hl(e){return e.styleSheets}function dl(e){return !e||!("shadowRoot"in e)?null:Te("Element",e,"shadowRoot")}function pl(e,t){return Te("Element",e,"querySelector")(t)}function ml(e,t){return Te("Element",e,"querySelectorAll")(t)}function gl(){return [On("MutationObserver").constructor,Ws.MutationObserver??(()=>{})]}var js=Date.now;/[1-9][0-9]{12}/.test(Date.now().toString())||(js=()=>new Date().getTime());function yl(e,t,r){try{if(!(t in e))return ()=>{};let i=e[t],n=r(i);return typeof n=="function"&&(n.prototype=n.prototype||{},Object.defineProperties(n,{__rrweb_original__:{enumerable:!1,value:i}})),e[t]=n,()=>{e[t]=i;}}catch{return ()=>{}}}var se={ownerDocument:il,childNodes:sl,parentNode:ol,parentElement:al,textContent:ll,contains:ul,getRootNode:cl,host:fl,styleSheets:hl,shadowRoot:dl,querySelector:pl,querySelectorAll:ml,nowTimestamp:js,mutationObserverCtor:gl,patch:yl};function Vs(e){return e.nodeType===e.ELEMENT_NODE}function tt(e){let t=e&&"host"in e&&"mode"in e&&se.host(e)||null;return !!(t&&"shadowRoot"in t&&se.shadowRoot(t)===e)}function rt(e){return Object.prototype.toString.call(e)==="[object ShadowRoot]"}function vl(e){return e.includes(" background-clip: text;")&&!e.includes(" -webkit-background-clip: text;")&&(e=e.replace(/\sbackground-clip:\s*text;/g," -webkit-background-clip: text; background-clip: text;")),e}function wl(e){let{cssText:t}=e;if(t.split('"').length<3)return t;let r=["@import",`url(${JSON.stringify(e.href)})`];return e.layerName===""?r.push("layer"):e.layerName&&r.push(`layer(${e.layerName})`),e.supportsText&&r.push(`supports(${e.supportsText})`),e.media.length&&r.push(e.media.mediaText),r.join(" ")+";"}function wn(e){try{let t=e.rules||e.cssRules;if(!t)return null;let r=e.href;!r&&e.ownerNode&&(r=e.ownerNode.baseURI);let i=Array.from(t,n=>Gs(n,r)).join("");return vl(i)}catch{return null}}function Gs(e,t){if(Sl(e)){let r;try{r=wn(e.styleSheet)||wl(e);}catch{r=e.cssText;}return e.styleSheet.href?At(r,e.styleSheet.href):r}else {let r=e.cssText;return Cl(e)&&e.selectorText.includes(":")&&(r=bl(r)),t?At(r,t):r}}function bl(e){let t=/(\[(?:[\w-]+)[^\\])(:(?:[\w-]+)\])/gm;return e.replace(t,"$1\\$2")}function Sl(e){return "styleSheet"in e}function Cl(e){return "selectorText"in e}var Nt=class{constructor(){bi(this,"idNodeMap",new Map),bi(this,"nodeMetaMap",new WeakMap);}getId(t){var r;return t?((r=this.getMeta(t))==null?void 0:r.id)??-1:-1}getNode(t){return this.idNodeMap.get(t)||null}getIds(){return Array.from(this.idNodeMap.keys())}getMeta(t){return this.nodeMetaMap.get(t)||null}removeNodeFromMap(t){let r=this.getId(t);this.idNodeMap.delete(r),t.childNodes&&t.childNodes.forEach(i=>this.removeNodeFromMap(i));}has(t){return this.idNodeMap.has(t)}hasNode(t){return this.nodeMetaMap.has(t)}add(t,r){let i=r.id;this.idNodeMap.set(i,t),this.nodeMetaMap.set(t,r);}replace(t,r){let i=this.getNode(t);if(i){let n=this.nodeMetaMap.get(i);n&&this.nodeMetaMap.set(r,n);}this.idNodeMap.set(t,r);}reset(){this.idNodeMap=new Map,this.nodeMetaMap=new WeakMap;}};function El(){return new Nt}function Tt({element:e,maskInputOptions:t,tagName:r,type:i,value:n,maskInputFn:o}){let l=n||"",p=i&&Pe(i);return (t[r.toLowerCase()]||p&&t[p])&&(o?l=o(l,e):l="*".repeat(l.length)),l}function Pe(e){return e.toLowerCase()}var Ei="__rrweb_original__";function xl(e){let t=e.getContext("2d");if(!t)return true;let r=50;for(let i=0;i<e.width;i+=r)for(let n=0;n<e.height;n+=r){let o=t.getImageData,l=Ei in o?o[Ei]:o;if(new Uint32Array(l.call(t,i,n,Math.min(r,e.width-i),Math.min(r,e.height-n)).data.buffer).some(a=>a!==0))return false}return true}function kt(e){let t=e.type;return e.hasAttribute("data-rr-is-password")?"password":t?Pe(t):null}function Ys(e,t){let r;try{r=new URL(e,t??window.location.href);}catch{return null}let i=/\.([0-9a-z]+)(?:$)/i,n=r.pathname.match(i);return n?.[1]??null}function Rl(e){let t="";return e.indexOf("//")>-1?t=e.split("/").slice(0,3).join("/"):t=e.split("/")[0],t=t.split("?")[0],t}var Ml=/url\((?:(')([^']*)'|(")(.*?)"|([^)]*))\)/gm,Il=/^(?:[a-z+]+:)?\/\//i,Nl=/^www\..*/i,Tl=/^(data:)([^,]*),(.*)/i;function At(e,t){return (e||"").replace(Ml,(r,i,n,o,l,p)=>{let a=n||l||p,h=i||o||"";if(!a)return r;if(Il.test(a)||Nl.test(a))return `url(${h}${a}${h})`;if(Tl.test(a))return `url(${h}${a}${h})`;if(a[0]==="/")return `url(${h}${Rl(t)+a}${h})`;let s=t.split("/"),f=a.split("/");s.pop();for(let c of f)c!=="."&&(c===".."?s.pop():s.push(c));return `url(${h}${s.join("/")}${h})`})}function vt(e,t=false){return t?e.replace(/(\/\*[^*]*\*\/)|[\s;]/g,""):e.replace(/(\/\*[^*]*\*\/)|[\s;]/g,"").replace(/0px/g,"0")}function kl(e,t,r=false){let i=Array.from(t.childNodes),n=[],o=0;if(i.length>1&&e&&typeof e=="string"){let l=vt(e,r),p=l.length/e.length;for(let a=1;a<i.length;a++)if(i[a].textContent&&typeof i[a].textContent=="string"){let h=vt(i[a].textContent,r),s=100,f=3;for(;f<h.length&&(h[f].match(/[a-zA-Z0-9]/)||h.indexOf(h.substring(0,f),1)!==-1);f++);for(;f<h.length;f++){let c=h.substring(0,f),u=l.split(c),m=-1;if(u.length===2)m=u[0].length;else if(u.length>2&&u[0]===""&&i[a-1].textContent!=="")m=l.indexOf(c,1);else if(u.length===1){if(c=c.substring(0,c.length-1),u=l.split(c),u.length<=1)return n.push(e),n;f=s+1;}else f===h.length-1&&(m=l.indexOf(c));if(u.length>=2&&f>s){let d=i[a-1].textContent;if(d&&typeof d=="string"){let g=vt(d).length;m=l.indexOf(c,g);}m===-1&&(m=u[0].length);}if(m!==-1){let d=Math.floor(m/p);for(;d>0&&d<e.length;){if(o+=1,o>50*i.length)return n.push(e),n;let g=vt(e.substring(0,d),r);if(g.length===m){n.push(e.substring(0,d)),e=e.substring(d),l=l.substring(m);break}else g.length<m?d+=Math.max(1,Math.floor((m-g.length)/p)):d-=Math.max(1,Math.floor((g.length-m)*p));}break}}}}return n.push(e),n}function Al(e,t){return kl(e,t).join("/* rr_split */")}var Ol=1,Dl=new RegExp("[^a-z0-9-_:]"),it=-2;function Xs(){return Ol++}function Ll(e){if(e instanceof HTMLFormElement)return "form";let t=Pe(e.tagName);return Dl.test(t)?"div":t}var $e,xi,Pl=/^[^ \t\n\r\u000c]+/,_l=/^[, \t\n\r\u000c]+/;function Fl(e,t){if(t.trim()==="")return t;let r=0;function i(o){let l,p=o.exec(t.substring(r));return p?(l=p[0],r+=l.length,l):""}let n=[];for(;i(_l),!(r>=t.length);){let o=i(Pl);if(o.slice(-1)===",")o=je(e,o.substring(0,o.length-1)),n.push(o);else {let l="";o=je(e,o);let p=false;for(;;){let a=t.charAt(r);if(a===""){n.push((o+l).trim());break}else if(p)a===")"&&(p=false);else if(a===","){r+=1,n.push((o+l).trim());break}else a==="("&&(p=true);l+=a,r+=1;}}}return n.join(", ")}var Ri=new WeakMap;function je(e,t){return !t||t.trim()===""?t:Dn(e,t)}function Ul(e){return !!(e.tagName==="svg"||e.ownerSVGElement)}function Dn(e,t){let r=Ri.get(e);if(r||(r=e.createElement("a"),Ri.set(e,r)),!t)t="";else if(t.startsWith("blob:")||t.startsWith("data:"))return t;return r.setAttribute("href",t),r.href}function Js(e,t,r,i){return i&&(r==="src"||r==="href"&&!(t==="use"&&i[0]==="#")||r==="xlink:href"&&i[0]!=="#"||r==="background"&&["table","td","th"].includes(t)?je(e,i):r==="srcset"?Fl(e,i):r==="style"?At(i,Dn(e)):t==="object"&&r==="data"?je(e,i):i)}function Ks(e,t,r){return ["video","audio"].includes(e)&&t==="autoplay"}function Bl(e,t,r){try{if(typeof t=="string"){if(e.classList.contains(t))return !0}else for(let i=e.classList.length;i--;){let n=e.classList[i];if(t.test(n))return !0}if(r)return e.matches(r)}catch{}return false}function Ot(e,t,r){if(!e)return false;if(e.nodeType!==e.ELEMENT_NODE)return r?Ot(se.parentNode(e),t,r):false;for(let i=e.classList.length;i--;){let n=e.classList[i];if(t.test(n))return true}return r?Ot(se.parentNode(e),t,r):false}function Zs(e,t,r,i){let n;if(Vs(e)){if(n=e,!se.childNodes(n).length)return false}else {if(se.parentElement(e)===null)return false;n=se.parentElement(e);}try{if(typeof t=="string"){if(i){if(n.closest(`.${t}`))return !0}else if(n.classList.contains(t))return !0}else if(Ot(n,t,i))return !0;if(r){if(i){if(n.closest(r))return !0}else if(n.matches(r))return !0}}catch{}return false}function ql(e,t,r){let i=e.contentWindow;if(!i)return;let n=false,o;try{o=i.document.readyState;}catch{return}if(o!=="complete"){let p=setTimeout(()=>{n||(t(),n=true);},r);e.addEventListener("load",()=>{clearTimeout(p),n=true,t();});return}let l="about:blank";if(i.location.href!==l||e.src===l||e.src==="")return setTimeout(t,0),e.addEventListener("load",t);e.addEventListener("load",t);}function zl(e,t,r){let i=false,n;try{n=e.sheet;}catch{return}if(n)return;let o=setTimeout(()=>{i||(t(),i=true);},r);e.addEventListener("load",()=>{clearTimeout(o),i=true,t();});}function $l(e,t){let{doc:r,mirror:i,blockClass:n,blockSelector:o,needsMask:l,inlineStylesheet:p,maskInputOptions:a={},maskTextFn:h,maskInputFn:s,dataURLOptions:f={},inlineImages:c,recordCanvas:u,keepIframeSrcFn:m,newlyAddedElement:d=false,cssCaptured:g=false}=t,S=Wl(r,i);switch(e.nodeType){case e.DOCUMENT_NODE:return e.compatMode!=="CSS1Compat"?{type:ne.Document,childNodes:[],compatMode:e.compatMode}:{type:ne.Document,childNodes:[]};case e.DOCUMENT_TYPE_NODE:return {type:ne.DocumentType,name:e.name,publicId:e.publicId,systemId:e.systemId,rootId:S};case e.ELEMENT_NODE:return jl(e,{doc:r,blockClass:n,blockSelector:o,inlineStylesheet:p,maskInputOptions:a,maskInputFn:s,dataURLOptions:f,inlineImages:c,recordCanvas:u,keepIframeSrcFn:m,newlyAddedElement:d,rootId:S});case e.TEXT_NODE:return Hl(e,{doc:r,needsMask:l,maskTextFn:h,rootId:S,cssCaptured:g});case e.CDATA_SECTION_NODE:return {type:ne.CDATA,textContent:"",rootId:S};case e.COMMENT_NODE:return {type:ne.Comment,textContent:se.textContent(e)||"",rootId:S};default:return false}}function Wl(e,t){if(!t.hasNode(e))return;let r=t.getId(e);return r===1?void 0:r}function Hl(e,t){let{needsMask:r,maskTextFn:i,rootId:n,cssCaptured:o}=t,l=se.parentNode(e),p=l&&l.tagName,a="",h=p==="STYLE"?true:void 0,s=p==="SCRIPT"?true:void 0;return s?a="SCRIPT_PLACEHOLDER":o||(a=se.textContent(e),h&&a&&(a=At(a,Dn(t.doc)))),!h&&!s&&a&&r&&(a=i?i(a,se.parentElement(e)):a.replace(/[\S]/g,"*")),{type:ne.Text,textContent:a||"",rootId:n}}function jl(e,t){let{doc:r,blockClass:i,blockSelector:n,inlineStylesheet:o,maskInputOptions:l={},maskInputFn:p,dataURLOptions:a={},inlineImages:h,recordCanvas:s,keepIframeSrcFn:f,newlyAddedElement:c=false,rootId:u}=t,m=Bl(e,i,n),d=Ll(e),g={},S=e.attributes.length;for(let b=0;b<S;b++){let E=e.attributes[b];Ks(d,E.name,E.value)||(g[E.name]=Js(r,d,Pe(E.name),E.value));}if(d==="link"&&o){let b=Array.from(r.styleSheets).find(w=>w.href===e.href),E=null;b&&(E=wn(b)),E&&(delete g.rel,delete g.href,g._cssText=E);}if(d==="style"&&e.sheet){let b=wn(e.sheet);b&&(e.childNodes.length>1&&(b=Al(b,e)),g._cssText=b);}if(["input","textarea","select"].includes(d)){let b=e.value,E=e.checked;g.type!=="radio"&&g.type!=="checkbox"&&g.type!=="submit"&&g.type!=="button"&&b?g.value=Tt({element:e,type:kt(e),tagName:d,value:b,maskInputOptions:l,maskInputFn:p}):E&&(g.checked=E);}if(d==="option"&&(e.selected&&!l.select?g.selected=true:delete g.selected),d==="dialog"&&e.open&&(g.rr_open_mode=e.matches("dialog:modal")?"modal":"non-modal"),d==="canvas"&&s){if(e.__context==="2d")xl(e)||(g.rr_dataURL=e.toDataURL(a.type,a.quality));else if(!("__context"in e)){let b=e.toDataURL(a.type,a.quality),E=r.createElement("canvas");E.width=e.width,E.height=e.height;let w=E.toDataURL(a.type,a.quality);b!==w&&(g.rr_dataURL=b);}}if(d==="img"&&h){$e||($e=r.createElement("canvas"),xi=$e.getContext("2d"));let b=e,E=b.currentSrc||b.getAttribute("src")||"<unknown-src>",w=b.crossOrigin,v=()=>{b.removeEventListener("load",v);try{$e.width=b.naturalWidth,$e.height=b.naturalHeight,xi.drawImage(b,0,0),g.rr_dataURL=$e.toDataURL(a.type,a.quality);}catch(C){if(b.crossOrigin!=="anonymous"){b.crossOrigin="anonymous",b.complete&&b.naturalWidth!==0?v():b.addEventListener("load",v);return}else console.warn(`Cannot inline img src=${E}! Error: ${C}`);}b.crossOrigin==="anonymous"&&(w?g.crossOrigin=w:b.removeAttribute("crossorigin"));};b.complete&&b.naturalWidth!==0?v():b.addEventListener("load",v);}if(["audio","video"].includes(d)){let b=g;b.rr_mediaState=e.paused?"paused":"played",b.rr_mediaCurrentTime=e.currentTime,b.rr_mediaPlaybackRate=e.playbackRate,b.rr_mediaMuted=e.muted,b.rr_mediaLoop=e.loop,b.rr_mediaVolume=e.volume;}if(c||(e.scrollLeft&&(g.rr_scrollLeft=e.scrollLeft),e.scrollTop&&(g.rr_scrollTop=e.scrollTop)),m){let{width:b,height:E}=e.getBoundingClientRect();g={class:g.class,rr_width:`${b}px`,rr_height:`${E}px`};}d==="iframe"&&!f(g.src)&&(e.contentDocument||(g.rr_src=g.src),delete g.src);let y;try{customElements.get(d)&&(y=!0);}catch{}return {type:ne.Element,tagName:d,attributes:g,childNodes:[],isSVG:Ul(e)||void 0,needBlock:m,rootId:u,isCustom:y}}function G(e){return e==null?"":e.toLowerCase()}function Qs(e){return e===true||e==="all"?{script:true,comment:true,headFavicon:true,headWhitespace:true,headMetaSocial:true,headMetaRobots:true,headMetaHttpEquiv:true,headMetaVerification:true,headMetaAuthorship:e==="all",headMetaDescKeywords:e==="all",headTitleMutations:e==="all"}:e||{}}function Vl(e,t){if(t.comment&&e.type===ne.Comment)return true;if(e.type===ne.Element){if(t.script&&(e.tagName==="script"||e.tagName==="link"&&(e.attributes.rel==="preload"&&e.attributes.as==="script"||e.attributes.rel==="modulepreload")||e.tagName==="link"&&e.attributes.rel==="prefetch"&&typeof e.attributes.href=="string"&&Ys(e.attributes.href)==="js"))return true;if(t.headFavicon&&(e.tagName==="link"&&e.attributes.rel==="shortcut icon"||e.tagName==="meta"&&(G(e.attributes.name).match(/^msapplication-tile(image|color)$/)||G(e.attributes.name)==="application-name"||G(e.attributes.rel)==="icon"||G(e.attributes.rel)==="apple-touch-icon"||G(e.attributes.rel)==="shortcut icon")))return true;if(e.tagName==="meta"){if(t.headMetaDescKeywords&&G(e.attributes.name).match(/^description|keywords$/))return true;if(t.headMetaSocial&&(G(e.attributes.property).match(/^(og|twitter|fb):/)||G(e.attributes.name).match(/^(og|twitter):/)||G(e.attributes.name)==="pinterest"))return true;if(t.headMetaRobots&&(G(e.attributes.name)==="robots"||G(e.attributes.name)==="googlebot"||G(e.attributes.name)==="bingbot"))return true;if(t.headMetaHttpEquiv&&e.attributes["http-equiv"]!==void 0)return true;if(t.headMetaAuthorship&&(G(e.attributes.name)==="author"||G(e.attributes.name)==="generator"||G(e.attributes.name)==="framework"||G(e.attributes.name)==="publisher"||G(e.attributes.name)==="progid"||G(e.attributes.property).match(/^article:/)||G(e.attributes.property).match(/^product:/)))return true;if(t.headMetaVerification&&(G(e.attributes.name)==="google-site-verification"||G(e.attributes.name)==="yandex-verification"||G(e.attributes.name)==="csrf-token"||G(e.attributes.name)==="p:domain_verify"||G(e.attributes.name)==="verify-v1"||G(e.attributes.name)==="verification"||G(e.attributes.name)==="shopify-checkout-api-token"))return true}}return false}function Ve(e,t){let{doc:r,mirror:i,blockClass:n,blockSelector:o,maskTextClass:l,maskTextSelector:p,skipChild:a=false,inlineStylesheet:h=true,maskInputOptions:s={},maskTextFn:f,maskInputFn:c,slimDOMOptions:u,dataURLOptions:m={},inlineImages:d=false,recordCanvas:g=false,onSerialize:S,onIframeLoad:y,iframeLoadTimeout:b=5e3,onStylesheetLoad:E,stylesheetLoadTimeout:w=5e3,keepIframeSrcFn:v=()=>false,newlyAddedElement:C=false,cssCaptured:R=false}=t,{needsMask:I}=t,{preserveWhiteSpace:M=true}=t;I||(I=Zs(e,l,p,I===void 0));let O=$l(e,{doc:r,mirror:i,blockClass:n,blockSelector:o,needsMask:I,inlineStylesheet:h,maskInputOptions:s,maskTextFn:f,maskInputFn:c,dataURLOptions:m,inlineImages:d,recordCanvas:g,keepIframeSrcFn:v,newlyAddedElement:C,cssCaptured:R});if(!O)return console.warn(e,"not serialized"),null;let k;i.hasNode(e)?k=i.getId(e):Vl(O,u)||!M&&O.type===ne.Text&&!O.textContent.replace(/^\s+|\s+$/gm,"").length?k=it:k=Xs();let x=Object.assign(O,{id:k});if(i.add(e,x),k===it)return null;S&&S(e);let Q=!a;if(x.type===ne.Element){Q=Q&&!x.needBlock,delete x.needBlock;let L=se.shadowRoot(e);L&&rt(L)&&(x.isShadowHost=true);}if((x.type===ne.Document||x.type===ne.Element)&&Q){u.headWhitespace&&x.type===ne.Element&&x.tagName==="head"&&(M=false);let L={doc:r,mirror:i,blockClass:n,blockSelector:o,needsMask:I,maskTextClass:l,maskTextSelector:p,skipChild:a,inlineStylesheet:h,maskInputOptions:s,maskTextFn:f,maskInputFn:c,slimDOMOptions:u,dataURLOptions:m,inlineImages:d,recordCanvas:g,preserveWhiteSpace:M,onSerialize:S,onIframeLoad:y,iframeLoadTimeout:b,onStylesheetLoad:E,stylesheetLoadTimeout:w,keepIframeSrcFn:v,cssCaptured:false};if(!(x.type===ne.Element&&x.tagName==="textarea"&&x.attributes.value!==void 0)){x.type===ne.Element&&x.attributes._cssText!==void 0&&typeof x.attributes._cssText=="string"&&(L.cssCaptured=true);for(let B of Array.from(se.childNodes(e))){let X=Ve(B,L);X&&x.childNodes.push(X);}}let A=null;if(Vs(e)&&(A=se.shadowRoot(e)))for(let B of Array.from(se.childNodes(A))){let X=Ve(B,L);X&&(rt(A)&&(X.isShadow=true),x.childNodes.push(X));}}let Y=se.parentNode(e);return Y&&tt(Y)&&rt(Y)&&(x.isShadow=true),x.type===ne.Element&&x.tagName==="iframe"&&ql(e,()=>{let L=e.contentDocument;if(L&&y){let A=Ve(L,{doc:L,mirror:i,blockClass:n,blockSelector:o,needsMask:I,maskTextClass:l,maskTextSelector:p,skipChild:false,inlineStylesheet:h,maskInputOptions:s,maskTextFn:f,maskInputFn:c,slimDOMOptions:u,dataURLOptions:m,inlineImages:d,recordCanvas:g,preserveWhiteSpace:M,onSerialize:S,onIframeLoad:y,iframeLoadTimeout:b,onStylesheetLoad:E,stylesheetLoadTimeout:w,keepIframeSrcFn:v});A&&y(e,A);}},b),x.type===ne.Element&&x.tagName==="link"&&typeof x.attributes.rel=="string"&&(x.attributes.rel==="stylesheet"||x.attributes.rel==="preload"&&typeof x.attributes.href=="string"&&Ys(x.attributes.href)==="css")&&zl(e,()=>{if(E){let L=Ve(e,{doc:r,mirror:i,blockClass:n,blockSelector:o,needsMask:I,maskTextClass:l,maskTextSelector:p,skipChild:false,inlineStylesheet:h,maskInputOptions:s,maskTextFn:f,maskInputFn:c,slimDOMOptions:u,dataURLOptions:m,inlineImages:d,recordCanvas:g,preserveWhiteSpace:M,onSerialize:S,onIframeLoad:y,iframeLoadTimeout:b,onStylesheetLoad:E,stylesheetLoadTimeout:w,keepIframeSrcFn:v});L&&E(e,L);}},w),x}function Gl(e,t){let{mirror:r=new Nt,blockClass:i="rr-block",blockSelector:n=null,maskTextClass:o="rr-mask",maskTextSelector:l=null,inlineStylesheet:p=true,inlineImages:a=false,recordCanvas:h=false,maskAllInputs:s=false,maskTextFn:f,maskInputFn:c,slimDOM:u=false,dataURLOptions:m,preserveWhiteSpace:d,onSerialize:g,onIframeLoad:S,iframeLoadTimeout:y,onStylesheetLoad:b,stylesheetLoadTimeout:E,keepIframeSrcFn:w=()=>false}=t,v=s===true?{color:true,date:true,"datetime-local":true,email:true,month:true,number:true,range:true,search:true,tel:true,text:true,time:true,url:true,week:true,textarea:true,select:true,password:true}:s===false?{password:true}:s,C=Qs(u);return Ve(e,{doc:e,mirror:r,blockClass:i,blockSelector:n,maskTextClass:o,maskTextSelector:l,skipChild:false,inlineStylesheet:p,maskInputOptions:v,maskTextFn:f,maskInputFn:c,slimDOMOptions:C,dataURLOptions:m,inlineImages:a,recordCanvas:h,preserveWhiteSpace:d,onSerialize:g,onIframeLoad:S,iframeLoadTimeout:y,onStylesheetLoad:b,stylesheetLoadTimeout:E,keepIframeSrcFn:w,newlyAddedElement:false})}function Xl(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}function Jl(e){if(e.__esModule)return e;var t=e.default;if(typeof t=="function"){var r=function i(){return this instanceof i?Reflect.construct(t,arguments,this.constructor):t.apply(this,arguments)};r.prototype=t.prototype;}else r={};return Object.defineProperty(r,"__esModule",{value:true}),Object.keys(e).forEach(function(i){var n=Object.getOwnPropertyDescriptor(e,i);Object.defineProperty(r,i,n.get?n:{enumerable:true,get:function(){return e[i]}});}),r}var wt={exports:{}},Mi;function Kl(){if(Mi)return wt.exports;Mi=1;var e=String,t=function(){return {isColorSupported:false,reset:e,bold:e,dim:e,italic:e,underline:e,inverse:e,hidden:e,strikethrough:e,black:e,red:e,green:e,yellow:e,blue:e,magenta:e,cyan:e,white:e,gray:e,bgBlack:e,bgRed:e,bgGreen:e,bgYellow:e,bgBlue:e,bgMagenta:e,bgCyan:e,bgWhite:e}};return wt.exports=t(),wt.exports.createColors=t,wt.exports}var Zl={},Ql=Object.freeze(Object.defineProperty({__proto__:null,default:Zl},Symbol.toStringTag,{value:"Module"})),Ce=Jl(Ql),pr,Ii;function Ln(){if(Ii)return pr;Ii=1;let e=Kl(),t=Ce;class r extends Error{constructor(n,o,l,p,a,h){super(n),this.name="CssSyntaxError",this.reason=n,a&&(this.file=a),p&&(this.source=p),h&&(this.plugin=h),typeof o<"u"&&typeof l<"u"&&(typeof o=="number"?(this.line=o,this.column=l):(this.line=o.line,this.column=o.column,this.endLine=l.line,this.endColumn=l.column)),this.setMessage(),Error.captureStackTrace&&Error.captureStackTrace(this,r);}setMessage(){this.message=this.plugin?this.plugin+": ":"",this.message+=this.file?this.file:"<css input>",typeof this.line<"u"&&(this.message+=":"+this.line+":"+this.column),this.message+=": "+this.reason;}showSourceCode(n){if(!this.source)return "";let o=this.source;n==null&&(n=e.isColorSupported),t&&n&&(o=t(o));let l=o.split(/\r?\n/),p=Math.max(this.line-3,0),a=Math.min(this.line+2,l.length),h=String(a).length,s,f;if(n){let{bold:c,gray:u,red:m}=e.createColors(true);s=d=>c(m(d)),f=d=>u(d);}else s=f=c=>c;return l.slice(p,a).map((c,u)=>{let m=p+1+u,d=" "+(" "+m).slice(-h)+" | ";if(m===this.line){let g=f(d.replace(/\d/g," "))+c.slice(0,this.column-1).replace(/[^\t]/g," ");return s(">")+f(d)+c+`
2
- `+g+s("^")}return " "+f(d)+c}).join(`
1
+ var ObsrviqSDK=(function(exports){'use strict';var be=Uint8Array,de=Uint16Array,sr=Int32Array,or=new be([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]),ar=new be([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]),si=new be([16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15]),ui=function(e,t){for(var r=new de(31),i=0;i<31;++i)r[i]=t+=1<<e[i-1];for(var n=new sr(r[30]),i=1;i<30;++i)for(var o=r[i];o<r[i+1];++o)n[o]=o-r[i]<<5|i;return {b:r,r:n}},ci=ui(or,2),xa=ci.b,tr=ci.r;xa[28]=258,tr[258]=28;var fi=ui(ar,0),oi=fi.r,rr=new de(32768);for(W=0;W<32768;++W)Ie=(W&43690)>>1|(W&21845)<<1,Ie=(Ie&52428)>>2|(Ie&13107)<<2,Ie=(Ie&61680)>>4|(Ie&3855)<<4,rr[W]=((Ie&65280)>>8|(Ie&255)<<8)>>1;var Ie,W,Ke=(function(e,t,r){for(var i=e.length,n=0,o=new de(t);n<i;++n)e[n]&&++o[e[n]-1];var l=new de(t);for(n=1;n<t;++n)l[n]=l[n-1]+o[n-1]<<1;var d;for(d=new de(i),n=0;n<i;++n)e[n]&&(d[n]=rr[l[e[n]-1]++]>>15-e[n]);return d}),De=new be(288);for(W=0;W<144;++W)De[W]=8;var W;for(W=144;W<256;++W)De[W]=9;var W;for(W=256;W<280;++W)De[W]=7;var W;for(W=280;W<288;++W)De[W]=8;var W,dt=new be(32);for(W=0;W<32;++W)dt[W]=5;var W,Ra=Ke(De,9);var Ia=Ke(dt,5);var hi=function(e){return (e+7)/8|0},Ma=function(e,t,r){return (r==null||r>e.length)&&(r=e.length),new be(e.subarray(t,r))};var Me=function(e,t,r){r<<=t&7;var i=t/8|0;e[i]|=r,e[i+1]|=r>>8;},Xe=function(e,t,r){r<<=t&7;var i=t/8|0;e[i]|=r,e[i+1]|=r>>8,e[i+2]|=r>>16;},er=function(e,t){for(var r=[],i=0;i<e.length;++i)e[i]&&r.push({s:i,f:e[i]});var n=r.length,o=r.slice();if(!n)return {t:pi,l:0};if(n==1){var l=new be(r[0].s+1);return l[r[0].s]=1,{t:l,l:1}}r.sort(function(w,v){return w.f-v.f}),r.push({s:-1,f:25001});var d=r[0],a=r[1],h=0,s=1,f=2;for(r[0]={s:-1,f:d.f+a.f,l:d,r:a};s!=n-1;)d=r[r[h].f<r[f].f?h++:f++],a=r[h!=s&&r[h].f<r[f].f?h++:f++],r[s++]={s:-1,f:d.f+a.f,l:d,r:a};for(var c=o[0].s,i=1;i<n;++i)o[i].s>c&&(c=o[i].s);var u=new de(c+1),m=nr(r[s-1],u,0);if(m>t){var i=0,p=0,g=m-t,S=1<<g;for(o.sort(function(v,C){return u[C.s]-u[v.s]||v.f-C.f});i<n;++i){var y=o[i].s;if(u[y]>t)p+=S-(1<<m-u[y]),u[y]=t;else break}for(p>>=g;p>0;){var b=o[i].s;u[b]<t?p-=1<<t-u[b]++-1:++i;}for(;i>=0&&p;--i){var E=o[i].s;u[E]==t&&(--u[E],++p);}m=t;}return {t:new be(u),l:m}},nr=function(e,t,r){return e.s==-1?Math.max(nr(e.l,t,r+1),nr(e.r,t,r+1)):t[e.s]=r},ai=function(e){for(var t=e.length;t&&!e[--t];);for(var r=new de(++t),i=0,n=e[0],o=1,l=function(a){r[i++]=a;},d=1;d<=t;++d)if(e[d]==n&&d!=t)++o;else {if(!n&&o>2){for(;o>138;o-=138)l(32754);o>2&&(l(o>10?o-11<<5|28690:o-3<<5|12305),o=0);}else if(o>3){for(l(n),--o;o>6;o-=6)l(8304);o>2&&(l(o-3<<5|8208),o=0);}for(;o--;)l(n);o=1,n=e[d];}return {c:r.subarray(0,i),n:t}},Je=function(e,t){for(var r=0,i=0;i<t.length;++i)r+=e[i]*t[i];return r},di=function(e,t,r){var i=r.length,n=hi(t+2);e[n]=i&255,e[n+1]=i>>8,e[n+2]=e[n]^255,e[n+3]=e[n+1]^255;for(var o=0;o<i;++o)e[n+o+4]=r[o];return (n+4+i)*8},li=function(e,t,r,i,n,o,l,d,a,h,s){Me(t,s++,r),++n[256];for(var f=er(n,15),c=f.t,u=f.l,m=er(o,15),p=m.t,g=m.l,S=ai(c),y=S.c,b=S.n,E=ai(p),w=E.c,v=E.n,C=new de(19),R=0;R<y.length;++R)++C[y[R]&31];for(var R=0;R<w.length;++R)++C[w[R]&31];for(var M=er(C,7),I=M.t,O=M.l,k=19;k>4&&!I[si[k-1]];--k);var x=h+5<<3,Q=Je(n,De)+Je(o,dt)+l,Y=Je(n,c)+Je(o,p)+l+14+3*k+Je(C,I)+2*C[16]+3*C[17]+7*C[18];if(a>=0&&x<=Q&&x<=Y)return di(t,s,e.subarray(a,a+h));var L,A,B,X;if(Me(t,s,1+(Y<Q)),s+=2,Y<Q){L=Ke(c,u),A=c,B=Ke(p,g),X=p;var J=Ke(I,O);Me(t,s,b-257),Me(t,s+5,v-1),Me(t,s+10,k-4),s+=14;for(var R=0;R<k;++R)Me(t,s+3*R,I[si[R]]);s+=3*k;for(var P=[y,w],ce=0;ce<2;++ce)for(var N=P[ce],R=0;R<N.length;++R){var re=N[R]&31;Me(t,s,J[re]),s+=I[re],re>15&&(Me(t,s,N[R]>>5&127),s+=N[R]>>12);}}else L=Ra,A=De,B=Ia,X=dt;for(var R=0;R<d;++R){var H=i[R];if(H>255){var re=H>>18&31;Xe(t,s,L[re+257]),s+=A[re+257],re>7&&(Me(t,s,H>>23&31),s+=or[re]);var me=H&31;Xe(t,s,B[me]),s+=X[me],me>3&&(Xe(t,s,H>>5&8191),s+=ar[me]);}else Xe(t,s,L[H]),s+=A[H];}return Xe(t,s,L[256]),s+A[256]},Na=new sr([65540,131080,131088,131104,262176,1048704,1048832,2114560,2117632]),pi=new be(0),Ta=function(e,t,r,i,n,o){var l=o.z||e.length,d=new be(i+l+5*(1+Math.ceil(l/7e3))+n),a=d.subarray(i,d.length-n),h=o.l,s=(o.r||0)&7;if(t){s&&(a[0]=o.r>>3);for(var f=Na[t-1],c=f>>13,u=f&8191,m=(1<<r)-1,p=o.p||new de(32768),g=o.h||new de(m+1),S=Math.ceil(r/3),y=2*S,b=function(V){return (e[V]^e[V+1]<<S^e[V+2]<<y)&m},E=new sr(25e3),w=new de(288),v=new de(32),C=0,R=0,M=o.i||0,I=0,O=o.w||0,k=0;M+2<l;++M){var x=b(M),Q=M&32767,Y=g[x];if(p[Q]=Y,g[x]=Q,O<=M){var L=l-M;if((C>7e3||I>24576)&&(L>423||!h)){s=li(e,a,0,E,w,v,R,I,k,M-k,s),I=C=R=0,k=M;for(var A=0;A<286;++A)w[A]=0;for(var A=0;A<30;++A)v[A]=0;}var B=2,X=0,J=u,P=Q-Y&32767;if(L>2&&x==b(M-P))for(var ce=Math.min(c,L)-1,N=Math.min(32767,M),re=Math.min(258,L);P<=N&&--J&&Q!=Y;){if(e[M+B]==e[M+B-P]){for(var H=0;H<re&&e[M+H]==e[M+H-P];++H);if(H>B){if(B=H,X=P,H>ce)break;for(var me=Math.min(P,H-2),ie=0,A=0;A<me;++A){var oe=M-P+A&32767,Re=p[oe],we=oe-Re&32767;we>ie&&(ie=we,Y=oe);}}}Q=Y,Y=p[Q],P+=Q-Y&32767;}if(X){E[I++]=268435456|tr[B]<<18|oi[X];var D=tr[B]&31,ee=oi[X]&31;R+=or[D]+ar[ee],++w[257+D],++v[ee],O=M+B,++C;}else E[I++]=e[M],++w[e[M]];}}for(M=Math.max(M,O);M<l;++M)E[I++]=e[M],++w[e[M]];s=li(e,a,h,E,w,v,R,I,k,M-k,s),h||(o.r=s&7|a[s/8|0]<<3,s-=7,o.h=g,o.p=p,o.i=M,o.w=O);}else {for(var M=o.w||0;M<l+h;M+=65535){var z=M+65535;z>=l&&(a[s/8|0]=h,z=l),s=di(a,s+1,e.subarray(M,z));}o.i=l;}return Ma(d,0,i+hi(s)+n)},ka=(function(){for(var e=new Int32Array(256),t=0;t<256;++t){for(var r=t,i=9;--i;)r=(r&1&&-306674912)^r>>>1;e[t]=r;}return e})(),Aa=function(){var e=-1;return {p:function(t){for(var r=e,i=0;i<t.length;++i)r=ka[r&255^t[i]]^r>>>8;e=r;},d:function(){return ~e}}};var Oa=function(e,t,r,i,n){if(!n&&(n={l:1},t.dictionary)){var o=t.dictionary.subarray(-32768),l=new be(o.length+e.length);l.set(o),l.set(e,o.length),e=l,n.w=o.length;}return Ta(e,t.level==null?6:t.level,t.mem==null?n.l?Math.ceil(Math.max(8,Math.min(13,Math.log(e.length)))*1.5):20:12+t.mem,r,i,n)};var ir=function(e,t,r){for(;r;++t)e[t]=r,r>>>=8;},Da=function(e,t){var r=t.filename;if(e[0]=31,e[1]=139,e[2]=8,e[8]=t.level<2?4:t.level==9?2:0,e[9]=3,t.mtime!=0&&ir(e,4,Math.floor(new Date(t.mtime||Date.now())/1e3)),r){e[3]=8;for(var i=0;i<=r.length;++i)e[i+10]=r.charCodeAt(i);}};var La=function(e){return 10+(e.filename?e.filename.length+1:0)};function lr(e,t){t||(t={});var r=Aa(),i=e.length;r.p(e);var n=Oa(e,t,La(t),8),o=n.length;return Da(n,t),ir(n,o-8,r.d()),ir(n,o-4,i),n}var Pa=typeof TextDecoder<"u"&&new TextDecoder,_a=0;try{Pa.decode(pi,{stream:!0}),_a=1;}catch{}var Fa=/[a-z0-9._%+-]+@[a-z0-9.-]+\.[a-z]{2,}/gi,Ua=/\b(?:\d[ -]*?){13,19}\b/g,Ba=/\b\d{3}-\d{2}-\d{4}\b/g,qa=/\b\d{9,}\b/g,za=/(password|passwd|passphrase|secret|token|authoriz|apikey|api[_-]key|creditcard|cardnumber|cardholder|cookie|cvv|cvc)/i,$a=new Set(["pass","pwd","auth","card","pin","otp","ssn","cvv","cvc"]);function Wa(e){return e.replace(/([a-z0-9])([A-Z])/g,"$1 $2").replace(/([A-Z]+)([A-Z][a-z])/g,"$1 $2").split(/[^A-Za-z0-9]+/).filter(Boolean).map(t=>t.toLowerCase())}function ge(e){return e.replace(Fa,"\xABemail\xBB").replace(Ua,t=>Ha(t)?"\xABcard\xBB":t).replace(Ba,"\xABssn\xBB").replace(qa,"\xABnumber\xBB")}function Ha(e){let t=e.replace(/\D/g,"");return t.length>=13&&t.length<=19}var mi=new Set;function ur(e){mi=new Set(e.map(t=>String(t).trim().toLowerCase()).filter(Boolean));}var gi=false;function cr(){gi=true;}function yi(){return !gi}function ja(e){return mi.has(e.toLowerCase())}function Ze(e){return ja(e)||za.test(e)?true:Wa(e).some(t=>$a.has(t))}function mt(e,t=0){if(t>24||e===null||typeof e!="object")return e;if(Array.isArray(e))return e.map(i=>mt(i,t+1));let r={};for(let[i,n]of Object.entries(e))r[i]=Ze(i)?"\xABredacted\xBB":mt(n,t+1);return r}function Va(e){let t=e.replace(/"([A-Za-z0-9_.\-]+)"\s*:\s*("(?:[^"\\]|\\.)*"|[^,}\]\s]+)/g,(r,i)=>Ze(i)?'"'+i+'": "\xABredacted\xBB"':r);return t=t.replace(/(^|[?&])([A-Za-z0-9_.\-[\]]+)=([^&\s]*)/g,(r,i,n)=>Ze(n)?i+n+"=\xABredacted\xBB":r),t}function pt(e){if(!e)return e;let t=e.trim();if(t[0]==="{"||t[0]==="[")try{return JSON.stringify(mt(JSON.parse(t)))}catch{}return Va(e)}function fr(e){for(let t of e)if(t.type==="network"||t.type==="ws"){let r=t;r.requestBody?.preview&&(r.requestBody.preview=pt(r.requestBody.preview)),r.responseBody?.preview&&(r.responseBody.preview=pt(r.responseBody.preview)),r.body?.preview&&(r.body.preview=pt(r.body.preview));}else if(t.type==="custom"){let r=t;r.props&&(r.props=mt(r.props));}else if(t.type==="console"){let r=t.args;if(r)for(let i of r)i.kind==="object"&&i.json&&(i.json=pt(i.json));}}var ze=5e3,Ga=4*1024*1024,vi=56*1024,Qe="obsrviq.spill",Ya=15e5,Xa=1440*60*1e3,Ja=2,Ka=4,gt=class{constructor(t){this.opts=t;this.buffer=[];this.seqFloor=0;this.sending=false;this.retryDelay=1e3;this.stopped=false;this.onVisibility=()=>{document.visibilityState==="hidden"&&this.flush("hidden");};this.onPageHide=()=>{this.flush("pagehide");};this.seq=t.startSeq??0;}start(){this.timer=setInterval(()=>{this.flush("timer");},this.opts.flushIntervalMs),document.addEventListener("visibilitychange",this.onVisibility,{capture:true}),window.addEventListener("pagehide",this.onPageHide,{capture:true}),this.resendSpill();}enqueue(t){this.stopped||(this.buffer.push(t),this.buffer.length>=ze&&(this.flush("backpressure"),this.buffer.length>=ze&&this.shedDomBacklog()));}shedDomBacklog(){let t=-1;for(let r=this.buffer.length-1;r>=0;r--){let i=this.buffer[r];if(i?.type==="dom"&&i.data?.type===Ja){t=r;break}}if(t>0){let r=t,i=this.buffer[t-1];i?.type==="dom"&&i.data?.type===Ka&&(r=t-1);let n=this.buffer.filter((o,l)=>o.type!=="dom"||l>=r);if(n.length<this.buffer.length&&(this.buffer=n,this.buffer.length<ze))return}this.buffer=this.buffer.filter(r=>r.type!=="dom"),this.buffer.length>=ze&&(this.buffer=this.buffer.slice(-Math.floor(ze/2))),this.opts.onDomDrop?.();}async flush(t){if(t==="pagehide"||t==="hidden")return this.flushUnload();if(this.sending||this.buffer.length===0)return true;if(yi()&&!this.stopped)return setTimeout(()=>{this.flush("timer");},200),true;this.sending=true;let r=this.buffer;this.buffer=[],fr(r);let i;try{i=await this.sendEvents(r);}finally{this.sending=false;}return i&&this.stopped&&this.buffer.length>0&&this.flush("manual"),i}async sendEvents(t){let r=[t];for(;r.length>0;){let i=r[0],n=await this.dispatch(i);if(n==="ok"){r.shift();continue}if(n==="too_large"&&i.length>1){let o=Math.ceil(i.length/2);r.splice(0,1,i.slice(0,o),i.slice(o));continue}if(n==="fatal"||n==="too_large"){r.shift();continue}if(this.buffer=[].concat(...r,this.buffer),this.buffer.length>=ze&&this.shedDomBacklog(),!this.stopped){let o=this.retryDelay*(.5+Math.random());this.retryDelay=Math.min(this.retryDelay*2,3e4),setTimeout(()=>{this.flush("timer");},o);}return false}return this.retryDelay=1e3,true}async dispatch(t){this.seqFloor>this.seq&&(this.seq=this.seqFloor);let r={siteKey:this.opts.siteKey,sessionId:this.opts.sessionId,seq:this.seq,meta:this.opts.getMeta(),events:t};if(this.opts.beforeSend)try{r=this.opts.beforeSend(r);}catch{r=null;}if(!r)return "ok";let i=JSON.stringify(r);if(i.length>Ga&&t.length>1)return "too_large";this.opts.onSeqDispatch?.(this.seq+1);let n=await Za(new TextEncoder().encode(i)),o=await this.send(n);return this.opts.onFlush?.({bytes:n.byteLength,events:t.length,ok:o==="ok"}),o==="ok"&&(this.seq=Math.max(this.seq+1,this.seqFloor)),o}async send(t){let r=`${this.opts.endpoint.replace(/\/$/,"")}/v1/batch`,i=new AbortController,n=setTimeout(()=>i.abort(),15e3);try{let o=await fetch(r,{method:"POST",body:t,headers:{"content-type":"application/octet-stream","x-obsrviq-key":this.opts.siteKey},credentials:"omit",mode:"cors",signal:i.signal});return o.ok?"ok":o.status===413?"too_large":o.status>=400&&o.status<500&&o.status!==408&&o.status!==429?"fatal":"retry"}catch{return "retry"}finally{clearTimeout(n);}}flushUnload(){if(this.buffer.length===0)return true;let t=this.buffer;this.buffer=[],fr(t);let r=Math.max(this.sending?this.seq+1:this.seq,this.seqFloor),i=[],n=[t];for(;n.length>0;){let o=n.shift(),l={siteKey:this.opts.siteKey,sessionId:this.opts.sessionId,seq:r,meta:this.opts.getMeta(),events:o};if(this.opts.beforeSend)try{l=this.opts.beforeSend(l);}catch{l=null;}if(!l)continue;let d=lr(new TextEncoder().encode(JSON.stringify(l)));if(d.byteLength>vi&&o.length>1){let a=Math.ceil(o.length/2);n.unshift(o.slice(0,a),o.slice(a));continue}i.push({gz:d,count:o.length}),r++;}this.seqFloor=r,this.opts.onSeqDispatch?.(r);for(let{gz:o,count:l}of i){let d=o.byteLength<=vi&&this.sendUnload(o);d||this.spill(o),this.opts.onFlush?.({bytes:o.byteLength,events:l,ok:d});}return true}sendUnload(t){let r=`${this.opts.endpoint.replace(/\/$/,"")}/v1/batch`,i=new Blob([t],{type:"application/octet-stream"});if(typeof navigator.sendBeacon=="function")try{if(navigator.sendBeacon(r,i))return !0}catch{}try{return fetch(r,{method:"POST",body:t,headers:{"content-type":"application/octet-stream","x-obsrviq-key":this.opts.siteKey},keepalive:!0,credentials:"omit",mode:"cors"}).catch(()=>{}),!0}catch{return false}}spill(t){try{let r=window.localStorage.getItem(Qe),i=r?JSON.parse(r):[];i.push({k:this.opts.siteKey,b:Qa(t),ts:Date.now()});let n=i.reduce((o,l)=>o+l.b.length,0);for(;i.length>0&&n>Ya;)n-=i[0].b.length,i.shift();window.localStorage.setItem(Qe,JSON.stringify(i));}catch{}}resendSpill(){let t=[];try{let r=window.localStorage.getItem(Qe);if(!r)return;let i=JSON.parse(r),n=Date.now(),o=i.filter(d=>d&&typeof d.b=="string"&&n-d.ts<Xa);t=o.filter(d=>d.k===this.opts.siteKey);let l=o.filter(d=>d.k!==this.opts.siteKey);l.length>0?window.localStorage.setItem(Qe,JSON.stringify(l)):window.localStorage.removeItem(Qe);}catch{return}t.length!==0&&(async()=>{for(let r of t)try{await this.send(wi(r.b))==="retry"&&this.spill(wi(r.b));}catch{}})();}stop(){this.stopped=true,this.timer&&clearInterval(this.timer),document.removeEventListener("visibilitychange",this.onVisibility,{capture:true}),window.removeEventListener("pagehide",this.onPageHide,{capture:true}),this.flush("manual");}};async function Za(e){if(typeof CompressionStream<"u")try{let t=new Blob([e]).stream().pipeThrough(new CompressionStream("gzip"));return new Uint8Array(await new Response(t).arrayBuffer())}catch{}return lr(e)}function Qa(e){let t="";for(let r=0;r<e.length;r+=32768)t+=String.fromCharCode(...e.subarray(r,r+32768));return btoa(t)}function wi(e){let t=atob(e),r=new Uint8Array(t.length);for(let i=0;i<t.length;i++)r[i]=t.charCodeAt(i);return r}var el=Object.defineProperty,tl=(e,t,r)=>t in e?el(e,t,{enumerable:true,configurable:true,writable:true,value:r}):e[t]=r,T=(e,t,r)=>tl(e,typeof t!="symbol"?t+"":t,r),bi,rl=Object.defineProperty,nl=(e,t,r)=>t in e?rl(e,t,{enumerable:true,configurable:true,writable:true,value:r}):e[t]=r,Si=(e,t,r)=>nl(e,typeof t!="symbol"?t+"":t,r),ne=(e=>(e[e.Document=0]="Document",e[e.DocumentType=1]="DocumentType",e[e.Element=2]="Element",e[e.Text=3]="Text",e[e.CDATA=4]="CDATA",e[e.Comment=5]="Comment",e))(ne||{}),Ci={Node:["childNodes","parentNode","parentElement","textContent","ownerDocument"],ShadowRoot:["host","styleSheets"],Element:["shadowRoot","querySelector","querySelectorAll"],MutationObserver:[]},Ei={Node:["contains","getRootNode"],ShadowRoot:["getSelection"],Element:[],MutationObserver:["constructor"]},yt={},Hs={},il=()=>!!globalThis.Zone;function On(e){if(yt[e])return yt[e];let t=globalThis[e],r=t.prototype,i=e in Ci?Ci[e]:void 0,n=!!(i&&i.every(d=>{var a,h;return !!((h=(a=Object.getOwnPropertyDescriptor(r,d))==null?void 0:a.get)!=null&&h.toString().includes("[native code]"))})),o=e in Ei?Ei[e]:void 0,l=!!(o&&o.every(d=>{var a;return typeof r[d]=="function"&&((a=r[d])==null?void 0:a.toString().includes("[native code]"))}));if(n&&l&&!il())return yt[e]=t.prototype,t.prototype;try{let d=document.createElement("iframe");d.style.display="none",document.body.appendChild(d);let a=d.contentWindow;if(!a)return t.prototype;let h=a[e].prototype;if(!h)return d.remove(),r;let s=navigator.userAgent;return s.includes("Safari")&&!s.includes("Chrome")?(d.classList.add("rr-block"),d.setAttribute("__rrwebUntaintedMutationObserver",""),Hs[e]=()=>d.remove()):d.remove(),yt[e]=h}catch{return r}}var hr={};function Te(e,t,r){var i;let n=`${e}.${String(r)}`;if(hr[n])return hr[n].call(t);let o=On(e),l=(i=Object.getOwnPropertyDescriptor(o,r))==null?void 0:i.get;return l?(hr[n]=l,l.call(t)):t[r]}var dr={};function js(e,t,r){let i=`${e}.${String(r)}`;if(dr[i])return dr[i].bind(t);let o=On(e)[r];return typeof o!="function"?t[r]:(dr[i]=o,o.bind(t))}function sl(e){return Te("Node",e,"ownerDocument")}function ol(e){return Te("Node",e,"childNodes")}function al(e){return Te("Node",e,"parentNode")}function ll(e){return Te("Node",e,"parentElement")}function ul(e){return Te("Node",e,"textContent")}function cl(e,t){return js("Node",e,"contains")(t)}function fl(e){return js("Node",e,"getRootNode")()}function hl(e){return !e||!("host"in e)?null:Te("ShadowRoot",e,"host")}function dl(e){return e.styleSheets}function pl(e){return !e||!("shadowRoot"in e)?null:Te("Element",e,"shadowRoot")}function ml(e,t){return Te("Element",e,"querySelector")(t)}function gl(e,t){return Te("Element",e,"querySelectorAll")(t)}function yl(){return [On("MutationObserver").constructor,Hs.MutationObserver??(()=>{})]}var Vs=Date.now;/[1-9][0-9]{12}/.test(Date.now().toString())||(Vs=()=>new Date().getTime());function vl(e,t,r){try{if(!(t in e))return ()=>{};let i=e[t],n=r(i);return typeof n=="function"&&(n.prototype=n.prototype||{},Object.defineProperties(n,{__rrweb_original__:{enumerable:!1,value:i}})),e[t]=n,()=>{e[t]=i;}}catch{return ()=>{}}}var se={ownerDocument:sl,childNodes:ol,parentNode:al,parentElement:ll,textContent:ul,contains:cl,getRootNode:fl,host:hl,styleSheets:dl,shadowRoot:pl,querySelector:ml,querySelectorAll:gl,nowTimestamp:Vs,mutationObserverCtor:yl,patch:vl};function Gs(e){return e.nodeType===e.ELEMENT_NODE}function tt(e){let t=e&&"host"in e&&"mode"in e&&se.host(e)||null;return !!(t&&"shadowRoot"in t&&se.shadowRoot(t)===e)}function rt(e){return Object.prototype.toString.call(e)==="[object ShadowRoot]"}function wl(e){return e.includes(" background-clip: text;")&&!e.includes(" -webkit-background-clip: text;")&&(e=e.replace(/\sbackground-clip:\s*text;/g," -webkit-background-clip: text; background-clip: text;")),e}function bl(e){let{cssText:t}=e;if(t.split('"').length<3)return t;let r=["@import",`url(${JSON.stringify(e.href)})`];return e.layerName===""?r.push("layer"):e.layerName&&r.push(`layer(${e.layerName})`),e.supportsText&&r.push(`supports(${e.supportsText})`),e.media.length&&r.push(e.media.mediaText),r.join(" ")+";"}function wn(e){try{let t=e.rules||e.cssRules;if(!t)return null;let r=e.href;!r&&e.ownerNode&&(r=e.ownerNode.baseURI);let i=Array.from(t,n=>Ys(n,r)).join("");return wl(i)}catch{return null}}function Ys(e,t){if(Cl(e)){let r;try{r=wn(e.styleSheet)||bl(e);}catch{r=e.cssText;}return e.styleSheet.href?At(r,e.styleSheet.href):r}else {let r=e.cssText;return El(e)&&e.selectorText.includes(":")&&(r=Sl(r)),t?At(r,t):r}}function Sl(e){let t=/(\[(?:[\w-]+)[^\\])(:(?:[\w-]+)\])/gm;return e.replace(t,"$1\\$2")}function Cl(e){return "styleSheet"in e}function El(e){return "selectorText"in e}var Nt=class{constructor(){Si(this,"idNodeMap",new Map),Si(this,"nodeMetaMap",new WeakMap);}getId(t){var r;return t?((r=this.getMeta(t))==null?void 0:r.id)??-1:-1}getNode(t){return this.idNodeMap.get(t)||null}getIds(){return Array.from(this.idNodeMap.keys())}getMeta(t){return this.nodeMetaMap.get(t)||null}removeNodeFromMap(t){let r=this.getId(t);this.idNodeMap.delete(r),t.childNodes&&t.childNodes.forEach(i=>this.removeNodeFromMap(i));}has(t){return this.idNodeMap.has(t)}hasNode(t){return this.nodeMetaMap.has(t)}add(t,r){let i=r.id;this.idNodeMap.set(i,t),this.nodeMetaMap.set(t,r);}replace(t,r){let i=this.getNode(t);if(i){let n=this.nodeMetaMap.get(i);n&&this.nodeMetaMap.set(r,n);}this.idNodeMap.set(t,r);}reset(){this.idNodeMap=new Map,this.nodeMetaMap=new WeakMap;}};function xl(){return new Nt}function Tt({element:e,maskInputOptions:t,tagName:r,type:i,value:n,maskInputFn:o}){let l=n||"",d=i&&Pe(i);return (t[r.toLowerCase()]||d&&t[d])&&(o?l=o(l,e):l="*".repeat(l.length)),l}function Pe(e){return e.toLowerCase()}var xi="__rrweb_original__";function Rl(e){let t=e.getContext("2d");if(!t)return true;let r=50;for(let i=0;i<e.width;i+=r)for(let n=0;n<e.height;n+=r){let o=t.getImageData,l=xi in o?o[xi]:o;if(new Uint32Array(l.call(t,i,n,Math.min(r,e.width-i),Math.min(r,e.height-n)).data.buffer).some(a=>a!==0))return false}return true}function kt(e){let t=e.type;return e.hasAttribute("data-rr-is-password")?"password":t?Pe(t):null}function Xs(e,t){let r;try{r=new URL(e,t??window.location.href);}catch{return null}let i=/\.([0-9a-z]+)(?:$)/i,n=r.pathname.match(i);return n?.[1]??null}function Il(e){let t="";return e.indexOf("//")>-1?t=e.split("/").slice(0,3).join("/"):t=e.split("/")[0],t=t.split("?")[0],t}var Ml=/url\((?:(')([^']*)'|(")(.*?)"|([^)]*))\)/gm,Nl=/^(?:[a-z+]+:)?\/\//i,Tl=/^www\..*/i,kl=/^(data:)([^,]*),(.*)/i;function At(e,t){return (e||"").replace(Ml,(r,i,n,o,l,d)=>{let a=n||l||d,h=i||o||"";if(!a)return r;if(Nl.test(a)||Tl.test(a))return `url(${h}${a}${h})`;if(kl.test(a))return `url(${h}${a}${h})`;if(a[0]==="/")return `url(${h}${Il(t)+a}${h})`;let s=t.split("/"),f=a.split("/");s.pop();for(let c of f)c!=="."&&(c===".."?s.pop():s.push(c));return `url(${h}${s.join("/")}${h})`})}function vt(e,t=false){return t?e.replace(/(\/\*[^*]*\*\/)|[\s;]/g,""):e.replace(/(\/\*[^*]*\*\/)|[\s;]/g,"").replace(/0px/g,"0")}function Al(e,t,r=false){let i=Array.from(t.childNodes),n=[],o=0;if(i.length>1&&e&&typeof e=="string"){let l=vt(e,r),d=l.length/e.length;for(let a=1;a<i.length;a++)if(i[a].textContent&&typeof i[a].textContent=="string"){let h=vt(i[a].textContent,r),s=100,f=3;for(;f<h.length&&(h[f].match(/[a-zA-Z0-9]/)||h.indexOf(h.substring(0,f),1)!==-1);f++);for(;f<h.length;f++){let c=h.substring(0,f),u=l.split(c),m=-1;if(u.length===2)m=u[0].length;else if(u.length>2&&u[0]===""&&i[a-1].textContent!=="")m=l.indexOf(c,1);else if(u.length===1){if(c=c.substring(0,c.length-1),u=l.split(c),u.length<=1)return n.push(e),n;f=s+1;}else f===h.length-1&&(m=l.indexOf(c));if(u.length>=2&&f>s){let p=i[a-1].textContent;if(p&&typeof p=="string"){let g=vt(p).length;m=l.indexOf(c,g);}m===-1&&(m=u[0].length);}if(m!==-1){let p=Math.floor(m/d);for(;p>0&&p<e.length;){if(o+=1,o>50*i.length)return n.push(e),n;let g=vt(e.substring(0,p),r);if(g.length===m){n.push(e.substring(0,p)),e=e.substring(p),l=l.substring(m);break}else g.length<m?p+=Math.max(1,Math.floor((m-g.length)/d)):p-=Math.max(1,Math.floor((g.length-m)*d));}break}}}}return n.push(e),n}function Ol(e,t){return Al(e,t).join("/* rr_split */")}var Dl=1,Ll=new RegExp("[^a-z0-9-_:]"),it=-2;function Js(){return Dl++}function Pl(e){if(e instanceof HTMLFormElement)return "form";let t=Pe(e.tagName);return Ll.test(t)?"div":t}var $e,Ri,_l=/^[^ \t\n\r\u000c]+/,Fl=/^[, \t\n\r\u000c]+/;function Ul(e,t){if(t.trim()==="")return t;let r=0;function i(o){let l,d=o.exec(t.substring(r));return d?(l=d[0],r+=l.length,l):""}let n=[];for(;i(Fl),!(r>=t.length);){let o=i(_l);if(o.slice(-1)===",")o=je(e,o.substring(0,o.length-1)),n.push(o);else {let l="";o=je(e,o);let d=false;for(;;){let a=t.charAt(r);if(a===""){n.push((o+l).trim());break}else if(d)a===")"&&(d=false);else if(a===","){r+=1,n.push((o+l).trim());break}else a==="("&&(d=true);l+=a,r+=1;}}}return n.join(", ")}var Ii=new WeakMap;function je(e,t){return !t||t.trim()===""?t:Dn(e,t)}function Bl(e){return !!(e.tagName==="svg"||e.ownerSVGElement)}function Dn(e,t){let r=Ii.get(e);if(r||(r=e.createElement("a"),Ii.set(e,r)),!t)t="";else if(t.startsWith("blob:")||t.startsWith("data:"))return t;return r.setAttribute("href",t),r.href}function Ks(e,t,r,i){return i&&(r==="src"||r==="href"&&!(t==="use"&&i[0]==="#")||r==="xlink:href"&&i[0]!=="#"||r==="background"&&["table","td","th"].includes(t)?je(e,i):r==="srcset"?Ul(e,i):r==="style"?At(i,Dn(e)):t==="object"&&r==="data"?je(e,i):i)}function Zs(e,t,r){return ["video","audio"].includes(e)&&t==="autoplay"}function ql(e,t,r){try{if(typeof t=="string"){if(e.classList.contains(t))return !0}else for(let i=e.classList.length;i--;){let n=e.classList[i];if(t.test(n))return !0}if(r)return e.matches(r)}catch{}return false}function Ot(e,t,r){if(!e)return false;if(e.nodeType!==e.ELEMENT_NODE)return r?Ot(se.parentNode(e),t,r):false;for(let i=e.classList.length;i--;){let n=e.classList[i];if(t.test(n))return true}return r?Ot(se.parentNode(e),t,r):false}function Qs(e,t,r,i){let n;if(Gs(e)){if(n=e,!se.childNodes(n).length)return false}else {if(se.parentElement(e)===null)return false;n=se.parentElement(e);}try{if(typeof t=="string"){if(i){if(n.closest(`.${t}`))return !0}else if(n.classList.contains(t))return !0}else if(Ot(n,t,i))return !0;if(r){if(i){if(n.closest(r))return !0}else if(n.matches(r))return !0}}catch{}return false}function zl(e,t,r){let i=e.contentWindow;if(!i)return;let n=false,o;try{o=i.document.readyState;}catch{return}if(o!=="complete"){let d=setTimeout(()=>{n||(t(),n=true);},r);e.addEventListener("load",()=>{clearTimeout(d),n=true,t();});return}let l="about:blank";if(i.location.href!==l||e.src===l||e.src==="")return setTimeout(t,0),e.addEventListener("load",t);e.addEventListener("load",t);}function $l(e,t,r){let i=false,n;try{n=e.sheet;}catch{return}if(n)return;let o=setTimeout(()=>{i||(t(),i=true);},r);e.addEventListener("load",()=>{clearTimeout(o),i=true,t();});}function Wl(e,t){let{doc:r,mirror:i,blockClass:n,blockSelector:o,needsMask:l,inlineStylesheet:d,maskInputOptions:a={},maskTextFn:h,maskInputFn:s,dataURLOptions:f={},inlineImages:c,recordCanvas:u,keepIframeSrcFn:m,newlyAddedElement:p=false,cssCaptured:g=false}=t,S=Hl(r,i);switch(e.nodeType){case e.DOCUMENT_NODE:return e.compatMode!=="CSS1Compat"?{type:ne.Document,childNodes:[],compatMode:e.compatMode}:{type:ne.Document,childNodes:[]};case e.DOCUMENT_TYPE_NODE:return {type:ne.DocumentType,name:e.name,publicId:e.publicId,systemId:e.systemId,rootId:S};case e.ELEMENT_NODE:return Vl(e,{doc:r,blockClass:n,blockSelector:o,inlineStylesheet:d,maskInputOptions:a,maskInputFn:s,dataURLOptions:f,inlineImages:c,recordCanvas:u,keepIframeSrcFn:m,newlyAddedElement:p,rootId:S});case e.TEXT_NODE:return jl(e,{doc:r,needsMask:l,maskTextFn:h,rootId:S,cssCaptured:g});case e.CDATA_SECTION_NODE:return {type:ne.CDATA,textContent:"",rootId:S};case e.COMMENT_NODE:return {type:ne.Comment,textContent:se.textContent(e)||"",rootId:S};default:return false}}function Hl(e,t){if(!t.hasNode(e))return;let r=t.getId(e);return r===1?void 0:r}function jl(e,t){let{needsMask:r,maskTextFn:i,rootId:n,cssCaptured:o}=t,l=se.parentNode(e),d=l&&l.tagName,a="",h=d==="STYLE"?true:void 0,s=d==="SCRIPT"?true:void 0;return s?a="SCRIPT_PLACEHOLDER":o||(a=se.textContent(e),h&&a&&(a=At(a,Dn(t.doc)))),!h&&!s&&a&&r&&(a=i?i(a,se.parentElement(e)):a.replace(/[\S]/g,"*")),{type:ne.Text,textContent:a||"",rootId:n}}function Vl(e,t){let{doc:r,blockClass:i,blockSelector:n,inlineStylesheet:o,maskInputOptions:l={},maskInputFn:d,dataURLOptions:a={},inlineImages:h,recordCanvas:s,keepIframeSrcFn:f,newlyAddedElement:c=false,rootId:u}=t,m=ql(e,i,n),p=Pl(e),g={},S=e.attributes.length;for(let b=0;b<S;b++){let E=e.attributes[b];Zs(p,E.name,E.value)||(g[E.name]=Ks(r,p,Pe(E.name),E.value));}if(p==="link"&&o){let b=Array.from(r.styleSheets).find(w=>w.href===e.href),E=null;b&&(E=wn(b)),E&&(delete g.rel,delete g.href,g._cssText=E);}if(p==="style"&&e.sheet){let b=wn(e.sheet);b&&(e.childNodes.length>1&&(b=Ol(b,e)),g._cssText=b);}if(["input","textarea","select"].includes(p)){let b=e.value,E=e.checked;g.type!=="radio"&&g.type!=="checkbox"&&g.type!=="submit"&&g.type!=="button"&&b?g.value=Tt({element:e,type:kt(e),tagName:p,value:b,maskInputOptions:l,maskInputFn:d}):E&&(g.checked=E);}if(p==="option"&&(e.selected&&!l.select?g.selected=true:delete g.selected),p==="dialog"&&e.open&&(g.rr_open_mode=e.matches("dialog:modal")?"modal":"non-modal"),p==="canvas"&&s){if(e.__context==="2d")Rl(e)||(g.rr_dataURL=e.toDataURL(a.type,a.quality));else if(!("__context"in e)){let b=e.toDataURL(a.type,a.quality),E=r.createElement("canvas");E.width=e.width,E.height=e.height;let w=E.toDataURL(a.type,a.quality);b!==w&&(g.rr_dataURL=b);}}if(p==="img"&&h){$e||($e=r.createElement("canvas"),Ri=$e.getContext("2d"));let b=e,E=b.currentSrc||b.getAttribute("src")||"<unknown-src>",w=b.crossOrigin,v=()=>{b.removeEventListener("load",v);try{$e.width=b.naturalWidth,$e.height=b.naturalHeight,Ri.drawImage(b,0,0),g.rr_dataURL=$e.toDataURL(a.type,a.quality);}catch(C){if(b.crossOrigin!=="anonymous"){b.crossOrigin="anonymous",b.complete&&b.naturalWidth!==0?v():b.addEventListener("load",v);return}else console.warn(`Cannot inline img src=${E}! Error: ${C}`);}b.crossOrigin==="anonymous"&&(w?g.crossOrigin=w:b.removeAttribute("crossorigin"));};b.complete&&b.naturalWidth!==0?v():b.addEventListener("load",v);}if(["audio","video"].includes(p)){let b=g;b.rr_mediaState=e.paused?"paused":"played",b.rr_mediaCurrentTime=e.currentTime,b.rr_mediaPlaybackRate=e.playbackRate,b.rr_mediaMuted=e.muted,b.rr_mediaLoop=e.loop,b.rr_mediaVolume=e.volume;}if(c||(e.scrollLeft&&(g.rr_scrollLeft=e.scrollLeft),e.scrollTop&&(g.rr_scrollTop=e.scrollTop)),m){let{width:b,height:E}=e.getBoundingClientRect();g={class:g.class,rr_width:`${b}px`,rr_height:`${E}px`};}p==="iframe"&&!f(g.src)&&(e.contentDocument||(g.rr_src=g.src),delete g.src);let y;try{customElements.get(p)&&(y=!0);}catch{}return {type:ne.Element,tagName:p,attributes:g,childNodes:[],isSVG:Bl(e)||void 0,needBlock:m,rootId:u,isCustom:y}}function G(e){return e==null?"":e.toLowerCase()}function eo(e){return e===true||e==="all"?{script:true,comment:true,headFavicon:true,headWhitespace:true,headMetaSocial:true,headMetaRobots:true,headMetaHttpEquiv:true,headMetaVerification:true,headMetaAuthorship:e==="all",headMetaDescKeywords:e==="all",headTitleMutations:e==="all"}:e||{}}function Gl(e,t){if(t.comment&&e.type===ne.Comment)return true;if(e.type===ne.Element){if(t.script&&(e.tagName==="script"||e.tagName==="link"&&(e.attributes.rel==="preload"&&e.attributes.as==="script"||e.attributes.rel==="modulepreload")||e.tagName==="link"&&e.attributes.rel==="prefetch"&&typeof e.attributes.href=="string"&&Xs(e.attributes.href)==="js"))return true;if(t.headFavicon&&(e.tagName==="link"&&e.attributes.rel==="shortcut icon"||e.tagName==="meta"&&(G(e.attributes.name).match(/^msapplication-tile(image|color)$/)||G(e.attributes.name)==="application-name"||G(e.attributes.rel)==="icon"||G(e.attributes.rel)==="apple-touch-icon"||G(e.attributes.rel)==="shortcut icon")))return true;if(e.tagName==="meta"){if(t.headMetaDescKeywords&&G(e.attributes.name).match(/^description|keywords$/))return true;if(t.headMetaSocial&&(G(e.attributes.property).match(/^(og|twitter|fb):/)||G(e.attributes.name).match(/^(og|twitter):/)||G(e.attributes.name)==="pinterest"))return true;if(t.headMetaRobots&&(G(e.attributes.name)==="robots"||G(e.attributes.name)==="googlebot"||G(e.attributes.name)==="bingbot"))return true;if(t.headMetaHttpEquiv&&e.attributes["http-equiv"]!==void 0)return true;if(t.headMetaAuthorship&&(G(e.attributes.name)==="author"||G(e.attributes.name)==="generator"||G(e.attributes.name)==="framework"||G(e.attributes.name)==="publisher"||G(e.attributes.name)==="progid"||G(e.attributes.property).match(/^article:/)||G(e.attributes.property).match(/^product:/)))return true;if(t.headMetaVerification&&(G(e.attributes.name)==="google-site-verification"||G(e.attributes.name)==="yandex-verification"||G(e.attributes.name)==="csrf-token"||G(e.attributes.name)==="p:domain_verify"||G(e.attributes.name)==="verify-v1"||G(e.attributes.name)==="verification"||G(e.attributes.name)==="shopify-checkout-api-token"))return true}}return false}function Ve(e,t){let{doc:r,mirror:i,blockClass:n,blockSelector:o,maskTextClass:l,maskTextSelector:d,skipChild:a=false,inlineStylesheet:h=true,maskInputOptions:s={},maskTextFn:f,maskInputFn:c,slimDOMOptions:u,dataURLOptions:m={},inlineImages:p=false,recordCanvas:g=false,onSerialize:S,onIframeLoad:y,iframeLoadTimeout:b=5e3,onStylesheetLoad:E,stylesheetLoadTimeout:w=5e3,keepIframeSrcFn:v=()=>false,newlyAddedElement:C=false,cssCaptured:R=false}=t,{needsMask:M}=t,{preserveWhiteSpace:I=true}=t;M||(M=Qs(e,l,d,M===void 0));let O=Wl(e,{doc:r,mirror:i,blockClass:n,blockSelector:o,needsMask:M,inlineStylesheet:h,maskInputOptions:s,maskTextFn:f,maskInputFn:c,dataURLOptions:m,inlineImages:p,recordCanvas:g,keepIframeSrcFn:v,newlyAddedElement:C,cssCaptured:R});if(!O)return console.warn(e,"not serialized"),null;let k;i.hasNode(e)?k=i.getId(e):Gl(O,u)||!I&&O.type===ne.Text&&!O.textContent.replace(/^\s+|\s+$/gm,"").length?k=it:k=Js();let x=Object.assign(O,{id:k});if(i.add(e,x),k===it)return null;S&&S(e);let Q=!a;if(x.type===ne.Element){Q=Q&&!x.needBlock,delete x.needBlock;let L=se.shadowRoot(e);L&&rt(L)&&(x.isShadowHost=true);}if((x.type===ne.Document||x.type===ne.Element)&&Q){u.headWhitespace&&x.type===ne.Element&&x.tagName==="head"&&(I=false);let L={doc:r,mirror:i,blockClass:n,blockSelector:o,needsMask:M,maskTextClass:l,maskTextSelector:d,skipChild:a,inlineStylesheet:h,maskInputOptions:s,maskTextFn:f,maskInputFn:c,slimDOMOptions:u,dataURLOptions:m,inlineImages:p,recordCanvas:g,preserveWhiteSpace:I,onSerialize:S,onIframeLoad:y,iframeLoadTimeout:b,onStylesheetLoad:E,stylesheetLoadTimeout:w,keepIframeSrcFn:v,cssCaptured:false};if(!(x.type===ne.Element&&x.tagName==="textarea"&&x.attributes.value!==void 0)){x.type===ne.Element&&x.attributes._cssText!==void 0&&typeof x.attributes._cssText=="string"&&(L.cssCaptured=true);for(let B of Array.from(se.childNodes(e))){let X=Ve(B,L);X&&x.childNodes.push(X);}}let A=null;if(Gs(e)&&(A=se.shadowRoot(e)))for(let B of Array.from(se.childNodes(A))){let X=Ve(B,L);X&&(rt(A)&&(X.isShadow=true),x.childNodes.push(X));}}let Y=se.parentNode(e);return Y&&tt(Y)&&rt(Y)&&(x.isShadow=true),x.type===ne.Element&&x.tagName==="iframe"&&zl(e,()=>{let L=e.contentDocument;if(L&&y){let A=Ve(L,{doc:L,mirror:i,blockClass:n,blockSelector:o,needsMask:M,maskTextClass:l,maskTextSelector:d,skipChild:false,inlineStylesheet:h,maskInputOptions:s,maskTextFn:f,maskInputFn:c,slimDOMOptions:u,dataURLOptions:m,inlineImages:p,recordCanvas:g,preserveWhiteSpace:I,onSerialize:S,onIframeLoad:y,iframeLoadTimeout:b,onStylesheetLoad:E,stylesheetLoadTimeout:w,keepIframeSrcFn:v});A&&y(e,A);}},b),x.type===ne.Element&&x.tagName==="link"&&typeof x.attributes.rel=="string"&&(x.attributes.rel==="stylesheet"||x.attributes.rel==="preload"&&typeof x.attributes.href=="string"&&Xs(x.attributes.href)==="css")&&$l(e,()=>{if(E){let L=Ve(e,{doc:r,mirror:i,blockClass:n,blockSelector:o,needsMask:M,maskTextClass:l,maskTextSelector:d,skipChild:false,inlineStylesheet:h,maskInputOptions:s,maskTextFn:f,maskInputFn:c,slimDOMOptions:u,dataURLOptions:m,inlineImages:p,recordCanvas:g,preserveWhiteSpace:I,onSerialize:S,onIframeLoad:y,iframeLoadTimeout:b,onStylesheetLoad:E,stylesheetLoadTimeout:w,keepIframeSrcFn:v});L&&E(e,L);}},w),x}function Yl(e,t){let{mirror:r=new Nt,blockClass:i="rr-block",blockSelector:n=null,maskTextClass:o="rr-mask",maskTextSelector:l=null,inlineStylesheet:d=true,inlineImages:a=false,recordCanvas:h=false,maskAllInputs:s=false,maskTextFn:f,maskInputFn:c,slimDOM:u=false,dataURLOptions:m,preserveWhiteSpace:p,onSerialize:g,onIframeLoad:S,iframeLoadTimeout:y,onStylesheetLoad:b,stylesheetLoadTimeout:E,keepIframeSrcFn:w=()=>false}=t,v=s===true?{color:true,date:true,"datetime-local":true,email:true,month:true,number:true,range:true,search:true,tel:true,text:true,time:true,url:true,week:true,textarea:true,select:true,password:true}:s===false?{password:true}:s,C=eo(u);return Ve(e,{doc:e,mirror:r,blockClass:i,blockSelector:n,maskTextClass:o,maskTextSelector:l,skipChild:false,inlineStylesheet:d,maskInputOptions:v,maskTextFn:f,maskInputFn:c,slimDOMOptions:C,dataURLOptions:m,inlineImages:a,recordCanvas:h,preserveWhiteSpace:p,onSerialize:g,onIframeLoad:S,iframeLoadTimeout:y,onStylesheetLoad:b,stylesheetLoadTimeout:E,keepIframeSrcFn:w,newlyAddedElement:false})}function Jl(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}function Kl(e){if(e.__esModule)return e;var t=e.default;if(typeof t=="function"){var r=function i(){return this instanceof i?Reflect.construct(t,arguments,this.constructor):t.apply(this,arguments)};r.prototype=t.prototype;}else r={};return Object.defineProperty(r,"__esModule",{value:true}),Object.keys(e).forEach(function(i){var n=Object.getOwnPropertyDescriptor(e,i);Object.defineProperty(r,i,n.get?n:{enumerable:true,get:function(){return e[i]}});}),r}var wt={exports:{}},Mi;function Zl(){if(Mi)return wt.exports;Mi=1;var e=String,t=function(){return {isColorSupported:false,reset:e,bold:e,dim:e,italic:e,underline:e,inverse:e,hidden:e,strikethrough:e,black:e,red:e,green:e,yellow:e,blue:e,magenta:e,cyan:e,white:e,gray:e,bgBlack:e,bgRed:e,bgGreen:e,bgYellow:e,bgBlue:e,bgMagenta:e,bgCyan:e,bgWhite:e}};return wt.exports=t(),wt.exports.createColors=t,wt.exports}var Ql={},eu=Object.freeze(Object.defineProperty({__proto__:null,default:Ql},Symbol.toStringTag,{value:"Module"})),Ce=Kl(eu),pr,Ni;function Ln(){if(Ni)return pr;Ni=1;let e=Zl(),t=Ce;class r extends Error{constructor(n,o,l,d,a,h){super(n),this.name="CssSyntaxError",this.reason=n,a&&(this.file=a),d&&(this.source=d),h&&(this.plugin=h),typeof o<"u"&&typeof l<"u"&&(typeof o=="number"?(this.line=o,this.column=l):(this.line=o.line,this.column=o.column,this.endLine=l.line,this.endColumn=l.column)),this.setMessage(),Error.captureStackTrace&&Error.captureStackTrace(this,r);}setMessage(){this.message=this.plugin?this.plugin+": ":"",this.message+=this.file?this.file:"<css input>",typeof this.line<"u"&&(this.message+=":"+this.line+":"+this.column),this.message+=": "+this.reason;}showSourceCode(n){if(!this.source)return "";let o=this.source;n==null&&(n=e.isColorSupported),t&&n&&(o=t(o));let l=o.split(/\r?\n/),d=Math.max(this.line-3,0),a=Math.min(this.line+2,l.length),h=String(a).length,s,f;if(n){let{bold:c,gray:u,red:m}=e.createColors(true);s=p=>c(m(p)),f=p=>u(p);}else s=f=c=>c;return l.slice(d,a).map((c,u)=>{let m=d+1+u,p=" "+(" "+m).slice(-h)+" | ";if(m===this.line){let g=f(p.replace(/\d/g," "))+c.slice(0,this.column-1).replace(/[^\t]/g," ");return s(">")+f(p)+c+`
2
+ `+g+s("^")}return " "+f(p)+c}).join(`
3
3
  `)}toString(){let n=this.showSourceCode();return n&&(n=`
4
4
 
5
5
  `+n+`
6
- `),this.name+": "+this.message+n}}return pr=r,r.default=r,pr}var bt={},Ni;function Pn(){return Ni||(Ni=1,bt.isClean=Symbol("isClean"),bt.my=Symbol("my")),bt}var mr,Ti;function eo(){if(Ti)return mr;Ti=1;let e={after:`
6
+ `),this.name+": "+this.message+n}}return pr=r,r.default=r,pr}var bt={},Ti;function Pn(){return Ti||(Ti=1,bt.isClean=Symbol("isClean"),bt.my=Symbol("my")),bt}var mr,ki;function to(){if(ki)return mr;ki=1;let e={after:`
7
7
  `,beforeClose:`
8
8
  `,beforeComment:`
9
9
  `,beforeDecl:`
10
10
  `,beforeOpen:" ",beforeRule:`
11
- `,colon:": ",commentLeft:" ",commentRight:" ",emptyBody:"",indent:" ",semicolon:false};function t(i){return i[0].toUpperCase()+i.slice(1)}class r{constructor(n){this.builder=n;}atrule(n,o){let l="@"+n.name,p=n.params?this.rawValue(n,"params"):"";if(typeof n.raws.afterName<"u"?l+=n.raws.afterName:p&&(l+=" "),n.nodes)this.block(n,l+p);else {let a=(n.raws.between||"")+(o?";":"");this.builder(l+p+a,n);}}beforeAfter(n,o){let l;n.type==="decl"?l=this.raw(n,null,"beforeDecl"):n.type==="comment"?l=this.raw(n,null,"beforeComment"):o==="before"?l=this.raw(n,null,"beforeRule"):l=this.raw(n,null,"beforeClose");let p=n.parent,a=0;for(;p&&p.type!=="root";)a+=1,p=p.parent;if(l.includes(`
12
- `)){let h=this.raw(n,null,"indent");if(h.length)for(let s=0;s<a;s++)l+=h;}return l}block(n,o){let l=this.raw(n,"between","beforeOpen");this.builder(o+l+"{",n,"start");let p;n.nodes&&n.nodes.length?(this.body(n),p=this.raw(n,"after")):p=this.raw(n,"after","emptyBody"),p&&this.builder(p),this.builder("}",n,"end");}body(n){let o=n.nodes.length-1;for(;o>0&&n.nodes[o].type==="comment";)o-=1;let l=this.raw(n,"semicolon");for(let p=0;p<n.nodes.length;p++){let a=n.nodes[p],h=this.raw(a,"before");h&&this.builder(h),this.stringify(a,o!==p||l);}}comment(n){let o=this.raw(n,"left","commentLeft"),l=this.raw(n,"right","commentRight");this.builder("/*"+o+n.text+l+"*/",n);}decl(n,o){let l=this.raw(n,"between","colon"),p=n.prop+l+this.rawValue(n,"value");n.important&&(p+=n.raws.important||" !important"),o&&(p+=";"),this.builder(p,n);}document(n){this.body(n);}raw(n,o,l){let p;if(l||(l=o),o&&(p=n.raws[o],typeof p<"u"))return p;let a=n.parent;if(l==="before"&&(!a||a.type==="root"&&a.first===n||a&&a.type==="document"))return "";if(!a)return e[l];let h=n.root();if(h.rawCache||(h.rawCache={}),typeof h.rawCache[l]<"u")return h.rawCache[l];if(l==="before"||l==="after")return this.beforeAfter(n,l);{let s="raw"+t(l);this[s]?p=this[s](h,n):h.walk(f=>{if(p=f.raws[o],typeof p<"u")return false});}return typeof p>"u"&&(p=e[l]),h.rawCache[l]=p,p}rawBeforeClose(n){let o;return n.walk(l=>{if(l.nodes&&l.nodes.length>0&&typeof l.raws.after<"u")return o=l.raws.after,o.includes(`
13
- `)&&(o=o.replace(/[^\n]+$/,"")),false}),o&&(o=o.replace(/\S/g,"")),o}rawBeforeComment(n,o){let l;return n.walkComments(p=>{if(typeof p.raws.before<"u")return l=p.raws.before,l.includes(`
14
- `)&&(l=l.replace(/[^\n]+$/,"")),false}),typeof l>"u"?l=this.raw(o,null,"beforeDecl"):l&&(l=l.replace(/\S/g,"")),l}rawBeforeDecl(n,o){let l;return n.walkDecls(p=>{if(typeof p.raws.before<"u")return l=p.raws.before,l.includes(`
11
+ `,colon:": ",commentLeft:" ",commentRight:" ",emptyBody:"",indent:" ",semicolon:false};function t(i){return i[0].toUpperCase()+i.slice(1)}class r{constructor(n){this.builder=n;}atrule(n,o){let l="@"+n.name,d=n.params?this.rawValue(n,"params"):"";if(typeof n.raws.afterName<"u"?l+=n.raws.afterName:d&&(l+=" "),n.nodes)this.block(n,l+d);else {let a=(n.raws.between||"")+(o?";":"");this.builder(l+d+a,n);}}beforeAfter(n,o){let l;n.type==="decl"?l=this.raw(n,null,"beforeDecl"):n.type==="comment"?l=this.raw(n,null,"beforeComment"):o==="before"?l=this.raw(n,null,"beforeRule"):l=this.raw(n,null,"beforeClose");let d=n.parent,a=0;for(;d&&d.type!=="root";)a+=1,d=d.parent;if(l.includes(`
12
+ `)){let h=this.raw(n,null,"indent");if(h.length)for(let s=0;s<a;s++)l+=h;}return l}block(n,o){let l=this.raw(n,"between","beforeOpen");this.builder(o+l+"{",n,"start");let d;n.nodes&&n.nodes.length?(this.body(n),d=this.raw(n,"after")):d=this.raw(n,"after","emptyBody"),d&&this.builder(d),this.builder("}",n,"end");}body(n){let o=n.nodes.length-1;for(;o>0&&n.nodes[o].type==="comment";)o-=1;let l=this.raw(n,"semicolon");for(let d=0;d<n.nodes.length;d++){let a=n.nodes[d],h=this.raw(a,"before");h&&this.builder(h),this.stringify(a,o!==d||l);}}comment(n){let o=this.raw(n,"left","commentLeft"),l=this.raw(n,"right","commentRight");this.builder("/*"+o+n.text+l+"*/",n);}decl(n,o){let l=this.raw(n,"between","colon"),d=n.prop+l+this.rawValue(n,"value");n.important&&(d+=n.raws.important||" !important"),o&&(d+=";"),this.builder(d,n);}document(n){this.body(n);}raw(n,o,l){let d;if(l||(l=o),o&&(d=n.raws[o],typeof d<"u"))return d;let a=n.parent;if(l==="before"&&(!a||a.type==="root"&&a.first===n||a&&a.type==="document"))return "";if(!a)return e[l];let h=n.root();if(h.rawCache||(h.rawCache={}),typeof h.rawCache[l]<"u")return h.rawCache[l];if(l==="before"||l==="after")return this.beforeAfter(n,l);{let s="raw"+t(l);this[s]?d=this[s](h,n):h.walk(f=>{if(d=f.raws[o],typeof d<"u")return false});}return typeof d>"u"&&(d=e[l]),h.rawCache[l]=d,d}rawBeforeClose(n){let o;return n.walk(l=>{if(l.nodes&&l.nodes.length>0&&typeof l.raws.after<"u")return o=l.raws.after,o.includes(`
13
+ `)&&(o=o.replace(/[^\n]+$/,"")),false}),o&&(o=o.replace(/\S/g,"")),o}rawBeforeComment(n,o){let l;return n.walkComments(d=>{if(typeof d.raws.before<"u")return l=d.raws.before,l.includes(`
14
+ `)&&(l=l.replace(/[^\n]+$/,"")),false}),typeof l>"u"?l=this.raw(o,null,"beforeDecl"):l&&(l=l.replace(/\S/g,"")),l}rawBeforeDecl(n,o){let l;return n.walkDecls(d=>{if(typeof d.raws.before<"u")return l=d.raws.before,l.includes(`
15
15
  `)&&(l=l.replace(/[^\n]+$/,"")),false}),typeof l>"u"?l=this.raw(o,null,"beforeRule"):l&&(l=l.replace(/\S/g,"")),l}rawBeforeOpen(n){let o;return n.walk(l=>{if(l.type!=="decl"&&(o=l.raws.between,typeof o<"u"))return false}),o}rawBeforeRule(n){let o;return n.walk(l=>{if(l.nodes&&(l.parent!==n||n.first!==l)&&typeof l.raws.before<"u")return o=l.raws.before,o.includes(`
16
- `)&&(o=o.replace(/[^\n]+$/,"")),false}),o&&(o=o.replace(/\S/g,"")),o}rawColon(n){let o;return n.walkDecls(l=>{if(typeof l.raws.between<"u")return o=l.raws.between.replace(/[^\s:]/g,""),false}),o}rawEmptyBody(n){let o;return n.walk(l=>{if(l.nodes&&l.nodes.length===0&&(o=l.raws.after,typeof o<"u"))return false}),o}rawIndent(n){if(n.raws.indent)return n.raws.indent;let o;return n.walk(l=>{let p=l.parent;if(p&&p!==n&&p.parent&&p.parent===n&&typeof l.raws.before<"u"){let a=l.raws.before.split(`
17
- `);return o=a[a.length-1],o=o.replace(/\S/g,""),false}}),o}rawSemicolon(n){let o;return n.walk(l=>{if(l.nodes&&l.nodes.length&&l.last.type==="decl"&&(o=l.raws.semicolon,typeof o<"u"))return false}),o}rawValue(n,o){let l=n[o],p=n.raws[o];return p&&p.value===l?p.raw:l}root(n){this.body(n),n.raws.after&&this.builder(n.raws.after);}rule(n){this.block(n,this.rawValue(n,"selector")),n.raws.ownSemicolon&&this.builder(n.raws.ownSemicolon,n,"end");}stringify(n,o){if(!this[n.type])throw new Error("Unknown AST node type "+n.type+". Maybe you need to change PostCSS stringifier.");this[n.type](n,o);}}return mr=r,r.default=r,mr}var gr,ki;function _t(){if(ki)return gr;ki=1;let e=eo();function t(r,i){new e(i).stringify(r);}return gr=t,t.default=t,gr}var yr,Ai;function Ft(){if(Ai)return yr;Ai=1;let{isClean:e,my:t}=Pn(),r=Ln(),i=eo(),n=_t();function o(p,a){let h=new p.constructor;for(let s in p){if(!Object.prototype.hasOwnProperty.call(p,s)||s==="proxyCache")continue;let f=p[s],c=typeof f;s==="parent"&&c==="object"?a&&(h[s]=a):s==="source"?h[s]=f:Array.isArray(f)?h[s]=f.map(u=>o(u,h)):(c==="object"&&f!==null&&(f=o(f)),h[s]=f);}return h}class l{constructor(a={}){this.raws={},this[e]=false,this[t]=true;for(let h in a)if(h==="nodes"){this.nodes=[];for(let s of a[h])typeof s.clone=="function"?this.append(s.clone()):this.append(s);}else this[h]=a[h];}addToError(a){if(a.postcssNode=this,a.stack&&this.source&&/\n\s{4}at /.test(a.stack)){let h=this.source;a.stack=a.stack.replace(/\n\s{4}at /,`$&${h.input.from}:${h.start.line}:${h.start.column}$&`);}return a}after(a){return this.parent.insertAfter(this,a),this}assign(a={}){for(let h in a)this[h]=a[h];return this}before(a){return this.parent.insertBefore(this,a),this}cleanRaws(a){delete this.raws.before,delete this.raws.after,a||delete this.raws.between;}clone(a={}){let h=o(this);for(let s in a)h[s]=a[s];return h}cloneAfter(a={}){let h=this.clone(a);return this.parent.insertAfter(this,h),h}cloneBefore(a={}){let h=this.clone(a);return this.parent.insertBefore(this,h),h}error(a,h={}){if(this.source){let{end:s,start:f}=this.rangeBy(h);return this.source.input.error(a,{column:f.column,line:f.line},{column:s.column,line:s.line},h)}return new r(a)}getProxyProcessor(){return {get(a,h){return h==="proxyOf"?a:h==="root"?()=>a.root().toProxy():a[h]},set(a,h,s){return a[h]===s||(a[h]=s,(h==="prop"||h==="value"||h==="name"||h==="params"||h==="important"||h==="text")&&a.markDirty()),true}}}markDirty(){if(this[e]){this[e]=false;let a=this;for(;a=a.parent;)a[e]=false;}}next(){if(!this.parent)return;let a=this.parent.index(this);return this.parent.nodes[a+1]}positionBy(a,h){let s=this.source.start;if(a.index)s=this.positionInside(a.index,h);else if(a.word){h=this.toString();let f=h.indexOf(a.word);f!==-1&&(s=this.positionInside(f,h));}return s}positionInside(a,h){let s=h||this.toString(),f=this.source.start.column,c=this.source.start.line;for(let u=0;u<a;u++)s[u]===`
18
- `?(f=1,c+=1):f+=1;return {column:f,line:c}}prev(){if(!this.parent)return;let a=this.parent.index(this);return this.parent.nodes[a-1]}rangeBy(a){let h={column:this.source.start.column,line:this.source.start.line},s=this.source.end?{column:this.source.end.column+1,line:this.source.end.line}:{column:h.column+1,line:h.line};if(a.word){let f=this.toString(),c=f.indexOf(a.word);c!==-1&&(h=this.positionInside(c,f),s=this.positionInside(c+a.word.length,f));}else a.start?h={column:a.start.column,line:a.start.line}:a.index&&(h=this.positionInside(a.index)),a.end?s={column:a.end.column,line:a.end.line}:typeof a.endIndex=="number"?s=this.positionInside(a.endIndex):a.index&&(s=this.positionInside(a.index+1));return (s.line<h.line||s.line===h.line&&s.column<=h.column)&&(s={column:h.column+1,line:h.line}),{end:s,start:h}}raw(a,h){return new i().raw(this,a,h)}remove(){return this.parent&&this.parent.removeChild(this),this.parent=void 0,this}replaceWith(...a){if(this.parent){let h=this,s=false;for(let f of a)f===this?s=true:s?(this.parent.insertAfter(h,f),h=f):this.parent.insertBefore(h,f);s||this.remove();}return this}root(){let a=this;for(;a.parent&&a.parent.type!=="document";)a=a.parent;return a}toJSON(a,h){let s={},f=h==null;h=h||new Map;let c=0;for(let u in this){if(!Object.prototype.hasOwnProperty.call(this,u)||u==="parent"||u==="proxyCache")continue;let m=this[u];if(Array.isArray(m))s[u]=m.map(d=>typeof d=="object"&&d.toJSON?d.toJSON(null,h):d);else if(typeof m=="object"&&m.toJSON)s[u]=m.toJSON(null,h);else if(u==="source"){let d=h.get(m.input);d==null&&(d=c,h.set(m.input,c),c++),s[u]={end:m.end,inputId:d,start:m.start};}else s[u]=m;}return f&&(s.inputs=[...h.keys()].map(u=>u.toJSON())),s}toProxy(){return this.proxyCache||(this.proxyCache=new Proxy(this,this.getProxyProcessor())),this.proxyCache}toString(a=n){a.stringify&&(a=a.stringify);let h="";return a(this,s=>{h+=s;}),h}warn(a,h,s){let f={node:this};for(let c in s)f[c]=s[c];return a.warn(h,f)}get proxyOf(){return this}}return yr=l,l.default=l,yr}var vr,Oi;function Ut(){if(Oi)return vr;Oi=1;let e=Ft();class t extends e{constructor(i){i&&typeof i.value<"u"&&typeof i.value!="string"&&(i={...i,value:String(i.value)}),super(i),this.type="decl";}get variable(){return this.prop.startsWith("--")||this.prop[0]==="$"}}return vr=t,t.default=t,vr}var wr,Di;function eu(){if(Di)return wr;Di=1;let e="useandom-26T198340PX75pxJACKVERYMINDBUSHWOLF_GQZbfghjklqvwyzrict";return wr={nanoid:(i=21)=>{let n="",o=i;for(;o--;)n+=e[Math.random()*64|0];return n},customAlphabet:(i,n=21)=>(o=n)=>{let l="",p=o;for(;p--;)l+=i[Math.random()*i.length|0];return l}},wr}var br,Li;function to(){if(Li)return br;Li=1;let{SourceMapConsumer:e,SourceMapGenerator:t}=Ce,{existsSync:r,readFileSync:i}=Ce,{dirname:n,join:o}=Ce;function l(a){return Buffer?Buffer.from(a,"base64").toString():window.atob(a)}class p{constructor(h,s){if(s.map===false)return;this.loadAnnotation(h),this.inline=this.startWith(this.annotation,"data:");let f=s.map?s.map.prev:void 0,c=this.loadMap(s.from,f);!this.mapFile&&s.from&&(this.mapFile=s.from),this.mapFile&&(this.root=n(this.mapFile)),c&&(this.text=c);}consumer(){return this.consumerCache||(this.consumerCache=new e(this.text)),this.consumerCache}decodeInline(h){let s=/^data:application\/json;charset=utf-?8;base64,/,f=/^data:application\/json;base64,/,c=/^data:application\/json;charset=utf-?8,/,u=/^data:application\/json,/;if(c.test(h)||u.test(h))return decodeURIComponent(h.substr(RegExp.lastMatch.length));if(s.test(h)||f.test(h))return l(h.substr(RegExp.lastMatch.length));let m=h.match(/data:application\/json;([^,]+),/)[1];throw new Error("Unsupported source map encoding "+m)}getAnnotationURL(h){return h.replace(/^\/\*\s*# sourceMappingURL=/,"").trim()}isMap(h){return typeof h!="object"?false:typeof h.mappings=="string"||typeof h._mappings=="string"||Array.isArray(h.sections)}loadAnnotation(h){let s=h.match(/\/\*\s*# sourceMappingURL=/gm);if(!s)return;let f=h.lastIndexOf(s.pop()),c=h.indexOf("*/",f);f>-1&&c>-1&&(this.annotation=this.getAnnotationURL(h.substring(f,c)));}loadFile(h){if(this.root=n(h),r(h))return this.mapFile=h,i(h,"utf-8").toString().trim()}loadMap(h,s){if(s===false)return false;if(s){if(typeof s=="string")return s;if(typeof s=="function"){let f=s(h);if(f){let c=this.loadFile(f);if(!c)throw new Error("Unable to load previous source map: "+f.toString());return c}}else {if(s instanceof e)return t.fromSourceMap(s).toString();if(s instanceof t)return s.toString();if(this.isMap(s))return JSON.stringify(s);throw new Error("Unsupported previous source map format: "+s.toString())}}else {if(this.inline)return this.decodeInline(this.annotation);if(this.annotation){let f=this.annotation;return h&&(f=o(n(h),f)),this.loadFile(f)}}}startWith(h,s){return h?h.substr(0,s.length)===s:false}withContent(){return !!(this.consumer().sourcesContent&&this.consumer().sourcesContent.length>0)}}return br=p,p.default=p,br}var Sr,Pi;function Bt(){if(Pi)return Sr;Pi=1;let{SourceMapConsumer:e,SourceMapGenerator:t}=Ce,{fileURLToPath:r,pathToFileURL:i}=Ce,{isAbsolute:n,resolve:o}=Ce,{nanoid:l}=eu(),p=Ce,a=Ln(),h=to(),s=Symbol("fromOffsetCache"),f=!!(e&&t),c=!!(o&&n);class u{constructor(d,g={}){if(d===null||typeof d>"u"||typeof d=="object"&&!d.toString)throw new Error(`PostCSS received ${d} instead of CSS string`);if(this.css=d.toString(),this.css[0]==="\uFEFF"||this.css[0]==="\uFFFE"?(this.hasBOM=true,this.css=this.css.slice(1)):this.hasBOM=false,g.from&&(!c||/^\w+:\/\//.test(g.from)||n(g.from)?this.file=g.from:this.file=o(g.from)),c&&f){let S=new h(this.css,g);if(S.text){this.map=S;let y=S.consumer().file;!this.file&&y&&(this.file=this.mapResolve(y));}}this.file||(this.id="<input css "+l(6)+">"),this.map&&(this.map.file=this.from);}error(d,g,S,y={}){let b,E,w;if(g&&typeof g=="object"){let C=g,R=S;if(typeof C.offset=="number"){let I=this.fromOffset(C.offset);g=I.line,S=I.col;}else g=C.line,S=C.column;if(typeof R.offset=="number"){let I=this.fromOffset(R.offset);E=I.line,w=I.col;}else E=R.line,w=R.column;}else if(!S){let C=this.fromOffset(g);g=C.line,S=C.col;}let v=this.origin(g,S,E,w);return v?b=new a(d,v.endLine===void 0?v.line:{column:v.column,line:v.line},v.endLine===void 0?v.column:{column:v.endColumn,line:v.endLine},v.source,v.file,y.plugin):b=new a(d,E===void 0?g:{column:S,line:g},E===void 0?S:{column:w,line:E},this.css,this.file,y.plugin),b.input={column:S,endColumn:w,endLine:E,line:g,source:this.css},this.file&&(i&&(b.input.url=i(this.file).toString()),b.input.file=this.file),b}fromOffset(d){let g,S;if(this[s])S=this[s];else {let b=this.css.split(`
19
- `);S=new Array(b.length);let E=0;for(let w=0,v=b.length;w<v;w++)S[w]=E,E+=b[w].length+1;this[s]=S;}g=S[S.length-1];let y=0;if(d>=g)y=S.length-1;else {let b=S.length-2,E;for(;y<b;)if(E=y+(b-y>>1),d<S[E])b=E-1;else if(d>=S[E+1])y=E+1;else {y=E;break}}return {col:d-S[y]+1,line:y+1}}mapResolve(d){return /^\w+:\/\//.test(d)?d:o(this.map.consumer().sourceRoot||this.map.root||".",d)}origin(d,g,S,y){if(!this.map)return false;let b=this.map.consumer(),E=b.originalPositionFor({column:g,line:d});if(!E.source)return false;let w;typeof S=="number"&&(w=b.originalPositionFor({column:y,line:S}));let v;n(E.source)?v=i(E.source):v=new URL(E.source,this.map.consumer().sourceRoot||i(this.map.mapFile));let C={column:E.column,endColumn:w&&w.column,endLine:w&&w.line,line:E.line,url:v.toString()};if(v.protocol==="file:")if(r)C.file=r(v);else throw new Error("file: protocol is not available in this PostCSS build");let R=b.sourceContentFor(E.source);return R&&(C.source=R),C}toJSON(){let d={};for(let g of ["hasBOM","css","file","id"])this[g]!=null&&(d[g]=this[g]);return this.map&&(d.map={...this.map},d.map.consumerCache&&(d.map.consumerCache=void 0)),d}get from(){return this.file||this.id}}return Sr=u,u.default=u,p&&p.registerInput&&p.registerInput(u),Sr}var Cr,_i;function ro(){if(_i)return Cr;_i=1;let{SourceMapConsumer:e,SourceMapGenerator:t}=Ce,{dirname:r,relative:i,resolve:n,sep:o}=Ce,{pathToFileURL:l}=Ce,p=Bt(),a=!!(e&&t),h=!!(r&&n&&i&&o);class s{constructor(c,u,m,d){this.stringify=c,this.mapOpts=m.map||{},this.root=u,this.opts=m,this.css=d,this.originalCSS=d,this.usesFileUrls=!this.mapOpts.from&&this.mapOpts.absolute,this.memoizedFileURLs=new Map,this.memoizedPaths=new Map,this.memoizedURLs=new Map;}addAnnotation(){let c;this.isInline()?c="data:application/json;base64,"+this.toBase64(this.map.toString()):typeof this.mapOpts.annotation=="string"?c=this.mapOpts.annotation:typeof this.mapOpts.annotation=="function"?c=this.mapOpts.annotation(this.opts.to,this.root):c=this.outputFile()+".map";let u=`
16
+ `)&&(o=o.replace(/[^\n]+$/,"")),false}),o&&(o=o.replace(/\S/g,"")),o}rawColon(n){let o;return n.walkDecls(l=>{if(typeof l.raws.between<"u")return o=l.raws.between.replace(/[^\s:]/g,""),false}),o}rawEmptyBody(n){let o;return n.walk(l=>{if(l.nodes&&l.nodes.length===0&&(o=l.raws.after,typeof o<"u"))return false}),o}rawIndent(n){if(n.raws.indent)return n.raws.indent;let o;return n.walk(l=>{let d=l.parent;if(d&&d!==n&&d.parent&&d.parent===n&&typeof l.raws.before<"u"){let a=l.raws.before.split(`
17
+ `);return o=a[a.length-1],o=o.replace(/\S/g,""),false}}),o}rawSemicolon(n){let o;return n.walk(l=>{if(l.nodes&&l.nodes.length&&l.last.type==="decl"&&(o=l.raws.semicolon,typeof o<"u"))return false}),o}rawValue(n,o){let l=n[o],d=n.raws[o];return d&&d.value===l?d.raw:l}root(n){this.body(n),n.raws.after&&this.builder(n.raws.after);}rule(n){this.block(n,this.rawValue(n,"selector")),n.raws.ownSemicolon&&this.builder(n.raws.ownSemicolon,n,"end");}stringify(n,o){if(!this[n.type])throw new Error("Unknown AST node type "+n.type+". Maybe you need to change PostCSS stringifier.");this[n.type](n,o);}}return mr=r,r.default=r,mr}var gr,Ai;function _t(){if(Ai)return gr;Ai=1;let e=to();function t(r,i){new e(i).stringify(r);}return gr=t,t.default=t,gr}var yr,Oi;function Ft(){if(Oi)return yr;Oi=1;let{isClean:e,my:t}=Pn(),r=Ln(),i=to(),n=_t();function o(d,a){let h=new d.constructor;for(let s in d){if(!Object.prototype.hasOwnProperty.call(d,s)||s==="proxyCache")continue;let f=d[s],c=typeof f;s==="parent"&&c==="object"?a&&(h[s]=a):s==="source"?h[s]=f:Array.isArray(f)?h[s]=f.map(u=>o(u,h)):(c==="object"&&f!==null&&(f=o(f)),h[s]=f);}return h}class l{constructor(a={}){this.raws={},this[e]=false,this[t]=true;for(let h in a)if(h==="nodes"){this.nodes=[];for(let s of a[h])typeof s.clone=="function"?this.append(s.clone()):this.append(s);}else this[h]=a[h];}addToError(a){if(a.postcssNode=this,a.stack&&this.source&&/\n\s{4}at /.test(a.stack)){let h=this.source;a.stack=a.stack.replace(/\n\s{4}at /,`$&${h.input.from}:${h.start.line}:${h.start.column}$&`);}return a}after(a){return this.parent.insertAfter(this,a),this}assign(a={}){for(let h in a)this[h]=a[h];return this}before(a){return this.parent.insertBefore(this,a),this}cleanRaws(a){delete this.raws.before,delete this.raws.after,a||delete this.raws.between;}clone(a={}){let h=o(this);for(let s in a)h[s]=a[s];return h}cloneAfter(a={}){let h=this.clone(a);return this.parent.insertAfter(this,h),h}cloneBefore(a={}){let h=this.clone(a);return this.parent.insertBefore(this,h),h}error(a,h={}){if(this.source){let{end:s,start:f}=this.rangeBy(h);return this.source.input.error(a,{column:f.column,line:f.line},{column:s.column,line:s.line},h)}return new r(a)}getProxyProcessor(){return {get(a,h){return h==="proxyOf"?a:h==="root"?()=>a.root().toProxy():a[h]},set(a,h,s){return a[h]===s||(a[h]=s,(h==="prop"||h==="value"||h==="name"||h==="params"||h==="important"||h==="text")&&a.markDirty()),true}}}markDirty(){if(this[e]){this[e]=false;let a=this;for(;a=a.parent;)a[e]=false;}}next(){if(!this.parent)return;let a=this.parent.index(this);return this.parent.nodes[a+1]}positionBy(a,h){let s=this.source.start;if(a.index)s=this.positionInside(a.index,h);else if(a.word){h=this.toString();let f=h.indexOf(a.word);f!==-1&&(s=this.positionInside(f,h));}return s}positionInside(a,h){let s=h||this.toString(),f=this.source.start.column,c=this.source.start.line;for(let u=0;u<a;u++)s[u]===`
18
+ `?(f=1,c+=1):f+=1;return {column:f,line:c}}prev(){if(!this.parent)return;let a=this.parent.index(this);return this.parent.nodes[a-1]}rangeBy(a){let h={column:this.source.start.column,line:this.source.start.line},s=this.source.end?{column:this.source.end.column+1,line:this.source.end.line}:{column:h.column+1,line:h.line};if(a.word){let f=this.toString(),c=f.indexOf(a.word);c!==-1&&(h=this.positionInside(c,f),s=this.positionInside(c+a.word.length,f));}else a.start?h={column:a.start.column,line:a.start.line}:a.index&&(h=this.positionInside(a.index)),a.end?s={column:a.end.column,line:a.end.line}:typeof a.endIndex=="number"?s=this.positionInside(a.endIndex):a.index&&(s=this.positionInside(a.index+1));return (s.line<h.line||s.line===h.line&&s.column<=h.column)&&(s={column:h.column+1,line:h.line}),{end:s,start:h}}raw(a,h){return new i().raw(this,a,h)}remove(){return this.parent&&this.parent.removeChild(this),this.parent=void 0,this}replaceWith(...a){if(this.parent){let h=this,s=false;for(let f of a)f===this?s=true:s?(this.parent.insertAfter(h,f),h=f):this.parent.insertBefore(h,f);s||this.remove();}return this}root(){let a=this;for(;a.parent&&a.parent.type!=="document";)a=a.parent;return a}toJSON(a,h){let s={},f=h==null;h=h||new Map;let c=0;for(let u in this){if(!Object.prototype.hasOwnProperty.call(this,u)||u==="parent"||u==="proxyCache")continue;let m=this[u];if(Array.isArray(m))s[u]=m.map(p=>typeof p=="object"&&p.toJSON?p.toJSON(null,h):p);else if(typeof m=="object"&&m.toJSON)s[u]=m.toJSON(null,h);else if(u==="source"){let p=h.get(m.input);p==null&&(p=c,h.set(m.input,c),c++),s[u]={end:m.end,inputId:p,start:m.start};}else s[u]=m;}return f&&(s.inputs=[...h.keys()].map(u=>u.toJSON())),s}toProxy(){return this.proxyCache||(this.proxyCache=new Proxy(this,this.getProxyProcessor())),this.proxyCache}toString(a=n){a.stringify&&(a=a.stringify);let h="";return a(this,s=>{h+=s;}),h}warn(a,h,s){let f={node:this};for(let c in s)f[c]=s[c];return a.warn(h,f)}get proxyOf(){return this}}return yr=l,l.default=l,yr}var vr,Di;function Ut(){if(Di)return vr;Di=1;let e=Ft();class t extends e{constructor(i){i&&typeof i.value<"u"&&typeof i.value!="string"&&(i={...i,value:String(i.value)}),super(i),this.type="decl";}get variable(){return this.prop.startsWith("--")||this.prop[0]==="$"}}return vr=t,t.default=t,vr}var wr,Li;function tu(){if(Li)return wr;Li=1;let e="useandom-26T198340PX75pxJACKVERYMINDBUSHWOLF_GQZbfghjklqvwyzrict";return wr={nanoid:(i=21)=>{let n="",o=i;for(;o--;)n+=e[Math.random()*64|0];return n},customAlphabet:(i,n=21)=>(o=n)=>{let l="",d=o;for(;d--;)l+=i[Math.random()*i.length|0];return l}},wr}var br,Pi;function ro(){if(Pi)return br;Pi=1;let{SourceMapConsumer:e,SourceMapGenerator:t}=Ce,{existsSync:r,readFileSync:i}=Ce,{dirname:n,join:o}=Ce;function l(a){return Buffer?Buffer.from(a,"base64").toString():window.atob(a)}class d{constructor(h,s){if(s.map===false)return;this.loadAnnotation(h),this.inline=this.startWith(this.annotation,"data:");let f=s.map?s.map.prev:void 0,c=this.loadMap(s.from,f);!this.mapFile&&s.from&&(this.mapFile=s.from),this.mapFile&&(this.root=n(this.mapFile)),c&&(this.text=c);}consumer(){return this.consumerCache||(this.consumerCache=new e(this.text)),this.consumerCache}decodeInline(h){let s=/^data:application\/json;charset=utf-?8;base64,/,f=/^data:application\/json;base64,/,c=/^data:application\/json;charset=utf-?8,/,u=/^data:application\/json,/;if(c.test(h)||u.test(h))return decodeURIComponent(h.substr(RegExp.lastMatch.length));if(s.test(h)||f.test(h))return l(h.substr(RegExp.lastMatch.length));let m=h.match(/data:application\/json;([^,]+),/)[1];throw new Error("Unsupported source map encoding "+m)}getAnnotationURL(h){return h.replace(/^\/\*\s*# sourceMappingURL=/,"").trim()}isMap(h){return typeof h!="object"?false:typeof h.mappings=="string"||typeof h._mappings=="string"||Array.isArray(h.sections)}loadAnnotation(h){let s=h.match(/\/\*\s*# sourceMappingURL=/gm);if(!s)return;let f=h.lastIndexOf(s.pop()),c=h.indexOf("*/",f);f>-1&&c>-1&&(this.annotation=this.getAnnotationURL(h.substring(f,c)));}loadFile(h){if(this.root=n(h),r(h))return this.mapFile=h,i(h,"utf-8").toString().trim()}loadMap(h,s){if(s===false)return false;if(s){if(typeof s=="string")return s;if(typeof s=="function"){let f=s(h);if(f){let c=this.loadFile(f);if(!c)throw new Error("Unable to load previous source map: "+f.toString());return c}}else {if(s instanceof e)return t.fromSourceMap(s).toString();if(s instanceof t)return s.toString();if(this.isMap(s))return JSON.stringify(s);throw new Error("Unsupported previous source map format: "+s.toString())}}else {if(this.inline)return this.decodeInline(this.annotation);if(this.annotation){let f=this.annotation;return h&&(f=o(n(h),f)),this.loadFile(f)}}}startWith(h,s){return h?h.substr(0,s.length)===s:false}withContent(){return !!(this.consumer().sourcesContent&&this.consumer().sourcesContent.length>0)}}return br=d,d.default=d,br}var Sr,_i;function Bt(){if(_i)return Sr;_i=1;let{SourceMapConsumer:e,SourceMapGenerator:t}=Ce,{fileURLToPath:r,pathToFileURL:i}=Ce,{isAbsolute:n,resolve:o}=Ce,{nanoid:l}=tu(),d=Ce,a=Ln(),h=ro(),s=Symbol("fromOffsetCache"),f=!!(e&&t),c=!!(o&&n);class u{constructor(p,g={}){if(p===null||typeof p>"u"||typeof p=="object"&&!p.toString)throw new Error(`PostCSS received ${p} instead of CSS string`);if(this.css=p.toString(),this.css[0]==="\uFEFF"||this.css[0]==="\uFFFE"?(this.hasBOM=true,this.css=this.css.slice(1)):this.hasBOM=false,g.from&&(!c||/^\w+:\/\//.test(g.from)||n(g.from)?this.file=g.from:this.file=o(g.from)),c&&f){let S=new h(this.css,g);if(S.text){this.map=S;let y=S.consumer().file;!this.file&&y&&(this.file=this.mapResolve(y));}}this.file||(this.id="<input css "+l(6)+">"),this.map&&(this.map.file=this.from);}error(p,g,S,y={}){let b,E,w;if(g&&typeof g=="object"){let C=g,R=S;if(typeof C.offset=="number"){let M=this.fromOffset(C.offset);g=M.line,S=M.col;}else g=C.line,S=C.column;if(typeof R.offset=="number"){let M=this.fromOffset(R.offset);E=M.line,w=M.col;}else E=R.line,w=R.column;}else if(!S){let C=this.fromOffset(g);g=C.line,S=C.col;}let v=this.origin(g,S,E,w);return v?b=new a(p,v.endLine===void 0?v.line:{column:v.column,line:v.line},v.endLine===void 0?v.column:{column:v.endColumn,line:v.endLine},v.source,v.file,y.plugin):b=new a(p,E===void 0?g:{column:S,line:g},E===void 0?S:{column:w,line:E},this.css,this.file,y.plugin),b.input={column:S,endColumn:w,endLine:E,line:g,source:this.css},this.file&&(i&&(b.input.url=i(this.file).toString()),b.input.file=this.file),b}fromOffset(p){let g,S;if(this[s])S=this[s];else {let b=this.css.split(`
19
+ `);S=new Array(b.length);let E=0;for(let w=0,v=b.length;w<v;w++)S[w]=E,E+=b[w].length+1;this[s]=S;}g=S[S.length-1];let y=0;if(p>=g)y=S.length-1;else {let b=S.length-2,E;for(;y<b;)if(E=y+(b-y>>1),p<S[E])b=E-1;else if(p>=S[E+1])y=E+1;else {y=E;break}}return {col:p-S[y]+1,line:y+1}}mapResolve(p){return /^\w+:\/\//.test(p)?p:o(this.map.consumer().sourceRoot||this.map.root||".",p)}origin(p,g,S,y){if(!this.map)return false;let b=this.map.consumer(),E=b.originalPositionFor({column:g,line:p});if(!E.source)return false;let w;typeof S=="number"&&(w=b.originalPositionFor({column:y,line:S}));let v;n(E.source)?v=i(E.source):v=new URL(E.source,this.map.consumer().sourceRoot||i(this.map.mapFile));let C={column:E.column,endColumn:w&&w.column,endLine:w&&w.line,line:E.line,url:v.toString()};if(v.protocol==="file:")if(r)C.file=r(v);else throw new Error("file: protocol is not available in this PostCSS build");let R=b.sourceContentFor(E.source);return R&&(C.source=R),C}toJSON(){let p={};for(let g of ["hasBOM","css","file","id"])this[g]!=null&&(p[g]=this[g]);return this.map&&(p.map={...this.map},p.map.consumerCache&&(p.map.consumerCache=void 0)),p}get from(){return this.file||this.id}}return Sr=u,u.default=u,d&&d.registerInput&&d.registerInput(u),Sr}var Cr,Fi;function no(){if(Fi)return Cr;Fi=1;let{SourceMapConsumer:e,SourceMapGenerator:t}=Ce,{dirname:r,relative:i,resolve:n,sep:o}=Ce,{pathToFileURL:l}=Ce,d=Bt(),a=!!(e&&t),h=!!(r&&n&&i&&o);class s{constructor(c,u,m,p){this.stringify=c,this.mapOpts=m.map||{},this.root=u,this.opts=m,this.css=p,this.originalCSS=p,this.usesFileUrls=!this.mapOpts.from&&this.mapOpts.absolute,this.memoizedFileURLs=new Map,this.memoizedPaths=new Map,this.memoizedURLs=new Map;}addAnnotation(){let c;this.isInline()?c="data:application/json;base64,"+this.toBase64(this.map.toString()):typeof this.mapOpts.annotation=="string"?c=this.mapOpts.annotation:typeof this.mapOpts.annotation=="function"?c=this.mapOpts.annotation(this.opts.to,this.root):c=this.outputFile()+".map";let u=`
20
20
  `;this.css.includes(`\r
21
21
  `)&&(u=`\r
22
- `),this.css+=u+"/*# sourceMappingURL="+c+" */";}applyPrevMaps(){for(let c of this.previous()){let u=this.toUrl(this.path(c.file)),m=c.root||r(c.file),d;this.mapOpts.sourcesContent===false?(d=new e(c.text),d.sourcesContent&&(d.sourcesContent=null)):d=c.consumer(),this.map.applySourceMap(d,u,this.toUrl(this.path(m)));}}clearAnnotation(){if(this.mapOpts.annotation!==false)if(this.root){let c;for(let u=this.root.nodes.length-1;u>=0;u--)c=this.root.nodes[u],c.type==="comment"&&c.text.indexOf("# sourceMappingURL=")===0&&this.root.removeChild(u);}else this.css&&(this.css=this.css.replace(/\n*?\/\*#[\S\s]*?\*\/$/gm,""));}generate(){if(this.clearAnnotation(),h&&a&&this.isMap())return this.generateMap();{let c="";return this.stringify(this.root,u=>{c+=u;}),[c]}}generateMap(){if(this.root)this.generateString();else if(this.previous().length===1){let c=this.previous()[0].consumer();c.file=this.outputFile(),this.map=t.fromSourceMap(c,{ignoreInvalidMapping:true});}else this.map=new t({file:this.outputFile(),ignoreInvalidMapping:true}),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 t({file:this.outputFile(),ignoreInvalidMapping:true});let c=1,u=1,m="<no source>",d={generated:{column:0,line:0},original:{column:0,line:0},source:""},g,S;this.stringify(this.root,(y,b,E)=>{if(this.css+=y,b&&E!=="end"&&(d.generated.line=c,d.generated.column=u-1,b.source&&b.source.start?(d.source=this.sourcePath(b),d.original.line=b.source.start.line,d.original.column=b.source.start.column-1,this.map.addMapping(d)):(d.source=m,d.original.line=1,d.original.column=0,this.map.addMapping(d))),g=y.match(/\n/g),g?(c+=g.length,S=y.lastIndexOf(`
23
- `),u=y.length-S):u+=y.length,b&&E!=="start"){let w=b.parent||{raws:{}};(!(b.type==="decl"||b.type==="atrule"&&!b.nodes)||b!==w.last||w.raws.semicolon)&&(b.source&&b.source.end?(d.source=this.sourcePath(b),d.original.line=b.source.end.line,d.original.column=b.source.end.column-1,d.generated.line=c,d.generated.column=u-2,this.map.addMapping(d)):(d.source=m,d.original.line=1,d.original.column=0,d.generated.line=c,d.generated.column=u-1,this.map.addMapping(d)));}});}isAnnotation(){return this.isInline()?true:typeof this.mapOpts.annotation<"u"?this.mapOpts.annotation:this.previous().length?this.previous().some(c=>c.annotation):true}isInline(){if(typeof this.mapOpts.inline<"u")return this.mapOpts.inline;let c=this.mapOpts.annotation;return typeof c<"u"&&c!==true?false:this.previous().length?this.previous().some(u=>u.inline):true}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(c=>c.withContent()):true}outputFile(){return this.opts.to?this.path(this.opts.to):this.opts.from?this.path(this.opts.from):"to.css"}path(c){if(this.mapOpts.absolute||c.charCodeAt(0)===60||/^\w+:\/\//.test(c))return c;let u=this.memoizedPaths.get(c);if(u)return u;let m=this.opts.to?r(this.opts.to):".";typeof this.mapOpts.annotation=="string"&&(m=r(n(m,this.mapOpts.annotation)));let d=i(m,c);return this.memoizedPaths.set(c,d),d}previous(){if(!this.previousMaps)if(this.previousMaps=[],this.root)this.root.walk(c=>{if(c.source&&c.source.input.map){let u=c.source.input.map;this.previousMaps.includes(u)||this.previousMaps.push(u);}});else {let c=new p(this.originalCSS,this.opts);c.map&&this.previousMaps.push(c.map);}return this.previousMaps}setSourcesContent(){let c={};if(this.root)this.root.walk(u=>{if(u.source){let m=u.source.input.from;if(m&&!c[m]){c[m]=true;let d=this.usesFileUrls?this.toFileUrl(m):this.toUrl(this.path(m));this.map.setSourceContent(d,u.source.input.css);}}});else if(this.css){let u=this.opts.from?this.toUrl(this.path(this.opts.from)):"<no source>";this.map.setSourceContent(u,this.css);}}sourcePath(c){return this.mapOpts.from?this.toUrl(this.mapOpts.from):this.usesFileUrls?this.toFileUrl(c.source.input.from):this.toUrl(this.path(c.source.input.from))}toBase64(c){return Buffer?Buffer.from(c).toString("base64"):window.btoa(unescape(encodeURIComponent(c)))}toFileUrl(c){let u=this.memoizedFileURLs.get(c);if(u)return u;if(l){let m=l(c).toString();return this.memoizedFileURLs.set(c,m),m}else throw new Error("`map.absolute` option is not available in this PostCSS build")}toUrl(c){let u=this.memoizedURLs.get(c);if(u)return u;o==="\\"&&(c=c.replace(/\\/g,"/"));let m=encodeURI(c).replace(/[#?]/g,encodeURIComponent);return this.memoizedURLs.set(c,m),m}}return Cr=s,Cr}var Er,Fi;function qt(){if(Fi)return Er;Fi=1;let e=Ft();class t extends e{constructor(i){super(i),this.type="comment";}}return Er=t,t.default=t,Er}var xr,Ui;function _e(){if(Ui)return xr;Ui=1;let{isClean:e,my:t}=Pn(),r=Ut(),i=qt(),n=Ft(),o,l,p,a;function h(c){return c.map(u=>(u.nodes&&(u.nodes=h(u.nodes)),delete u.source,u))}function s(c){if(c[e]=false,c.proxyOf.nodes)for(let u of c.proxyOf.nodes)s(u);}class f extends n{append(...u){for(let m of u){let d=this.normalize(m,this.last);for(let g of d)this.proxyOf.nodes.push(g);}return this.markDirty(),this}cleanRaws(u){if(super.cleanRaws(u),this.nodes)for(let m of this.nodes)m.cleanRaws(u);}each(u){if(!this.proxyOf.nodes)return;let m=this.getIterator(),d,g;for(;this.indexes[m]<this.proxyOf.nodes.length&&(d=this.indexes[m],g=u(this.proxyOf.nodes[d],d),g!==false);)this.indexes[m]+=1;return delete this.indexes[m],g}every(u){return this.nodes.every(u)}getIterator(){this.lastEach||(this.lastEach=0),this.indexes||(this.indexes={}),this.lastEach+=1;let u=this.lastEach;return this.indexes[u]=0,u}getProxyProcessor(){return {get(u,m){return m==="proxyOf"?u:u[m]?m==="each"||typeof m=="string"&&m.startsWith("walk")?(...d)=>u[m](...d.map(g=>typeof g=="function"?(S,y)=>g(S.toProxy(),y):g)):m==="every"||m==="some"?d=>u[m]((g,...S)=>d(g.toProxy(),...S)):m==="root"?()=>u.root().toProxy():m==="nodes"?u.nodes.map(d=>d.toProxy()):m==="first"||m==="last"?u[m].toProxy():u[m]:u[m]},set(u,m,d){return u[m]===d||(u[m]=d,(m==="name"||m==="params"||m==="selector")&&u.markDirty()),true}}}index(u){return typeof u=="number"?u:(u.proxyOf&&(u=u.proxyOf),this.proxyOf.nodes.indexOf(u))}insertAfter(u,m){let d=this.index(u),g=this.normalize(m,this.proxyOf.nodes[d]).reverse();d=this.index(u);for(let y of g)this.proxyOf.nodes.splice(d+1,0,y);let S;for(let y in this.indexes)S=this.indexes[y],d<S&&(this.indexes[y]=S+g.length);return this.markDirty(),this}insertBefore(u,m){let d=this.index(u),g=d===0?"prepend":false,S=this.normalize(m,this.proxyOf.nodes[d],g).reverse();d=this.index(u);for(let b of S)this.proxyOf.nodes.splice(d,0,b);let y;for(let b in this.indexes)y=this.indexes[b],d<=y&&(this.indexes[b]=y+S.length);return this.markDirty(),this}normalize(u,m){if(typeof u=="string")u=h(o(u).nodes);else if(typeof u>"u")u=[];else if(Array.isArray(u)){u=u.slice(0);for(let g of u)g.parent&&g.parent.removeChild(g,"ignore");}else if(u.type==="root"&&this.type!=="document"){u=u.nodes.slice(0);for(let g of u)g.parent&&g.parent.removeChild(g,"ignore");}else if(u.type)u=[u];else if(u.prop){if(typeof u.value>"u")throw new Error("Value field is missed in node creation");typeof u.value!="string"&&(u.value=String(u.value)),u=[new r(u)];}else if(u.selector)u=[new l(u)];else if(u.name)u=[new p(u)];else if(u.text)u=[new i(u)];else throw new Error("Unknown node type in node creation");return u.map(g=>(g[t]||f.rebuild(g),g=g.proxyOf,g.parent&&g.parent.removeChild(g),g[e]&&s(g),typeof g.raws.before>"u"&&m&&typeof m.raws.before<"u"&&(g.raws.before=m.raws.before.replace(/\S/g,"")),g.parent=this.proxyOf,g))}prepend(...u){u=u.reverse();for(let m of u){let d=this.normalize(m,this.first,"prepend").reverse();for(let g of d)this.proxyOf.nodes.unshift(g);for(let g in this.indexes)this.indexes[g]=this.indexes[g]+d.length;}return this.markDirty(),this}push(u){return u.parent=this,this.proxyOf.nodes.push(u),this}removeAll(){for(let u of this.proxyOf.nodes)u.parent=void 0;return this.proxyOf.nodes=[],this.markDirty(),this}removeChild(u){u=this.index(u),this.proxyOf.nodes[u].parent=void 0,this.proxyOf.nodes.splice(u,1);let m;for(let d in this.indexes)m=this.indexes[d],m>=u&&(this.indexes[d]=m-1);return this.markDirty(),this}replaceValues(u,m,d){return d||(d=m,m={}),this.walkDecls(g=>{m.props&&!m.props.includes(g.prop)||m.fast&&!g.value.includes(m.fast)||(g.value=g.value.replace(u,d));}),this.markDirty(),this}some(u){return this.nodes.some(u)}walk(u){return this.each((m,d)=>{let g;try{g=u(m,d);}catch(S){throw m.addToError(S)}return g!==false&&m.walk&&(g=m.walk(u)),g})}walkAtRules(u,m){return m?u instanceof RegExp?this.walk((d,g)=>{if(d.type==="atrule"&&u.test(d.name))return m(d,g)}):this.walk((d,g)=>{if(d.type==="atrule"&&d.name===u)return m(d,g)}):(m=u,this.walk((d,g)=>{if(d.type==="atrule")return m(d,g)}))}walkComments(u){return this.walk((m,d)=>{if(m.type==="comment")return u(m,d)})}walkDecls(u,m){return m?u instanceof RegExp?this.walk((d,g)=>{if(d.type==="decl"&&u.test(d.prop))return m(d,g)}):this.walk((d,g)=>{if(d.type==="decl"&&d.prop===u)return m(d,g)}):(m=u,this.walk((d,g)=>{if(d.type==="decl")return m(d,g)}))}walkRules(u,m){return m?u instanceof RegExp?this.walk((d,g)=>{if(d.type==="rule"&&u.test(d.selector))return m(d,g)}):this.walk((d,g)=>{if(d.type==="rule"&&d.selector===u)return m(d,g)}):(m=u,this.walk((d,g)=>{if(d.type==="rule")return m(d,g)}))}get first(){if(this.proxyOf.nodes)return this.proxyOf.nodes[0]}get last(){if(this.proxyOf.nodes)return this.proxyOf.nodes[this.proxyOf.nodes.length-1]}}return f.registerParse=c=>{o=c;},f.registerRule=c=>{l=c;},f.registerAtRule=c=>{p=c;},f.registerRoot=c=>{a=c;},xr=f,f.default=f,f.rebuild=c=>{c.type==="atrule"?Object.setPrototypeOf(c,p.prototype):c.type==="rule"?Object.setPrototypeOf(c,l.prototype):c.type==="decl"?Object.setPrototypeOf(c,r.prototype):c.type==="comment"?Object.setPrototypeOf(c,i.prototype):c.type==="root"&&Object.setPrototypeOf(c,a.prototype),c[t]=true,c.nodes&&c.nodes.forEach(u=>{f.rebuild(u);});},xr}var Rr,Bi;function _n(){if(Bi)return Rr;Bi=1;let e=_e(),t,r;class i extends e{constructor(o){super({type:"document",...o}),this.nodes||(this.nodes=[]);}toResult(o={}){return new t(new r,this,o).stringify()}}return i.registerLazyResult=n=>{t=n;},i.registerProcessor=n=>{r=n;},Rr=i,i.default=i,Rr}var Ir,zi;function io(){if(zi)return Ir;zi=1;class e{constructor(r,i={}){if(this.type="warning",this.text=r,i.node&&i.node.source){let n=i.node.rangeBy(i);this.line=n.start.line,this.column=n.start.column,this.endLine=n.end.line,this.endColumn=n.end.column;}for(let n in i)this[n]=i[n];}toString(){return this.node?this.node.error(this.text,{index:this.index,plugin:this.plugin,word:this.word}).message:this.plugin?this.plugin+": "+this.text:this.text}}return Ir=e,e.default=e,Ir}var Nr,$i;function Fn(){if($i)return Nr;$i=1;let e=io();class t{constructor(i,n,o){this.processor=i,this.messages=[],this.root=n,this.opts=o,this.css=void 0,this.map=void 0;}toString(){return this.css}warn(i,n={}){n.plugin||this.lastPlugin&&this.lastPlugin.postcssPlugin&&(n.plugin=this.lastPlugin.postcssPlugin);let o=new e(i,n);return this.messages.push(o),o}warnings(){return this.messages.filter(i=>i.type==="warning")}get content(){return this.css}}return Nr=t,t.default=t,Nr}var Tr,Wi;function tu(){if(Wi)return Tr;Wi=1;let e=39,t=34,r=92,i=47,n=10,o=32,l=12,p=9,a=13,h=91,s=93,f=40,c=41,u=123,m=125,d=59,g=42,S=58,y=64,b=/[\t\n\f\r "#'()/;[\\\]{}]/g,E=/[\t\n\f\r !"#'():;@[\\\]{}]|\/(?=\*)/g,w=/.[\r\n"'(/\\]/,v=/[\da-f]/i;return Tr=function(R,I={}){let M=R.css.valueOf(),O=I.ignoreErrors,k,x,Q,Y,L,A,B,X,J,P,ce=M.length,N=0,re=[],H=[];function me(){return N}function ie(D){throw R.error("Unclosed "+D,N)}function oe(){return H.length===0&&N>=ce}function Re(D){if(H.length)return H.pop();if(N>=ce)return;let ee=D?D.ignoreUnclosed:false;switch(k=M.charCodeAt(N),k){case n:case o:case p:case a:case l:{x=N;do x+=1,k=M.charCodeAt(x);while(k===o||k===n||k===p||k===a||k===l);P=["space",M.slice(N,x)],N=x-1;break}case h:case s:case u:case m:case S:case d:case c:{let z=String.fromCharCode(k);P=[z,z,N];break}case f:{if(X=re.length?re.pop()[1]:"",J=M.charCodeAt(N+1),X==="url"&&J!==e&&J!==t&&J!==o&&J!==n&&J!==p&&J!==l&&J!==a){x=N;do{if(A=false,x=M.indexOf(")",x+1),x===-1)if(O||ee){x=N;break}else ie("bracket");for(B=x;M.charCodeAt(B-1)===r;)B-=1,A=!A;}while(A);P=["brackets",M.slice(N,x+1),N,x],N=x;}else x=M.indexOf(")",N+1),Y=M.slice(N,x+1),x===-1||w.test(Y)?P=["(","(",N]:(P=["brackets",Y,N,x],N=x);break}case e:case t:{Q=k===e?"'":'"',x=N;do{if(A=false,x=M.indexOf(Q,x+1),x===-1)if(O||ee){x=N+1;break}else ie("string");for(B=x;M.charCodeAt(B-1)===r;)B-=1,A=!A;}while(A);P=["string",M.slice(N,x+1),N,x],N=x;break}case y:{b.lastIndex=N+1,b.test(M),b.lastIndex===0?x=M.length-1:x=b.lastIndex-2,P=["at-word",M.slice(N,x+1),N,x],N=x;break}case r:{for(x=N,L=true;M.charCodeAt(x+1)===r;)x+=1,L=!L;if(k=M.charCodeAt(x+1),L&&k!==i&&k!==o&&k!==n&&k!==p&&k!==a&&k!==l&&(x+=1,v.test(M.charAt(x)))){for(;v.test(M.charAt(x+1));)x+=1;M.charCodeAt(x+1)===o&&(x+=1);}P=["word",M.slice(N,x+1),N,x],N=x;break}default:{k===i&&M.charCodeAt(N+1)===g?(x=M.indexOf("*/",N+2)+1,x===0&&(O||ee?x=M.length:ie("comment")),P=["comment",M.slice(N,x+1),N,x],N=x):(E.lastIndex=N+1,E.test(M),E.lastIndex===0?x=M.length-1:x=E.lastIndex-2,P=["word",M.slice(N,x+1),N,x],re.push(P),N=x);break}}return N++,P}function we(D){H.push(D);}return {back:we,endOfFile:oe,nextToken:Re,position:me}},Tr}var kr,Hi;function Un(){if(Hi)return kr;Hi=1;let e=_e();class t extends e{constructor(i){super(i),this.type="atrule";}append(...i){return this.proxyOf.nodes||(this.nodes=[]),super.append(...i)}prepend(...i){return this.proxyOf.nodes||(this.nodes=[]),super.prepend(...i)}}return kr=t,t.default=t,e.registerAtRule(t),kr}var Ar,ji;function at(){if(ji)return Ar;ji=1;let e=_e(),t,r;class i extends e{constructor(o){super(o),this.type="root",this.nodes||(this.nodes=[]);}normalize(o,l,p){let a=super.normalize(o);if(l){if(p==="prepend")this.nodes.length>1?l.raws.before=this.nodes[1].raws.before:delete l.raws.before;else if(this.first!==l)for(let h of a)h.raws.before=l.raws.before;}return a}removeChild(o,l){let p=this.index(o);return !l&&p===0&&this.nodes.length>1&&(this.nodes[1].raws.before=this.nodes[p].raws.before),super.removeChild(o)}toResult(o={}){return new t(new r,this,o).stringify()}}return i.registerLazyResult=n=>{t=n;},i.registerProcessor=n=>{r=n;},Ar=i,i.default=i,e.registerRoot(i),Ar}var Or,Vi;function so(){if(Vi)return Or;Vi=1;let e={comma(t){return e.split(t,[","],true)},space(t){let r=[" ",`
24
- `," "];return e.split(t,r)},split(t,r,i){let n=[],o="",l=false,p=0,a=false,h="",s=false;for(let f of t)s?s=false:f==="\\"?s=true:a?f===h&&(a=false):f==='"'||f==="'"?(a=true,h=f):f==="("?p+=1:f===")"?p>0&&(p-=1):p===0&&r.includes(f)&&(l=true),l?(o!==""&&n.push(o.trim()),o="",l=false):o+=f;return (i||o!=="")&&n.push(o.trim()),n}};return Or=e,e.default=e,Or}var Dr,Gi;function Bn(){if(Gi)return Dr;Gi=1;let e=_e(),t=so();class r extends e{constructor(n){super(n),this.type="rule",this.nodes||(this.nodes=[]);}get selectors(){return t.comma(this.selector)}set selectors(n){let o=this.selector?this.selector.match(/,\s*/):null,l=o?o[0]:","+this.raw("between","beforeOpen");this.selector=n.join(l);}}return Dr=r,r.default=r,e.registerRule(r),Dr}var Lr,Yi;function ru(){if(Yi)return Lr;Yi=1;let e=Ut(),t=tu(),r=qt(),i=Un(),n=at(),o=Bn(),l={empty:true,space:true};function p(h){for(let s=h.length-1;s>=0;s--){let f=h[s],c=f[3]||f[2];if(c)return c}}class a{constructor(s){this.input=s,this.root=new n,this.current=this.root,this.spaces="",this.semicolon=false,this.createTokenizer(),this.root.source={input:s,start:{column:1,line:1,offset:0}};}atrule(s){let f=new i;f.name=s[1].slice(1),f.name===""&&this.unnamedAtrule(f,s),this.init(f,s[2]);let c,u,m,d=false,g=false,S=[],y=[];for(;!this.tokenizer.endOfFile();){if(s=this.tokenizer.nextToken(),c=s[0],c==="("||c==="["?y.push(c==="("?")":"]"):c==="{"&&y.length>0?y.push("}"):c===y[y.length-1]&&y.pop(),y.length===0)if(c===";"){f.source.end=this.getPosition(s[2]),f.source.end.offset++,this.semicolon=true;break}else if(c==="{"){g=true;break}else if(c==="}"){if(S.length>0){for(m=S.length-1,u=S[m];u&&u[0]==="space";)u=S[--m];u&&(f.source.end=this.getPosition(u[3]||u[2]),f.source.end.offset++);}this.end(s);break}else S.push(s);else S.push(s);if(this.tokenizer.endOfFile()){d=true;break}}f.raws.between=this.spacesAndCommentsFromEnd(S),S.length?(f.raws.afterName=this.spacesAndCommentsFromStart(S),this.raw(f,"params",S),d&&(s=S[S.length-1],f.source.end=this.getPosition(s[3]||s[2]),f.source.end.offset++,this.spaces=f.raws.between,f.raws.between="")):(f.raws.afterName="",f.params=""),g&&(f.nodes=[],this.current=f);}checkMissedSemicolon(s){let f=this.colon(s);if(f===false)return;let c=0,u;for(let m=f-1;m>=0&&(u=s[m],!(u[0]!=="space"&&(c+=1,c===2)));m--);throw this.input.error("Missed semicolon",u[0]==="word"?u[3]+1:u[2])}colon(s){let f=0,c,u,m;for(let[d,g]of s.entries()){if(c=g,u=c[0],u==="("&&(f+=1),u===")"&&(f-=1),f===0&&u===":")if(!m)this.doubleColon(c);else {if(m[0]==="word"&&m[1]==="progid")continue;return d}m=c;}return false}comment(s){let f=new r;this.init(f,s[2]),f.source.end=this.getPosition(s[3]||s[2]),f.source.end.offset++;let c=s[1].slice(2,-2);if(/^\s*$/.test(c))f.text="",f.raws.left=c,f.raws.right="";else {let u=c.match(/^(\s*)([^]*\S)(\s*)$/);f.text=u[2],f.raws.left=u[1],f.raws.right=u[3];}}createTokenizer(){this.tokenizer=t(this.input);}decl(s,f){let c=new e;this.init(c,s[0][2]);let u=s[s.length-1];for(u[0]===";"&&(this.semicolon=true,s.pop()),c.source.end=this.getPosition(u[3]||u[2]||p(s)),c.source.end.offset++;s[0][0]!=="word";)s.length===1&&this.unknownWord(s),c.raws.before+=s.shift()[1];for(c.source.start=this.getPosition(s[0][2]),c.prop="";s.length;){let y=s[0][0];if(y===":"||y==="space"||y==="comment")break;c.prop+=s.shift()[1];}c.raws.between="";let m;for(;s.length;)if(m=s.shift(),m[0]===":"){c.raws.between+=m[1];break}else m[0]==="word"&&/\w/.test(m[1])&&this.unknownWord([m]),c.raws.between+=m[1];(c.prop[0]==="_"||c.prop[0]==="*")&&(c.raws.before+=c.prop[0],c.prop=c.prop.slice(1));let d=[],g;for(;s.length&&(g=s[0][0],!(g!=="space"&&g!=="comment"));)d.push(s.shift());this.precheckMissedSemicolon(s);for(let y=s.length-1;y>=0;y--){if(m=s[y],m[1].toLowerCase()==="!important"){c.important=true;let b=this.stringFrom(s,y);b=this.spacesFromEnd(s)+b,b!==" !important"&&(c.raws.important=b);break}else if(m[1].toLowerCase()==="important"){let b=s.slice(0),E="";for(let w=y;w>0;w--){let v=b[w][0];if(E.trim().indexOf("!")===0&&v!=="space")break;E=b.pop()[1]+E;}E.trim().indexOf("!")===0&&(c.important=true,c.raws.important=E,s=b);}if(m[0]!=="space"&&m[0]!=="comment")break}s.some(y=>y[0]!=="space"&&y[0]!=="comment")&&(c.raws.between+=d.map(y=>y[1]).join(""),d=[]),this.raw(c,"value",d.concat(s),f),c.value.includes(":")&&!f&&this.checkMissedSemicolon(s);}doubleColon(s){throw this.input.error("Double colon",{offset:s[2]},{offset:s[2]+s[1].length})}emptyRule(s){let f=new o;this.init(f,s[2]),f.selector="",f.raws.between="",this.current=f;}end(s){this.current.nodes&&this.current.nodes.length&&(this.current.raws.semicolon=this.semicolon),this.semicolon=false,this.current.raws.after=(this.current.raws.after||"")+this.spaces,this.spaces="",this.current.parent?(this.current.source.end=this.getPosition(s[2]),this.current.source.end.offset++,this.current=this.current.parent):this.unexpectedClose(s);}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(s){if(this.spaces+=s[1],this.current.nodes){let f=this.current.nodes[this.current.nodes.length-1];f&&f.type==="rule"&&!f.raws.ownSemicolon&&(f.raws.ownSemicolon=this.spaces,this.spaces="");}}getPosition(s){let f=this.input.fromOffset(s);return {column:f.col,line:f.line,offset:s}}init(s,f){this.current.push(s),s.source={input:this.input,start:this.getPosition(f)},s.raws.before=this.spaces,this.spaces="",s.type!=="comment"&&(this.semicolon=false);}other(s){let f=false,c=null,u=false,m=null,d=[],g=s[1].startsWith("--"),S=[],y=s;for(;y;){if(c=y[0],S.push(y),c==="("||c==="[")m||(m=y),d.push(c==="("?")":"]");else if(g&&u&&c==="{")m||(m=y),d.push("}");else if(d.length===0)if(c===";")if(u){this.decl(S,g);return}else break;else if(c==="{"){this.rule(S);return}else if(c==="}"){this.tokenizer.back(S.pop()),f=true;break}else c===":"&&(u=true);else c===d[d.length-1]&&(d.pop(),d.length===0&&(m=null));y=this.tokenizer.nextToken();}if(this.tokenizer.endOfFile()&&(f=true),d.length>0&&this.unclosedBracket(m),f&&u){if(!g)for(;S.length&&(y=S[S.length-1][0],!(y!=="space"&&y!=="comment"));)this.tokenizer.back(S.pop());this.decl(S,g);}else this.unknownWord(S);}parse(){let s;for(;!this.tokenizer.endOfFile();)switch(s=this.tokenizer.nextToken(),s[0]){case "space":this.spaces+=s[1];break;case ";":this.freeSemicolon(s);break;case "}":this.end(s);break;case "comment":this.comment(s);break;case "at-word":this.atrule(s);break;case "{":this.emptyRule(s);break;default:this.other(s);break}this.endFile();}precheckMissedSemicolon(){}raw(s,f,c,u){let m,d,g=c.length,S="",y=true,b,E;for(let w=0;w<g;w+=1)m=c[w],d=m[0],d==="space"&&w===g-1&&!u?y=false:d==="comment"?(E=c[w-1]?c[w-1][0]:"empty",b=c[w+1]?c[w+1][0]:"empty",!l[E]&&!l[b]?S.slice(-1)===","?y=false:S+=m[1]:y=false):S+=m[1];if(!y){let w=c.reduce((v,C)=>v+C[1],"");s.raws[f]={raw:w,value:S};}s[f]=S;}rule(s){s.pop();let f=new o;this.init(f,s[0][2]),f.raws.between=this.spacesAndCommentsFromEnd(s),this.raw(f,"selector",s),this.current=f;}spacesAndCommentsFromEnd(s){let f,c="";for(;s.length&&(f=s[s.length-1][0],!(f!=="space"&&f!=="comment"));)c=s.pop()[1]+c;return c}spacesAndCommentsFromStart(s){let f,c="";for(;s.length&&(f=s[0][0],!(f!=="space"&&f!=="comment"));)c+=s.shift()[1];return c}spacesFromEnd(s){let f,c="";for(;s.length&&(f=s[s.length-1][0],f==="space");)c=s.pop()[1]+c;return c}stringFrom(s,f){let c="";for(let u=f;u<s.length;u++)c+=s[u][1];return s.splice(f,s.length-f),c}unclosedBlock(){let s=this.current.source.start;throw this.input.error("Unclosed block",s.line,s.column)}unclosedBracket(s){throw this.input.error("Unclosed bracket",{offset:s[2]},{offset:s[2]+1})}unexpectedClose(s){throw this.input.error("Unexpected }",{offset:s[2]},{offset:s[2]+1})}unknownWord(s){throw this.input.error("Unknown word",{offset:s[0][2]},{offset:s[0][2]+s[0][1].length})}unnamedAtrule(s,f){throw this.input.error("At-rule without name",{offset:f[2]},{offset:f[2]+f[1].length})}}return Lr=a,Lr}var Pr,Xi;function qn(){if(Xi)return Pr;Xi=1;let e=_e(),t=ru(),r=Bt();function i(n,o){let l=new r(n,o),p=new t(l);try{p.parse();}catch(a){throw a}return p.root}return Pr=i,i.default=i,e.registerParse(i),Pr}var _r,Ji;function oo(){if(Ji)return _r;Ji=1;let {isClean:e,my:t}=Pn(),r=ro(),i=_t(),n=_e(),o=_n(),p=Fn(),a=qn(),h=at(),s={atrule:"AtRule",comment:"Comment",decl:"Declaration",document:"Document",root:"Root",rule:"Rule"},f={AtRule:true,AtRuleExit:true,Comment:true,CommentExit:true,Declaration:true,DeclarationExit:true,Document:true,DocumentExit:true,Once:true,OnceExit:true,postcssPlugin:true,prepare:true,Root:true,RootExit:true,Rule:true,RuleExit:true},c={Once:true,postcssPlugin:true,prepare:true},u=0;function m(E){return typeof E=="object"&&typeof E.then=="function"}function d(E){let w=false,v=s[E.type];return E.type==="decl"?w=E.prop.toLowerCase():E.type==="atrule"&&(w=E.name.toLowerCase()),w&&E.append?[v,v+"-"+w,u,v+"Exit",v+"Exit-"+w]:w?[v,v+"-"+w,v+"Exit",v+"Exit-"+w]:E.append?[v,u,v+"Exit"]:[v,v+"Exit"]}function g(E){let w;return E.type==="document"?w=["Document",u,"DocumentExit"]:E.type==="root"?w=["Root",u,"RootExit"]:w=d(E),{eventIndex:0,events:w,iterator:0,node:E,visitorIndex:0,visitors:[]}}function S(E){return E[e]=false,E.nodes&&E.nodes.forEach(w=>S(w)),E}let y={};class b{constructor(w,v,C){this.stringified=false,this.processed=false;let R;if(typeof v=="object"&&v!==null&&(v.type==="root"||v.type==="document"))R=S(v);else if(v instanceof b||v instanceof p)R=S(v.root),v.map&&(typeof C.map>"u"&&(C.map={}),C.map.inline||(C.map.inline=false),C.map.prev=v.map);else {let I=a;C.syntax&&(I=C.syntax.parse),C.parser&&(I=C.parser),I.parse&&(I=I.parse);try{R=I(v,C);}catch(M){this.processed=true,this.error=M;}R&&!R[t]&&n.rebuild(R);}this.result=new p(w,R,C),this.helpers={...y,postcss:y,result:this.result},this.plugins=this.processor.plugins.map(I=>typeof I=="object"&&I.prepare?{...I,...I.prepare(this.result)}:I);}async(){return this.error?Promise.reject(this.error):this.processed?Promise.resolve(this.result):(this.processing||(this.processing=this.runAsync()),this.processing)}catch(w){return this.async().catch(w)}finally(w){return this.async().then(w,w)}getAsyncError(){throw new Error("Use process(css).then(cb) to work with async plugins")}handleError(w,v){let C=this.result.lastPlugin;try{v&&v.addToError(w),this.error=w,w.name==="CssSyntaxError"&&!w.plugin?(w.plugin=C.postcssPlugin,w.setMessage()):C.postcssVersion;}catch(R){console&&console.error&&console.error(R);}return w}prepareVisitors(){this.listeners={};let w=(v,C,R)=>{this.listeners[C]||(this.listeners[C]=[]),this.listeners[C].push([v,R]);};for(let v of this.plugins)if(typeof v=="object")for(let C in v){if(!f[C]&&/^[A-Z]/.test(C))throw new Error(`Unknown event ${C} in ${v.postcssPlugin}. Try to update PostCSS (${this.processor.version} now).`);if(!c[C])if(typeof v[C]=="object")for(let R in v[C])R==="*"?w(v,C,v[C][R]):w(v,C+"-"+R.toLowerCase(),v[C][R]);else typeof v[C]=="function"&&w(v,C,v[C]);}this.hasListener=Object.keys(this.listeners).length>0;}async runAsync(){this.plugin=0;for(let w=0;w<this.plugins.length;w++){let v=this.plugins[w],C=this.runOnRoot(v);if(m(C))try{await C;}catch(R){throw this.handleError(R)}}if(this.prepareVisitors(),this.hasListener){let w=this.result.root;for(;!w[e];){w[e]=true;let v=[g(w)];for(;v.length>0;){let C=this.visitTick(v);if(m(C))try{await C;}catch(R){let I=v[v.length-1].node;throw this.handleError(R,I)}}}if(this.listeners.OnceExit)for(let[v,C]of this.listeners.OnceExit){this.result.lastPlugin=v;try{if(w.type==="document"){let R=w.nodes.map(I=>C(I,this.helpers));await Promise.all(R);}else await C(w,this.helpers);}catch(R){throw this.handleError(R)}}}return this.processed=true,this.stringify()}runOnRoot(w){this.result.lastPlugin=w;try{if(typeof w=="object"&&w.Once){if(this.result.root.type==="document"){let v=this.result.root.nodes.map(C=>w.Once(C,this.helpers));return m(v[0])?Promise.all(v):v}return w.Once(this.result.root,this.helpers)}else if(typeof w=="function")return w(this.result.root,this.result)}catch(v){throw this.handleError(v)}}stringify(){if(this.error)throw this.error;if(this.stringified)return this.result;this.stringified=true,this.sync();let w=this.result.opts,v=i;w.syntax&&(v=w.syntax.stringify),w.stringifier&&(v=w.stringifier),v.stringify&&(v=v.stringify);let R=new r(v,this.result.root,this.result.opts).generate();return this.result.css=R[0],this.result.map=R[1],this.result}sync(){if(this.error)throw this.error;if(this.processed)return this.result;if(this.processed=true,this.processing)throw this.getAsyncError();for(let w of this.plugins){let v=this.runOnRoot(w);if(m(v))throw this.getAsyncError()}if(this.prepareVisitors(),this.hasListener){let w=this.result.root;for(;!w[e];)w[e]=true,this.walkSync(w);if(this.listeners.OnceExit)if(w.type==="document")for(let v of w.nodes)this.visitSync(this.listeners.OnceExit,v);else this.visitSync(this.listeners.OnceExit,w);}return this.result}then(w,v){return this.async().then(w,v)}toString(){return this.css}visitSync(w,v){for(let[C,R]of w){this.result.lastPlugin=C;let I;try{I=R(v,this.helpers);}catch(M){throw this.handleError(M,v.proxyOf)}if(v.type!=="root"&&v.type!=="document"&&!v.parent)return true;if(m(I))throw this.getAsyncError()}}visitTick(w){let v=w[w.length-1],{node:C,visitors:R}=v;if(C.type!=="root"&&C.type!=="document"&&!C.parent){w.pop();return}if(R.length>0&&v.visitorIndex<R.length){let[M,O]=R[v.visitorIndex];v.visitorIndex+=1,v.visitorIndex===R.length&&(v.visitors=[],v.visitorIndex=0),this.result.lastPlugin=M;try{return O(C.toProxy(),this.helpers)}catch(k){throw this.handleError(k,C)}}if(v.iterator!==0){let M=v.iterator,O;for(;O=C.nodes[C.indexes[M]];)if(C.indexes[M]+=1,!O[e]){O[e]=true,w.push(g(O));return}v.iterator=0,delete C.indexes[M];}let I=v.events;for(;v.eventIndex<I.length;){let M=I[v.eventIndex];if(v.eventIndex+=1,M===u){C.nodes&&C.nodes.length&&(C[e]=true,v.iterator=C.getIterator());return}else if(this.listeners[M]){v.visitors=this.listeners[M];return}}w.pop();}walkSync(w){w[e]=true;let v=d(w);for(let C of v)if(C===u)w.nodes&&w.each(R=>{R[e]||this.walkSync(R);});else {let R=this.listeners[C];if(R&&this.visitSync(R,w.toProxy()))return}}warnings(){return this.sync().warnings()}get content(){return this.stringify().content}get css(){return this.stringify().css}get map(){return this.stringify().map}get messages(){return this.sync().messages}get opts(){return this.result.opts}get processor(){return this.result.processor}get root(){return this.sync().root}get[Symbol.toStringTag](){return "LazyResult"}}return b.registerPostcss=E=>{y=E;},_r=b,b.default=b,h.registerLazyResult(b),o.registerLazyResult(b),_r}var Fr,Ki;function nu(){if(Ki)return Fr;Ki=1;let e=ro(),t=_t(),i=qn(),n=Fn();class o{constructor(p,a,h){a=a.toString(),this.stringified=false,this._processor=p,this._css=a,this._opts=h,this._map=void 0;let s,f=t;this.result=new n(this._processor,s,this._opts),this.result.css=a;let c=this;Object.defineProperty(this.result,"root",{get(){return c.root}});let u=new e(f,s,this._opts,a);if(u.isMap()){let[m,d]=u.generate();m&&(this.result.css=m),d&&(this.result.map=d);}else u.clearAnnotation(),this.result.css=u.css;}async(){return this.error?Promise.reject(this.error):Promise.resolve(this.result)}catch(p){return this.async().catch(p)}finally(p){return this.async().then(p,p)}sync(){if(this.error)throw this.error;return this.result}then(p,a){return this.async().then(p,a)}toString(){return this._css}warnings(){return []}get content(){return this.result.css}get css(){return this.result.css}get map(){return this.result.map}get messages(){return []}get opts(){return this.result.opts}get processor(){return this.result.processor}get root(){if(this._root)return this._root;let p,a=i;try{p=a(this._css,this._opts);}catch(h){this.error=h;}if(this.error)throw this.error;return this._root=p,p}get[Symbol.toStringTag](){return "NoWorkResult"}}return Fr=o,o.default=o,Fr}var Ur,Zi;function iu(){if(Zi)return Ur;Zi=1;let e=nu(),t=oo(),r=_n(),i=at();class n{constructor(l=[]){this.version="8.4.38",this.plugins=this.normalize(l);}normalize(l){let p=[];for(let a of l)if(a.postcss===true?a=a():a.postcss&&(a=a.postcss),typeof a=="object"&&Array.isArray(a.plugins))p=p.concat(a.plugins);else if(typeof a=="object"&&a.postcssPlugin)p.push(a);else if(typeof a=="function")p.push(a);else if(!(typeof a=="object"&&(a.parse||a.stringify)))throw new Error(a+" is not a PostCSS plugin");return p}process(l,p={}){return !this.plugins.length&&!p.parser&&!p.stringifier&&!p.syntax?new e(this,l,p):new t(this,l,p)}use(l){return this.plugins=this.plugins.concat(this.normalize([l])),this}}return Ur=n,n.default=n,i.registerProcessor(n),r.registerProcessor(n),Ur}var Br,Qi;function su(){if(Qi)return Br;Qi=1;let e=Ut(),t=to(),r=qt(),i=Un(),n=Bt(),o=at(),l=Bn();function p(a,h){if(Array.isArray(a))return a.map(c=>p(c));let{inputs:s,...f}=a;if(s){h=[];for(let c of s){let u={...c,__proto__:n.prototype};u.map&&(u.map={...u.map,__proto__:t.prototype}),h.push(u);}}if(f.nodes&&(f.nodes=a.nodes.map(c=>p(c,h))),f.source){let{inputId:c,...u}=f.source;f.source=u,c!=null&&(f.source.input=h[c]);}if(f.type==="root")return new o(f);if(f.type==="decl")return new e(f);if(f.type==="rule")return new l(f);if(f.type==="comment")return new r(f);if(f.type==="atrule")return new i(f);throw new Error("Unknown node type: "+a.type)}return Br=p,p.default=p,Br}var qr,es;function ou(){if(es)return qr;es=1;let e=Ln(),t=Ut(),r=oo(),i=_e(),n=iu(),o=_t(),l=su(),p=_n(),a=io(),h=qt(),s=Un(),f=Fn(),c=Bt(),u=qn(),m=so(),d=Bn(),g=at(),S=Ft();function y(...b){return b.length===1&&Array.isArray(b[0])&&(b=b[0]),new n(b)}return y.plugin=function(E,w){let v=false;function C(...I){console&&console.warn&&!v&&(v=true,console.warn(E+`: postcss.plugin was deprecated. Migration guide:
22
+ `),this.css+=u+"/*# sourceMappingURL="+c+" */";}applyPrevMaps(){for(let c of this.previous()){let u=this.toUrl(this.path(c.file)),m=c.root||r(c.file),p;this.mapOpts.sourcesContent===false?(p=new e(c.text),p.sourcesContent&&(p.sourcesContent=null)):p=c.consumer(),this.map.applySourceMap(p,u,this.toUrl(this.path(m)));}}clearAnnotation(){if(this.mapOpts.annotation!==false)if(this.root){let c;for(let u=this.root.nodes.length-1;u>=0;u--)c=this.root.nodes[u],c.type==="comment"&&c.text.indexOf("# sourceMappingURL=")===0&&this.root.removeChild(u);}else this.css&&(this.css=this.css.replace(/\n*?\/\*#[\S\s]*?\*\/$/gm,""));}generate(){if(this.clearAnnotation(),h&&a&&this.isMap())return this.generateMap();{let c="";return this.stringify(this.root,u=>{c+=u;}),[c]}}generateMap(){if(this.root)this.generateString();else if(this.previous().length===1){let c=this.previous()[0].consumer();c.file=this.outputFile(),this.map=t.fromSourceMap(c,{ignoreInvalidMapping:true});}else this.map=new t({file:this.outputFile(),ignoreInvalidMapping:true}),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 t({file:this.outputFile(),ignoreInvalidMapping:true});let c=1,u=1,m="<no source>",p={generated:{column:0,line:0},original:{column:0,line:0},source:""},g,S;this.stringify(this.root,(y,b,E)=>{if(this.css+=y,b&&E!=="end"&&(p.generated.line=c,p.generated.column=u-1,b.source&&b.source.start?(p.source=this.sourcePath(b),p.original.line=b.source.start.line,p.original.column=b.source.start.column-1,this.map.addMapping(p)):(p.source=m,p.original.line=1,p.original.column=0,this.map.addMapping(p))),g=y.match(/\n/g),g?(c+=g.length,S=y.lastIndexOf(`
23
+ `),u=y.length-S):u+=y.length,b&&E!=="start"){let w=b.parent||{raws:{}};(!(b.type==="decl"||b.type==="atrule"&&!b.nodes)||b!==w.last||w.raws.semicolon)&&(b.source&&b.source.end?(p.source=this.sourcePath(b),p.original.line=b.source.end.line,p.original.column=b.source.end.column-1,p.generated.line=c,p.generated.column=u-2,this.map.addMapping(p)):(p.source=m,p.original.line=1,p.original.column=0,p.generated.line=c,p.generated.column=u-1,this.map.addMapping(p)));}});}isAnnotation(){return this.isInline()?true:typeof this.mapOpts.annotation<"u"?this.mapOpts.annotation:this.previous().length?this.previous().some(c=>c.annotation):true}isInline(){if(typeof this.mapOpts.inline<"u")return this.mapOpts.inline;let c=this.mapOpts.annotation;return typeof c<"u"&&c!==true?false:this.previous().length?this.previous().some(u=>u.inline):true}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(c=>c.withContent()):true}outputFile(){return this.opts.to?this.path(this.opts.to):this.opts.from?this.path(this.opts.from):"to.css"}path(c){if(this.mapOpts.absolute||c.charCodeAt(0)===60||/^\w+:\/\//.test(c))return c;let u=this.memoizedPaths.get(c);if(u)return u;let m=this.opts.to?r(this.opts.to):".";typeof this.mapOpts.annotation=="string"&&(m=r(n(m,this.mapOpts.annotation)));let p=i(m,c);return this.memoizedPaths.set(c,p),p}previous(){if(!this.previousMaps)if(this.previousMaps=[],this.root)this.root.walk(c=>{if(c.source&&c.source.input.map){let u=c.source.input.map;this.previousMaps.includes(u)||this.previousMaps.push(u);}});else {let c=new d(this.originalCSS,this.opts);c.map&&this.previousMaps.push(c.map);}return this.previousMaps}setSourcesContent(){let c={};if(this.root)this.root.walk(u=>{if(u.source){let m=u.source.input.from;if(m&&!c[m]){c[m]=true;let p=this.usesFileUrls?this.toFileUrl(m):this.toUrl(this.path(m));this.map.setSourceContent(p,u.source.input.css);}}});else if(this.css){let u=this.opts.from?this.toUrl(this.path(this.opts.from)):"<no source>";this.map.setSourceContent(u,this.css);}}sourcePath(c){return this.mapOpts.from?this.toUrl(this.mapOpts.from):this.usesFileUrls?this.toFileUrl(c.source.input.from):this.toUrl(this.path(c.source.input.from))}toBase64(c){return Buffer?Buffer.from(c).toString("base64"):window.btoa(unescape(encodeURIComponent(c)))}toFileUrl(c){let u=this.memoizedFileURLs.get(c);if(u)return u;if(l){let m=l(c).toString();return this.memoizedFileURLs.set(c,m),m}else throw new Error("`map.absolute` option is not available in this PostCSS build")}toUrl(c){let u=this.memoizedURLs.get(c);if(u)return u;o==="\\"&&(c=c.replace(/\\/g,"/"));let m=encodeURI(c).replace(/[#?]/g,encodeURIComponent);return this.memoizedURLs.set(c,m),m}}return Cr=s,Cr}var Er,Ui;function qt(){if(Ui)return Er;Ui=1;let e=Ft();class t extends e{constructor(i){super(i),this.type="comment";}}return Er=t,t.default=t,Er}var xr,Bi;function _e(){if(Bi)return xr;Bi=1;let{isClean:e,my:t}=Pn(),r=Ut(),i=qt(),n=Ft(),o,l,d,a;function h(c){return c.map(u=>(u.nodes&&(u.nodes=h(u.nodes)),delete u.source,u))}function s(c){if(c[e]=false,c.proxyOf.nodes)for(let u of c.proxyOf.nodes)s(u);}class f extends n{append(...u){for(let m of u){let p=this.normalize(m,this.last);for(let g of p)this.proxyOf.nodes.push(g);}return this.markDirty(),this}cleanRaws(u){if(super.cleanRaws(u),this.nodes)for(let m of this.nodes)m.cleanRaws(u);}each(u){if(!this.proxyOf.nodes)return;let m=this.getIterator(),p,g;for(;this.indexes[m]<this.proxyOf.nodes.length&&(p=this.indexes[m],g=u(this.proxyOf.nodes[p],p),g!==false);)this.indexes[m]+=1;return delete this.indexes[m],g}every(u){return this.nodes.every(u)}getIterator(){this.lastEach||(this.lastEach=0),this.indexes||(this.indexes={}),this.lastEach+=1;let u=this.lastEach;return this.indexes[u]=0,u}getProxyProcessor(){return {get(u,m){return m==="proxyOf"?u:u[m]?m==="each"||typeof m=="string"&&m.startsWith("walk")?(...p)=>u[m](...p.map(g=>typeof g=="function"?(S,y)=>g(S.toProxy(),y):g)):m==="every"||m==="some"?p=>u[m]((g,...S)=>p(g.toProxy(),...S)):m==="root"?()=>u.root().toProxy():m==="nodes"?u.nodes.map(p=>p.toProxy()):m==="first"||m==="last"?u[m].toProxy():u[m]:u[m]},set(u,m,p){return u[m]===p||(u[m]=p,(m==="name"||m==="params"||m==="selector")&&u.markDirty()),true}}}index(u){return typeof u=="number"?u:(u.proxyOf&&(u=u.proxyOf),this.proxyOf.nodes.indexOf(u))}insertAfter(u,m){let p=this.index(u),g=this.normalize(m,this.proxyOf.nodes[p]).reverse();p=this.index(u);for(let y of g)this.proxyOf.nodes.splice(p+1,0,y);let S;for(let y in this.indexes)S=this.indexes[y],p<S&&(this.indexes[y]=S+g.length);return this.markDirty(),this}insertBefore(u,m){let p=this.index(u),g=p===0?"prepend":false,S=this.normalize(m,this.proxyOf.nodes[p],g).reverse();p=this.index(u);for(let b of S)this.proxyOf.nodes.splice(p,0,b);let y;for(let b in this.indexes)y=this.indexes[b],p<=y&&(this.indexes[b]=y+S.length);return this.markDirty(),this}normalize(u,m){if(typeof u=="string")u=h(o(u).nodes);else if(typeof u>"u")u=[];else if(Array.isArray(u)){u=u.slice(0);for(let g of u)g.parent&&g.parent.removeChild(g,"ignore");}else if(u.type==="root"&&this.type!=="document"){u=u.nodes.slice(0);for(let g of u)g.parent&&g.parent.removeChild(g,"ignore");}else if(u.type)u=[u];else if(u.prop){if(typeof u.value>"u")throw new Error("Value field is missed in node creation");typeof u.value!="string"&&(u.value=String(u.value)),u=[new r(u)];}else if(u.selector)u=[new l(u)];else if(u.name)u=[new d(u)];else if(u.text)u=[new i(u)];else throw new Error("Unknown node type in node creation");return u.map(g=>(g[t]||f.rebuild(g),g=g.proxyOf,g.parent&&g.parent.removeChild(g),g[e]&&s(g),typeof g.raws.before>"u"&&m&&typeof m.raws.before<"u"&&(g.raws.before=m.raws.before.replace(/\S/g,"")),g.parent=this.proxyOf,g))}prepend(...u){u=u.reverse();for(let m of u){let p=this.normalize(m,this.first,"prepend").reverse();for(let g of p)this.proxyOf.nodes.unshift(g);for(let g in this.indexes)this.indexes[g]=this.indexes[g]+p.length;}return this.markDirty(),this}push(u){return u.parent=this,this.proxyOf.nodes.push(u),this}removeAll(){for(let u of this.proxyOf.nodes)u.parent=void 0;return this.proxyOf.nodes=[],this.markDirty(),this}removeChild(u){u=this.index(u),this.proxyOf.nodes[u].parent=void 0,this.proxyOf.nodes.splice(u,1);let m;for(let p in this.indexes)m=this.indexes[p],m>=u&&(this.indexes[p]=m-1);return this.markDirty(),this}replaceValues(u,m,p){return p||(p=m,m={}),this.walkDecls(g=>{m.props&&!m.props.includes(g.prop)||m.fast&&!g.value.includes(m.fast)||(g.value=g.value.replace(u,p));}),this.markDirty(),this}some(u){return this.nodes.some(u)}walk(u){return this.each((m,p)=>{let g;try{g=u(m,p);}catch(S){throw m.addToError(S)}return g!==false&&m.walk&&(g=m.walk(u)),g})}walkAtRules(u,m){return m?u instanceof RegExp?this.walk((p,g)=>{if(p.type==="atrule"&&u.test(p.name))return m(p,g)}):this.walk((p,g)=>{if(p.type==="atrule"&&p.name===u)return m(p,g)}):(m=u,this.walk((p,g)=>{if(p.type==="atrule")return m(p,g)}))}walkComments(u){return this.walk((m,p)=>{if(m.type==="comment")return u(m,p)})}walkDecls(u,m){return m?u instanceof RegExp?this.walk((p,g)=>{if(p.type==="decl"&&u.test(p.prop))return m(p,g)}):this.walk((p,g)=>{if(p.type==="decl"&&p.prop===u)return m(p,g)}):(m=u,this.walk((p,g)=>{if(p.type==="decl")return m(p,g)}))}walkRules(u,m){return m?u instanceof RegExp?this.walk((p,g)=>{if(p.type==="rule"&&u.test(p.selector))return m(p,g)}):this.walk((p,g)=>{if(p.type==="rule"&&p.selector===u)return m(p,g)}):(m=u,this.walk((p,g)=>{if(p.type==="rule")return m(p,g)}))}get first(){if(this.proxyOf.nodes)return this.proxyOf.nodes[0]}get last(){if(this.proxyOf.nodes)return this.proxyOf.nodes[this.proxyOf.nodes.length-1]}}return f.registerParse=c=>{o=c;},f.registerRule=c=>{l=c;},f.registerAtRule=c=>{d=c;},f.registerRoot=c=>{a=c;},xr=f,f.default=f,f.rebuild=c=>{c.type==="atrule"?Object.setPrototypeOf(c,d.prototype):c.type==="rule"?Object.setPrototypeOf(c,l.prototype):c.type==="decl"?Object.setPrototypeOf(c,r.prototype):c.type==="comment"?Object.setPrototypeOf(c,i.prototype):c.type==="root"&&Object.setPrototypeOf(c,a.prototype),c[t]=true,c.nodes&&c.nodes.forEach(u=>{f.rebuild(u);});},xr}var Rr,qi;function _n(){if(qi)return Rr;qi=1;let e=_e(),t,r;class i extends e{constructor(o){super({type:"document",...o}),this.nodes||(this.nodes=[]);}toResult(o={}){return new t(new r,this,o).stringify()}}return i.registerLazyResult=n=>{t=n;},i.registerProcessor=n=>{r=n;},Rr=i,i.default=i,Rr}var Mr,$i;function so(){if($i)return Mr;$i=1;class e{constructor(r,i={}){if(this.type="warning",this.text=r,i.node&&i.node.source){let n=i.node.rangeBy(i);this.line=n.start.line,this.column=n.start.column,this.endLine=n.end.line,this.endColumn=n.end.column;}for(let n in i)this[n]=i[n];}toString(){return this.node?this.node.error(this.text,{index:this.index,plugin:this.plugin,word:this.word}).message:this.plugin?this.plugin+": "+this.text:this.text}}return Mr=e,e.default=e,Mr}var Nr,Wi;function Fn(){if(Wi)return Nr;Wi=1;let e=so();class t{constructor(i,n,o){this.processor=i,this.messages=[],this.root=n,this.opts=o,this.css=void 0,this.map=void 0;}toString(){return this.css}warn(i,n={}){n.plugin||this.lastPlugin&&this.lastPlugin.postcssPlugin&&(n.plugin=this.lastPlugin.postcssPlugin);let o=new e(i,n);return this.messages.push(o),o}warnings(){return this.messages.filter(i=>i.type==="warning")}get content(){return this.css}}return Nr=t,t.default=t,Nr}var Tr,Hi;function ru(){if(Hi)return Tr;Hi=1;let e=39,t=34,r=92,i=47,n=10,o=32,l=12,d=9,a=13,h=91,s=93,f=40,c=41,u=123,m=125,p=59,g=42,S=58,y=64,b=/[\t\n\f\r "#'()/;[\\\]{}]/g,E=/[\t\n\f\r !"#'():;@[\\\]{}]|\/(?=\*)/g,w=/.[\r\n"'(/\\]/,v=/[\da-f]/i;return Tr=function(R,M={}){let I=R.css.valueOf(),O=M.ignoreErrors,k,x,Q,Y,L,A,B,X,J,P,ce=I.length,N=0,re=[],H=[];function me(){return N}function ie(D){throw R.error("Unclosed "+D,N)}function oe(){return H.length===0&&N>=ce}function Re(D){if(H.length)return H.pop();if(N>=ce)return;let ee=D?D.ignoreUnclosed:false;switch(k=I.charCodeAt(N),k){case n:case o:case d:case a:case l:{x=N;do x+=1,k=I.charCodeAt(x);while(k===o||k===n||k===d||k===a||k===l);P=["space",I.slice(N,x)],N=x-1;break}case h:case s:case u:case m:case S:case p:case c:{let z=String.fromCharCode(k);P=[z,z,N];break}case f:{if(X=re.length?re.pop()[1]:"",J=I.charCodeAt(N+1),X==="url"&&J!==e&&J!==t&&J!==o&&J!==n&&J!==d&&J!==l&&J!==a){x=N;do{if(A=false,x=I.indexOf(")",x+1),x===-1)if(O||ee){x=N;break}else ie("bracket");for(B=x;I.charCodeAt(B-1)===r;)B-=1,A=!A;}while(A);P=["brackets",I.slice(N,x+1),N,x],N=x;}else x=I.indexOf(")",N+1),Y=I.slice(N,x+1),x===-1||w.test(Y)?P=["(","(",N]:(P=["brackets",Y,N,x],N=x);break}case e:case t:{Q=k===e?"'":'"',x=N;do{if(A=false,x=I.indexOf(Q,x+1),x===-1)if(O||ee){x=N+1;break}else ie("string");for(B=x;I.charCodeAt(B-1)===r;)B-=1,A=!A;}while(A);P=["string",I.slice(N,x+1),N,x],N=x;break}case y:{b.lastIndex=N+1,b.test(I),b.lastIndex===0?x=I.length-1:x=b.lastIndex-2,P=["at-word",I.slice(N,x+1),N,x],N=x;break}case r:{for(x=N,L=true;I.charCodeAt(x+1)===r;)x+=1,L=!L;if(k=I.charCodeAt(x+1),L&&k!==i&&k!==o&&k!==n&&k!==d&&k!==a&&k!==l&&(x+=1,v.test(I.charAt(x)))){for(;v.test(I.charAt(x+1));)x+=1;I.charCodeAt(x+1)===o&&(x+=1);}P=["word",I.slice(N,x+1),N,x],N=x;break}default:{k===i&&I.charCodeAt(N+1)===g?(x=I.indexOf("*/",N+2)+1,x===0&&(O||ee?x=I.length:ie("comment")),P=["comment",I.slice(N,x+1),N,x],N=x):(E.lastIndex=N+1,E.test(I),E.lastIndex===0?x=I.length-1:x=E.lastIndex-2,P=["word",I.slice(N,x+1),N,x],re.push(P),N=x);break}}return N++,P}function we(D){H.push(D);}return {back:we,endOfFile:oe,nextToken:Re,position:me}},Tr}var kr,ji;function Un(){if(ji)return kr;ji=1;let e=_e();class t extends e{constructor(i){super(i),this.type="atrule";}append(...i){return this.proxyOf.nodes||(this.nodes=[]),super.append(...i)}prepend(...i){return this.proxyOf.nodes||(this.nodes=[]),super.prepend(...i)}}return kr=t,t.default=t,e.registerAtRule(t),kr}var Ar,Vi;function at(){if(Vi)return Ar;Vi=1;let e=_e(),t,r;class i extends e{constructor(o){super(o),this.type="root",this.nodes||(this.nodes=[]);}normalize(o,l,d){let a=super.normalize(o);if(l){if(d==="prepend")this.nodes.length>1?l.raws.before=this.nodes[1].raws.before:delete l.raws.before;else if(this.first!==l)for(let h of a)h.raws.before=l.raws.before;}return a}removeChild(o,l){let d=this.index(o);return !l&&d===0&&this.nodes.length>1&&(this.nodes[1].raws.before=this.nodes[d].raws.before),super.removeChild(o)}toResult(o={}){return new t(new r,this,o).stringify()}}return i.registerLazyResult=n=>{t=n;},i.registerProcessor=n=>{r=n;},Ar=i,i.default=i,e.registerRoot(i),Ar}var Or,Gi;function oo(){if(Gi)return Or;Gi=1;let e={comma(t){return e.split(t,[","],true)},space(t){let r=[" ",`
24
+ `," "];return e.split(t,r)},split(t,r,i){let n=[],o="",l=false,d=0,a=false,h="",s=false;for(let f of t)s?s=false:f==="\\"?s=true:a?f===h&&(a=false):f==='"'||f==="'"?(a=true,h=f):f==="("?d+=1:f===")"?d>0&&(d-=1):d===0&&r.includes(f)&&(l=true),l?(o!==""&&n.push(o.trim()),o="",l=false):o+=f;return (i||o!=="")&&n.push(o.trim()),n}};return Or=e,e.default=e,Or}var Dr,Yi;function Bn(){if(Yi)return Dr;Yi=1;let e=_e(),t=oo();class r extends e{constructor(n){super(n),this.type="rule",this.nodes||(this.nodes=[]);}get selectors(){return t.comma(this.selector)}set selectors(n){let o=this.selector?this.selector.match(/,\s*/):null,l=o?o[0]:","+this.raw("between","beforeOpen");this.selector=n.join(l);}}return Dr=r,r.default=r,e.registerRule(r),Dr}var Lr,Xi;function nu(){if(Xi)return Lr;Xi=1;let e=Ut(),t=ru(),r=qt(),i=Un(),n=at(),o=Bn(),l={empty:true,space:true};function d(h){for(let s=h.length-1;s>=0;s--){let f=h[s],c=f[3]||f[2];if(c)return c}}class a{constructor(s){this.input=s,this.root=new n,this.current=this.root,this.spaces="",this.semicolon=false,this.createTokenizer(),this.root.source={input:s,start:{column:1,line:1,offset:0}};}atrule(s){let f=new i;f.name=s[1].slice(1),f.name===""&&this.unnamedAtrule(f,s),this.init(f,s[2]);let c,u,m,p=false,g=false,S=[],y=[];for(;!this.tokenizer.endOfFile();){if(s=this.tokenizer.nextToken(),c=s[0],c==="("||c==="["?y.push(c==="("?")":"]"):c==="{"&&y.length>0?y.push("}"):c===y[y.length-1]&&y.pop(),y.length===0)if(c===";"){f.source.end=this.getPosition(s[2]),f.source.end.offset++,this.semicolon=true;break}else if(c==="{"){g=true;break}else if(c==="}"){if(S.length>0){for(m=S.length-1,u=S[m];u&&u[0]==="space";)u=S[--m];u&&(f.source.end=this.getPosition(u[3]||u[2]),f.source.end.offset++);}this.end(s);break}else S.push(s);else S.push(s);if(this.tokenizer.endOfFile()){p=true;break}}f.raws.between=this.spacesAndCommentsFromEnd(S),S.length?(f.raws.afterName=this.spacesAndCommentsFromStart(S),this.raw(f,"params",S),p&&(s=S[S.length-1],f.source.end=this.getPosition(s[3]||s[2]),f.source.end.offset++,this.spaces=f.raws.between,f.raws.between="")):(f.raws.afterName="",f.params=""),g&&(f.nodes=[],this.current=f);}checkMissedSemicolon(s){let f=this.colon(s);if(f===false)return;let c=0,u;for(let m=f-1;m>=0&&(u=s[m],!(u[0]!=="space"&&(c+=1,c===2)));m--);throw this.input.error("Missed semicolon",u[0]==="word"?u[3]+1:u[2])}colon(s){let f=0,c,u,m;for(let[p,g]of s.entries()){if(c=g,u=c[0],u==="("&&(f+=1),u===")"&&(f-=1),f===0&&u===":")if(!m)this.doubleColon(c);else {if(m[0]==="word"&&m[1]==="progid")continue;return p}m=c;}return false}comment(s){let f=new r;this.init(f,s[2]),f.source.end=this.getPosition(s[3]||s[2]),f.source.end.offset++;let c=s[1].slice(2,-2);if(/^\s*$/.test(c))f.text="",f.raws.left=c,f.raws.right="";else {let u=c.match(/^(\s*)([^]*\S)(\s*)$/);f.text=u[2],f.raws.left=u[1],f.raws.right=u[3];}}createTokenizer(){this.tokenizer=t(this.input);}decl(s,f){let c=new e;this.init(c,s[0][2]);let u=s[s.length-1];for(u[0]===";"&&(this.semicolon=true,s.pop()),c.source.end=this.getPosition(u[3]||u[2]||d(s)),c.source.end.offset++;s[0][0]!=="word";)s.length===1&&this.unknownWord(s),c.raws.before+=s.shift()[1];for(c.source.start=this.getPosition(s[0][2]),c.prop="";s.length;){let y=s[0][0];if(y===":"||y==="space"||y==="comment")break;c.prop+=s.shift()[1];}c.raws.between="";let m;for(;s.length;)if(m=s.shift(),m[0]===":"){c.raws.between+=m[1];break}else m[0]==="word"&&/\w/.test(m[1])&&this.unknownWord([m]),c.raws.between+=m[1];(c.prop[0]==="_"||c.prop[0]==="*")&&(c.raws.before+=c.prop[0],c.prop=c.prop.slice(1));let p=[],g;for(;s.length&&(g=s[0][0],!(g!=="space"&&g!=="comment"));)p.push(s.shift());this.precheckMissedSemicolon(s);for(let y=s.length-1;y>=0;y--){if(m=s[y],m[1].toLowerCase()==="!important"){c.important=true;let b=this.stringFrom(s,y);b=this.spacesFromEnd(s)+b,b!==" !important"&&(c.raws.important=b);break}else if(m[1].toLowerCase()==="important"){let b=s.slice(0),E="";for(let w=y;w>0;w--){let v=b[w][0];if(E.trim().indexOf("!")===0&&v!=="space")break;E=b.pop()[1]+E;}E.trim().indexOf("!")===0&&(c.important=true,c.raws.important=E,s=b);}if(m[0]!=="space"&&m[0]!=="comment")break}s.some(y=>y[0]!=="space"&&y[0]!=="comment")&&(c.raws.between+=p.map(y=>y[1]).join(""),p=[]),this.raw(c,"value",p.concat(s),f),c.value.includes(":")&&!f&&this.checkMissedSemicolon(s);}doubleColon(s){throw this.input.error("Double colon",{offset:s[2]},{offset:s[2]+s[1].length})}emptyRule(s){let f=new o;this.init(f,s[2]),f.selector="",f.raws.between="",this.current=f;}end(s){this.current.nodes&&this.current.nodes.length&&(this.current.raws.semicolon=this.semicolon),this.semicolon=false,this.current.raws.after=(this.current.raws.after||"")+this.spaces,this.spaces="",this.current.parent?(this.current.source.end=this.getPosition(s[2]),this.current.source.end.offset++,this.current=this.current.parent):this.unexpectedClose(s);}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(s){if(this.spaces+=s[1],this.current.nodes){let f=this.current.nodes[this.current.nodes.length-1];f&&f.type==="rule"&&!f.raws.ownSemicolon&&(f.raws.ownSemicolon=this.spaces,this.spaces="");}}getPosition(s){let f=this.input.fromOffset(s);return {column:f.col,line:f.line,offset:s}}init(s,f){this.current.push(s),s.source={input:this.input,start:this.getPosition(f)},s.raws.before=this.spaces,this.spaces="",s.type!=="comment"&&(this.semicolon=false);}other(s){let f=false,c=null,u=false,m=null,p=[],g=s[1].startsWith("--"),S=[],y=s;for(;y;){if(c=y[0],S.push(y),c==="("||c==="[")m||(m=y),p.push(c==="("?")":"]");else if(g&&u&&c==="{")m||(m=y),p.push("}");else if(p.length===0)if(c===";")if(u){this.decl(S,g);return}else break;else if(c==="{"){this.rule(S);return}else if(c==="}"){this.tokenizer.back(S.pop()),f=true;break}else c===":"&&(u=true);else c===p[p.length-1]&&(p.pop(),p.length===0&&(m=null));y=this.tokenizer.nextToken();}if(this.tokenizer.endOfFile()&&(f=true),p.length>0&&this.unclosedBracket(m),f&&u){if(!g)for(;S.length&&(y=S[S.length-1][0],!(y!=="space"&&y!=="comment"));)this.tokenizer.back(S.pop());this.decl(S,g);}else this.unknownWord(S);}parse(){let s;for(;!this.tokenizer.endOfFile();)switch(s=this.tokenizer.nextToken(),s[0]){case "space":this.spaces+=s[1];break;case ";":this.freeSemicolon(s);break;case "}":this.end(s);break;case "comment":this.comment(s);break;case "at-word":this.atrule(s);break;case "{":this.emptyRule(s);break;default:this.other(s);break}this.endFile();}precheckMissedSemicolon(){}raw(s,f,c,u){let m,p,g=c.length,S="",y=true,b,E;for(let w=0;w<g;w+=1)m=c[w],p=m[0],p==="space"&&w===g-1&&!u?y=false:p==="comment"?(E=c[w-1]?c[w-1][0]:"empty",b=c[w+1]?c[w+1][0]:"empty",!l[E]&&!l[b]?S.slice(-1)===","?y=false:S+=m[1]:y=false):S+=m[1];if(!y){let w=c.reduce((v,C)=>v+C[1],"");s.raws[f]={raw:w,value:S};}s[f]=S;}rule(s){s.pop();let f=new o;this.init(f,s[0][2]),f.raws.between=this.spacesAndCommentsFromEnd(s),this.raw(f,"selector",s),this.current=f;}spacesAndCommentsFromEnd(s){let f,c="";for(;s.length&&(f=s[s.length-1][0],!(f!=="space"&&f!=="comment"));)c=s.pop()[1]+c;return c}spacesAndCommentsFromStart(s){let f,c="";for(;s.length&&(f=s[0][0],!(f!=="space"&&f!=="comment"));)c+=s.shift()[1];return c}spacesFromEnd(s){let f,c="";for(;s.length&&(f=s[s.length-1][0],f==="space");)c=s.pop()[1]+c;return c}stringFrom(s,f){let c="";for(let u=f;u<s.length;u++)c+=s[u][1];return s.splice(f,s.length-f),c}unclosedBlock(){let s=this.current.source.start;throw this.input.error("Unclosed block",s.line,s.column)}unclosedBracket(s){throw this.input.error("Unclosed bracket",{offset:s[2]},{offset:s[2]+1})}unexpectedClose(s){throw this.input.error("Unexpected }",{offset:s[2]},{offset:s[2]+1})}unknownWord(s){throw this.input.error("Unknown word",{offset:s[0][2]},{offset:s[0][2]+s[0][1].length})}unnamedAtrule(s,f){throw this.input.error("At-rule without name",{offset:f[2]},{offset:f[2]+f[1].length})}}return Lr=a,Lr}var Pr,Ji;function qn(){if(Ji)return Pr;Ji=1;let e=_e(),t=nu(),r=Bt();function i(n,o){let l=new r(n,o),d=new t(l);try{d.parse();}catch(a){throw a}return d.root}return Pr=i,i.default=i,e.registerParse(i),Pr}var _r,Ki;function ao(){if(Ki)return _r;Ki=1;let {isClean:e,my:t}=Pn(),r=no(),i=_t(),n=_e(),o=_n(),d=Fn(),a=qn(),h=at(),s={atrule:"AtRule",comment:"Comment",decl:"Declaration",document:"Document",root:"Root",rule:"Rule"},f={AtRule:true,AtRuleExit:true,Comment:true,CommentExit:true,Declaration:true,DeclarationExit:true,Document:true,DocumentExit:true,Once:true,OnceExit:true,postcssPlugin:true,prepare:true,Root:true,RootExit:true,Rule:true,RuleExit:true},c={Once:true,postcssPlugin:true,prepare:true},u=0;function m(E){return typeof E=="object"&&typeof E.then=="function"}function p(E){let w=false,v=s[E.type];return E.type==="decl"?w=E.prop.toLowerCase():E.type==="atrule"&&(w=E.name.toLowerCase()),w&&E.append?[v,v+"-"+w,u,v+"Exit",v+"Exit-"+w]:w?[v,v+"-"+w,v+"Exit",v+"Exit-"+w]:E.append?[v,u,v+"Exit"]:[v,v+"Exit"]}function g(E){let w;return E.type==="document"?w=["Document",u,"DocumentExit"]:E.type==="root"?w=["Root",u,"RootExit"]:w=p(E),{eventIndex:0,events:w,iterator:0,node:E,visitorIndex:0,visitors:[]}}function S(E){return E[e]=false,E.nodes&&E.nodes.forEach(w=>S(w)),E}let y={};class b{constructor(w,v,C){this.stringified=false,this.processed=false;let R;if(typeof v=="object"&&v!==null&&(v.type==="root"||v.type==="document"))R=S(v);else if(v instanceof b||v instanceof d)R=S(v.root),v.map&&(typeof C.map>"u"&&(C.map={}),C.map.inline||(C.map.inline=false),C.map.prev=v.map);else {let M=a;C.syntax&&(M=C.syntax.parse),C.parser&&(M=C.parser),M.parse&&(M=M.parse);try{R=M(v,C);}catch(I){this.processed=true,this.error=I;}R&&!R[t]&&n.rebuild(R);}this.result=new d(w,R,C),this.helpers={...y,postcss:y,result:this.result},this.plugins=this.processor.plugins.map(M=>typeof M=="object"&&M.prepare?{...M,...M.prepare(this.result)}:M);}async(){return this.error?Promise.reject(this.error):this.processed?Promise.resolve(this.result):(this.processing||(this.processing=this.runAsync()),this.processing)}catch(w){return this.async().catch(w)}finally(w){return this.async().then(w,w)}getAsyncError(){throw new Error("Use process(css).then(cb) to work with async plugins")}handleError(w,v){let C=this.result.lastPlugin;try{v&&v.addToError(w),this.error=w,w.name==="CssSyntaxError"&&!w.plugin?(w.plugin=C.postcssPlugin,w.setMessage()):C.postcssVersion;}catch(R){console&&console.error&&console.error(R);}return w}prepareVisitors(){this.listeners={};let w=(v,C,R)=>{this.listeners[C]||(this.listeners[C]=[]),this.listeners[C].push([v,R]);};for(let v of this.plugins)if(typeof v=="object")for(let C in v){if(!f[C]&&/^[A-Z]/.test(C))throw new Error(`Unknown event ${C} in ${v.postcssPlugin}. Try to update PostCSS (${this.processor.version} now).`);if(!c[C])if(typeof v[C]=="object")for(let R in v[C])R==="*"?w(v,C,v[C][R]):w(v,C+"-"+R.toLowerCase(),v[C][R]);else typeof v[C]=="function"&&w(v,C,v[C]);}this.hasListener=Object.keys(this.listeners).length>0;}async runAsync(){this.plugin=0;for(let w=0;w<this.plugins.length;w++){let v=this.plugins[w],C=this.runOnRoot(v);if(m(C))try{await C;}catch(R){throw this.handleError(R)}}if(this.prepareVisitors(),this.hasListener){let w=this.result.root;for(;!w[e];){w[e]=true;let v=[g(w)];for(;v.length>0;){let C=this.visitTick(v);if(m(C))try{await C;}catch(R){let M=v[v.length-1].node;throw this.handleError(R,M)}}}if(this.listeners.OnceExit)for(let[v,C]of this.listeners.OnceExit){this.result.lastPlugin=v;try{if(w.type==="document"){let R=w.nodes.map(M=>C(M,this.helpers));await Promise.all(R);}else await C(w,this.helpers);}catch(R){throw this.handleError(R)}}}return this.processed=true,this.stringify()}runOnRoot(w){this.result.lastPlugin=w;try{if(typeof w=="object"&&w.Once){if(this.result.root.type==="document"){let v=this.result.root.nodes.map(C=>w.Once(C,this.helpers));return m(v[0])?Promise.all(v):v}return w.Once(this.result.root,this.helpers)}else if(typeof w=="function")return w(this.result.root,this.result)}catch(v){throw this.handleError(v)}}stringify(){if(this.error)throw this.error;if(this.stringified)return this.result;this.stringified=true,this.sync();let w=this.result.opts,v=i;w.syntax&&(v=w.syntax.stringify),w.stringifier&&(v=w.stringifier),v.stringify&&(v=v.stringify);let R=new r(v,this.result.root,this.result.opts).generate();return this.result.css=R[0],this.result.map=R[1],this.result}sync(){if(this.error)throw this.error;if(this.processed)return this.result;if(this.processed=true,this.processing)throw this.getAsyncError();for(let w of this.plugins){let v=this.runOnRoot(w);if(m(v))throw this.getAsyncError()}if(this.prepareVisitors(),this.hasListener){let w=this.result.root;for(;!w[e];)w[e]=true,this.walkSync(w);if(this.listeners.OnceExit)if(w.type==="document")for(let v of w.nodes)this.visitSync(this.listeners.OnceExit,v);else this.visitSync(this.listeners.OnceExit,w);}return this.result}then(w,v){return this.async().then(w,v)}toString(){return this.css}visitSync(w,v){for(let[C,R]of w){this.result.lastPlugin=C;let M;try{M=R(v,this.helpers);}catch(I){throw this.handleError(I,v.proxyOf)}if(v.type!=="root"&&v.type!=="document"&&!v.parent)return true;if(m(M))throw this.getAsyncError()}}visitTick(w){let v=w[w.length-1],{node:C,visitors:R}=v;if(C.type!=="root"&&C.type!=="document"&&!C.parent){w.pop();return}if(R.length>0&&v.visitorIndex<R.length){let[I,O]=R[v.visitorIndex];v.visitorIndex+=1,v.visitorIndex===R.length&&(v.visitors=[],v.visitorIndex=0),this.result.lastPlugin=I;try{return O(C.toProxy(),this.helpers)}catch(k){throw this.handleError(k,C)}}if(v.iterator!==0){let I=v.iterator,O;for(;O=C.nodes[C.indexes[I]];)if(C.indexes[I]+=1,!O[e]){O[e]=true,w.push(g(O));return}v.iterator=0,delete C.indexes[I];}let M=v.events;for(;v.eventIndex<M.length;){let I=M[v.eventIndex];if(v.eventIndex+=1,I===u){C.nodes&&C.nodes.length&&(C[e]=true,v.iterator=C.getIterator());return}else if(this.listeners[I]){v.visitors=this.listeners[I];return}}w.pop();}walkSync(w){w[e]=true;let v=p(w);for(let C of v)if(C===u)w.nodes&&w.each(R=>{R[e]||this.walkSync(R);});else {let R=this.listeners[C];if(R&&this.visitSync(R,w.toProxy()))return}}warnings(){return this.sync().warnings()}get content(){return this.stringify().content}get css(){return this.stringify().css}get map(){return this.stringify().map}get messages(){return this.sync().messages}get opts(){return this.result.opts}get processor(){return this.result.processor}get root(){return this.sync().root}get[Symbol.toStringTag](){return "LazyResult"}}return b.registerPostcss=E=>{y=E;},_r=b,b.default=b,h.registerLazyResult(b),o.registerLazyResult(b),_r}var Fr,Zi;function iu(){if(Zi)return Fr;Zi=1;let e=no(),t=_t(),i=qn(),n=Fn();class o{constructor(d,a,h){a=a.toString(),this.stringified=false,this._processor=d,this._css=a,this._opts=h,this._map=void 0;let s,f=t;this.result=new n(this._processor,s,this._opts),this.result.css=a;let c=this;Object.defineProperty(this.result,"root",{get(){return c.root}});let u=new e(f,s,this._opts,a);if(u.isMap()){let[m,p]=u.generate();m&&(this.result.css=m),p&&(this.result.map=p);}else u.clearAnnotation(),this.result.css=u.css;}async(){return this.error?Promise.reject(this.error):Promise.resolve(this.result)}catch(d){return this.async().catch(d)}finally(d){return this.async().then(d,d)}sync(){if(this.error)throw this.error;return this.result}then(d,a){return this.async().then(d,a)}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 d,a=i;try{d=a(this._css,this._opts);}catch(h){this.error=h;}if(this.error)throw this.error;return this._root=d,d}get[Symbol.toStringTag](){return "NoWorkResult"}}return Fr=o,o.default=o,Fr}var Ur,Qi;function su(){if(Qi)return Ur;Qi=1;let e=iu(),t=ao(),r=_n(),i=at();class n{constructor(l=[]){this.version="8.4.38",this.plugins=this.normalize(l);}normalize(l){let d=[];for(let a of l)if(a.postcss===true?a=a():a.postcss&&(a=a.postcss),typeof a=="object"&&Array.isArray(a.plugins))d=d.concat(a.plugins);else if(typeof a=="object"&&a.postcssPlugin)d.push(a);else if(typeof a=="function")d.push(a);else if(!(typeof a=="object"&&(a.parse||a.stringify)))throw new Error(a+" is not a PostCSS plugin");return d}process(l,d={}){return !this.plugins.length&&!d.parser&&!d.stringifier&&!d.syntax?new e(this,l,d):new t(this,l,d)}use(l){return this.plugins=this.plugins.concat(this.normalize([l])),this}}return Ur=n,n.default=n,i.registerProcessor(n),r.registerProcessor(n),Ur}var Br,es;function ou(){if(es)return Br;es=1;let e=Ut(),t=ro(),r=qt(),i=Un(),n=Bt(),o=at(),l=Bn();function d(a,h){if(Array.isArray(a))return a.map(c=>d(c));let{inputs:s,...f}=a;if(s){h=[];for(let c of s){let u={...c,__proto__:n.prototype};u.map&&(u.map={...u.map,__proto__:t.prototype}),h.push(u);}}if(f.nodes&&(f.nodes=a.nodes.map(c=>d(c,h))),f.source){let{inputId:c,...u}=f.source;f.source=u,c!=null&&(f.source.input=h[c]);}if(f.type==="root")return new o(f);if(f.type==="decl")return new e(f);if(f.type==="rule")return new l(f);if(f.type==="comment")return new r(f);if(f.type==="atrule")return new i(f);throw new Error("Unknown node type: "+a.type)}return Br=d,d.default=d,Br}var qr,ts;function au(){if(ts)return qr;ts=1;let e=Ln(),t=Ut(),r=ao(),i=_e(),n=su(),o=_t(),l=ou(),d=_n(),a=so(),h=qt(),s=Un(),f=Fn(),c=Bt(),u=qn(),m=oo(),p=Bn(),g=at(),S=Ft();function y(...b){return b.length===1&&Array.isArray(b[0])&&(b=b[0]),new n(b)}return y.plugin=function(E,w){let v=false;function C(...M){console&&console.warn&&!v&&(v=true,console.warn(E+`: postcss.plugin was deprecated. Migration guide:
25
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:
26
- https://www.w3ctech.com/topic/2226`));let M=w(...I);return M.postcssPlugin=E,M.postcssVersion=new n().version,M}let R;return Object.defineProperty(C,"postcss",{get(){return R||(R=C()),R}}),C.process=function(I,M,O){return y([C(O)]).process(I,M)},C},y.stringify=o,y.parse=u,y.fromJSON=l,y.list=m,y.comment=b=>new h(b),y.atRule=b=>new s(b),y.decl=b=>new t(b),y.rule=b=>new d(b),y.root=b=>new g(b),y.document=b=>new p(b),y.CssSyntaxError=e,y.Declaration=t,y.Container=i,y.Processor=n,y.Document=p,y.Comment=h,y.Warning=a,y.AtRule=s,y.Result=f,y.Input=c,y.Rule=d,y.Root=g,y.Node=S,r.registerPostcss(y),qr=y,y.default=y,qr}var au=ou(),K=Xl(au);K.stringify;K.fromJSON;K.plugin;K.parse;K.list;K.document;K.comment;K.atRule;K.rule;K.decl;K.root;K.CssSyntaxError;K.Declaration;K.Container;K.Processor;K.Document;K.Comment;K.Warning;K.AtRule;K.Result;K.Input;K.Rule;K.Root;K.Node;var lu=Object.defineProperty,uu=(e,t,r)=>t in e?lu(e,t,{enumerable:true,configurable:true,writable:true,value:r}):e[t]=r,ye=(e,t,r)=>uu(e,typeof t!="symbol"?t+"":t,r);Date.now().toString();function cu(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}function fu(e){if(e.__esModule)return e;var t=e.default;if(typeof t=="function"){var r=function i(){return this instanceof i?Reflect.construct(t,arguments,this.constructor):t.apply(this,arguments)};r.prototype=t.prototype;}else r={};return Object.defineProperty(r,"__esModule",{value:true}),Object.keys(e).forEach(function(i){var n=Object.getOwnPropertyDescriptor(e,i);Object.defineProperty(r,i,n.get?n:{enumerable:true,get:function(){return e[i]}});}),r}var St={exports:{}},ts;function hu(){if(ts)return St.exports;ts=1;var e=String,t=function(){return {isColorSupported:false,reset:e,bold:e,dim:e,italic:e,underline:e,inverse:e,hidden:e,strikethrough:e,black:e,red:e,green:e,yellow:e,blue:e,magenta:e,cyan:e,white:e,gray:e,bgBlack:e,bgRed:e,bgGreen:e,bgYellow:e,bgBlue:e,bgMagenta:e,bgCyan:e,bgWhite:e}};return St.exports=t(),St.exports.createColors=t,St.exports}var du={},pu=Object.freeze(Object.defineProperty({__proto__:null,default:du},Symbol.toStringTag,{value:"Module"})),Ee=fu(pu),zr,rs;function zn(){if(rs)return zr;rs=1;let e=hu(),t=Ee;class r extends Error{constructor(n,o,l,p,a,h){super(n),this.name="CssSyntaxError",this.reason=n,a&&(this.file=a),p&&(this.source=p),h&&(this.plugin=h),typeof o<"u"&&typeof l<"u"&&(typeof o=="number"?(this.line=o,this.column=l):(this.line=o.line,this.column=o.column,this.endLine=l.line,this.endColumn=l.column)),this.setMessage(),Error.captureStackTrace&&Error.captureStackTrace(this,r);}setMessage(){this.message=this.plugin?this.plugin+": ":"",this.message+=this.file?this.file:"<css input>",typeof this.line<"u"&&(this.message+=":"+this.line+":"+this.column),this.message+=": "+this.reason;}showSourceCode(n){if(!this.source)return "";let o=this.source;n==null&&(n=e.isColorSupported),t&&n&&(o=t(o));let l=o.split(/\r?\n/),p=Math.max(this.line-3,0),a=Math.min(this.line+2,l.length),h=String(a).length,s,f;if(n){let{bold:c,gray:u,red:m}=e.createColors(true);s=d=>c(m(d)),f=d=>u(d);}else s=f=c=>c;return l.slice(p,a).map((c,u)=>{let m=p+1+u,d=" "+(" "+m).slice(-h)+" | ";if(m===this.line){let g=f(d.replace(/\d/g," "))+c.slice(0,this.column-1).replace(/[^\t]/g," ");return s(">")+f(d)+c+`
27
- `+g+s("^")}return " "+f(d)+c}).join(`
26
+ https://www.w3ctech.com/topic/2226`));let I=w(...M);return I.postcssPlugin=E,I.postcssVersion=new n().version,I}let R;return Object.defineProperty(C,"postcss",{get(){return R||(R=C()),R}}),C.process=function(M,I,O){return y([C(O)]).process(M,I)},C},y.stringify=o,y.parse=u,y.fromJSON=l,y.list=m,y.comment=b=>new h(b),y.atRule=b=>new s(b),y.decl=b=>new t(b),y.rule=b=>new p(b),y.root=b=>new g(b),y.document=b=>new d(b),y.CssSyntaxError=e,y.Declaration=t,y.Container=i,y.Processor=n,y.Document=d,y.Comment=h,y.Warning=a,y.AtRule=s,y.Result=f,y.Input=c,y.Rule=p,y.Root=g,y.Node=S,r.registerPostcss(y),qr=y,y.default=y,qr}var lu=au(),K=Jl(lu);K.stringify;K.fromJSON;K.plugin;K.parse;K.list;K.document;K.comment;K.atRule;K.rule;K.decl;K.root;K.CssSyntaxError;K.Declaration;K.Container;K.Processor;K.Document;K.Comment;K.Warning;K.AtRule;K.Result;K.Input;K.Rule;K.Root;K.Node;var uu=Object.defineProperty,cu=(e,t,r)=>t in e?uu(e,t,{enumerable:true,configurable:true,writable:true,value:r}):e[t]=r,ye=(e,t,r)=>cu(e,typeof t!="symbol"?t+"":t,r);Date.now().toString();function fu(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}function hu(e){if(e.__esModule)return e;var t=e.default;if(typeof t=="function"){var r=function i(){return this instanceof i?Reflect.construct(t,arguments,this.constructor):t.apply(this,arguments)};r.prototype=t.prototype;}else r={};return Object.defineProperty(r,"__esModule",{value:true}),Object.keys(e).forEach(function(i){var n=Object.getOwnPropertyDescriptor(e,i);Object.defineProperty(r,i,n.get?n:{enumerable:true,get:function(){return e[i]}});}),r}var St={exports:{}},rs;function du(){if(rs)return St.exports;rs=1;var e=String,t=function(){return {isColorSupported:false,reset:e,bold:e,dim:e,italic:e,underline:e,inverse:e,hidden:e,strikethrough:e,black:e,red:e,green:e,yellow:e,blue:e,magenta:e,cyan:e,white:e,gray:e,bgBlack:e,bgRed:e,bgGreen:e,bgYellow:e,bgBlue:e,bgMagenta:e,bgCyan:e,bgWhite:e}};return St.exports=t(),St.exports.createColors=t,St.exports}var pu={},mu=Object.freeze(Object.defineProperty({__proto__:null,default:pu},Symbol.toStringTag,{value:"Module"})),Ee=hu(mu),zr,ns;function zn(){if(ns)return zr;ns=1;let e=du(),t=Ee;class r extends Error{constructor(n,o,l,d,a,h){super(n),this.name="CssSyntaxError",this.reason=n,a&&(this.file=a),d&&(this.source=d),h&&(this.plugin=h),typeof o<"u"&&typeof l<"u"&&(typeof o=="number"?(this.line=o,this.column=l):(this.line=o.line,this.column=o.column,this.endLine=l.line,this.endColumn=l.column)),this.setMessage(),Error.captureStackTrace&&Error.captureStackTrace(this,r);}setMessage(){this.message=this.plugin?this.plugin+": ":"",this.message+=this.file?this.file:"<css input>",typeof this.line<"u"&&(this.message+=":"+this.line+":"+this.column),this.message+=": "+this.reason;}showSourceCode(n){if(!this.source)return "";let o=this.source;n==null&&(n=e.isColorSupported),t&&n&&(o=t(o));let l=o.split(/\r?\n/),d=Math.max(this.line-3,0),a=Math.min(this.line+2,l.length),h=String(a).length,s,f;if(n){let{bold:c,gray:u,red:m}=e.createColors(true);s=p=>c(m(p)),f=p=>u(p);}else s=f=c=>c;return l.slice(d,a).map((c,u)=>{let m=d+1+u,p=" "+(" "+m).slice(-h)+" | ";if(m===this.line){let g=f(p.replace(/\d/g," "))+c.slice(0,this.column-1).replace(/[^\t]/g," ");return s(">")+f(p)+c+`
27
+ `+g+s("^")}return " "+f(p)+c}).join(`
28
28
  `)}toString(){let n=this.showSourceCode();return n&&(n=`
29
29
 
30
30
  `+n+`
31
- `),this.name+": "+this.message+n}}return zr=r,r.default=r,zr}var Ct={},ns;function $n(){return ns||(ns=1,Ct.isClean=Symbol("isClean"),Ct.my=Symbol("my")),Ct}var $r,is;function ao(){if(is)return $r;is=1;let e={after:`
31
+ `),this.name+": "+this.message+n}}return zr=r,r.default=r,zr}var Ct={},is;function $n(){return is||(is=1,Ct.isClean=Symbol("isClean"),Ct.my=Symbol("my")),Ct}var $r,ss;function lo(){if(ss)return $r;ss=1;let e={after:`
32
32
  `,beforeClose:`
33
33
  `,beforeComment:`
34
34
  `,beforeDecl:`
35
35
  `,beforeOpen:" ",beforeRule:`
36
- `,colon:": ",commentLeft:" ",commentRight:" ",emptyBody:"",indent:" ",semicolon:false};function t(i){return i[0].toUpperCase()+i.slice(1)}class r{constructor(n){this.builder=n;}atrule(n,o){let l="@"+n.name,p=n.params?this.rawValue(n,"params"):"";if(typeof n.raws.afterName<"u"?l+=n.raws.afterName:p&&(l+=" "),n.nodes)this.block(n,l+p);else {let a=(n.raws.between||"")+(o?";":"");this.builder(l+p+a,n);}}beforeAfter(n,o){let l;n.type==="decl"?l=this.raw(n,null,"beforeDecl"):n.type==="comment"?l=this.raw(n,null,"beforeComment"):o==="before"?l=this.raw(n,null,"beforeRule"):l=this.raw(n,null,"beforeClose");let p=n.parent,a=0;for(;p&&p.type!=="root";)a+=1,p=p.parent;if(l.includes(`
37
- `)){let h=this.raw(n,null,"indent");if(h.length)for(let s=0;s<a;s++)l+=h;}return l}block(n,o){let l=this.raw(n,"between","beforeOpen");this.builder(o+l+"{",n,"start");let p;n.nodes&&n.nodes.length?(this.body(n),p=this.raw(n,"after")):p=this.raw(n,"after","emptyBody"),p&&this.builder(p),this.builder("}",n,"end");}body(n){let o=n.nodes.length-1;for(;o>0&&n.nodes[o].type==="comment";)o-=1;let l=this.raw(n,"semicolon");for(let p=0;p<n.nodes.length;p++){let a=n.nodes[p],h=this.raw(a,"before");h&&this.builder(h),this.stringify(a,o!==p||l);}}comment(n){let o=this.raw(n,"left","commentLeft"),l=this.raw(n,"right","commentRight");this.builder("/*"+o+n.text+l+"*/",n);}decl(n,o){let l=this.raw(n,"between","colon"),p=n.prop+l+this.rawValue(n,"value");n.important&&(p+=n.raws.important||" !important"),o&&(p+=";"),this.builder(p,n);}document(n){this.body(n);}raw(n,o,l){let p;if(l||(l=o),o&&(p=n.raws[o],typeof p<"u"))return p;let a=n.parent;if(l==="before"&&(!a||a.type==="root"&&a.first===n||a&&a.type==="document"))return "";if(!a)return e[l];let h=n.root();if(h.rawCache||(h.rawCache={}),typeof h.rawCache[l]<"u")return h.rawCache[l];if(l==="before"||l==="after")return this.beforeAfter(n,l);{let s="raw"+t(l);this[s]?p=this[s](h,n):h.walk(f=>{if(p=f.raws[o],typeof p<"u")return false});}return typeof p>"u"&&(p=e[l]),h.rawCache[l]=p,p}rawBeforeClose(n){let o;return n.walk(l=>{if(l.nodes&&l.nodes.length>0&&typeof l.raws.after<"u")return o=l.raws.after,o.includes(`
38
- `)&&(o=o.replace(/[^\n]+$/,"")),false}),o&&(o=o.replace(/\S/g,"")),o}rawBeforeComment(n,o){let l;return n.walkComments(p=>{if(typeof p.raws.before<"u")return l=p.raws.before,l.includes(`
39
- `)&&(l=l.replace(/[^\n]+$/,"")),false}),typeof l>"u"?l=this.raw(o,null,"beforeDecl"):l&&(l=l.replace(/\S/g,"")),l}rawBeforeDecl(n,o){let l;return n.walkDecls(p=>{if(typeof p.raws.before<"u")return l=p.raws.before,l.includes(`
36
+ `,colon:": ",commentLeft:" ",commentRight:" ",emptyBody:"",indent:" ",semicolon:false};function t(i){return i[0].toUpperCase()+i.slice(1)}class r{constructor(n){this.builder=n;}atrule(n,o){let l="@"+n.name,d=n.params?this.rawValue(n,"params"):"";if(typeof n.raws.afterName<"u"?l+=n.raws.afterName:d&&(l+=" "),n.nodes)this.block(n,l+d);else {let a=(n.raws.between||"")+(o?";":"");this.builder(l+d+a,n);}}beforeAfter(n,o){let l;n.type==="decl"?l=this.raw(n,null,"beforeDecl"):n.type==="comment"?l=this.raw(n,null,"beforeComment"):o==="before"?l=this.raw(n,null,"beforeRule"):l=this.raw(n,null,"beforeClose");let d=n.parent,a=0;for(;d&&d.type!=="root";)a+=1,d=d.parent;if(l.includes(`
37
+ `)){let h=this.raw(n,null,"indent");if(h.length)for(let s=0;s<a;s++)l+=h;}return l}block(n,o){let l=this.raw(n,"between","beforeOpen");this.builder(o+l+"{",n,"start");let d;n.nodes&&n.nodes.length?(this.body(n),d=this.raw(n,"after")):d=this.raw(n,"after","emptyBody"),d&&this.builder(d),this.builder("}",n,"end");}body(n){let o=n.nodes.length-1;for(;o>0&&n.nodes[o].type==="comment";)o-=1;let l=this.raw(n,"semicolon");for(let d=0;d<n.nodes.length;d++){let a=n.nodes[d],h=this.raw(a,"before");h&&this.builder(h),this.stringify(a,o!==d||l);}}comment(n){let o=this.raw(n,"left","commentLeft"),l=this.raw(n,"right","commentRight");this.builder("/*"+o+n.text+l+"*/",n);}decl(n,o){let l=this.raw(n,"between","colon"),d=n.prop+l+this.rawValue(n,"value");n.important&&(d+=n.raws.important||" !important"),o&&(d+=";"),this.builder(d,n);}document(n){this.body(n);}raw(n,o,l){let d;if(l||(l=o),o&&(d=n.raws[o],typeof d<"u"))return d;let a=n.parent;if(l==="before"&&(!a||a.type==="root"&&a.first===n||a&&a.type==="document"))return "";if(!a)return e[l];let h=n.root();if(h.rawCache||(h.rawCache={}),typeof h.rawCache[l]<"u")return h.rawCache[l];if(l==="before"||l==="after")return this.beforeAfter(n,l);{let s="raw"+t(l);this[s]?d=this[s](h,n):h.walk(f=>{if(d=f.raws[o],typeof d<"u")return false});}return typeof d>"u"&&(d=e[l]),h.rawCache[l]=d,d}rawBeforeClose(n){let o;return n.walk(l=>{if(l.nodes&&l.nodes.length>0&&typeof l.raws.after<"u")return o=l.raws.after,o.includes(`
38
+ `)&&(o=o.replace(/[^\n]+$/,"")),false}),o&&(o=o.replace(/\S/g,"")),o}rawBeforeComment(n,o){let l;return n.walkComments(d=>{if(typeof d.raws.before<"u")return l=d.raws.before,l.includes(`
39
+ `)&&(l=l.replace(/[^\n]+$/,"")),false}),typeof l>"u"?l=this.raw(o,null,"beforeDecl"):l&&(l=l.replace(/\S/g,"")),l}rawBeforeDecl(n,o){let l;return n.walkDecls(d=>{if(typeof d.raws.before<"u")return l=d.raws.before,l.includes(`
40
40
  `)&&(l=l.replace(/[^\n]+$/,"")),false}),typeof l>"u"?l=this.raw(o,null,"beforeRule"):l&&(l=l.replace(/\S/g,"")),l}rawBeforeOpen(n){let o;return n.walk(l=>{if(l.type!=="decl"&&(o=l.raws.between,typeof o<"u"))return false}),o}rawBeforeRule(n){let o;return n.walk(l=>{if(l.nodes&&(l.parent!==n||n.first!==l)&&typeof l.raws.before<"u")return o=l.raws.before,o.includes(`
41
- `)&&(o=o.replace(/[^\n]+$/,"")),false}),o&&(o=o.replace(/\S/g,"")),o}rawColon(n){let o;return n.walkDecls(l=>{if(typeof l.raws.between<"u")return o=l.raws.between.replace(/[^\s:]/g,""),false}),o}rawEmptyBody(n){let o;return n.walk(l=>{if(l.nodes&&l.nodes.length===0&&(o=l.raws.after,typeof o<"u"))return false}),o}rawIndent(n){if(n.raws.indent)return n.raws.indent;let o;return n.walk(l=>{let p=l.parent;if(p&&p!==n&&p.parent&&p.parent===n&&typeof l.raws.before<"u"){let a=l.raws.before.split(`
42
- `);return o=a[a.length-1],o=o.replace(/\S/g,""),false}}),o}rawSemicolon(n){let o;return n.walk(l=>{if(l.nodes&&l.nodes.length&&l.last.type==="decl"&&(o=l.raws.semicolon,typeof o<"u"))return false}),o}rawValue(n,o){let l=n[o],p=n.raws[o];return p&&p.value===l?p.raw:l}root(n){this.body(n),n.raws.after&&this.builder(n.raws.after);}rule(n){this.block(n,this.rawValue(n,"selector")),n.raws.ownSemicolon&&this.builder(n.raws.ownSemicolon,n,"end");}stringify(n,o){if(!this[n.type])throw new Error("Unknown AST node type "+n.type+". Maybe you need to change PostCSS stringifier.");this[n.type](n,o);}}return $r=r,r.default=r,$r}var Wr,ss;function zt(){if(ss)return Wr;ss=1;let e=ao();function t(r,i){new e(i).stringify(r);}return Wr=t,t.default=t,Wr}var Hr,os;function $t(){if(os)return Hr;os=1;let{isClean:e,my:t}=$n(),r=zn(),i=ao(),n=zt();function o(p,a){let h=new p.constructor;for(let s in p){if(!Object.prototype.hasOwnProperty.call(p,s)||s==="proxyCache")continue;let f=p[s],c=typeof f;s==="parent"&&c==="object"?a&&(h[s]=a):s==="source"?h[s]=f:Array.isArray(f)?h[s]=f.map(u=>o(u,h)):(c==="object"&&f!==null&&(f=o(f)),h[s]=f);}return h}class l{constructor(a={}){this.raws={},this[e]=false,this[t]=true;for(let h in a)if(h==="nodes"){this.nodes=[];for(let s of a[h])typeof s.clone=="function"?this.append(s.clone()):this.append(s);}else this[h]=a[h];}addToError(a){if(a.postcssNode=this,a.stack&&this.source&&/\n\s{4}at /.test(a.stack)){let h=this.source;a.stack=a.stack.replace(/\n\s{4}at /,`$&${h.input.from}:${h.start.line}:${h.start.column}$&`);}return a}after(a){return this.parent.insertAfter(this,a),this}assign(a={}){for(let h in a)this[h]=a[h];return this}before(a){return this.parent.insertBefore(this,a),this}cleanRaws(a){delete this.raws.before,delete this.raws.after,a||delete this.raws.between;}clone(a={}){let h=o(this);for(let s in a)h[s]=a[s];return h}cloneAfter(a={}){let h=this.clone(a);return this.parent.insertAfter(this,h),h}cloneBefore(a={}){let h=this.clone(a);return this.parent.insertBefore(this,h),h}error(a,h={}){if(this.source){let{end:s,start:f}=this.rangeBy(h);return this.source.input.error(a,{column:f.column,line:f.line},{column:s.column,line:s.line},h)}return new r(a)}getProxyProcessor(){return {get(a,h){return h==="proxyOf"?a:h==="root"?()=>a.root().toProxy():a[h]},set(a,h,s){return a[h]===s||(a[h]=s,(h==="prop"||h==="value"||h==="name"||h==="params"||h==="important"||h==="text")&&a.markDirty()),true}}}markDirty(){if(this[e]){this[e]=false;let a=this;for(;a=a.parent;)a[e]=false;}}next(){if(!this.parent)return;let a=this.parent.index(this);return this.parent.nodes[a+1]}positionBy(a,h){let s=this.source.start;if(a.index)s=this.positionInside(a.index,h);else if(a.word){h=this.toString();let f=h.indexOf(a.word);f!==-1&&(s=this.positionInside(f,h));}return s}positionInside(a,h){let s=h||this.toString(),f=this.source.start.column,c=this.source.start.line;for(let u=0;u<a;u++)s[u]===`
43
- `?(f=1,c+=1):f+=1;return {column:f,line:c}}prev(){if(!this.parent)return;let a=this.parent.index(this);return this.parent.nodes[a-1]}rangeBy(a){let h={column:this.source.start.column,line:this.source.start.line},s=this.source.end?{column:this.source.end.column+1,line:this.source.end.line}:{column:h.column+1,line:h.line};if(a.word){let f=this.toString(),c=f.indexOf(a.word);c!==-1&&(h=this.positionInside(c,f),s=this.positionInside(c+a.word.length,f));}else a.start?h={column:a.start.column,line:a.start.line}:a.index&&(h=this.positionInside(a.index)),a.end?s={column:a.end.column,line:a.end.line}:typeof a.endIndex=="number"?s=this.positionInside(a.endIndex):a.index&&(s=this.positionInside(a.index+1));return (s.line<h.line||s.line===h.line&&s.column<=h.column)&&(s={column:h.column+1,line:h.line}),{end:s,start:h}}raw(a,h){return new i().raw(this,a,h)}remove(){return this.parent&&this.parent.removeChild(this),this.parent=void 0,this}replaceWith(...a){if(this.parent){let h=this,s=false;for(let f of a)f===this?s=true:s?(this.parent.insertAfter(h,f),h=f):this.parent.insertBefore(h,f);s||this.remove();}return this}root(){let a=this;for(;a.parent&&a.parent.type!=="document";)a=a.parent;return a}toJSON(a,h){let s={},f=h==null;h=h||new Map;let c=0;for(let u in this){if(!Object.prototype.hasOwnProperty.call(this,u)||u==="parent"||u==="proxyCache")continue;let m=this[u];if(Array.isArray(m))s[u]=m.map(d=>typeof d=="object"&&d.toJSON?d.toJSON(null,h):d);else if(typeof m=="object"&&m.toJSON)s[u]=m.toJSON(null,h);else if(u==="source"){let d=h.get(m.input);d==null&&(d=c,h.set(m.input,c),c++),s[u]={end:m.end,inputId:d,start:m.start};}else s[u]=m;}return f&&(s.inputs=[...h.keys()].map(u=>u.toJSON())),s}toProxy(){return this.proxyCache||(this.proxyCache=new Proxy(this,this.getProxyProcessor())),this.proxyCache}toString(a=n){a.stringify&&(a=a.stringify);let h="";return a(this,s=>{h+=s;}),h}warn(a,h,s){let f={node:this};for(let c in s)f[c]=s[c];return a.warn(h,f)}get proxyOf(){return this}}return Hr=l,l.default=l,Hr}var jr,as;function Wt(){if(as)return jr;as=1;let e=$t();class t extends e{constructor(i){i&&typeof i.value<"u"&&typeof i.value!="string"&&(i={...i,value:String(i.value)}),super(i),this.type="decl";}get variable(){return this.prop.startsWith("--")||this.prop[0]==="$"}}return jr=t,t.default=t,jr}var Vr,ls;function mu(){if(ls)return Vr;ls=1;let e="useandom-26T198340PX75pxJACKVERYMINDBUSHWOLF_GQZbfghjklqvwyzrict";return Vr={nanoid:(i=21)=>{let n="",o=i;for(;o--;)n+=e[Math.random()*64|0];return n},customAlphabet:(i,n=21)=>(o=n)=>{let l="",p=o;for(;p--;)l+=i[Math.random()*i.length|0];return l}},Vr}var Gr,us;function lo(){if(us)return Gr;us=1;let{SourceMapConsumer:e,SourceMapGenerator:t}=Ee,{existsSync:r,readFileSync:i}=Ee,{dirname:n,join:o}=Ee;function l(a){return Buffer?Buffer.from(a,"base64").toString():window.atob(a)}class p{constructor(h,s){if(s.map===false)return;this.loadAnnotation(h),this.inline=this.startWith(this.annotation,"data:");let f=s.map?s.map.prev:void 0,c=this.loadMap(s.from,f);!this.mapFile&&s.from&&(this.mapFile=s.from),this.mapFile&&(this.root=n(this.mapFile)),c&&(this.text=c);}consumer(){return this.consumerCache||(this.consumerCache=new e(this.text)),this.consumerCache}decodeInline(h){let s=/^data:application\/json;charset=utf-?8;base64,/,f=/^data:application\/json;base64,/,c=/^data:application\/json;charset=utf-?8,/,u=/^data:application\/json,/;if(c.test(h)||u.test(h))return decodeURIComponent(h.substr(RegExp.lastMatch.length));if(s.test(h)||f.test(h))return l(h.substr(RegExp.lastMatch.length));let m=h.match(/data:application\/json;([^,]+),/)[1];throw new Error("Unsupported source map encoding "+m)}getAnnotationURL(h){return h.replace(/^\/\*\s*# sourceMappingURL=/,"").trim()}isMap(h){return typeof h!="object"?false:typeof h.mappings=="string"||typeof h._mappings=="string"||Array.isArray(h.sections)}loadAnnotation(h){let s=h.match(/\/\*\s*# sourceMappingURL=/gm);if(!s)return;let f=h.lastIndexOf(s.pop()),c=h.indexOf("*/",f);f>-1&&c>-1&&(this.annotation=this.getAnnotationURL(h.substring(f,c)));}loadFile(h){if(this.root=n(h),r(h))return this.mapFile=h,i(h,"utf-8").toString().trim()}loadMap(h,s){if(s===false)return false;if(s){if(typeof s=="string")return s;if(typeof s=="function"){let f=s(h);if(f){let c=this.loadFile(f);if(!c)throw new Error("Unable to load previous source map: "+f.toString());return c}}else {if(s instanceof e)return t.fromSourceMap(s).toString();if(s instanceof t)return s.toString();if(this.isMap(s))return JSON.stringify(s);throw new Error("Unsupported previous source map format: "+s.toString())}}else {if(this.inline)return this.decodeInline(this.annotation);if(this.annotation){let f=this.annotation;return h&&(f=o(n(h),f)),this.loadFile(f)}}}startWith(h,s){return h?h.substr(0,s.length)===s:false}withContent(){return !!(this.consumer().sourcesContent&&this.consumer().sourcesContent.length>0)}}return Gr=p,p.default=p,Gr}var Yr,cs;function Ht(){if(cs)return Yr;cs=1;let{SourceMapConsumer:e,SourceMapGenerator:t}=Ee,{fileURLToPath:r,pathToFileURL:i}=Ee,{isAbsolute:n,resolve:o}=Ee,{nanoid:l}=mu(),p=Ee,a=zn(),h=lo(),s=Symbol("fromOffsetCache"),f=!!(e&&t),c=!!(o&&n);class u{constructor(d,g={}){if(d===null||typeof d>"u"||typeof d=="object"&&!d.toString)throw new Error(`PostCSS received ${d} instead of CSS string`);if(this.css=d.toString(),this.css[0]==="\uFEFF"||this.css[0]==="\uFFFE"?(this.hasBOM=true,this.css=this.css.slice(1)):this.hasBOM=false,g.from&&(!c||/^\w+:\/\//.test(g.from)||n(g.from)?this.file=g.from:this.file=o(g.from)),c&&f){let S=new h(this.css,g);if(S.text){this.map=S;let y=S.consumer().file;!this.file&&y&&(this.file=this.mapResolve(y));}}this.file||(this.id="<input css "+l(6)+">"),this.map&&(this.map.file=this.from);}error(d,g,S,y={}){let b,E,w;if(g&&typeof g=="object"){let C=g,R=S;if(typeof C.offset=="number"){let I=this.fromOffset(C.offset);g=I.line,S=I.col;}else g=C.line,S=C.column;if(typeof R.offset=="number"){let I=this.fromOffset(R.offset);E=I.line,w=I.col;}else E=R.line,w=R.column;}else if(!S){let C=this.fromOffset(g);g=C.line,S=C.col;}let v=this.origin(g,S,E,w);return v?b=new a(d,v.endLine===void 0?v.line:{column:v.column,line:v.line},v.endLine===void 0?v.column:{column:v.endColumn,line:v.endLine},v.source,v.file,y.plugin):b=new a(d,E===void 0?g:{column:S,line:g},E===void 0?S:{column:w,line:E},this.css,this.file,y.plugin),b.input={column:S,endColumn:w,endLine:E,line:g,source:this.css},this.file&&(i&&(b.input.url=i(this.file).toString()),b.input.file=this.file),b}fromOffset(d){let g,S;if(this[s])S=this[s];else {let b=this.css.split(`
44
- `);S=new Array(b.length);let E=0;for(let w=0,v=b.length;w<v;w++)S[w]=E,E+=b[w].length+1;this[s]=S;}g=S[S.length-1];let y=0;if(d>=g)y=S.length-1;else {let b=S.length-2,E;for(;y<b;)if(E=y+(b-y>>1),d<S[E])b=E-1;else if(d>=S[E+1])y=E+1;else {y=E;break}}return {col:d-S[y]+1,line:y+1}}mapResolve(d){return /^\w+:\/\//.test(d)?d:o(this.map.consumer().sourceRoot||this.map.root||".",d)}origin(d,g,S,y){if(!this.map)return false;let b=this.map.consumer(),E=b.originalPositionFor({column:g,line:d});if(!E.source)return false;let w;typeof S=="number"&&(w=b.originalPositionFor({column:y,line:S}));let v;n(E.source)?v=i(E.source):v=new URL(E.source,this.map.consumer().sourceRoot||i(this.map.mapFile));let C={column:E.column,endColumn:w&&w.column,endLine:w&&w.line,line:E.line,url:v.toString()};if(v.protocol==="file:")if(r)C.file=r(v);else throw new Error("file: protocol is not available in this PostCSS build");let R=b.sourceContentFor(E.source);return R&&(C.source=R),C}toJSON(){let d={};for(let g of ["hasBOM","css","file","id"])this[g]!=null&&(d[g]=this[g]);return this.map&&(d.map={...this.map},d.map.consumerCache&&(d.map.consumerCache=void 0)),d}get from(){return this.file||this.id}}return Yr=u,u.default=u,p&&p.registerInput&&p.registerInput(u),Yr}var Xr,fs;function uo(){if(fs)return Xr;fs=1;let{SourceMapConsumer:e,SourceMapGenerator:t}=Ee,{dirname:r,relative:i,resolve:n,sep:o}=Ee,{pathToFileURL:l}=Ee,p=Ht(),a=!!(e&&t),h=!!(r&&n&&i&&o);class s{constructor(c,u,m,d){this.stringify=c,this.mapOpts=m.map||{},this.root=u,this.opts=m,this.css=d,this.originalCSS=d,this.usesFileUrls=!this.mapOpts.from&&this.mapOpts.absolute,this.memoizedFileURLs=new Map,this.memoizedPaths=new Map,this.memoizedURLs=new Map;}addAnnotation(){let c;this.isInline()?c="data:application/json;base64,"+this.toBase64(this.map.toString()):typeof this.mapOpts.annotation=="string"?c=this.mapOpts.annotation:typeof this.mapOpts.annotation=="function"?c=this.mapOpts.annotation(this.opts.to,this.root):c=this.outputFile()+".map";let u=`
41
+ `)&&(o=o.replace(/[^\n]+$/,"")),false}),o&&(o=o.replace(/\S/g,"")),o}rawColon(n){let o;return n.walkDecls(l=>{if(typeof l.raws.between<"u")return o=l.raws.between.replace(/[^\s:]/g,""),false}),o}rawEmptyBody(n){let o;return n.walk(l=>{if(l.nodes&&l.nodes.length===0&&(o=l.raws.after,typeof o<"u"))return false}),o}rawIndent(n){if(n.raws.indent)return n.raws.indent;let o;return n.walk(l=>{let d=l.parent;if(d&&d!==n&&d.parent&&d.parent===n&&typeof l.raws.before<"u"){let a=l.raws.before.split(`
42
+ `);return o=a[a.length-1],o=o.replace(/\S/g,""),false}}),o}rawSemicolon(n){let o;return n.walk(l=>{if(l.nodes&&l.nodes.length&&l.last.type==="decl"&&(o=l.raws.semicolon,typeof o<"u"))return false}),o}rawValue(n,o){let l=n[o],d=n.raws[o];return d&&d.value===l?d.raw:l}root(n){this.body(n),n.raws.after&&this.builder(n.raws.after);}rule(n){this.block(n,this.rawValue(n,"selector")),n.raws.ownSemicolon&&this.builder(n.raws.ownSemicolon,n,"end");}stringify(n,o){if(!this[n.type])throw new Error("Unknown AST node type "+n.type+". Maybe you need to change PostCSS stringifier.");this[n.type](n,o);}}return $r=r,r.default=r,$r}var Wr,os;function zt(){if(os)return Wr;os=1;let e=lo();function t(r,i){new e(i).stringify(r);}return Wr=t,t.default=t,Wr}var Hr,as;function $t(){if(as)return Hr;as=1;let{isClean:e,my:t}=$n(),r=zn(),i=lo(),n=zt();function o(d,a){let h=new d.constructor;for(let s in d){if(!Object.prototype.hasOwnProperty.call(d,s)||s==="proxyCache")continue;let f=d[s],c=typeof f;s==="parent"&&c==="object"?a&&(h[s]=a):s==="source"?h[s]=f:Array.isArray(f)?h[s]=f.map(u=>o(u,h)):(c==="object"&&f!==null&&(f=o(f)),h[s]=f);}return h}class l{constructor(a={}){this.raws={},this[e]=false,this[t]=true;for(let h in a)if(h==="nodes"){this.nodes=[];for(let s of a[h])typeof s.clone=="function"?this.append(s.clone()):this.append(s);}else this[h]=a[h];}addToError(a){if(a.postcssNode=this,a.stack&&this.source&&/\n\s{4}at /.test(a.stack)){let h=this.source;a.stack=a.stack.replace(/\n\s{4}at /,`$&${h.input.from}:${h.start.line}:${h.start.column}$&`);}return a}after(a){return this.parent.insertAfter(this,a),this}assign(a={}){for(let h in a)this[h]=a[h];return this}before(a){return this.parent.insertBefore(this,a),this}cleanRaws(a){delete this.raws.before,delete this.raws.after,a||delete this.raws.between;}clone(a={}){let h=o(this);for(let s in a)h[s]=a[s];return h}cloneAfter(a={}){let h=this.clone(a);return this.parent.insertAfter(this,h),h}cloneBefore(a={}){let h=this.clone(a);return this.parent.insertBefore(this,h),h}error(a,h={}){if(this.source){let{end:s,start:f}=this.rangeBy(h);return this.source.input.error(a,{column:f.column,line:f.line},{column:s.column,line:s.line},h)}return new r(a)}getProxyProcessor(){return {get(a,h){return h==="proxyOf"?a:h==="root"?()=>a.root().toProxy():a[h]},set(a,h,s){return a[h]===s||(a[h]=s,(h==="prop"||h==="value"||h==="name"||h==="params"||h==="important"||h==="text")&&a.markDirty()),true}}}markDirty(){if(this[e]){this[e]=false;let a=this;for(;a=a.parent;)a[e]=false;}}next(){if(!this.parent)return;let a=this.parent.index(this);return this.parent.nodes[a+1]}positionBy(a,h){let s=this.source.start;if(a.index)s=this.positionInside(a.index,h);else if(a.word){h=this.toString();let f=h.indexOf(a.word);f!==-1&&(s=this.positionInside(f,h));}return s}positionInside(a,h){let s=h||this.toString(),f=this.source.start.column,c=this.source.start.line;for(let u=0;u<a;u++)s[u]===`
43
+ `?(f=1,c+=1):f+=1;return {column:f,line:c}}prev(){if(!this.parent)return;let a=this.parent.index(this);return this.parent.nodes[a-1]}rangeBy(a){let h={column:this.source.start.column,line:this.source.start.line},s=this.source.end?{column:this.source.end.column+1,line:this.source.end.line}:{column:h.column+1,line:h.line};if(a.word){let f=this.toString(),c=f.indexOf(a.word);c!==-1&&(h=this.positionInside(c,f),s=this.positionInside(c+a.word.length,f));}else a.start?h={column:a.start.column,line:a.start.line}:a.index&&(h=this.positionInside(a.index)),a.end?s={column:a.end.column,line:a.end.line}:typeof a.endIndex=="number"?s=this.positionInside(a.endIndex):a.index&&(s=this.positionInside(a.index+1));return (s.line<h.line||s.line===h.line&&s.column<=h.column)&&(s={column:h.column+1,line:h.line}),{end:s,start:h}}raw(a,h){return new i().raw(this,a,h)}remove(){return this.parent&&this.parent.removeChild(this),this.parent=void 0,this}replaceWith(...a){if(this.parent){let h=this,s=false;for(let f of a)f===this?s=true:s?(this.parent.insertAfter(h,f),h=f):this.parent.insertBefore(h,f);s||this.remove();}return this}root(){let a=this;for(;a.parent&&a.parent.type!=="document";)a=a.parent;return a}toJSON(a,h){let s={},f=h==null;h=h||new Map;let c=0;for(let u in this){if(!Object.prototype.hasOwnProperty.call(this,u)||u==="parent"||u==="proxyCache")continue;let m=this[u];if(Array.isArray(m))s[u]=m.map(p=>typeof p=="object"&&p.toJSON?p.toJSON(null,h):p);else if(typeof m=="object"&&m.toJSON)s[u]=m.toJSON(null,h);else if(u==="source"){let p=h.get(m.input);p==null&&(p=c,h.set(m.input,c),c++),s[u]={end:m.end,inputId:p,start:m.start};}else s[u]=m;}return f&&(s.inputs=[...h.keys()].map(u=>u.toJSON())),s}toProxy(){return this.proxyCache||(this.proxyCache=new Proxy(this,this.getProxyProcessor())),this.proxyCache}toString(a=n){a.stringify&&(a=a.stringify);let h="";return a(this,s=>{h+=s;}),h}warn(a,h,s){let f={node:this};for(let c in s)f[c]=s[c];return a.warn(h,f)}get proxyOf(){return this}}return Hr=l,l.default=l,Hr}var jr,ls;function Wt(){if(ls)return jr;ls=1;let e=$t();class t extends e{constructor(i){i&&typeof i.value<"u"&&typeof i.value!="string"&&(i={...i,value:String(i.value)}),super(i),this.type="decl";}get variable(){return this.prop.startsWith("--")||this.prop[0]==="$"}}return jr=t,t.default=t,jr}var Vr,us;function gu(){if(us)return Vr;us=1;let e="useandom-26T198340PX75pxJACKVERYMINDBUSHWOLF_GQZbfghjklqvwyzrict";return Vr={nanoid:(i=21)=>{let n="",o=i;for(;o--;)n+=e[Math.random()*64|0];return n},customAlphabet:(i,n=21)=>(o=n)=>{let l="",d=o;for(;d--;)l+=i[Math.random()*i.length|0];return l}},Vr}var Gr,cs;function uo(){if(cs)return Gr;cs=1;let{SourceMapConsumer:e,SourceMapGenerator:t}=Ee,{existsSync:r,readFileSync:i}=Ee,{dirname:n,join:o}=Ee;function l(a){return Buffer?Buffer.from(a,"base64").toString():window.atob(a)}class d{constructor(h,s){if(s.map===false)return;this.loadAnnotation(h),this.inline=this.startWith(this.annotation,"data:");let f=s.map?s.map.prev:void 0,c=this.loadMap(s.from,f);!this.mapFile&&s.from&&(this.mapFile=s.from),this.mapFile&&(this.root=n(this.mapFile)),c&&(this.text=c);}consumer(){return this.consumerCache||(this.consumerCache=new e(this.text)),this.consumerCache}decodeInline(h){let s=/^data:application\/json;charset=utf-?8;base64,/,f=/^data:application\/json;base64,/,c=/^data:application\/json;charset=utf-?8,/,u=/^data:application\/json,/;if(c.test(h)||u.test(h))return decodeURIComponent(h.substr(RegExp.lastMatch.length));if(s.test(h)||f.test(h))return l(h.substr(RegExp.lastMatch.length));let m=h.match(/data:application\/json;([^,]+),/)[1];throw new Error("Unsupported source map encoding "+m)}getAnnotationURL(h){return h.replace(/^\/\*\s*# sourceMappingURL=/,"").trim()}isMap(h){return typeof h!="object"?false:typeof h.mappings=="string"||typeof h._mappings=="string"||Array.isArray(h.sections)}loadAnnotation(h){let s=h.match(/\/\*\s*# sourceMappingURL=/gm);if(!s)return;let f=h.lastIndexOf(s.pop()),c=h.indexOf("*/",f);f>-1&&c>-1&&(this.annotation=this.getAnnotationURL(h.substring(f,c)));}loadFile(h){if(this.root=n(h),r(h))return this.mapFile=h,i(h,"utf-8").toString().trim()}loadMap(h,s){if(s===false)return false;if(s){if(typeof s=="string")return s;if(typeof s=="function"){let f=s(h);if(f){let c=this.loadFile(f);if(!c)throw new Error("Unable to load previous source map: "+f.toString());return c}}else {if(s instanceof e)return t.fromSourceMap(s).toString();if(s instanceof t)return s.toString();if(this.isMap(s))return JSON.stringify(s);throw new Error("Unsupported previous source map format: "+s.toString())}}else {if(this.inline)return this.decodeInline(this.annotation);if(this.annotation){let f=this.annotation;return h&&(f=o(n(h),f)),this.loadFile(f)}}}startWith(h,s){return h?h.substr(0,s.length)===s:false}withContent(){return !!(this.consumer().sourcesContent&&this.consumer().sourcesContent.length>0)}}return Gr=d,d.default=d,Gr}var Yr,fs;function Ht(){if(fs)return Yr;fs=1;let{SourceMapConsumer:e,SourceMapGenerator:t}=Ee,{fileURLToPath:r,pathToFileURL:i}=Ee,{isAbsolute:n,resolve:o}=Ee,{nanoid:l}=gu(),d=Ee,a=zn(),h=uo(),s=Symbol("fromOffsetCache"),f=!!(e&&t),c=!!(o&&n);class u{constructor(p,g={}){if(p===null||typeof p>"u"||typeof p=="object"&&!p.toString)throw new Error(`PostCSS received ${p} instead of CSS string`);if(this.css=p.toString(),this.css[0]==="\uFEFF"||this.css[0]==="\uFFFE"?(this.hasBOM=true,this.css=this.css.slice(1)):this.hasBOM=false,g.from&&(!c||/^\w+:\/\//.test(g.from)||n(g.from)?this.file=g.from:this.file=o(g.from)),c&&f){let S=new h(this.css,g);if(S.text){this.map=S;let y=S.consumer().file;!this.file&&y&&(this.file=this.mapResolve(y));}}this.file||(this.id="<input css "+l(6)+">"),this.map&&(this.map.file=this.from);}error(p,g,S,y={}){let b,E,w;if(g&&typeof g=="object"){let C=g,R=S;if(typeof C.offset=="number"){let M=this.fromOffset(C.offset);g=M.line,S=M.col;}else g=C.line,S=C.column;if(typeof R.offset=="number"){let M=this.fromOffset(R.offset);E=M.line,w=M.col;}else E=R.line,w=R.column;}else if(!S){let C=this.fromOffset(g);g=C.line,S=C.col;}let v=this.origin(g,S,E,w);return v?b=new a(p,v.endLine===void 0?v.line:{column:v.column,line:v.line},v.endLine===void 0?v.column:{column:v.endColumn,line:v.endLine},v.source,v.file,y.plugin):b=new a(p,E===void 0?g:{column:S,line:g},E===void 0?S:{column:w,line:E},this.css,this.file,y.plugin),b.input={column:S,endColumn:w,endLine:E,line:g,source:this.css},this.file&&(i&&(b.input.url=i(this.file).toString()),b.input.file=this.file),b}fromOffset(p){let g,S;if(this[s])S=this[s];else {let b=this.css.split(`
44
+ `);S=new Array(b.length);let E=0;for(let w=0,v=b.length;w<v;w++)S[w]=E,E+=b[w].length+1;this[s]=S;}g=S[S.length-1];let y=0;if(p>=g)y=S.length-1;else {let b=S.length-2,E;for(;y<b;)if(E=y+(b-y>>1),p<S[E])b=E-1;else if(p>=S[E+1])y=E+1;else {y=E;break}}return {col:p-S[y]+1,line:y+1}}mapResolve(p){return /^\w+:\/\//.test(p)?p:o(this.map.consumer().sourceRoot||this.map.root||".",p)}origin(p,g,S,y){if(!this.map)return false;let b=this.map.consumer(),E=b.originalPositionFor({column:g,line:p});if(!E.source)return false;let w;typeof S=="number"&&(w=b.originalPositionFor({column:y,line:S}));let v;n(E.source)?v=i(E.source):v=new URL(E.source,this.map.consumer().sourceRoot||i(this.map.mapFile));let C={column:E.column,endColumn:w&&w.column,endLine:w&&w.line,line:E.line,url:v.toString()};if(v.protocol==="file:")if(r)C.file=r(v);else throw new Error("file: protocol is not available in this PostCSS build");let R=b.sourceContentFor(E.source);return R&&(C.source=R),C}toJSON(){let p={};for(let g of ["hasBOM","css","file","id"])this[g]!=null&&(p[g]=this[g]);return this.map&&(p.map={...this.map},p.map.consumerCache&&(p.map.consumerCache=void 0)),p}get from(){return this.file||this.id}}return Yr=u,u.default=u,d&&d.registerInput&&d.registerInput(u),Yr}var Xr,hs;function co(){if(hs)return Xr;hs=1;let{SourceMapConsumer:e,SourceMapGenerator:t}=Ee,{dirname:r,relative:i,resolve:n,sep:o}=Ee,{pathToFileURL:l}=Ee,d=Ht(),a=!!(e&&t),h=!!(r&&n&&i&&o);class s{constructor(c,u,m,p){this.stringify=c,this.mapOpts=m.map||{},this.root=u,this.opts=m,this.css=p,this.originalCSS=p,this.usesFileUrls=!this.mapOpts.from&&this.mapOpts.absolute,this.memoizedFileURLs=new Map,this.memoizedPaths=new Map,this.memoizedURLs=new Map;}addAnnotation(){let c;this.isInline()?c="data:application/json;base64,"+this.toBase64(this.map.toString()):typeof this.mapOpts.annotation=="string"?c=this.mapOpts.annotation:typeof this.mapOpts.annotation=="function"?c=this.mapOpts.annotation(this.opts.to,this.root):c=this.outputFile()+".map";let u=`
45
45
  `;this.css.includes(`\r
46
46
  `)&&(u=`\r
47
- `),this.css+=u+"/*# sourceMappingURL="+c+" */";}applyPrevMaps(){for(let c of this.previous()){let u=this.toUrl(this.path(c.file)),m=c.root||r(c.file),d;this.mapOpts.sourcesContent===false?(d=new e(c.text),d.sourcesContent&&(d.sourcesContent=null)):d=c.consumer(),this.map.applySourceMap(d,u,this.toUrl(this.path(m)));}}clearAnnotation(){if(this.mapOpts.annotation!==false)if(this.root){let c;for(let u=this.root.nodes.length-1;u>=0;u--)c=this.root.nodes[u],c.type==="comment"&&c.text.indexOf("# sourceMappingURL=")===0&&this.root.removeChild(u);}else this.css&&(this.css=this.css.replace(/\n*?\/\*#[\S\s]*?\*\/$/gm,""));}generate(){if(this.clearAnnotation(),h&&a&&this.isMap())return this.generateMap();{let c="";return this.stringify(this.root,u=>{c+=u;}),[c]}}generateMap(){if(this.root)this.generateString();else if(this.previous().length===1){let c=this.previous()[0].consumer();c.file=this.outputFile(),this.map=t.fromSourceMap(c,{ignoreInvalidMapping:true});}else this.map=new t({file:this.outputFile(),ignoreInvalidMapping:true}),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 t({file:this.outputFile(),ignoreInvalidMapping:true});let c=1,u=1,m="<no source>",d={generated:{column:0,line:0},original:{column:0,line:0},source:""},g,S;this.stringify(this.root,(y,b,E)=>{if(this.css+=y,b&&E!=="end"&&(d.generated.line=c,d.generated.column=u-1,b.source&&b.source.start?(d.source=this.sourcePath(b),d.original.line=b.source.start.line,d.original.column=b.source.start.column-1,this.map.addMapping(d)):(d.source=m,d.original.line=1,d.original.column=0,this.map.addMapping(d))),g=y.match(/\n/g),g?(c+=g.length,S=y.lastIndexOf(`
48
- `),u=y.length-S):u+=y.length,b&&E!=="start"){let w=b.parent||{raws:{}};(!(b.type==="decl"||b.type==="atrule"&&!b.nodes)||b!==w.last||w.raws.semicolon)&&(b.source&&b.source.end?(d.source=this.sourcePath(b),d.original.line=b.source.end.line,d.original.column=b.source.end.column-1,d.generated.line=c,d.generated.column=u-2,this.map.addMapping(d)):(d.source=m,d.original.line=1,d.original.column=0,d.generated.line=c,d.generated.column=u-1,this.map.addMapping(d)));}});}isAnnotation(){return this.isInline()?true:typeof this.mapOpts.annotation<"u"?this.mapOpts.annotation:this.previous().length?this.previous().some(c=>c.annotation):true}isInline(){if(typeof this.mapOpts.inline<"u")return this.mapOpts.inline;let c=this.mapOpts.annotation;return typeof c<"u"&&c!==true?false:this.previous().length?this.previous().some(u=>u.inline):true}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(c=>c.withContent()):true}outputFile(){return this.opts.to?this.path(this.opts.to):this.opts.from?this.path(this.opts.from):"to.css"}path(c){if(this.mapOpts.absolute||c.charCodeAt(0)===60||/^\w+:\/\//.test(c))return c;let u=this.memoizedPaths.get(c);if(u)return u;let m=this.opts.to?r(this.opts.to):".";typeof this.mapOpts.annotation=="string"&&(m=r(n(m,this.mapOpts.annotation)));let d=i(m,c);return this.memoizedPaths.set(c,d),d}previous(){if(!this.previousMaps)if(this.previousMaps=[],this.root)this.root.walk(c=>{if(c.source&&c.source.input.map){let u=c.source.input.map;this.previousMaps.includes(u)||this.previousMaps.push(u);}});else {let c=new p(this.originalCSS,this.opts);c.map&&this.previousMaps.push(c.map);}return this.previousMaps}setSourcesContent(){let c={};if(this.root)this.root.walk(u=>{if(u.source){let m=u.source.input.from;if(m&&!c[m]){c[m]=true;let d=this.usesFileUrls?this.toFileUrl(m):this.toUrl(this.path(m));this.map.setSourceContent(d,u.source.input.css);}}});else if(this.css){let u=this.opts.from?this.toUrl(this.path(this.opts.from)):"<no source>";this.map.setSourceContent(u,this.css);}}sourcePath(c){return this.mapOpts.from?this.toUrl(this.mapOpts.from):this.usesFileUrls?this.toFileUrl(c.source.input.from):this.toUrl(this.path(c.source.input.from))}toBase64(c){return Buffer?Buffer.from(c).toString("base64"):window.btoa(unescape(encodeURIComponent(c)))}toFileUrl(c){let u=this.memoizedFileURLs.get(c);if(u)return u;if(l){let m=l(c).toString();return this.memoizedFileURLs.set(c,m),m}else throw new Error("`map.absolute` option is not available in this PostCSS build")}toUrl(c){let u=this.memoizedURLs.get(c);if(u)return u;o==="\\"&&(c=c.replace(/\\/g,"/"));let m=encodeURI(c).replace(/[#?]/g,encodeURIComponent);return this.memoizedURLs.set(c,m),m}}return Xr=s,Xr}var Jr,hs;function jt(){if(hs)return Jr;hs=1;let e=$t();class t extends e{constructor(i){super(i),this.type="comment";}}return Jr=t,t.default=t,Jr}var Kr,ds;function Fe(){if(ds)return Kr;ds=1;let{isClean:e,my:t}=$n(),r=Wt(),i=jt(),n=$t(),o,l,p,a;function h(c){return c.map(u=>(u.nodes&&(u.nodes=h(u.nodes)),delete u.source,u))}function s(c){if(c[e]=false,c.proxyOf.nodes)for(let u of c.proxyOf.nodes)s(u);}class f extends n{append(...u){for(let m of u){let d=this.normalize(m,this.last);for(let g of d)this.proxyOf.nodes.push(g);}return this.markDirty(),this}cleanRaws(u){if(super.cleanRaws(u),this.nodes)for(let m of this.nodes)m.cleanRaws(u);}each(u){if(!this.proxyOf.nodes)return;let m=this.getIterator(),d,g;for(;this.indexes[m]<this.proxyOf.nodes.length&&(d=this.indexes[m],g=u(this.proxyOf.nodes[d],d),g!==false);)this.indexes[m]+=1;return delete this.indexes[m],g}every(u){return this.nodes.every(u)}getIterator(){this.lastEach||(this.lastEach=0),this.indexes||(this.indexes={}),this.lastEach+=1;let u=this.lastEach;return this.indexes[u]=0,u}getProxyProcessor(){return {get(u,m){return m==="proxyOf"?u:u[m]?m==="each"||typeof m=="string"&&m.startsWith("walk")?(...d)=>u[m](...d.map(g=>typeof g=="function"?(S,y)=>g(S.toProxy(),y):g)):m==="every"||m==="some"?d=>u[m]((g,...S)=>d(g.toProxy(),...S)):m==="root"?()=>u.root().toProxy():m==="nodes"?u.nodes.map(d=>d.toProxy()):m==="first"||m==="last"?u[m].toProxy():u[m]:u[m]},set(u,m,d){return u[m]===d||(u[m]=d,(m==="name"||m==="params"||m==="selector")&&u.markDirty()),true}}}index(u){return typeof u=="number"?u:(u.proxyOf&&(u=u.proxyOf),this.proxyOf.nodes.indexOf(u))}insertAfter(u,m){let d=this.index(u),g=this.normalize(m,this.proxyOf.nodes[d]).reverse();d=this.index(u);for(let y of g)this.proxyOf.nodes.splice(d+1,0,y);let S;for(let y in this.indexes)S=this.indexes[y],d<S&&(this.indexes[y]=S+g.length);return this.markDirty(),this}insertBefore(u,m){let d=this.index(u),g=d===0?"prepend":false,S=this.normalize(m,this.proxyOf.nodes[d],g).reverse();d=this.index(u);for(let b of S)this.proxyOf.nodes.splice(d,0,b);let y;for(let b in this.indexes)y=this.indexes[b],d<=y&&(this.indexes[b]=y+S.length);return this.markDirty(),this}normalize(u,m){if(typeof u=="string")u=h(o(u).nodes);else if(typeof u>"u")u=[];else if(Array.isArray(u)){u=u.slice(0);for(let g of u)g.parent&&g.parent.removeChild(g,"ignore");}else if(u.type==="root"&&this.type!=="document"){u=u.nodes.slice(0);for(let g of u)g.parent&&g.parent.removeChild(g,"ignore");}else if(u.type)u=[u];else if(u.prop){if(typeof u.value>"u")throw new Error("Value field is missed in node creation");typeof u.value!="string"&&(u.value=String(u.value)),u=[new r(u)];}else if(u.selector)u=[new l(u)];else if(u.name)u=[new p(u)];else if(u.text)u=[new i(u)];else throw new Error("Unknown node type in node creation");return u.map(g=>(g[t]||f.rebuild(g),g=g.proxyOf,g.parent&&g.parent.removeChild(g),g[e]&&s(g),typeof g.raws.before>"u"&&m&&typeof m.raws.before<"u"&&(g.raws.before=m.raws.before.replace(/\S/g,"")),g.parent=this.proxyOf,g))}prepend(...u){u=u.reverse();for(let m of u){let d=this.normalize(m,this.first,"prepend").reverse();for(let g of d)this.proxyOf.nodes.unshift(g);for(let g in this.indexes)this.indexes[g]=this.indexes[g]+d.length;}return this.markDirty(),this}push(u){return u.parent=this,this.proxyOf.nodes.push(u),this}removeAll(){for(let u of this.proxyOf.nodes)u.parent=void 0;return this.proxyOf.nodes=[],this.markDirty(),this}removeChild(u){u=this.index(u),this.proxyOf.nodes[u].parent=void 0,this.proxyOf.nodes.splice(u,1);let m;for(let d in this.indexes)m=this.indexes[d],m>=u&&(this.indexes[d]=m-1);return this.markDirty(),this}replaceValues(u,m,d){return d||(d=m,m={}),this.walkDecls(g=>{m.props&&!m.props.includes(g.prop)||m.fast&&!g.value.includes(m.fast)||(g.value=g.value.replace(u,d));}),this.markDirty(),this}some(u){return this.nodes.some(u)}walk(u){return this.each((m,d)=>{let g;try{g=u(m,d);}catch(S){throw m.addToError(S)}return g!==false&&m.walk&&(g=m.walk(u)),g})}walkAtRules(u,m){return m?u instanceof RegExp?this.walk((d,g)=>{if(d.type==="atrule"&&u.test(d.name))return m(d,g)}):this.walk((d,g)=>{if(d.type==="atrule"&&d.name===u)return m(d,g)}):(m=u,this.walk((d,g)=>{if(d.type==="atrule")return m(d,g)}))}walkComments(u){return this.walk((m,d)=>{if(m.type==="comment")return u(m,d)})}walkDecls(u,m){return m?u instanceof RegExp?this.walk((d,g)=>{if(d.type==="decl"&&u.test(d.prop))return m(d,g)}):this.walk((d,g)=>{if(d.type==="decl"&&d.prop===u)return m(d,g)}):(m=u,this.walk((d,g)=>{if(d.type==="decl")return m(d,g)}))}walkRules(u,m){return m?u instanceof RegExp?this.walk((d,g)=>{if(d.type==="rule"&&u.test(d.selector))return m(d,g)}):this.walk((d,g)=>{if(d.type==="rule"&&d.selector===u)return m(d,g)}):(m=u,this.walk((d,g)=>{if(d.type==="rule")return m(d,g)}))}get first(){if(this.proxyOf.nodes)return this.proxyOf.nodes[0]}get last(){if(this.proxyOf.nodes)return this.proxyOf.nodes[this.proxyOf.nodes.length-1]}}return f.registerParse=c=>{o=c;},f.registerRule=c=>{l=c;},f.registerAtRule=c=>{p=c;},f.registerRoot=c=>{a=c;},Kr=f,f.default=f,f.rebuild=c=>{c.type==="atrule"?Object.setPrototypeOf(c,p.prototype):c.type==="rule"?Object.setPrototypeOf(c,l.prototype):c.type==="decl"?Object.setPrototypeOf(c,r.prototype):c.type==="comment"?Object.setPrototypeOf(c,i.prototype):c.type==="root"&&Object.setPrototypeOf(c,a.prototype),c[t]=true,c.nodes&&c.nodes.forEach(u=>{f.rebuild(u);});},Kr}var Zr,ps;function Wn(){if(ps)return Zr;ps=1;let e=Fe(),t,r;class i extends e{constructor(o){super({type:"document",...o}),this.nodes||(this.nodes=[]);}toResult(o={}){return new t(new r,this,o).stringify()}}return i.registerLazyResult=n=>{t=n;},i.registerProcessor=n=>{r=n;},Zr=i,i.default=i,Zr}var en,gs;function fo(){if(gs)return en;gs=1;class e{constructor(r,i={}){if(this.type="warning",this.text=r,i.node&&i.node.source){let n=i.node.rangeBy(i);this.line=n.start.line,this.column=n.start.column,this.endLine=n.end.line,this.endColumn=n.end.column;}for(let n in i)this[n]=i[n];}toString(){return this.node?this.node.error(this.text,{index:this.index,plugin:this.plugin,word:this.word}).message:this.plugin?this.plugin+": "+this.text:this.text}}return en=e,e.default=e,en}var tn,ys;function Hn(){if(ys)return tn;ys=1;let e=fo();class t{constructor(i,n,o){this.processor=i,this.messages=[],this.root=n,this.opts=o,this.css=void 0,this.map=void 0;}toString(){return this.css}warn(i,n={}){n.plugin||this.lastPlugin&&this.lastPlugin.postcssPlugin&&(n.plugin=this.lastPlugin.postcssPlugin);let o=new e(i,n);return this.messages.push(o),o}warnings(){return this.messages.filter(i=>i.type==="warning")}get content(){return this.css}}return tn=t,t.default=t,tn}var rn,vs;function gu(){if(vs)return rn;vs=1;let e=39,t=34,r=92,i=47,n=10,o=32,l=12,p=9,a=13,h=91,s=93,f=40,c=41,u=123,m=125,d=59,g=42,S=58,y=64,b=/[\t\n\f\r "#'()/;[\\\]{}]/g,E=/[\t\n\f\r !"#'():;@[\\\]{}]|\/(?=\*)/g,w=/.[\r\n"'(/\\]/,v=/[\da-f]/i;return rn=function(R,I={}){let M=R.css.valueOf(),O=I.ignoreErrors,k,x,Q,Y,L,A,B,X,J,P,ce=M.length,N=0,re=[],H=[];function me(){return N}function ie(D){throw R.error("Unclosed "+D,N)}function oe(){return H.length===0&&N>=ce}function Re(D){if(H.length)return H.pop();if(N>=ce)return;let ee=D?D.ignoreUnclosed:false;switch(k=M.charCodeAt(N),k){case n:case o:case p:case a:case l:{x=N;do x+=1,k=M.charCodeAt(x);while(k===o||k===n||k===p||k===a||k===l);P=["space",M.slice(N,x)],N=x-1;break}case h:case s:case u:case m:case S:case d:case c:{let z=String.fromCharCode(k);P=[z,z,N];break}case f:{if(X=re.length?re.pop()[1]:"",J=M.charCodeAt(N+1),X==="url"&&J!==e&&J!==t&&J!==o&&J!==n&&J!==p&&J!==l&&J!==a){x=N;do{if(A=false,x=M.indexOf(")",x+1),x===-1)if(O||ee){x=N;break}else ie("bracket");for(B=x;M.charCodeAt(B-1)===r;)B-=1,A=!A;}while(A);P=["brackets",M.slice(N,x+1),N,x],N=x;}else x=M.indexOf(")",N+1),Y=M.slice(N,x+1),x===-1||w.test(Y)?P=["(","(",N]:(P=["brackets",Y,N,x],N=x);break}case e:case t:{Q=k===e?"'":'"',x=N;do{if(A=false,x=M.indexOf(Q,x+1),x===-1)if(O||ee){x=N+1;break}else ie("string");for(B=x;M.charCodeAt(B-1)===r;)B-=1,A=!A;}while(A);P=["string",M.slice(N,x+1),N,x],N=x;break}case y:{b.lastIndex=N+1,b.test(M),b.lastIndex===0?x=M.length-1:x=b.lastIndex-2,P=["at-word",M.slice(N,x+1),N,x],N=x;break}case r:{for(x=N,L=true;M.charCodeAt(x+1)===r;)x+=1,L=!L;if(k=M.charCodeAt(x+1),L&&k!==i&&k!==o&&k!==n&&k!==p&&k!==a&&k!==l&&(x+=1,v.test(M.charAt(x)))){for(;v.test(M.charAt(x+1));)x+=1;M.charCodeAt(x+1)===o&&(x+=1);}P=["word",M.slice(N,x+1),N,x],N=x;break}default:{k===i&&M.charCodeAt(N+1)===g?(x=M.indexOf("*/",N+2)+1,x===0&&(O||ee?x=M.length:ie("comment")),P=["comment",M.slice(N,x+1),N,x],N=x):(E.lastIndex=N+1,E.test(M),E.lastIndex===0?x=M.length-1:x=E.lastIndex-2,P=["word",M.slice(N,x+1),N,x],re.push(P),N=x);break}}return N++,P}function we(D){H.push(D);}return {back:we,endOfFile:oe,nextToken:Re,position:me}},rn}var nn,ws;function jn(){if(ws)return nn;ws=1;let e=Fe();class t extends e{constructor(i){super(i),this.type="atrule";}append(...i){return this.proxyOf.nodes||(this.nodes=[]),super.append(...i)}prepend(...i){return this.proxyOf.nodes||(this.nodes=[]),super.prepend(...i)}}return nn=t,t.default=t,e.registerAtRule(t),nn}var sn,bs;function lt(){if(bs)return sn;bs=1;let e=Fe(),t,r;class i extends e{constructor(o){super(o),this.type="root",this.nodes||(this.nodes=[]);}normalize(o,l,p){let a=super.normalize(o);if(l){if(p==="prepend")this.nodes.length>1?l.raws.before=this.nodes[1].raws.before:delete l.raws.before;else if(this.first!==l)for(let h of a)h.raws.before=l.raws.before;}return a}removeChild(o,l){let p=this.index(o);return !l&&p===0&&this.nodes.length>1&&(this.nodes[1].raws.before=this.nodes[p].raws.before),super.removeChild(o)}toResult(o={}){return new t(new r,this,o).stringify()}}return i.registerLazyResult=n=>{t=n;},i.registerProcessor=n=>{r=n;},sn=i,i.default=i,e.registerRoot(i),sn}var on,Ss;function ho(){if(Ss)return on;Ss=1;let e={comma(t){return e.split(t,[","],true)},space(t){let r=[" ",`
49
- `," "];return e.split(t,r)},split(t,r,i){let n=[],o="",l=false,p=0,a=false,h="",s=false;for(let f of t)s?s=false:f==="\\"?s=true:a?f===h&&(a=false):f==='"'||f==="'"?(a=true,h=f):f==="("?p+=1:f===")"?p>0&&(p-=1):p===0&&r.includes(f)&&(l=true),l?(o!==""&&n.push(o.trim()),o="",l=false):o+=f;return (i||o!=="")&&n.push(o.trim()),n}};return on=e,e.default=e,on}var an,Cs;function Vn(){if(Cs)return an;Cs=1;let e=Fe(),t=ho();class r extends e{constructor(n){super(n),this.type="rule",this.nodes||(this.nodes=[]);}get selectors(){return t.comma(this.selector)}set selectors(n){let o=this.selector?this.selector.match(/,\s*/):null,l=o?o[0]:","+this.raw("between","beforeOpen");this.selector=n.join(l);}}return an=r,r.default=r,e.registerRule(r),an}var ln,Es;function yu(){if(Es)return ln;Es=1;let e=Wt(),t=gu(),r=jt(),i=jn(),n=lt(),o=Vn(),l={empty:true,space:true};function p(h){for(let s=h.length-1;s>=0;s--){let f=h[s],c=f[3]||f[2];if(c)return c}}class a{constructor(s){this.input=s,this.root=new n,this.current=this.root,this.spaces="",this.semicolon=false,this.createTokenizer(),this.root.source={input:s,start:{column:1,line:1,offset:0}};}atrule(s){let f=new i;f.name=s[1].slice(1),f.name===""&&this.unnamedAtrule(f,s),this.init(f,s[2]);let c,u,m,d=false,g=false,S=[],y=[];for(;!this.tokenizer.endOfFile();){if(s=this.tokenizer.nextToken(),c=s[0],c==="("||c==="["?y.push(c==="("?")":"]"):c==="{"&&y.length>0?y.push("}"):c===y[y.length-1]&&y.pop(),y.length===0)if(c===";"){f.source.end=this.getPosition(s[2]),f.source.end.offset++,this.semicolon=true;break}else if(c==="{"){g=true;break}else if(c==="}"){if(S.length>0){for(m=S.length-1,u=S[m];u&&u[0]==="space";)u=S[--m];u&&(f.source.end=this.getPosition(u[3]||u[2]),f.source.end.offset++);}this.end(s);break}else S.push(s);else S.push(s);if(this.tokenizer.endOfFile()){d=true;break}}f.raws.between=this.spacesAndCommentsFromEnd(S),S.length?(f.raws.afterName=this.spacesAndCommentsFromStart(S),this.raw(f,"params",S),d&&(s=S[S.length-1],f.source.end=this.getPosition(s[3]||s[2]),f.source.end.offset++,this.spaces=f.raws.between,f.raws.between="")):(f.raws.afterName="",f.params=""),g&&(f.nodes=[],this.current=f);}checkMissedSemicolon(s){let f=this.colon(s);if(f===false)return;let c=0,u;for(let m=f-1;m>=0&&(u=s[m],!(u[0]!=="space"&&(c+=1,c===2)));m--);throw this.input.error("Missed semicolon",u[0]==="word"?u[3]+1:u[2])}colon(s){let f=0,c,u,m;for(let[d,g]of s.entries()){if(c=g,u=c[0],u==="("&&(f+=1),u===")"&&(f-=1),f===0&&u===":")if(!m)this.doubleColon(c);else {if(m[0]==="word"&&m[1]==="progid")continue;return d}m=c;}return false}comment(s){let f=new r;this.init(f,s[2]),f.source.end=this.getPosition(s[3]||s[2]),f.source.end.offset++;let c=s[1].slice(2,-2);if(/^\s*$/.test(c))f.text="",f.raws.left=c,f.raws.right="";else {let u=c.match(/^(\s*)([^]*\S)(\s*)$/);f.text=u[2],f.raws.left=u[1],f.raws.right=u[3];}}createTokenizer(){this.tokenizer=t(this.input);}decl(s,f){let c=new e;this.init(c,s[0][2]);let u=s[s.length-1];for(u[0]===";"&&(this.semicolon=true,s.pop()),c.source.end=this.getPosition(u[3]||u[2]||p(s)),c.source.end.offset++;s[0][0]!=="word";)s.length===1&&this.unknownWord(s),c.raws.before+=s.shift()[1];for(c.source.start=this.getPosition(s[0][2]),c.prop="";s.length;){let y=s[0][0];if(y===":"||y==="space"||y==="comment")break;c.prop+=s.shift()[1];}c.raws.between="";let m;for(;s.length;)if(m=s.shift(),m[0]===":"){c.raws.between+=m[1];break}else m[0]==="word"&&/\w/.test(m[1])&&this.unknownWord([m]),c.raws.between+=m[1];(c.prop[0]==="_"||c.prop[0]==="*")&&(c.raws.before+=c.prop[0],c.prop=c.prop.slice(1));let d=[],g;for(;s.length&&(g=s[0][0],!(g!=="space"&&g!=="comment"));)d.push(s.shift());this.precheckMissedSemicolon(s);for(let y=s.length-1;y>=0;y--){if(m=s[y],m[1].toLowerCase()==="!important"){c.important=true;let b=this.stringFrom(s,y);b=this.spacesFromEnd(s)+b,b!==" !important"&&(c.raws.important=b);break}else if(m[1].toLowerCase()==="important"){let b=s.slice(0),E="";for(let w=y;w>0;w--){let v=b[w][0];if(E.trim().indexOf("!")===0&&v!=="space")break;E=b.pop()[1]+E;}E.trim().indexOf("!")===0&&(c.important=true,c.raws.important=E,s=b);}if(m[0]!=="space"&&m[0]!=="comment")break}s.some(y=>y[0]!=="space"&&y[0]!=="comment")&&(c.raws.between+=d.map(y=>y[1]).join(""),d=[]),this.raw(c,"value",d.concat(s),f),c.value.includes(":")&&!f&&this.checkMissedSemicolon(s);}doubleColon(s){throw this.input.error("Double colon",{offset:s[2]},{offset:s[2]+s[1].length})}emptyRule(s){let f=new o;this.init(f,s[2]),f.selector="",f.raws.between="",this.current=f;}end(s){this.current.nodes&&this.current.nodes.length&&(this.current.raws.semicolon=this.semicolon),this.semicolon=false,this.current.raws.after=(this.current.raws.after||"")+this.spaces,this.spaces="",this.current.parent?(this.current.source.end=this.getPosition(s[2]),this.current.source.end.offset++,this.current=this.current.parent):this.unexpectedClose(s);}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(s){if(this.spaces+=s[1],this.current.nodes){let f=this.current.nodes[this.current.nodes.length-1];f&&f.type==="rule"&&!f.raws.ownSemicolon&&(f.raws.ownSemicolon=this.spaces,this.spaces="");}}getPosition(s){let f=this.input.fromOffset(s);return {column:f.col,line:f.line,offset:s}}init(s,f){this.current.push(s),s.source={input:this.input,start:this.getPosition(f)},s.raws.before=this.spaces,this.spaces="",s.type!=="comment"&&(this.semicolon=false);}other(s){let f=false,c=null,u=false,m=null,d=[],g=s[1].startsWith("--"),S=[],y=s;for(;y;){if(c=y[0],S.push(y),c==="("||c==="[")m||(m=y),d.push(c==="("?")":"]");else if(g&&u&&c==="{")m||(m=y),d.push("}");else if(d.length===0)if(c===";")if(u){this.decl(S,g);return}else break;else if(c==="{"){this.rule(S);return}else if(c==="}"){this.tokenizer.back(S.pop()),f=true;break}else c===":"&&(u=true);else c===d[d.length-1]&&(d.pop(),d.length===0&&(m=null));y=this.tokenizer.nextToken();}if(this.tokenizer.endOfFile()&&(f=true),d.length>0&&this.unclosedBracket(m),f&&u){if(!g)for(;S.length&&(y=S[S.length-1][0],!(y!=="space"&&y!=="comment"));)this.tokenizer.back(S.pop());this.decl(S,g);}else this.unknownWord(S);}parse(){let s;for(;!this.tokenizer.endOfFile();)switch(s=this.tokenizer.nextToken(),s[0]){case "space":this.spaces+=s[1];break;case ";":this.freeSemicolon(s);break;case "}":this.end(s);break;case "comment":this.comment(s);break;case "at-word":this.atrule(s);break;case "{":this.emptyRule(s);break;default:this.other(s);break}this.endFile();}precheckMissedSemicolon(){}raw(s,f,c,u){let m,d,g=c.length,S="",y=true,b,E;for(let w=0;w<g;w+=1)m=c[w],d=m[0],d==="space"&&w===g-1&&!u?y=false:d==="comment"?(E=c[w-1]?c[w-1][0]:"empty",b=c[w+1]?c[w+1][0]:"empty",!l[E]&&!l[b]?S.slice(-1)===","?y=false:S+=m[1]:y=false):S+=m[1];if(!y){let w=c.reduce((v,C)=>v+C[1],"");s.raws[f]={raw:w,value:S};}s[f]=S;}rule(s){s.pop();let f=new o;this.init(f,s[0][2]),f.raws.between=this.spacesAndCommentsFromEnd(s),this.raw(f,"selector",s),this.current=f;}spacesAndCommentsFromEnd(s){let f,c="";for(;s.length&&(f=s[s.length-1][0],!(f!=="space"&&f!=="comment"));)c=s.pop()[1]+c;return c}spacesAndCommentsFromStart(s){let f,c="";for(;s.length&&(f=s[0][0],!(f!=="space"&&f!=="comment"));)c+=s.shift()[1];return c}spacesFromEnd(s){let f,c="";for(;s.length&&(f=s[s.length-1][0],f==="space");)c=s.pop()[1]+c;return c}stringFrom(s,f){let c="";for(let u=f;u<s.length;u++)c+=s[u][1];return s.splice(f,s.length-f),c}unclosedBlock(){let s=this.current.source.start;throw this.input.error("Unclosed block",s.line,s.column)}unclosedBracket(s){throw this.input.error("Unclosed bracket",{offset:s[2]},{offset:s[2]+1})}unexpectedClose(s){throw this.input.error("Unexpected }",{offset:s[2]},{offset:s[2]+1})}unknownWord(s){throw this.input.error("Unknown word",{offset:s[0][2]},{offset:s[0][2]+s[0][1].length})}unnamedAtrule(s,f){throw this.input.error("At-rule without name",{offset:f[2]},{offset:f[2]+f[1].length})}}return ln=a,ln}var un,xs;function Gn(){if(xs)return un;xs=1;let e=Fe(),t=yu(),r=Ht();function i(n,o){let l=new r(n,o),p=new t(l);try{p.parse();}catch(a){throw a}return p.root}return un=i,i.default=i,e.registerParse(i),un}var cn,Rs;function po(){if(Rs)return cn;Rs=1;let {isClean:e,my:t}=$n(),r=uo(),i=zt(),n=Fe(),o=Wn(),p=Hn(),a=Gn(),h=lt(),s={atrule:"AtRule",comment:"Comment",decl:"Declaration",document:"Document",root:"Root",rule:"Rule"},f={AtRule:true,AtRuleExit:true,Comment:true,CommentExit:true,Declaration:true,DeclarationExit:true,Document:true,DocumentExit:true,Once:true,OnceExit:true,postcssPlugin:true,prepare:true,Root:true,RootExit:true,Rule:true,RuleExit:true},c={Once:true,postcssPlugin:true,prepare:true},u=0;function m(E){return typeof E=="object"&&typeof E.then=="function"}function d(E){let w=false,v=s[E.type];return E.type==="decl"?w=E.prop.toLowerCase():E.type==="atrule"&&(w=E.name.toLowerCase()),w&&E.append?[v,v+"-"+w,u,v+"Exit",v+"Exit-"+w]:w?[v,v+"-"+w,v+"Exit",v+"Exit-"+w]:E.append?[v,u,v+"Exit"]:[v,v+"Exit"]}function g(E){let w;return E.type==="document"?w=["Document",u,"DocumentExit"]:E.type==="root"?w=["Root",u,"RootExit"]:w=d(E),{eventIndex:0,events:w,iterator:0,node:E,visitorIndex:0,visitors:[]}}function S(E){return E[e]=false,E.nodes&&E.nodes.forEach(w=>S(w)),E}let y={};class b{constructor(w,v,C){this.stringified=false,this.processed=false;let R;if(typeof v=="object"&&v!==null&&(v.type==="root"||v.type==="document"))R=S(v);else if(v instanceof b||v instanceof p)R=S(v.root),v.map&&(typeof C.map>"u"&&(C.map={}),C.map.inline||(C.map.inline=false),C.map.prev=v.map);else {let I=a;C.syntax&&(I=C.syntax.parse),C.parser&&(I=C.parser),I.parse&&(I=I.parse);try{R=I(v,C);}catch(M){this.processed=true,this.error=M;}R&&!R[t]&&n.rebuild(R);}this.result=new p(w,R,C),this.helpers={...y,postcss:y,result:this.result},this.plugins=this.processor.plugins.map(I=>typeof I=="object"&&I.prepare?{...I,...I.prepare(this.result)}:I);}async(){return this.error?Promise.reject(this.error):this.processed?Promise.resolve(this.result):(this.processing||(this.processing=this.runAsync()),this.processing)}catch(w){return this.async().catch(w)}finally(w){return this.async().then(w,w)}getAsyncError(){throw new Error("Use process(css).then(cb) to work with async plugins")}handleError(w,v){let C=this.result.lastPlugin;try{v&&v.addToError(w),this.error=w,w.name==="CssSyntaxError"&&!w.plugin?(w.plugin=C.postcssPlugin,w.setMessage()):C.postcssVersion;}catch(R){console&&console.error&&console.error(R);}return w}prepareVisitors(){this.listeners={};let w=(v,C,R)=>{this.listeners[C]||(this.listeners[C]=[]),this.listeners[C].push([v,R]);};for(let v of this.plugins)if(typeof v=="object")for(let C in v){if(!f[C]&&/^[A-Z]/.test(C))throw new Error(`Unknown event ${C} in ${v.postcssPlugin}. Try to update PostCSS (${this.processor.version} now).`);if(!c[C])if(typeof v[C]=="object")for(let R in v[C])R==="*"?w(v,C,v[C][R]):w(v,C+"-"+R.toLowerCase(),v[C][R]);else typeof v[C]=="function"&&w(v,C,v[C]);}this.hasListener=Object.keys(this.listeners).length>0;}async runAsync(){this.plugin=0;for(let w=0;w<this.plugins.length;w++){let v=this.plugins[w],C=this.runOnRoot(v);if(m(C))try{await C;}catch(R){throw this.handleError(R)}}if(this.prepareVisitors(),this.hasListener){let w=this.result.root;for(;!w[e];){w[e]=true;let v=[g(w)];for(;v.length>0;){let C=this.visitTick(v);if(m(C))try{await C;}catch(R){let I=v[v.length-1].node;throw this.handleError(R,I)}}}if(this.listeners.OnceExit)for(let[v,C]of this.listeners.OnceExit){this.result.lastPlugin=v;try{if(w.type==="document"){let R=w.nodes.map(I=>C(I,this.helpers));await Promise.all(R);}else await C(w,this.helpers);}catch(R){throw this.handleError(R)}}}return this.processed=true,this.stringify()}runOnRoot(w){this.result.lastPlugin=w;try{if(typeof w=="object"&&w.Once){if(this.result.root.type==="document"){let v=this.result.root.nodes.map(C=>w.Once(C,this.helpers));return m(v[0])?Promise.all(v):v}return w.Once(this.result.root,this.helpers)}else if(typeof w=="function")return w(this.result.root,this.result)}catch(v){throw this.handleError(v)}}stringify(){if(this.error)throw this.error;if(this.stringified)return this.result;this.stringified=true,this.sync();let w=this.result.opts,v=i;w.syntax&&(v=w.syntax.stringify),w.stringifier&&(v=w.stringifier),v.stringify&&(v=v.stringify);let R=new r(v,this.result.root,this.result.opts).generate();return this.result.css=R[0],this.result.map=R[1],this.result}sync(){if(this.error)throw this.error;if(this.processed)return this.result;if(this.processed=true,this.processing)throw this.getAsyncError();for(let w of this.plugins){let v=this.runOnRoot(w);if(m(v))throw this.getAsyncError()}if(this.prepareVisitors(),this.hasListener){let w=this.result.root;for(;!w[e];)w[e]=true,this.walkSync(w);if(this.listeners.OnceExit)if(w.type==="document")for(let v of w.nodes)this.visitSync(this.listeners.OnceExit,v);else this.visitSync(this.listeners.OnceExit,w);}return this.result}then(w,v){return this.async().then(w,v)}toString(){return this.css}visitSync(w,v){for(let[C,R]of w){this.result.lastPlugin=C;let I;try{I=R(v,this.helpers);}catch(M){throw this.handleError(M,v.proxyOf)}if(v.type!=="root"&&v.type!=="document"&&!v.parent)return true;if(m(I))throw this.getAsyncError()}}visitTick(w){let v=w[w.length-1],{node:C,visitors:R}=v;if(C.type!=="root"&&C.type!=="document"&&!C.parent){w.pop();return}if(R.length>0&&v.visitorIndex<R.length){let[M,O]=R[v.visitorIndex];v.visitorIndex+=1,v.visitorIndex===R.length&&(v.visitors=[],v.visitorIndex=0),this.result.lastPlugin=M;try{return O(C.toProxy(),this.helpers)}catch(k){throw this.handleError(k,C)}}if(v.iterator!==0){let M=v.iterator,O;for(;O=C.nodes[C.indexes[M]];)if(C.indexes[M]+=1,!O[e]){O[e]=true,w.push(g(O));return}v.iterator=0,delete C.indexes[M];}let I=v.events;for(;v.eventIndex<I.length;){let M=I[v.eventIndex];if(v.eventIndex+=1,M===u){C.nodes&&C.nodes.length&&(C[e]=true,v.iterator=C.getIterator());return}else if(this.listeners[M]){v.visitors=this.listeners[M];return}}w.pop();}walkSync(w){w[e]=true;let v=d(w);for(let C of v)if(C===u)w.nodes&&w.each(R=>{R[e]||this.walkSync(R);});else {let R=this.listeners[C];if(R&&this.visitSync(R,w.toProxy()))return}}warnings(){return this.sync().warnings()}get content(){return this.stringify().content}get css(){return this.stringify().css}get map(){return this.stringify().map}get messages(){return this.sync().messages}get opts(){return this.result.opts}get processor(){return this.result.processor}get root(){return this.sync().root}get[Symbol.toStringTag](){return "LazyResult"}}return b.registerPostcss=E=>{y=E;},cn=b,b.default=b,h.registerLazyResult(b),o.registerLazyResult(b),cn}var fn,Ms;function vu(){if(Ms)return fn;Ms=1;let e=uo(),t=zt(),i=Gn(),n=Hn();class o{constructor(p,a,h){a=a.toString(),this.stringified=false,this._processor=p,this._css=a,this._opts=h,this._map=void 0;let s,f=t;this.result=new n(this._processor,s,this._opts),this.result.css=a;let c=this;Object.defineProperty(this.result,"root",{get(){return c.root}});let u=new e(f,s,this._opts,a);if(u.isMap()){let[m,d]=u.generate();m&&(this.result.css=m),d&&(this.result.map=d);}else u.clearAnnotation(),this.result.css=u.css;}async(){return this.error?Promise.reject(this.error):Promise.resolve(this.result)}catch(p){return this.async().catch(p)}finally(p){return this.async().then(p,p)}sync(){if(this.error)throw this.error;return this.result}then(p,a){return this.async().then(p,a)}toString(){return this._css}warnings(){return []}get content(){return this.result.css}get css(){return this.result.css}get map(){return this.result.map}get messages(){return []}get opts(){return this.result.opts}get processor(){return this.result.processor}get root(){if(this._root)return this._root;let p,a=i;try{p=a(this._css,this._opts);}catch(h){this.error=h;}if(this.error)throw this.error;return this._root=p,p}get[Symbol.toStringTag](){return "NoWorkResult"}}return fn=o,o.default=o,fn}var hn,Is;function wu(){if(Is)return hn;Is=1;let e=vu(),t=po(),r=Wn(),i=lt();class n{constructor(l=[]){this.version="8.4.38",this.plugins=this.normalize(l);}normalize(l){let p=[];for(let a of l)if(a.postcss===true?a=a():a.postcss&&(a=a.postcss),typeof a=="object"&&Array.isArray(a.plugins))p=p.concat(a.plugins);else if(typeof a=="object"&&a.postcssPlugin)p.push(a);else if(typeof a=="function")p.push(a);else if(!(typeof a=="object"&&(a.parse||a.stringify)))throw new Error(a+" is not a PostCSS plugin");return p}process(l,p={}){return !this.plugins.length&&!p.parser&&!p.stringifier&&!p.syntax?new e(this,l,p):new t(this,l,p)}use(l){return this.plugins=this.plugins.concat(this.normalize([l])),this}}return hn=n,n.default=n,i.registerProcessor(n),r.registerProcessor(n),hn}var dn,Ns;function bu(){if(Ns)return dn;Ns=1;let e=Wt(),t=lo(),r=jt(),i=jn(),n=Ht(),o=lt(),l=Vn();function p(a,h){if(Array.isArray(a))return a.map(c=>p(c));let{inputs:s,...f}=a;if(s){h=[];for(let c of s){let u={...c,__proto__:n.prototype};u.map&&(u.map={...u.map,__proto__:t.prototype}),h.push(u);}}if(f.nodes&&(f.nodes=a.nodes.map(c=>p(c,h))),f.source){let{inputId:c,...u}=f.source;f.source=u,c!=null&&(f.source.input=h[c]);}if(f.type==="root")return new o(f);if(f.type==="decl")return new e(f);if(f.type==="rule")return new l(f);if(f.type==="comment")return new r(f);if(f.type==="atrule")return new i(f);throw new Error("Unknown node type: "+a.type)}return dn=p,p.default=p,dn}var pn,Ts;function Su(){if(Ts)return pn;Ts=1;let e=zn(),t=Wt(),r=po(),i=Fe(),n=wu(),o=zt(),l=bu(),p=Wn(),a=fo(),h=jt(),s=jn(),f=Hn(),c=Ht(),u=Gn(),m=ho(),d=Vn(),g=lt(),S=$t();function y(...b){return b.length===1&&Array.isArray(b[0])&&(b=b[0]),new n(b)}return y.plugin=function(E,w){let v=false;function C(...I){console&&console.warn&&!v&&(v=true,console.warn(E+`: postcss.plugin was deprecated. Migration guide:
47
+ `),this.css+=u+"/*# sourceMappingURL="+c+" */";}applyPrevMaps(){for(let c of this.previous()){let u=this.toUrl(this.path(c.file)),m=c.root||r(c.file),p;this.mapOpts.sourcesContent===false?(p=new e(c.text),p.sourcesContent&&(p.sourcesContent=null)):p=c.consumer(),this.map.applySourceMap(p,u,this.toUrl(this.path(m)));}}clearAnnotation(){if(this.mapOpts.annotation!==false)if(this.root){let c;for(let u=this.root.nodes.length-1;u>=0;u--)c=this.root.nodes[u],c.type==="comment"&&c.text.indexOf("# sourceMappingURL=")===0&&this.root.removeChild(u);}else this.css&&(this.css=this.css.replace(/\n*?\/\*#[\S\s]*?\*\/$/gm,""));}generate(){if(this.clearAnnotation(),h&&a&&this.isMap())return this.generateMap();{let c="";return this.stringify(this.root,u=>{c+=u;}),[c]}}generateMap(){if(this.root)this.generateString();else if(this.previous().length===1){let c=this.previous()[0].consumer();c.file=this.outputFile(),this.map=t.fromSourceMap(c,{ignoreInvalidMapping:true});}else this.map=new t({file:this.outputFile(),ignoreInvalidMapping:true}),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 t({file:this.outputFile(),ignoreInvalidMapping:true});let c=1,u=1,m="<no source>",p={generated:{column:0,line:0},original:{column:0,line:0},source:""},g,S;this.stringify(this.root,(y,b,E)=>{if(this.css+=y,b&&E!=="end"&&(p.generated.line=c,p.generated.column=u-1,b.source&&b.source.start?(p.source=this.sourcePath(b),p.original.line=b.source.start.line,p.original.column=b.source.start.column-1,this.map.addMapping(p)):(p.source=m,p.original.line=1,p.original.column=0,this.map.addMapping(p))),g=y.match(/\n/g),g?(c+=g.length,S=y.lastIndexOf(`
48
+ `),u=y.length-S):u+=y.length,b&&E!=="start"){let w=b.parent||{raws:{}};(!(b.type==="decl"||b.type==="atrule"&&!b.nodes)||b!==w.last||w.raws.semicolon)&&(b.source&&b.source.end?(p.source=this.sourcePath(b),p.original.line=b.source.end.line,p.original.column=b.source.end.column-1,p.generated.line=c,p.generated.column=u-2,this.map.addMapping(p)):(p.source=m,p.original.line=1,p.original.column=0,p.generated.line=c,p.generated.column=u-1,this.map.addMapping(p)));}});}isAnnotation(){return this.isInline()?true:typeof this.mapOpts.annotation<"u"?this.mapOpts.annotation:this.previous().length?this.previous().some(c=>c.annotation):true}isInline(){if(typeof this.mapOpts.inline<"u")return this.mapOpts.inline;let c=this.mapOpts.annotation;return typeof c<"u"&&c!==true?false:this.previous().length?this.previous().some(u=>u.inline):true}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(c=>c.withContent()):true}outputFile(){return this.opts.to?this.path(this.opts.to):this.opts.from?this.path(this.opts.from):"to.css"}path(c){if(this.mapOpts.absolute||c.charCodeAt(0)===60||/^\w+:\/\//.test(c))return c;let u=this.memoizedPaths.get(c);if(u)return u;let m=this.opts.to?r(this.opts.to):".";typeof this.mapOpts.annotation=="string"&&(m=r(n(m,this.mapOpts.annotation)));let p=i(m,c);return this.memoizedPaths.set(c,p),p}previous(){if(!this.previousMaps)if(this.previousMaps=[],this.root)this.root.walk(c=>{if(c.source&&c.source.input.map){let u=c.source.input.map;this.previousMaps.includes(u)||this.previousMaps.push(u);}});else {let c=new d(this.originalCSS,this.opts);c.map&&this.previousMaps.push(c.map);}return this.previousMaps}setSourcesContent(){let c={};if(this.root)this.root.walk(u=>{if(u.source){let m=u.source.input.from;if(m&&!c[m]){c[m]=true;let p=this.usesFileUrls?this.toFileUrl(m):this.toUrl(this.path(m));this.map.setSourceContent(p,u.source.input.css);}}});else if(this.css){let u=this.opts.from?this.toUrl(this.path(this.opts.from)):"<no source>";this.map.setSourceContent(u,this.css);}}sourcePath(c){return this.mapOpts.from?this.toUrl(this.mapOpts.from):this.usesFileUrls?this.toFileUrl(c.source.input.from):this.toUrl(this.path(c.source.input.from))}toBase64(c){return Buffer?Buffer.from(c).toString("base64"):window.btoa(unescape(encodeURIComponent(c)))}toFileUrl(c){let u=this.memoizedFileURLs.get(c);if(u)return u;if(l){let m=l(c).toString();return this.memoizedFileURLs.set(c,m),m}else throw new Error("`map.absolute` option is not available in this PostCSS build")}toUrl(c){let u=this.memoizedURLs.get(c);if(u)return u;o==="\\"&&(c=c.replace(/\\/g,"/"));let m=encodeURI(c).replace(/[#?]/g,encodeURIComponent);return this.memoizedURLs.set(c,m),m}}return Xr=s,Xr}var Jr,ds;function jt(){if(ds)return Jr;ds=1;let e=$t();class t extends e{constructor(i){super(i),this.type="comment";}}return Jr=t,t.default=t,Jr}var Kr,ps;function Fe(){if(ps)return Kr;ps=1;let{isClean:e,my:t}=$n(),r=Wt(),i=jt(),n=$t(),o,l,d,a;function h(c){return c.map(u=>(u.nodes&&(u.nodes=h(u.nodes)),delete u.source,u))}function s(c){if(c[e]=false,c.proxyOf.nodes)for(let u of c.proxyOf.nodes)s(u);}class f extends n{append(...u){for(let m of u){let p=this.normalize(m,this.last);for(let g of p)this.proxyOf.nodes.push(g);}return this.markDirty(),this}cleanRaws(u){if(super.cleanRaws(u),this.nodes)for(let m of this.nodes)m.cleanRaws(u);}each(u){if(!this.proxyOf.nodes)return;let m=this.getIterator(),p,g;for(;this.indexes[m]<this.proxyOf.nodes.length&&(p=this.indexes[m],g=u(this.proxyOf.nodes[p],p),g!==false);)this.indexes[m]+=1;return delete this.indexes[m],g}every(u){return this.nodes.every(u)}getIterator(){this.lastEach||(this.lastEach=0),this.indexes||(this.indexes={}),this.lastEach+=1;let u=this.lastEach;return this.indexes[u]=0,u}getProxyProcessor(){return {get(u,m){return m==="proxyOf"?u:u[m]?m==="each"||typeof m=="string"&&m.startsWith("walk")?(...p)=>u[m](...p.map(g=>typeof g=="function"?(S,y)=>g(S.toProxy(),y):g)):m==="every"||m==="some"?p=>u[m]((g,...S)=>p(g.toProxy(),...S)):m==="root"?()=>u.root().toProxy():m==="nodes"?u.nodes.map(p=>p.toProxy()):m==="first"||m==="last"?u[m].toProxy():u[m]:u[m]},set(u,m,p){return u[m]===p||(u[m]=p,(m==="name"||m==="params"||m==="selector")&&u.markDirty()),true}}}index(u){return typeof u=="number"?u:(u.proxyOf&&(u=u.proxyOf),this.proxyOf.nodes.indexOf(u))}insertAfter(u,m){let p=this.index(u),g=this.normalize(m,this.proxyOf.nodes[p]).reverse();p=this.index(u);for(let y of g)this.proxyOf.nodes.splice(p+1,0,y);let S;for(let y in this.indexes)S=this.indexes[y],p<S&&(this.indexes[y]=S+g.length);return this.markDirty(),this}insertBefore(u,m){let p=this.index(u),g=p===0?"prepend":false,S=this.normalize(m,this.proxyOf.nodes[p],g).reverse();p=this.index(u);for(let b of S)this.proxyOf.nodes.splice(p,0,b);let y;for(let b in this.indexes)y=this.indexes[b],p<=y&&(this.indexes[b]=y+S.length);return this.markDirty(),this}normalize(u,m){if(typeof u=="string")u=h(o(u).nodes);else if(typeof u>"u")u=[];else if(Array.isArray(u)){u=u.slice(0);for(let g of u)g.parent&&g.parent.removeChild(g,"ignore");}else if(u.type==="root"&&this.type!=="document"){u=u.nodes.slice(0);for(let g of u)g.parent&&g.parent.removeChild(g,"ignore");}else if(u.type)u=[u];else if(u.prop){if(typeof u.value>"u")throw new Error("Value field is missed in node creation");typeof u.value!="string"&&(u.value=String(u.value)),u=[new r(u)];}else if(u.selector)u=[new l(u)];else if(u.name)u=[new d(u)];else if(u.text)u=[new i(u)];else throw new Error("Unknown node type in node creation");return u.map(g=>(g[t]||f.rebuild(g),g=g.proxyOf,g.parent&&g.parent.removeChild(g),g[e]&&s(g),typeof g.raws.before>"u"&&m&&typeof m.raws.before<"u"&&(g.raws.before=m.raws.before.replace(/\S/g,"")),g.parent=this.proxyOf,g))}prepend(...u){u=u.reverse();for(let m of u){let p=this.normalize(m,this.first,"prepend").reverse();for(let g of p)this.proxyOf.nodes.unshift(g);for(let g in this.indexes)this.indexes[g]=this.indexes[g]+p.length;}return this.markDirty(),this}push(u){return u.parent=this,this.proxyOf.nodes.push(u),this}removeAll(){for(let u of this.proxyOf.nodes)u.parent=void 0;return this.proxyOf.nodes=[],this.markDirty(),this}removeChild(u){u=this.index(u),this.proxyOf.nodes[u].parent=void 0,this.proxyOf.nodes.splice(u,1);let m;for(let p in this.indexes)m=this.indexes[p],m>=u&&(this.indexes[p]=m-1);return this.markDirty(),this}replaceValues(u,m,p){return p||(p=m,m={}),this.walkDecls(g=>{m.props&&!m.props.includes(g.prop)||m.fast&&!g.value.includes(m.fast)||(g.value=g.value.replace(u,p));}),this.markDirty(),this}some(u){return this.nodes.some(u)}walk(u){return this.each((m,p)=>{let g;try{g=u(m,p);}catch(S){throw m.addToError(S)}return g!==false&&m.walk&&(g=m.walk(u)),g})}walkAtRules(u,m){return m?u instanceof RegExp?this.walk((p,g)=>{if(p.type==="atrule"&&u.test(p.name))return m(p,g)}):this.walk((p,g)=>{if(p.type==="atrule"&&p.name===u)return m(p,g)}):(m=u,this.walk((p,g)=>{if(p.type==="atrule")return m(p,g)}))}walkComments(u){return this.walk((m,p)=>{if(m.type==="comment")return u(m,p)})}walkDecls(u,m){return m?u instanceof RegExp?this.walk((p,g)=>{if(p.type==="decl"&&u.test(p.prop))return m(p,g)}):this.walk((p,g)=>{if(p.type==="decl"&&p.prop===u)return m(p,g)}):(m=u,this.walk((p,g)=>{if(p.type==="decl")return m(p,g)}))}walkRules(u,m){return m?u instanceof RegExp?this.walk((p,g)=>{if(p.type==="rule"&&u.test(p.selector))return m(p,g)}):this.walk((p,g)=>{if(p.type==="rule"&&p.selector===u)return m(p,g)}):(m=u,this.walk((p,g)=>{if(p.type==="rule")return m(p,g)}))}get first(){if(this.proxyOf.nodes)return this.proxyOf.nodes[0]}get last(){if(this.proxyOf.nodes)return this.proxyOf.nodes[this.proxyOf.nodes.length-1]}}return f.registerParse=c=>{o=c;},f.registerRule=c=>{l=c;},f.registerAtRule=c=>{d=c;},f.registerRoot=c=>{a=c;},Kr=f,f.default=f,f.rebuild=c=>{c.type==="atrule"?Object.setPrototypeOf(c,d.prototype):c.type==="rule"?Object.setPrototypeOf(c,l.prototype):c.type==="decl"?Object.setPrototypeOf(c,r.prototype):c.type==="comment"?Object.setPrototypeOf(c,i.prototype):c.type==="root"&&Object.setPrototypeOf(c,a.prototype),c[t]=true,c.nodes&&c.nodes.forEach(u=>{f.rebuild(u);});},Kr}var Zr,ms;function Wn(){if(ms)return Zr;ms=1;let e=Fe(),t,r;class i extends e{constructor(o){super({type:"document",...o}),this.nodes||(this.nodes=[]);}toResult(o={}){return new t(new r,this,o).stringify()}}return i.registerLazyResult=n=>{t=n;},i.registerProcessor=n=>{r=n;},Zr=i,i.default=i,Zr}var en,ys;function ho(){if(ys)return en;ys=1;class e{constructor(r,i={}){if(this.type="warning",this.text=r,i.node&&i.node.source){let n=i.node.rangeBy(i);this.line=n.start.line,this.column=n.start.column,this.endLine=n.end.line,this.endColumn=n.end.column;}for(let n in i)this[n]=i[n];}toString(){return this.node?this.node.error(this.text,{index:this.index,plugin:this.plugin,word:this.word}).message:this.plugin?this.plugin+": "+this.text:this.text}}return en=e,e.default=e,en}var tn,vs;function Hn(){if(vs)return tn;vs=1;let e=ho();class t{constructor(i,n,o){this.processor=i,this.messages=[],this.root=n,this.opts=o,this.css=void 0,this.map=void 0;}toString(){return this.css}warn(i,n={}){n.plugin||this.lastPlugin&&this.lastPlugin.postcssPlugin&&(n.plugin=this.lastPlugin.postcssPlugin);let o=new e(i,n);return this.messages.push(o),o}warnings(){return this.messages.filter(i=>i.type==="warning")}get content(){return this.css}}return tn=t,t.default=t,tn}var rn,ws;function yu(){if(ws)return rn;ws=1;let e=39,t=34,r=92,i=47,n=10,o=32,l=12,d=9,a=13,h=91,s=93,f=40,c=41,u=123,m=125,p=59,g=42,S=58,y=64,b=/[\t\n\f\r "#'()/;[\\\]{}]/g,E=/[\t\n\f\r !"#'():;@[\\\]{}]|\/(?=\*)/g,w=/.[\r\n"'(/\\]/,v=/[\da-f]/i;return rn=function(R,M={}){let I=R.css.valueOf(),O=M.ignoreErrors,k,x,Q,Y,L,A,B,X,J,P,ce=I.length,N=0,re=[],H=[];function me(){return N}function ie(D){throw R.error("Unclosed "+D,N)}function oe(){return H.length===0&&N>=ce}function Re(D){if(H.length)return H.pop();if(N>=ce)return;let ee=D?D.ignoreUnclosed:false;switch(k=I.charCodeAt(N),k){case n:case o:case d:case a:case l:{x=N;do x+=1,k=I.charCodeAt(x);while(k===o||k===n||k===d||k===a||k===l);P=["space",I.slice(N,x)],N=x-1;break}case h:case s:case u:case m:case S:case p:case c:{let z=String.fromCharCode(k);P=[z,z,N];break}case f:{if(X=re.length?re.pop()[1]:"",J=I.charCodeAt(N+1),X==="url"&&J!==e&&J!==t&&J!==o&&J!==n&&J!==d&&J!==l&&J!==a){x=N;do{if(A=false,x=I.indexOf(")",x+1),x===-1)if(O||ee){x=N;break}else ie("bracket");for(B=x;I.charCodeAt(B-1)===r;)B-=1,A=!A;}while(A);P=["brackets",I.slice(N,x+1),N,x],N=x;}else x=I.indexOf(")",N+1),Y=I.slice(N,x+1),x===-1||w.test(Y)?P=["(","(",N]:(P=["brackets",Y,N,x],N=x);break}case e:case t:{Q=k===e?"'":'"',x=N;do{if(A=false,x=I.indexOf(Q,x+1),x===-1)if(O||ee){x=N+1;break}else ie("string");for(B=x;I.charCodeAt(B-1)===r;)B-=1,A=!A;}while(A);P=["string",I.slice(N,x+1),N,x],N=x;break}case y:{b.lastIndex=N+1,b.test(I),b.lastIndex===0?x=I.length-1:x=b.lastIndex-2,P=["at-word",I.slice(N,x+1),N,x],N=x;break}case r:{for(x=N,L=true;I.charCodeAt(x+1)===r;)x+=1,L=!L;if(k=I.charCodeAt(x+1),L&&k!==i&&k!==o&&k!==n&&k!==d&&k!==a&&k!==l&&(x+=1,v.test(I.charAt(x)))){for(;v.test(I.charAt(x+1));)x+=1;I.charCodeAt(x+1)===o&&(x+=1);}P=["word",I.slice(N,x+1),N,x],N=x;break}default:{k===i&&I.charCodeAt(N+1)===g?(x=I.indexOf("*/",N+2)+1,x===0&&(O||ee?x=I.length:ie("comment")),P=["comment",I.slice(N,x+1),N,x],N=x):(E.lastIndex=N+1,E.test(I),E.lastIndex===0?x=I.length-1:x=E.lastIndex-2,P=["word",I.slice(N,x+1),N,x],re.push(P),N=x);break}}return N++,P}function we(D){H.push(D);}return {back:we,endOfFile:oe,nextToken:Re,position:me}},rn}var nn,bs;function jn(){if(bs)return nn;bs=1;let e=Fe();class t extends e{constructor(i){super(i),this.type="atrule";}append(...i){return this.proxyOf.nodes||(this.nodes=[]),super.append(...i)}prepend(...i){return this.proxyOf.nodes||(this.nodes=[]),super.prepend(...i)}}return nn=t,t.default=t,e.registerAtRule(t),nn}var sn,Ss;function lt(){if(Ss)return sn;Ss=1;let e=Fe(),t,r;class i extends e{constructor(o){super(o),this.type="root",this.nodes||(this.nodes=[]);}normalize(o,l,d){let a=super.normalize(o);if(l){if(d==="prepend")this.nodes.length>1?l.raws.before=this.nodes[1].raws.before:delete l.raws.before;else if(this.first!==l)for(let h of a)h.raws.before=l.raws.before;}return a}removeChild(o,l){let d=this.index(o);return !l&&d===0&&this.nodes.length>1&&(this.nodes[1].raws.before=this.nodes[d].raws.before),super.removeChild(o)}toResult(o={}){return new t(new r,this,o).stringify()}}return i.registerLazyResult=n=>{t=n;},i.registerProcessor=n=>{r=n;},sn=i,i.default=i,e.registerRoot(i),sn}var on,Cs;function po(){if(Cs)return on;Cs=1;let e={comma(t){return e.split(t,[","],true)},space(t){let r=[" ",`
49
+ `," "];return e.split(t,r)},split(t,r,i){let n=[],o="",l=false,d=0,a=false,h="",s=false;for(let f of t)s?s=false:f==="\\"?s=true:a?f===h&&(a=false):f==='"'||f==="'"?(a=true,h=f):f==="("?d+=1:f===")"?d>0&&(d-=1):d===0&&r.includes(f)&&(l=true),l?(o!==""&&n.push(o.trim()),o="",l=false):o+=f;return (i||o!=="")&&n.push(o.trim()),n}};return on=e,e.default=e,on}var an,Es;function Vn(){if(Es)return an;Es=1;let e=Fe(),t=po();class r extends e{constructor(n){super(n),this.type="rule",this.nodes||(this.nodes=[]);}get selectors(){return t.comma(this.selector)}set selectors(n){let o=this.selector?this.selector.match(/,\s*/):null,l=o?o[0]:","+this.raw("between","beforeOpen");this.selector=n.join(l);}}return an=r,r.default=r,e.registerRule(r),an}var ln,xs;function vu(){if(xs)return ln;xs=1;let e=Wt(),t=yu(),r=jt(),i=jn(),n=lt(),o=Vn(),l={empty:true,space:true};function d(h){for(let s=h.length-1;s>=0;s--){let f=h[s],c=f[3]||f[2];if(c)return c}}class a{constructor(s){this.input=s,this.root=new n,this.current=this.root,this.spaces="",this.semicolon=false,this.createTokenizer(),this.root.source={input:s,start:{column:1,line:1,offset:0}};}atrule(s){let f=new i;f.name=s[1].slice(1),f.name===""&&this.unnamedAtrule(f,s),this.init(f,s[2]);let c,u,m,p=false,g=false,S=[],y=[];for(;!this.tokenizer.endOfFile();){if(s=this.tokenizer.nextToken(),c=s[0],c==="("||c==="["?y.push(c==="("?")":"]"):c==="{"&&y.length>0?y.push("}"):c===y[y.length-1]&&y.pop(),y.length===0)if(c===";"){f.source.end=this.getPosition(s[2]),f.source.end.offset++,this.semicolon=true;break}else if(c==="{"){g=true;break}else if(c==="}"){if(S.length>0){for(m=S.length-1,u=S[m];u&&u[0]==="space";)u=S[--m];u&&(f.source.end=this.getPosition(u[3]||u[2]),f.source.end.offset++);}this.end(s);break}else S.push(s);else S.push(s);if(this.tokenizer.endOfFile()){p=true;break}}f.raws.between=this.spacesAndCommentsFromEnd(S),S.length?(f.raws.afterName=this.spacesAndCommentsFromStart(S),this.raw(f,"params",S),p&&(s=S[S.length-1],f.source.end=this.getPosition(s[3]||s[2]),f.source.end.offset++,this.spaces=f.raws.between,f.raws.between="")):(f.raws.afterName="",f.params=""),g&&(f.nodes=[],this.current=f);}checkMissedSemicolon(s){let f=this.colon(s);if(f===false)return;let c=0,u;for(let m=f-1;m>=0&&(u=s[m],!(u[0]!=="space"&&(c+=1,c===2)));m--);throw this.input.error("Missed semicolon",u[0]==="word"?u[3]+1:u[2])}colon(s){let f=0,c,u,m;for(let[p,g]of s.entries()){if(c=g,u=c[0],u==="("&&(f+=1),u===")"&&(f-=1),f===0&&u===":")if(!m)this.doubleColon(c);else {if(m[0]==="word"&&m[1]==="progid")continue;return p}m=c;}return false}comment(s){let f=new r;this.init(f,s[2]),f.source.end=this.getPosition(s[3]||s[2]),f.source.end.offset++;let c=s[1].slice(2,-2);if(/^\s*$/.test(c))f.text="",f.raws.left=c,f.raws.right="";else {let u=c.match(/^(\s*)([^]*\S)(\s*)$/);f.text=u[2],f.raws.left=u[1],f.raws.right=u[3];}}createTokenizer(){this.tokenizer=t(this.input);}decl(s,f){let c=new e;this.init(c,s[0][2]);let u=s[s.length-1];for(u[0]===";"&&(this.semicolon=true,s.pop()),c.source.end=this.getPosition(u[3]||u[2]||d(s)),c.source.end.offset++;s[0][0]!=="word";)s.length===1&&this.unknownWord(s),c.raws.before+=s.shift()[1];for(c.source.start=this.getPosition(s[0][2]),c.prop="";s.length;){let y=s[0][0];if(y===":"||y==="space"||y==="comment")break;c.prop+=s.shift()[1];}c.raws.between="";let m;for(;s.length;)if(m=s.shift(),m[0]===":"){c.raws.between+=m[1];break}else m[0]==="word"&&/\w/.test(m[1])&&this.unknownWord([m]),c.raws.between+=m[1];(c.prop[0]==="_"||c.prop[0]==="*")&&(c.raws.before+=c.prop[0],c.prop=c.prop.slice(1));let p=[],g;for(;s.length&&(g=s[0][0],!(g!=="space"&&g!=="comment"));)p.push(s.shift());this.precheckMissedSemicolon(s);for(let y=s.length-1;y>=0;y--){if(m=s[y],m[1].toLowerCase()==="!important"){c.important=true;let b=this.stringFrom(s,y);b=this.spacesFromEnd(s)+b,b!==" !important"&&(c.raws.important=b);break}else if(m[1].toLowerCase()==="important"){let b=s.slice(0),E="";for(let w=y;w>0;w--){let v=b[w][0];if(E.trim().indexOf("!")===0&&v!=="space")break;E=b.pop()[1]+E;}E.trim().indexOf("!")===0&&(c.important=true,c.raws.important=E,s=b);}if(m[0]!=="space"&&m[0]!=="comment")break}s.some(y=>y[0]!=="space"&&y[0]!=="comment")&&(c.raws.between+=p.map(y=>y[1]).join(""),p=[]),this.raw(c,"value",p.concat(s),f),c.value.includes(":")&&!f&&this.checkMissedSemicolon(s);}doubleColon(s){throw this.input.error("Double colon",{offset:s[2]},{offset:s[2]+s[1].length})}emptyRule(s){let f=new o;this.init(f,s[2]),f.selector="",f.raws.between="",this.current=f;}end(s){this.current.nodes&&this.current.nodes.length&&(this.current.raws.semicolon=this.semicolon),this.semicolon=false,this.current.raws.after=(this.current.raws.after||"")+this.spaces,this.spaces="",this.current.parent?(this.current.source.end=this.getPosition(s[2]),this.current.source.end.offset++,this.current=this.current.parent):this.unexpectedClose(s);}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(s){if(this.spaces+=s[1],this.current.nodes){let f=this.current.nodes[this.current.nodes.length-1];f&&f.type==="rule"&&!f.raws.ownSemicolon&&(f.raws.ownSemicolon=this.spaces,this.spaces="");}}getPosition(s){let f=this.input.fromOffset(s);return {column:f.col,line:f.line,offset:s}}init(s,f){this.current.push(s),s.source={input:this.input,start:this.getPosition(f)},s.raws.before=this.spaces,this.spaces="",s.type!=="comment"&&(this.semicolon=false);}other(s){let f=false,c=null,u=false,m=null,p=[],g=s[1].startsWith("--"),S=[],y=s;for(;y;){if(c=y[0],S.push(y),c==="("||c==="[")m||(m=y),p.push(c==="("?")":"]");else if(g&&u&&c==="{")m||(m=y),p.push("}");else if(p.length===0)if(c===";")if(u){this.decl(S,g);return}else break;else if(c==="{"){this.rule(S);return}else if(c==="}"){this.tokenizer.back(S.pop()),f=true;break}else c===":"&&(u=true);else c===p[p.length-1]&&(p.pop(),p.length===0&&(m=null));y=this.tokenizer.nextToken();}if(this.tokenizer.endOfFile()&&(f=true),p.length>0&&this.unclosedBracket(m),f&&u){if(!g)for(;S.length&&(y=S[S.length-1][0],!(y!=="space"&&y!=="comment"));)this.tokenizer.back(S.pop());this.decl(S,g);}else this.unknownWord(S);}parse(){let s;for(;!this.tokenizer.endOfFile();)switch(s=this.tokenizer.nextToken(),s[0]){case "space":this.spaces+=s[1];break;case ";":this.freeSemicolon(s);break;case "}":this.end(s);break;case "comment":this.comment(s);break;case "at-word":this.atrule(s);break;case "{":this.emptyRule(s);break;default:this.other(s);break}this.endFile();}precheckMissedSemicolon(){}raw(s,f,c,u){let m,p,g=c.length,S="",y=true,b,E;for(let w=0;w<g;w+=1)m=c[w],p=m[0],p==="space"&&w===g-1&&!u?y=false:p==="comment"?(E=c[w-1]?c[w-1][0]:"empty",b=c[w+1]?c[w+1][0]:"empty",!l[E]&&!l[b]?S.slice(-1)===","?y=false:S+=m[1]:y=false):S+=m[1];if(!y){let w=c.reduce((v,C)=>v+C[1],"");s.raws[f]={raw:w,value:S};}s[f]=S;}rule(s){s.pop();let f=new o;this.init(f,s[0][2]),f.raws.between=this.spacesAndCommentsFromEnd(s),this.raw(f,"selector",s),this.current=f;}spacesAndCommentsFromEnd(s){let f,c="";for(;s.length&&(f=s[s.length-1][0],!(f!=="space"&&f!=="comment"));)c=s.pop()[1]+c;return c}spacesAndCommentsFromStart(s){let f,c="";for(;s.length&&(f=s[0][0],!(f!=="space"&&f!=="comment"));)c+=s.shift()[1];return c}spacesFromEnd(s){let f,c="";for(;s.length&&(f=s[s.length-1][0],f==="space");)c=s.pop()[1]+c;return c}stringFrom(s,f){let c="";for(let u=f;u<s.length;u++)c+=s[u][1];return s.splice(f,s.length-f),c}unclosedBlock(){let s=this.current.source.start;throw this.input.error("Unclosed block",s.line,s.column)}unclosedBracket(s){throw this.input.error("Unclosed bracket",{offset:s[2]},{offset:s[2]+1})}unexpectedClose(s){throw this.input.error("Unexpected }",{offset:s[2]},{offset:s[2]+1})}unknownWord(s){throw this.input.error("Unknown word",{offset:s[0][2]},{offset:s[0][2]+s[0][1].length})}unnamedAtrule(s,f){throw this.input.error("At-rule without name",{offset:f[2]},{offset:f[2]+f[1].length})}}return ln=a,ln}var un,Rs;function Gn(){if(Rs)return un;Rs=1;let e=Fe(),t=vu(),r=Ht();function i(n,o){let l=new r(n,o),d=new t(l);try{d.parse();}catch(a){throw a}return d.root}return un=i,i.default=i,e.registerParse(i),un}var cn,Is;function mo(){if(Is)return cn;Is=1;let {isClean:e,my:t}=$n(),r=co(),i=zt(),n=Fe(),o=Wn(),d=Hn(),a=Gn(),h=lt(),s={atrule:"AtRule",comment:"Comment",decl:"Declaration",document:"Document",root:"Root",rule:"Rule"},f={AtRule:true,AtRuleExit:true,Comment:true,CommentExit:true,Declaration:true,DeclarationExit:true,Document:true,DocumentExit:true,Once:true,OnceExit:true,postcssPlugin:true,prepare:true,Root:true,RootExit:true,Rule:true,RuleExit:true},c={Once:true,postcssPlugin:true,prepare:true},u=0;function m(E){return typeof E=="object"&&typeof E.then=="function"}function p(E){let w=false,v=s[E.type];return E.type==="decl"?w=E.prop.toLowerCase():E.type==="atrule"&&(w=E.name.toLowerCase()),w&&E.append?[v,v+"-"+w,u,v+"Exit",v+"Exit-"+w]:w?[v,v+"-"+w,v+"Exit",v+"Exit-"+w]:E.append?[v,u,v+"Exit"]:[v,v+"Exit"]}function g(E){let w;return E.type==="document"?w=["Document",u,"DocumentExit"]:E.type==="root"?w=["Root",u,"RootExit"]:w=p(E),{eventIndex:0,events:w,iterator:0,node:E,visitorIndex:0,visitors:[]}}function S(E){return E[e]=false,E.nodes&&E.nodes.forEach(w=>S(w)),E}let y={};class b{constructor(w,v,C){this.stringified=false,this.processed=false;let R;if(typeof v=="object"&&v!==null&&(v.type==="root"||v.type==="document"))R=S(v);else if(v instanceof b||v instanceof d)R=S(v.root),v.map&&(typeof C.map>"u"&&(C.map={}),C.map.inline||(C.map.inline=false),C.map.prev=v.map);else {let M=a;C.syntax&&(M=C.syntax.parse),C.parser&&(M=C.parser),M.parse&&(M=M.parse);try{R=M(v,C);}catch(I){this.processed=true,this.error=I;}R&&!R[t]&&n.rebuild(R);}this.result=new d(w,R,C),this.helpers={...y,postcss:y,result:this.result},this.plugins=this.processor.plugins.map(M=>typeof M=="object"&&M.prepare?{...M,...M.prepare(this.result)}:M);}async(){return this.error?Promise.reject(this.error):this.processed?Promise.resolve(this.result):(this.processing||(this.processing=this.runAsync()),this.processing)}catch(w){return this.async().catch(w)}finally(w){return this.async().then(w,w)}getAsyncError(){throw new Error("Use process(css).then(cb) to work with async plugins")}handleError(w,v){let C=this.result.lastPlugin;try{v&&v.addToError(w),this.error=w,w.name==="CssSyntaxError"&&!w.plugin?(w.plugin=C.postcssPlugin,w.setMessage()):C.postcssVersion;}catch(R){console&&console.error&&console.error(R);}return w}prepareVisitors(){this.listeners={};let w=(v,C,R)=>{this.listeners[C]||(this.listeners[C]=[]),this.listeners[C].push([v,R]);};for(let v of this.plugins)if(typeof v=="object")for(let C in v){if(!f[C]&&/^[A-Z]/.test(C))throw new Error(`Unknown event ${C} in ${v.postcssPlugin}. Try to update PostCSS (${this.processor.version} now).`);if(!c[C])if(typeof v[C]=="object")for(let R in v[C])R==="*"?w(v,C,v[C][R]):w(v,C+"-"+R.toLowerCase(),v[C][R]);else typeof v[C]=="function"&&w(v,C,v[C]);}this.hasListener=Object.keys(this.listeners).length>0;}async runAsync(){this.plugin=0;for(let w=0;w<this.plugins.length;w++){let v=this.plugins[w],C=this.runOnRoot(v);if(m(C))try{await C;}catch(R){throw this.handleError(R)}}if(this.prepareVisitors(),this.hasListener){let w=this.result.root;for(;!w[e];){w[e]=true;let v=[g(w)];for(;v.length>0;){let C=this.visitTick(v);if(m(C))try{await C;}catch(R){let M=v[v.length-1].node;throw this.handleError(R,M)}}}if(this.listeners.OnceExit)for(let[v,C]of this.listeners.OnceExit){this.result.lastPlugin=v;try{if(w.type==="document"){let R=w.nodes.map(M=>C(M,this.helpers));await Promise.all(R);}else await C(w,this.helpers);}catch(R){throw this.handleError(R)}}}return this.processed=true,this.stringify()}runOnRoot(w){this.result.lastPlugin=w;try{if(typeof w=="object"&&w.Once){if(this.result.root.type==="document"){let v=this.result.root.nodes.map(C=>w.Once(C,this.helpers));return m(v[0])?Promise.all(v):v}return w.Once(this.result.root,this.helpers)}else if(typeof w=="function")return w(this.result.root,this.result)}catch(v){throw this.handleError(v)}}stringify(){if(this.error)throw this.error;if(this.stringified)return this.result;this.stringified=true,this.sync();let w=this.result.opts,v=i;w.syntax&&(v=w.syntax.stringify),w.stringifier&&(v=w.stringifier),v.stringify&&(v=v.stringify);let R=new r(v,this.result.root,this.result.opts).generate();return this.result.css=R[0],this.result.map=R[1],this.result}sync(){if(this.error)throw this.error;if(this.processed)return this.result;if(this.processed=true,this.processing)throw this.getAsyncError();for(let w of this.plugins){let v=this.runOnRoot(w);if(m(v))throw this.getAsyncError()}if(this.prepareVisitors(),this.hasListener){let w=this.result.root;for(;!w[e];)w[e]=true,this.walkSync(w);if(this.listeners.OnceExit)if(w.type==="document")for(let v of w.nodes)this.visitSync(this.listeners.OnceExit,v);else this.visitSync(this.listeners.OnceExit,w);}return this.result}then(w,v){return this.async().then(w,v)}toString(){return this.css}visitSync(w,v){for(let[C,R]of w){this.result.lastPlugin=C;let M;try{M=R(v,this.helpers);}catch(I){throw this.handleError(I,v.proxyOf)}if(v.type!=="root"&&v.type!=="document"&&!v.parent)return true;if(m(M))throw this.getAsyncError()}}visitTick(w){let v=w[w.length-1],{node:C,visitors:R}=v;if(C.type!=="root"&&C.type!=="document"&&!C.parent){w.pop();return}if(R.length>0&&v.visitorIndex<R.length){let[I,O]=R[v.visitorIndex];v.visitorIndex+=1,v.visitorIndex===R.length&&(v.visitors=[],v.visitorIndex=0),this.result.lastPlugin=I;try{return O(C.toProxy(),this.helpers)}catch(k){throw this.handleError(k,C)}}if(v.iterator!==0){let I=v.iterator,O;for(;O=C.nodes[C.indexes[I]];)if(C.indexes[I]+=1,!O[e]){O[e]=true,w.push(g(O));return}v.iterator=0,delete C.indexes[I];}let M=v.events;for(;v.eventIndex<M.length;){let I=M[v.eventIndex];if(v.eventIndex+=1,I===u){C.nodes&&C.nodes.length&&(C[e]=true,v.iterator=C.getIterator());return}else if(this.listeners[I]){v.visitors=this.listeners[I];return}}w.pop();}walkSync(w){w[e]=true;let v=p(w);for(let C of v)if(C===u)w.nodes&&w.each(R=>{R[e]||this.walkSync(R);});else {let R=this.listeners[C];if(R&&this.visitSync(R,w.toProxy()))return}}warnings(){return this.sync().warnings()}get content(){return this.stringify().content}get css(){return this.stringify().css}get map(){return this.stringify().map}get messages(){return this.sync().messages}get opts(){return this.result.opts}get processor(){return this.result.processor}get root(){return this.sync().root}get[Symbol.toStringTag](){return "LazyResult"}}return b.registerPostcss=E=>{y=E;},cn=b,b.default=b,h.registerLazyResult(b),o.registerLazyResult(b),cn}var fn,Ms;function wu(){if(Ms)return fn;Ms=1;let e=co(),t=zt(),i=Gn(),n=Hn();class o{constructor(d,a,h){a=a.toString(),this.stringified=false,this._processor=d,this._css=a,this._opts=h,this._map=void 0;let s,f=t;this.result=new n(this._processor,s,this._opts),this.result.css=a;let c=this;Object.defineProperty(this.result,"root",{get(){return c.root}});let u=new e(f,s,this._opts,a);if(u.isMap()){let[m,p]=u.generate();m&&(this.result.css=m),p&&(this.result.map=p);}else u.clearAnnotation(),this.result.css=u.css;}async(){return this.error?Promise.reject(this.error):Promise.resolve(this.result)}catch(d){return this.async().catch(d)}finally(d){return this.async().then(d,d)}sync(){if(this.error)throw this.error;return this.result}then(d,a){return this.async().then(d,a)}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 d,a=i;try{d=a(this._css,this._opts);}catch(h){this.error=h;}if(this.error)throw this.error;return this._root=d,d}get[Symbol.toStringTag](){return "NoWorkResult"}}return fn=o,o.default=o,fn}var hn,Ns;function bu(){if(Ns)return hn;Ns=1;let e=wu(),t=mo(),r=Wn(),i=lt();class n{constructor(l=[]){this.version="8.4.38",this.plugins=this.normalize(l);}normalize(l){let d=[];for(let a of l)if(a.postcss===true?a=a():a.postcss&&(a=a.postcss),typeof a=="object"&&Array.isArray(a.plugins))d=d.concat(a.plugins);else if(typeof a=="object"&&a.postcssPlugin)d.push(a);else if(typeof a=="function")d.push(a);else if(!(typeof a=="object"&&(a.parse||a.stringify)))throw new Error(a+" is not a PostCSS plugin");return d}process(l,d={}){return !this.plugins.length&&!d.parser&&!d.stringifier&&!d.syntax?new e(this,l,d):new t(this,l,d)}use(l){return this.plugins=this.plugins.concat(this.normalize([l])),this}}return hn=n,n.default=n,i.registerProcessor(n),r.registerProcessor(n),hn}var dn,Ts;function Su(){if(Ts)return dn;Ts=1;let e=Wt(),t=uo(),r=jt(),i=jn(),n=Ht(),o=lt(),l=Vn();function d(a,h){if(Array.isArray(a))return a.map(c=>d(c));let{inputs:s,...f}=a;if(s){h=[];for(let c of s){let u={...c,__proto__:n.prototype};u.map&&(u.map={...u.map,__proto__:t.prototype}),h.push(u);}}if(f.nodes&&(f.nodes=a.nodes.map(c=>d(c,h))),f.source){let{inputId:c,...u}=f.source;f.source=u,c!=null&&(f.source.input=h[c]);}if(f.type==="root")return new o(f);if(f.type==="decl")return new e(f);if(f.type==="rule")return new l(f);if(f.type==="comment")return new r(f);if(f.type==="atrule")return new i(f);throw new Error("Unknown node type: "+a.type)}return dn=d,d.default=d,dn}var pn,ks;function Cu(){if(ks)return pn;ks=1;let e=zn(),t=Wt(),r=mo(),i=Fe(),n=bu(),o=zt(),l=Su(),d=Wn(),a=ho(),h=jt(),s=jn(),f=Hn(),c=Ht(),u=Gn(),m=po(),p=Vn(),g=lt(),S=$t();function y(...b){return b.length===1&&Array.isArray(b[0])&&(b=b[0]),new n(b)}return y.plugin=function(E,w){let v=false;function C(...M){console&&console.warn&&!v&&(v=true,console.warn(E+`: postcss.plugin was deprecated. Migration guide:
50
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:
51
- https://www.w3ctech.com/topic/2226`));let M=w(...I);return M.postcssPlugin=E,M.postcssVersion=new n().version,M}let R;return Object.defineProperty(C,"postcss",{get(){return R||(R=C()),R}}),C.process=function(I,M,O){return y([C(O)]).process(I,M)},C},y.stringify=o,y.parse=u,y.fromJSON=l,y.list=m,y.comment=b=>new h(b),y.atRule=b=>new s(b),y.decl=b=>new t(b),y.rule=b=>new d(b),y.root=b=>new g(b),y.document=b=>new p(b),y.CssSyntaxError=e,y.Declaration=t,y.Container=i,y.Processor=n,y.Document=p,y.Comment=h,y.Warning=a,y.AtRule=s,y.Result=f,y.Input=c,y.Rule=d,y.Root=g,y.Node=S,r.registerPostcss(y),pn=y,y.default=y,pn}var Cu=Su(),Z=cu(Cu);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 bn=class e{constructor(...t){ye(this,"parentElement",null),ye(this,"parentNode",null),ye(this,"ownerDocument"),ye(this,"firstChild",null),ye(this,"lastChild",null),ye(this,"previousSibling",null),ye(this,"nextSibling",null),ye(this,"ELEMENT_NODE",1),ye(this,"TEXT_NODE",3),ye(this,"nodeType"),ye(this,"nodeName"),ye(this,"RRNodeType");}get childNodes(){let t=[],r=this.firstChild;for(;r;)t.push(r),r=r.nextSibling;return t}contains(t){if(t instanceof e){if(t.ownerDocument!==this.ownerDocument)return false;if(t===this)return true}else return false;for(;t.parentNode;){if(t.parentNode===this)return true;t=t.parentNode;}return false}appendChild(t){throw new Error("RRDomException: Failed to execute 'appendChild' on 'RRNode': This RRNode type does not support this method.")}insertBefore(t,r){throw new Error("RRDomException: Failed to execute 'insertBefore' on 'RRNode': This RRNode type does not support this method.")}removeChild(t){throw new Error("RRDomException: Failed to execute 'removeChild' on 'RRNode': This RRNode type does not support this method.")}toString(){return "RRNode"}};var ks={Node:["childNodes","parentNode","parentElement","textContent","ownerDocument"],ShadowRoot:["host","styleSheets"],Element:["shadowRoot","querySelector","querySelectorAll"],MutationObserver:[]},As={Node:["contains","getRootNode"],ShadowRoot:["getSelection"],Element:[],MutationObserver:["constructor"]},Et={},mo={},Eu=()=>!!globalThis.Zone;function Yn(e){if(Et[e])return Et[e];let t=globalThis[e],r=t.prototype,i=e in ks?ks[e]:void 0,n=!!(i&&i.every(p=>{var a,h;return !!((h=(a=Object.getOwnPropertyDescriptor(r,p))==null?void 0:a.get)!=null&&h.toString().includes("[native code]"))})),o=e in As?As[e]:void 0,l=!!(o&&o.every(p=>{var a;return typeof r[p]=="function"&&((a=r[p])==null?void 0:a.toString().includes("[native code]"))}));if(n&&l&&!Eu())return Et[e]=t.prototype,t.prototype;try{let p=document.createElement("iframe");p.style.display="none",document.body.appendChild(p);let a=p.contentWindow;if(!a)return t.prototype;let h=a[e].prototype;if(!h)return p.remove(),r;let s=navigator.userAgent;return s.includes("Safari")&&!s.includes("Chrome")?(p.classList.add("rr-block"),p.setAttribute("__rrwebUntaintedMutationObserver",""),mo[e]=()=>p.remove()):p.remove(),Et[e]=h}catch{return r}}var mn={};function ke(e,t,r){var i;let n=`${e}.${String(r)}`;if(mn[n])return mn[n].call(t);let o=Yn(e),l=(i=Object.getOwnPropertyDescriptor(o,r))==null?void 0:i.get;return l?(mn[n]=l,l.call(t)):t[r]}var gn={};function go(e,t,r){let i=`${e}.${String(r)}`;if(gn[i])return gn[i].bind(t);let o=Yn(e)[r];return typeof o!="function"?t[r]:(gn[i]=o,o.bind(t))}function xu(e){return ke("Node",e,"ownerDocument")}function Ru(e){return ke("Node",e,"childNodes")}function Mu(e){return ke("Node",e,"parentNode")}function Iu(e){return ke("Node",e,"parentElement")}function Nu(e){return ke("Node",e,"textContent")}function Tu(e,t){return go("Node",e,"contains")(t)}function ku(e){return go("Node",e,"getRootNode")()}function Au(e){return !e||!("host"in e)?null:ke("ShadowRoot",e,"host")}function Ou(e){return e.styleSheets}function Du(e){return !e||!("shadowRoot"in e)?null:ke("Element",e,"shadowRoot")}function Lu(e,t){return ke("Element",e,"querySelector")(t)}function Pu(e,t){return ke("Element",e,"querySelectorAll")(t)}function yo(){return [Yn("MutationObserver").constructor,mo.MutationObserver??(()=>{})]}var st=Date.now;/[1-9][0-9]{12}/.test(Date.now().toString())||(st=()=>new Date().getTime());function Ue(e,t,r){try{if(!(t in e))return ()=>{};let i=e[t],n=r(i);return typeof n=="function"&&(n.prototype=n.prototype||{},Object.defineProperties(n,{__rrweb_original__:{enumerable:!1,value:i}})),e[t]=n,()=>{e[t]=i;}}catch{return ()=>{}}}var _={ownerDocument:xu,childNodes:Ru,parentNode:Mu,parentElement:Iu,textContent:Nu,contains:Tu,getRootNode:ku,host:Au,styleSheets:Ou,shadowRoot:Du,querySelector:Lu,querySelectorAll:Pu,nowTimestamp:st,mutationObserverCtor:yo,patch:Ue};function ae(e,t,r=document){let i={capture:true,passive:true};return r.addEventListener(e,t,i),()=>r.removeEventListener(e,t,i)}var We=`Please stop import mirror directly. Instead of that,\r
51
+ https://www.w3ctech.com/topic/2226`));let I=w(...M);return I.postcssPlugin=E,I.postcssVersion=new n().version,I}let R;return Object.defineProperty(C,"postcss",{get(){return R||(R=C()),R}}),C.process=function(M,I,O){return y([C(O)]).process(M,I)},C},y.stringify=o,y.parse=u,y.fromJSON=l,y.list=m,y.comment=b=>new h(b),y.atRule=b=>new s(b),y.decl=b=>new t(b),y.rule=b=>new p(b),y.root=b=>new g(b),y.document=b=>new d(b),y.CssSyntaxError=e,y.Declaration=t,y.Container=i,y.Processor=n,y.Document=d,y.Comment=h,y.Warning=a,y.AtRule=s,y.Result=f,y.Input=c,y.Rule=p,y.Root=g,y.Node=S,r.registerPostcss(y),pn=y,y.default=y,pn}var Eu=Cu(),Z=fu(Eu);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 bn=class e{constructor(...t){ye(this,"parentElement",null),ye(this,"parentNode",null),ye(this,"ownerDocument"),ye(this,"firstChild",null),ye(this,"lastChild",null),ye(this,"previousSibling",null),ye(this,"nextSibling",null),ye(this,"ELEMENT_NODE",1),ye(this,"TEXT_NODE",3),ye(this,"nodeType"),ye(this,"nodeName"),ye(this,"RRNodeType");}get childNodes(){let t=[],r=this.firstChild;for(;r;)t.push(r),r=r.nextSibling;return t}contains(t){if(t instanceof e){if(t.ownerDocument!==this.ownerDocument)return false;if(t===this)return true}else return false;for(;t.parentNode;){if(t.parentNode===this)return true;t=t.parentNode;}return false}appendChild(t){throw new Error("RRDomException: Failed to execute 'appendChild' on 'RRNode': This RRNode type does not support this method.")}insertBefore(t,r){throw new Error("RRDomException: Failed to execute 'insertBefore' on 'RRNode': This RRNode type does not support this method.")}removeChild(t){throw new Error("RRDomException: Failed to execute 'removeChild' on 'RRNode': This RRNode type does not support this method.")}toString(){return "RRNode"}};var As={Node:["childNodes","parentNode","parentElement","textContent","ownerDocument"],ShadowRoot:["host","styleSheets"],Element:["shadowRoot","querySelector","querySelectorAll"],MutationObserver:[]},Os={Node:["contains","getRootNode"],ShadowRoot:["getSelection"],Element:[],MutationObserver:["constructor"]},Et={},go={},xu=()=>!!globalThis.Zone;function Yn(e){if(Et[e])return Et[e];let t=globalThis[e],r=t.prototype,i=e in As?As[e]:void 0,n=!!(i&&i.every(d=>{var a,h;return !!((h=(a=Object.getOwnPropertyDescriptor(r,d))==null?void 0:a.get)!=null&&h.toString().includes("[native code]"))})),o=e in Os?Os[e]:void 0,l=!!(o&&o.every(d=>{var a;return typeof r[d]=="function"&&((a=r[d])==null?void 0:a.toString().includes("[native code]"))}));if(n&&l&&!xu())return Et[e]=t.prototype,t.prototype;try{let d=document.createElement("iframe");d.style.display="none",document.body.appendChild(d);let a=d.contentWindow;if(!a)return t.prototype;let h=a[e].prototype;if(!h)return d.remove(),r;let s=navigator.userAgent;return s.includes("Safari")&&!s.includes("Chrome")?(d.classList.add("rr-block"),d.setAttribute("__rrwebUntaintedMutationObserver",""),go[e]=()=>d.remove()):d.remove(),Et[e]=h}catch{return r}}var mn={};function ke(e,t,r){var i;let n=`${e}.${String(r)}`;if(mn[n])return mn[n].call(t);let o=Yn(e),l=(i=Object.getOwnPropertyDescriptor(o,r))==null?void 0:i.get;return l?(mn[n]=l,l.call(t)):t[r]}var gn={};function yo(e,t,r){let i=`${e}.${String(r)}`;if(gn[i])return gn[i].bind(t);let o=Yn(e)[r];return typeof o!="function"?t[r]:(gn[i]=o,o.bind(t))}function Ru(e){return ke("Node",e,"ownerDocument")}function Iu(e){return ke("Node",e,"childNodes")}function Mu(e){return ke("Node",e,"parentNode")}function Nu(e){return ke("Node",e,"parentElement")}function Tu(e){return ke("Node",e,"textContent")}function ku(e,t){return yo("Node",e,"contains")(t)}function Au(e){return yo("Node",e,"getRootNode")()}function Ou(e){return !e||!("host"in e)?null:ke("ShadowRoot",e,"host")}function Du(e){return e.styleSheets}function Lu(e){return !e||!("shadowRoot"in e)?null:ke("Element",e,"shadowRoot")}function Pu(e,t){return ke("Element",e,"querySelector")(t)}function _u(e,t){return ke("Element",e,"querySelectorAll")(t)}function vo(){return [Yn("MutationObserver").constructor,go.MutationObserver??(()=>{})]}var st=Date.now;/[1-9][0-9]{12}/.test(Date.now().toString())||(st=()=>new Date().getTime());function Ue(e,t,r){try{if(!(t in e))return ()=>{};let i=e[t],n=r(i);return typeof n=="function"&&(n.prototype=n.prototype||{},Object.defineProperties(n,{__rrweb_original__:{enumerable:!1,value:i}})),e[t]=n,()=>{e[t]=i;}}catch{return ()=>{}}}var _={ownerDocument:Ru,childNodes:Iu,parentNode:Mu,parentElement:Nu,textContent:Tu,contains:ku,getRootNode:Au,host:Ou,styleSheets:Du,shadowRoot:Lu,querySelector:Pu,querySelectorAll:_u,nowTimestamp:st,mutationObserverCtor:vo,patch:Ue};function ae(e,t,r=document){let i={capture:true,passive:true};return r.addEventListener(e,t,i),()=>r.removeEventListener(e,t,i)}var We=`Please stop import mirror directly. Instead of that,\r
52
52
  now you can use replayer.getMirror() to access the mirror instance of a replayer,\r
53
- or you can use record.mirror to access the mirror instance during recording.`,Os={map:{},getId(){return console.error(We),-1},getNode(){return console.error(We),null},removeNodeFromMap(){console.error(We);},has(){return console.error(We),false},reset(){console.error(We);}};typeof window<"u"&&window.Proxy&&window.Reflect&&(Os=new Proxy(Os,{get(e,t,r){return t==="map"&&console.error(We),Reflect.get(e,t,r)}}));function ot(e,t,r={}){let i=null,n=0;return function(...o){let l=Date.now();!n&&r.leading===false&&(n=l);let p=t-(l-n),a=this;p<=0||p>t?(i&&(clearTimeout(i),i=null),n=l,e.apply(a,o)):!i&&r.trailing!==false&&(i=setTimeout(()=>{n=r.leading===false?0:Date.now(),i=null,e.apply(a,o);},p));}}function Vt(e,t,r,i,n=window){let o=n.Object.getOwnPropertyDescriptor(e,t);return n.Object.defineProperty(e,t,i?r:{set(l){setTimeout(()=>{r.set.call(this,l);},0),o&&o.set&&o.set.call(this,l);}}),()=>Vt(e,t,o||{},true)}function vo(e){var t,r,i,n;let o=e.document;return {left:o.scrollingElement?o.scrollingElement.scrollLeft:e.pageXOffset!==void 0?e.pageXOffset:o.documentElement.scrollLeft||o?.body&&((t=_.parentElement(o.body))==null?void 0:t.scrollLeft)||((r=o?.body)==null?void 0:r.scrollLeft)||0,top:o.scrollingElement?o.scrollingElement.scrollTop:e.pageYOffset!==void 0?e.pageYOffset:o?.documentElement.scrollTop||o?.body&&((i=_.parentElement(o.body))==null?void 0:i.scrollTop)||((n=o?.body)==null?void 0:n.scrollTop)||0}}function wo(){return window.innerHeight||document.documentElement&&document.documentElement.clientHeight||document.body&&document.body.clientHeight}function bo(){return window.innerWidth||document.documentElement&&document.documentElement.clientWidth||document.body&&document.body.clientWidth}function So(e){return e?e.nodeType===e.ELEMENT_NODE?e:_.parentElement(e):null}function le(e,t,r,i){if(!e)return false;let n=So(e);if(!n)return false;try{if(typeof t=="string"){if(n.classList.contains(t)||i&&n.closest("."+t)!==null)return !0}else if(Ot(n,t,i))return !0}catch{}return !!(r&&(n.matches(r)||i&&n.closest(r)!==null))}function _u(e,t){return t.getId(e)!==-1}function yn(e,t,r){return e.tagName==="TITLE"&&r.headTitleMutations?true:t.getId(e)===it}function Co(e,t){if(tt(e))return false;let r=t.getId(e);if(!t.has(r))return true;let i=_.parentNode(e);return i&&i.nodeType===e.DOCUMENT_NODE?false:i?Co(i,t):true}function Sn(e){return !!e.changedTouches}function Fu(e=window){"NodeList"in e&&!e.NodeList.prototype.forEach&&(e.NodeList.prototype.forEach=Array.prototype.forEach),"DOMTokenList"in e&&!e.DOMTokenList.prototype.forEach&&(e.DOMTokenList.prototype.forEach=Array.prototype.forEach);}function Eo(e,t){return !!(e.nodeName==="IFRAME"&&t.getMeta(e))}function xo(e,t){return !!(e.nodeName==="LINK"&&e.nodeType===e.ELEMENT_NODE&&e.getAttribute&&e.getAttribute("rel")==="stylesheet"&&t.getMeta(e))}function Cn(e){return e?e instanceof bn&&"shadowRoot"in e?!!e.shadowRoot:!!_.shadowRoot(e):false}var En=class{constructor(){T(this,"id",1),T(this,"styleIDMap",new WeakMap),T(this,"idStyleMap",new Map);}getId(t){return this.styleIDMap.get(t)??-1}has(t){return this.styleIDMap.has(t)}add(t,r){if(this.has(t))return this.getId(t);let i;return r===void 0?i=this.id++:i=r,this.styleIDMap.set(t,i),this.idStyleMap.set(i,t),i}getStyle(t){return this.idStyleMap.get(t)||null}reset(){this.styleIDMap=new WeakMap,this.idStyleMap=new Map,this.id=1;}generateId(){return this.id++}};function Ro(e){var t;let r=null;return "getRootNode"in e&&((t=_.getRootNode(e))==null?void 0:t.nodeType)===Node.DOCUMENT_FRAGMENT_NODE&&_.host(_.getRootNode(e))&&(r=_.host(_.getRootNode(e))),r}function Uu(e){let t=e,r;for(;r=Ro(t);)t=r;return t}function Bu(e){let t=_.ownerDocument(e);if(!t)return false;let r=Uu(e);return _.contains(t,r)}function Mo(e){let t=_.ownerDocument(e);return t?_.contains(t,e)||Bu(e):false}var q=(e=>(e[e.DomContentLoaded=0]="DomContentLoaded",e[e.Load=1]="Load",e[e.FullSnapshot=2]="FullSnapshot",e[e.IncrementalSnapshot=3]="IncrementalSnapshot",e[e.Meta=4]="Meta",e[e.Custom=5]="Custom",e[e.Plugin=6]="Plugin",e[e.Asset=7]="Asset",e))(q||{}),F=(e=>(e[e.Mutation=0]="Mutation",e[e.MouseMove=1]="MouseMove",e[e.MouseInteraction=2]="MouseInteraction",e[e.Scroll=3]="Scroll",e[e.ViewportResize=4]="ViewportResize",e[e.Input=5]="Input",e[e.TouchMove=6]="TouchMove",e[e.MediaInteraction=7]="MediaInteraction",e[e.StyleSheetRule=8]="StyleSheetRule",e[e.CanvasMutation=9]="CanvasMutation",e[e.Font=10]="Font",e[e.Log=11]="Log",e[e.Drag=12]="Drag",e[e.StyleDeclaration=13]="StyleDeclaration",e[e.Selection=14]="Selection",e[e.AdoptedStyleSheet=15]="AdoptedStyleSheet",e[e.CustomElement=16]="CustomElement",e))(F||{}),fe=(e=>(e[e.MouseUp=0]="MouseUp",e[e.MouseDown=1]="MouseDown",e[e.Click=2]="Click",e[e.ContextMenu=3]="ContextMenu",e[e.DblClick=4]="DblClick",e[e.Focus=5]="Focus",e[e.Blur=6]="Blur",e[e.TouchStart=7]="TouchStart",e[e.TouchMove_Departed=8]="TouchMove_Departed",e[e.TouchEnd=9]="TouchEnd",e[e.TouchCancel=10]="TouchCancel",e))(fe||{}),Ne=(e=>(e[e.Mouse=0]="Mouse",e[e.Pen=1]="Pen",e[e.Touch=2]="Touch",e))(Ne||{}),Ye=(e=>(e[e["2D"]=0]="2D",e[e.WebGL=1]="WebGL",e[e.WebGL2=2]="WebGL2",e))(Ye||{}),He=(e=>(e[e.Play=0]="Play",e[e.Pause=1]="Pause",e[e.Seeked=2]="Seeked",e[e.VolumeChange=3]="VolumeChange",e[e.RateChange=4]="RateChange",e))(He||{});var Io=(e=>(e[e.Document=0]="Document",e[e.DocumentType=1]="DocumentType",e[e.Element=2]="Element",e[e.Text=3]="Text",e[e.CDATA=4]="CDATA",e[e.Comment=5]="Comment",e))(Io||{});function Ds(e){return "__ln"in e}var xn=class{constructor(){T(this,"length",0),T(this,"head",null),T(this,"tail",null);}get(t){if(t>=this.length)throw new Error("Position outside of list range");let r=this.head;for(let i=0;i<t;i++)r=r?.next||null;return r}addNode(t){let r={value:t,previous:null,next:null};if(t.__ln=r,t.previousSibling&&Ds(t.previousSibling)){let i=t.previousSibling.__ln.next;r.next=i,r.previous=t.previousSibling.__ln,t.previousSibling.__ln.next=r,i&&(i.previous=r);}else if(t.nextSibling&&Ds(t.nextSibling)&&t.nextSibling.__ln.previous){let i=t.nextSibling.__ln.previous;r.previous=i,r.next=t.nextSibling.__ln,t.nextSibling.__ln.previous=r,i&&(i.next=r);}else this.head&&(this.head.previous=r),r.next=this.head,this.head=r;r.next===null&&(this.tail=r),this.length++;}removeNode(t){let r=t.__ln;this.head&&(r.previous?(r.previous.next=r.next,r.next?r.next.previous=r.previous:this.tail=r.previous):(this.head=r.next,this.head?this.head.previous=null:this.tail=null),t.__ln&&delete t.__ln,this.length--);}},Ls=(e,t)=>`${e}@${t}`,Rn=class{constructor(){T(this,"frozen",false),T(this,"locked",false),T(this,"texts",[]),T(this,"attributes",[]),T(this,"attributeMap",new WeakMap),T(this,"removes",[]),T(this,"mapRemoves",[]),T(this,"movedMap",{}),T(this,"addedSet",new Set),T(this,"movedSet",new Set),T(this,"droppedSet",new Set),T(this,"removesSubTreeCache",new Set),T(this,"mutationCb"),T(this,"blockClass"),T(this,"blockSelector"),T(this,"maskTextClass"),T(this,"maskTextSelector"),T(this,"inlineStylesheet"),T(this,"maskInputOptions"),T(this,"maskTextFn"),T(this,"maskInputFn"),T(this,"keepIframeSrcFn"),T(this,"recordCanvas"),T(this,"inlineImages"),T(this,"slimDOMOptions"),T(this,"dataURLOptions"),T(this,"doc"),T(this,"mirror"),T(this,"iframeManager"),T(this,"stylesheetManager"),T(this,"shadowDomManager"),T(this,"canvasManager"),T(this,"processedNodeManager"),T(this,"unattachedDoc"),T(this,"processMutations",t=>{t.forEach(this.processMutation),this.emit();}),T(this,"emit",()=>{if(this.frozen||this.locked)return;let t=[],r=new Set,i=new xn,n=a=>{let h=a,s=it;for(;s===it;)h=h&&h.nextSibling,s=h&&this.mirror.getId(h);return s},o=a=>{let h=_.parentNode(a);if(!h||!Mo(a))return;let s=false;if(a.nodeType===Node.TEXT_NODE){let m=h.tagName;if(m==="TEXTAREA")return;m==="STYLE"&&this.addedSet.has(h)&&(s=true);}let f=tt(h)?this.mirror.getId(Ro(a)):this.mirror.getId(h),c=n(a);if(f===-1||c===-1)return i.addNode(a);let u=Ve(a,{doc:this.doc,mirror:this.mirror,blockClass:this.blockClass,blockSelector:this.blockSelector,maskTextClass:this.maskTextClass,maskTextSelector:this.maskTextSelector,skipChild:true,newlyAddedElement:true,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:m=>{Eo(m,this.mirror)&&this.iframeManager.addIframe(m),xo(m,this.mirror)&&this.stylesheetManager.trackLinkElement(m),Cn(a)&&this.shadowDomManager.addShadowRoot(_.shadowRoot(a),this.doc);},onIframeLoad:(m,d)=>{this.iframeManager.attachIframe(m,d),this.shadowDomManager.observeAttachShadow(m);},onStylesheetLoad:(m,d)=>{this.stylesheetManager.attachLinkElement(m,d);},cssCaptured:s});u&&(t.push({parentId:f,nextId:c,node:u}),r.add(u.id));};for(;this.mapRemoves.length;)this.mirror.removeNodeFromMap(this.mapRemoves.shift());for(let a of this.movedSet)Ps(this.removesSubTreeCache,a,this.mirror)&&!this.movedSet.has(_.parentNode(a))||o(a);for(let a of this.addedSet)!_s(this.droppedSet,a)&&!Ps(this.removesSubTreeCache,a,this.mirror)||_s(this.movedSet,a)?o(a):this.droppedSet.add(a);let l=null;for(;i.length;){let a=null;if(l){let h=this.mirror.getId(_.parentNode(l.value)),s=n(l.value);h!==-1&&s!==-1&&(a=l);}if(!a){let h=i.tail;for(;h;){let s=h;if(h=h.previous,s){let f=this.mirror.getId(_.parentNode(s.value));if(n(s.value)===-1)continue;if(f!==-1){a=s;break}else {let u=s.value,m=_.parentNode(u);if(m&&m.nodeType===Node.DOCUMENT_FRAGMENT_NODE){let d=_.host(m);if(this.mirror.getId(d)!==-1){a=s;break}}}}}}if(!a){for(;i.head;)i.removeNode(i.head.value);break}l=a.previous,i.removeNode(a.value),o(a.value);}let p={texts:this.texts.map(a=>{let h=a.node,s=_.parentNode(h);return s&&s.tagName==="TEXTAREA"&&this.genTextAreaValueMutation(s),{id:this.mirror.getId(h),value:a.value}}).filter(a=>!r.has(a.id)).filter(a=>this.mirror.has(a.id)),attributes:this.attributes.map(a=>{let{attributes:h}=a;if(typeof h.style=="string"){let s=JSON.stringify(a.styleDiff),f=JSON.stringify(a._unchangedStyles);s.length<h.style.length&&(s+f).split("var(").length===h.style.split("var(").length&&(h.style=a.styleDiff);}return {id:this.mirror.getId(a.node),attributes:h}}).filter(a=>!r.has(a.id)).filter(a=>this.mirror.has(a.id)),removes:this.removes,adds:t};!p.texts.length&&!p.attributes.length&&!p.removes.length&&!p.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(p));}),T(this,"genTextAreaValueMutation",t=>{let r=this.attributeMap.get(t);r||(r={node:t,attributes:{},styleDiff:{},_unchangedStyles:{}},this.attributes.push(r),this.attributeMap.set(t,r));let i=Array.from(_.childNodes(t),n=>_.textContent(n)||"").join("");r.attributes.value=Tt({element:t,maskInputOptions:this.maskInputOptions,tagName:t.tagName,type:kt(t),value:i,maskInputFn:this.maskInputFn});}),T(this,"processMutation",t=>{if(!yn(t.target,this.mirror,this.slimDOMOptions))switch(t.type){case "characterData":{let r=_.textContent(t.target);!le(t.target,this.blockClass,this.blockSelector,false)&&r!==t.oldValue&&this.texts.push({value:Zs(t.target,this.maskTextClass,this.maskTextSelector,true)&&r?this.maskTextFn?this.maskTextFn(r,So(t.target)):r.replace(/[\S]/g,"*"):r,node:t.target});break}case "attributes":{let r=t.target,i=t.attributeName,n=t.target.getAttribute(i);if(i==="value"){let l=kt(r);n=Tt({element:r,maskInputOptions:this.maskInputOptions,tagName:r.tagName,type:l,value:n,maskInputFn:this.maskInputFn});}if(le(t.target,this.blockClass,this.blockSelector,false)||n===t.oldValue)return;let o=this.attributeMap.get(t.target);if(r.tagName==="IFRAME"&&i==="src"&&!this.keepIframeSrcFn(n))if(!r.contentDocument)i="rr_src";else return;if(o||(o={node:t.target,attributes:{},styleDiff:{},_unchangedStyles:{}},this.attributes.push(o),this.attributeMap.set(t.target,o)),i==="type"&&r.tagName==="INPUT"&&(t.oldValue||"").toLowerCase()==="password"&&r.setAttribute("data-rr-is-password","true"),!Ks(r.tagName,i))if(o.attributes[i]=Js(this.doc,Pe(r.tagName),Pe(i),n),i==="style"){if(!this.unattachedDoc)try{this.unattachedDoc=document.implementation.createHTMLDocument();}catch{this.unattachedDoc=this.doc;}let l=this.unattachedDoc.createElement("span");t.oldValue&&l.setAttribute("style",t.oldValue);for(let p of Array.from(r.style)){let a=r.style.getPropertyValue(p),h=r.style.getPropertyPriority(p);a!==l.style.getPropertyValue(p)||h!==l.style.getPropertyPriority(p)?h===""?o.styleDiff[p]=a:o.styleDiff[p]=[a,h]:o._unchangedStyles[p]=[a,h];}for(let p of Array.from(l.style))r.style.getPropertyValue(p)===""&&(o.styleDiff[p]=false);}else i==="open"&&r.tagName==="DIALOG"&&(r.matches("dialog:modal")?o.attributes.rr_open_mode="modal":o.attributes.rr_open_mode="non-modal");break}case "childList":{if(le(t.target,this.blockClass,this.blockSelector,true))return;if(t.target.tagName==="TEXTAREA"){this.genTextAreaValueMutation(t.target);return}t.addedNodes.forEach(r=>this.genAdds(r,t.target)),t.removedNodes.forEach(r=>{let i=this.mirror.getId(r),n=tt(t.target)?this.mirror.getId(_.host(t.target)):this.mirror.getId(t.target);le(t.target,this.blockClass,this.blockSelector,false)||yn(r,this.mirror,this.slimDOMOptions)||!_u(r,this.mirror)||(this.addedSet.has(r)?(Mn(this.addedSet,r),this.droppedSet.add(r)):this.addedSet.has(t.target)&&i===-1||Co(t.target,this.mirror)||(this.movedSet.has(r)&&this.movedMap[Ls(i,n)]?Mn(this.movedSet,r):(this.removes.push({parentId:n,id:i,isShadow:tt(t.target)&&rt(t.target)?true:void 0}),qu(r,this.removesSubTreeCache))),this.mapRemoves.push(r));});break}}}),T(this,"genAdds",(t,r)=>{if(!this.processedNodeManager.inOtherBuffer(t,this)&&!(this.addedSet.has(t)||this.movedSet.has(t))){if(this.mirror.hasNode(t)){if(yn(t,this.mirror,this.slimDOMOptions))return;this.movedSet.add(t);let i=null;r&&this.mirror.hasNode(r)&&(i=this.mirror.getId(r)),i&&i!==-1&&(this.movedMap[Ls(this.mirror.getId(t),i)]=true);}else this.addedSet.add(t),this.droppedSet.delete(t);le(t,this.blockClass,this.blockSelector,false)||(_.childNodes(t).forEach(i=>this.genAdds(i)),Cn(t)&&_.childNodes(_.shadowRoot(t)).forEach(i=>{this.processedNodeManager.add(i,this),this.genAdds(i,t);}));}});}init(t){["mutationCb","blockClass","blockSelector","maskTextClass","maskTextSelector","inlineStylesheet","maskInputOptions","maskTextFn","maskInputFn","keepIframeSrcFn","recordCanvas","inlineImages","slimDOMOptions","dataURLOptions","doc","mirror","iframeManager","stylesheetManager","shadowDomManager","canvasManager","processedNodeManager"].forEach(r=>{this[r]=t[r];});}freeze(){this.frozen=true,this.canvasManager.freeze();}unfreeze(){this.frozen=false,this.canvasManager.unfreeze(),this.emit();}isFrozen(){return this.frozen}lock(){this.locked=true,this.canvasManager.lock();}unlock(){this.locked=false,this.canvasManager.unlock(),this.emit();}reset(){this.shadowDomManager.reset(),this.canvasManager.reset();}};function Mn(e,t){e.delete(t),_.childNodes(t).forEach(r=>Mn(e,r));}function qu(e,t){let r=[e];for(;r.length;){let i=r.pop();t.has(i)||(t.add(i),_.childNodes(i).forEach(n=>r.push(n)));}}function Ps(e,t,r){return e.size===0?false:zu(e,t)}function zu(e,t,r){let i=_.parentNode(t);return i?e.has(i):false}function _s(e,t){return e.size===0?false:No(e,t)}function No(e,t){let r=_.parentNode(t);return r?e.has(r)?true:No(e,r):false}var nt;function $u(e){nt=e;}function Wu(){nt=void 0;}var U=e=>nt?(...r)=>{try{return e(...r)}catch(i){if(nt&&nt(i)===true)return;throw i}}:e,Le=[];function ut(e){try{if("composedPath"in e){let t=e.composedPath();if(t.length)return t[0]}else if("path"in e&&e.path.length)return e.path[0]}catch{}return e&&e.target}function To(e,t){let r=new Rn;Le.push(r),r.init(e);let[i,n]=yo(),o=new i(U(r.processMutations.bind(r)));return o.observe(t,{attributes:true,attributeOldValue:true,characterData:true,characterDataOldValue:true,childList:true,subtree:true}),[o,n]}function Hu({mousemoveCb:e,sampling:t,doc:r,mirror:i}){if(t.mousemove===false)return ()=>{};let n=typeof t.mousemove=="number"?t.mousemove:50,o=typeof t.mousemoveCallback=="number"?t.mousemoveCallback:500,l=[],p,a=ot(U(f=>{let c=Date.now()-p;e(l.map(u=>(u.timeOffset-=c,u)),f),l=[],p=null;}),o),h=U(ot(U(f=>{let c=ut(f),{clientX:u,clientY:m}=Sn(f)?f.changedTouches[0]:f;p||(p=st()),l.push({x:u,y:m,id:i.getId(c),timeOffset:st()-p}),a(typeof DragEvent<"u"&&f instanceof DragEvent?F.Drag:f instanceof MouseEvent?F.MouseMove:F.TouchMove);}),n,{trailing:!1})),s=[ae("mousemove",h,r),ae("touchmove",h,r),ae("drag",h,r)];return U(()=>{s.forEach(f=>f());})}function ju({mouseInteractionCb:e,doc:t,mirror:r,blockClass:i,blockSelector:n,sampling:o}){if(o.mouseInteraction===false)return ()=>{};let l=o.mouseInteraction===true||o.mouseInteraction===void 0?{}:o.mouseInteraction,p=[],a=null,h=s=>f=>{let c=ut(f);if(le(c,i,n,true))return;let u=null,m=s;if("pointerType"in f){switch(f.pointerType){case "mouse":u=Ne.Mouse;break;case "touch":u=Ne.Touch;break;case "pen":u=Ne.Pen;break}u===Ne.Touch?fe[s]===fe.MouseDown?m="TouchStart":fe[s]===fe.MouseUp&&(m="TouchEnd"):Ne.Pen;}else Sn(f)&&(u=Ne.Touch);u!==null?(a=u,(m.startsWith("Touch")&&u===Ne.Touch||m.startsWith("Mouse")&&u===Ne.Mouse)&&(u=null)):fe[s]===fe.Click&&(u=a,a=null);let d=Sn(f)?f.changedTouches[0]:f;if(!d)return;let g=r.getId(c),{clientX:S,clientY:y}=d;U(e)({type:fe[m],id:g,x:S,y,...u!==null&&{pointerType:u}});};return Object.keys(fe).filter(s=>Number.isNaN(Number(s))&&!s.endsWith("_Departed")&&l[s]!==false).forEach(s=>{let f=Pe(s),c=h(s);if(window.PointerEvent)switch(fe[s]){case fe.MouseDown:case fe.MouseUp:f=f.replace("mouse","pointer");break;case fe.TouchStart:case fe.TouchEnd:return}p.push(ae(f,c,t));}),U(()=>{p.forEach(s=>s());})}function ko({scrollCb:e,doc:t,mirror:r,blockClass:i,blockSelector:n,sampling:o}){let l=U(ot(U(p=>{let a=ut(p);if(!a||le(a,i,n,!0))return;let h=r.getId(a);if(a===t&&t.defaultView){let s=vo(t.defaultView);e({id:h,x:s.left,y:s.top});}else e({id:h,x:a.scrollLeft,y:a.scrollTop});}),o.scroll||100));return ae("scroll",l,t)}function Vu({viewportResizeCb:e},{win:t}){let r=-1,i=-1,n=U(ot(U(()=>{let o=wo(),l=bo();(r!==o||i!==l)&&(e({width:Number(l),height:Number(o)}),r=o,i=l);}),200));return ae("resize",n,t)}var Gu=["INPUT","TEXTAREA","SELECT"],Fs=new WeakMap;function Yu({inputCb:e,doc:t,mirror:r,blockClass:i,blockSelector:n,ignoreClass:o,ignoreSelector:l,maskInputOptions:p,maskInputFn:a,sampling:h,userTriggeredOnInput:s}){function f(y){let b=ut(y),E=y.isTrusted,w=b&&b.tagName;if(b&&w==="OPTION"&&(b=_.parentElement(b)),!b||!w||Gu.indexOf(w)<0||le(b,i,n,true)||b.classList.contains(o)||l&&b.matches(l))return;let v=b.value,C=false,R=kt(b)||"";R==="radio"||R==="checkbox"?C=b.checked:(p[w.toLowerCase()]||p[R])&&(v=Tt({element:b,maskInputOptions:p,tagName:w,type:R,value:v,maskInputFn:a})),c(b,s?{text:v,isChecked:C,userTriggered:E}:{text:v,isChecked:C});let I=b.name;R==="radio"&&I&&C&&t.querySelectorAll(`input[type="radio"][name="${I}"]`).forEach(M=>{if(M!==b){let O=M.value;c(M,s?{text:O,isChecked:!C,userTriggered:false}:{text:O,isChecked:!C});}});}function c(y,b){let E=Fs.get(y);if(!E||E.text!==b.text||E.isChecked!==b.isChecked){Fs.set(y,b);let w=r.getId(y);U(e)({...b,id:w});}}let m=(h.input==="last"?["change"]:["input","change"]).map(y=>ae(y,U(f),t)),d=t.defaultView;if(!d)return ()=>{m.forEach(y=>y());};let g=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 g&&g.set&&m.push(...S.map(y=>Vt(y[0],y[1],{set(){U(f)({target:this,isTrusted:false});}},false,d))),U(()=>{m.forEach(y=>y());})}function Dt(e){let t=[];function r(i,n){if(xt("CSSGroupingRule")&&i.parentRule instanceof CSSGroupingRule||xt("CSSMediaRule")&&i.parentRule instanceof CSSMediaRule||xt("CSSSupportsRule")&&i.parentRule instanceof CSSSupportsRule||xt("CSSConditionRule")&&i.parentRule instanceof CSSConditionRule){let l=Array.from(i.parentRule.cssRules).indexOf(i);return n.unshift(l),r(i.parentRule,n)}else if(i.parentStyleSheet){let l=Array.from(i.parentStyleSheet.cssRules).indexOf(i);n.unshift(l);}return n}return r(e,t)}function Oe(e,t,r){let i,n;return e?(e.ownerNode?i=t.getId(e.ownerNode):n=r.getId(e),{styleId:n,id:i}):{}}function Xu({styleSheetRuleCb:e,mirror:t,stylesheetManager:r},{win:i}){if(!i.CSSStyleSheet||!i.CSSStyleSheet.prototype)return ()=>{};let n=i.CSSStyleSheet.prototype.insertRule;i.CSSStyleSheet.prototype.insertRule=new Proxy(n,{apply:U((s,f,c)=>{let[u,m]=c,{id:d,styleId:g}=Oe(f,t,r.styleMirror);return (d&&d!==-1||g&&g!==-1)&&e({id:d,styleId:g,adds:[{rule:u,index:m}]}),s.apply(f,c)})}),i.CSSStyleSheet.prototype.addRule=function(s,f,c=this.cssRules.length){let u=`${s} { ${f} }`;return i.CSSStyleSheet.prototype.insertRule.apply(this,[u,c])};let o=i.CSSStyleSheet.prototype.deleteRule;i.CSSStyleSheet.prototype.deleteRule=new Proxy(o,{apply:U((s,f,c)=>{let[u]=c,{id:m,styleId:d}=Oe(f,t,r.styleMirror);return (m&&m!==-1||d&&d!==-1)&&e({id:m,styleId:d,removes:[{index:u}]}),s.apply(f,c)})}),i.CSSStyleSheet.prototype.removeRule=function(s){return i.CSSStyleSheet.prototype.deleteRule.apply(this,[s])};let l;i.CSSStyleSheet.prototype.replace&&(l=i.CSSStyleSheet.prototype.replace,i.CSSStyleSheet.prototype.replace=new Proxy(l,{apply:U((s,f,c)=>{let[u]=c,{id:m,styleId:d}=Oe(f,t,r.styleMirror);return (m&&m!==-1||d&&d!==-1)&&e({id:m,styleId:d,replace:u}),s.apply(f,c)})}));let p;i.CSSStyleSheet.prototype.replaceSync&&(p=i.CSSStyleSheet.prototype.replaceSync,i.CSSStyleSheet.prototype.replaceSync=new Proxy(p,{apply:U((s,f,c)=>{let[u]=c,{id:m,styleId:d}=Oe(f,t,r.styleMirror);return (m&&m!==-1||d&&d!==-1)&&e({id:m,styleId:d,replaceSync:u}),s.apply(f,c)})}));let a={};Rt("CSSGroupingRule")?a.CSSGroupingRule=i.CSSGroupingRule:(Rt("CSSMediaRule")&&(a.CSSMediaRule=i.CSSMediaRule),Rt("CSSConditionRule")&&(a.CSSConditionRule=i.CSSConditionRule),Rt("CSSSupportsRule")&&(a.CSSSupportsRule=i.CSSSupportsRule));let h={};return Object.entries(a).forEach(([s,f])=>{h[s]={insertRule:f.prototype.insertRule,deleteRule:f.prototype.deleteRule},f.prototype.insertRule=new Proxy(h[s].insertRule,{apply:U((c,u,m)=>{let[d,g]=m,{id:S,styleId:y}=Oe(u.parentStyleSheet,t,r.styleMirror);return (S&&S!==-1||y&&y!==-1)&&e({id:S,styleId:y,adds:[{rule:d,index:[...Dt(u),g||0]}]}),c.apply(u,m)})}),f.prototype.deleteRule=new Proxy(h[s].deleteRule,{apply:U((c,u,m)=>{let[d]=m,{id:g,styleId:S}=Oe(u.parentStyleSheet,t,r.styleMirror);return (g&&g!==-1||S&&S!==-1)&&e({id:g,styleId:S,removes:[{index:[...Dt(u),d]}]}),c.apply(u,m)})});}),U(()=>{i.CSSStyleSheet.prototype.insertRule=n,i.CSSStyleSheet.prototype.deleteRule=o,l&&(i.CSSStyleSheet.prototype.replace=l),p&&(i.CSSStyleSheet.prototype.replaceSync=p),Object.entries(a).forEach(([s,f])=>{f.prototype.insertRule=h[s].insertRule,f.prototype.deleteRule=h[s].deleteRule;});})}function Ao({mirror:e,stylesheetManager:t},r){var i,n,o;let l=null;r.nodeName==="#document"?l=e.getId(r):l=e.getId(_.host(r));let p=r.nodeName==="#document"?(i=r.defaultView)==null?void 0:i.Document:(o=(n=r.ownerDocument)==null?void 0:n.defaultView)==null?void 0:o.ShadowRoot,a=p?.prototype?Object.getOwnPropertyDescriptor(p?.prototype,"adoptedStyleSheets"):void 0;return l===null||l===-1||!p||!a?()=>{}:(Object.defineProperty(r,"adoptedStyleSheets",{configurable:a.configurable,enumerable:a.enumerable,get(){var h;return (h=a.get)==null?void 0:h.call(this)},set(h){var s;let f=(s=a.set)==null?void 0:s.call(this,h);if(l!==null&&l!==-1)try{t.adoptStyleSheets(h,l);}catch{}return f}}),U(()=>{Object.defineProperty(r,"adoptedStyleSheets",{configurable:a.configurable,enumerable:a.enumerable,get:a.get,set:a.set});}))}function Ju({styleDeclarationCb:e,mirror:t,ignoreCSSAttributes:r,stylesheetManager:i},{win:n}){let o=n.CSSStyleDeclaration.prototype.setProperty;n.CSSStyleDeclaration.prototype.setProperty=new Proxy(o,{apply:U((p,a,h)=>{var s;let[f,c,u]=h;if(r.has(f))return o.apply(a,[f,c,u]);let{id:m,styleId:d}=Oe((s=a.parentRule)==null?void 0:s.parentStyleSheet,t,i.styleMirror);return (m&&m!==-1||d&&d!==-1)&&e({id:m,styleId:d,set:{property:f,value:c,priority:u},index:Dt(a.parentRule)}),p.apply(a,h)})});let l=n.CSSStyleDeclaration.prototype.removeProperty;return n.CSSStyleDeclaration.prototype.removeProperty=new Proxy(l,{apply:U((p,a,h)=>{var s;let[f]=h;if(r.has(f))return l.apply(a,[f]);let{id:c,styleId:u}=Oe((s=a.parentRule)==null?void 0:s.parentStyleSheet,t,i.styleMirror);return (c&&c!==-1||u&&u!==-1)&&e({id:c,styleId:u,remove:{property:f},index:Dt(a.parentRule)}),p.apply(a,h)})}),U(()=>{n.CSSStyleDeclaration.prototype.setProperty=o,n.CSSStyleDeclaration.prototype.removeProperty=l;})}function Ku({mediaInteractionCb:e,blockClass:t,blockSelector:r,mirror:i,sampling:n,doc:o}){let l=U(a=>ot(U(h=>{let s=ut(h);if(!s||le(s,t,r,!0))return;let{currentTime:f,volume:c,muted:u,playbackRate:m,loop:d}=s;e({type:a,id:i.getId(s),currentTime:f,volume:c,muted:u,playbackRate:m,loop:d});}),n.media||500)),p=[ae("play",l(He.Play),o),ae("pause",l(He.Pause),o),ae("seeked",l(He.Seeked),o),ae("volumechange",l(He.VolumeChange),o),ae("ratechange",l(He.RateChange),o)];return U(()=>{p.forEach(a=>a());})}function Zu({fontCb:e,doc:t}){let r=t.defaultView;if(!r)return ()=>{};let i=[],n=new WeakMap,o=r.FontFace;r.FontFace=function(a,h,s){let f=new o(a,h,s);return n.set(f,{family:a,buffer:typeof h!="string",descriptors:s,fontSource:typeof h=="string"?h:JSON.stringify(Array.from(new Uint8Array(h)))}),f};let l=Ue(t.fonts,"add",function(p){return function(a){return setTimeout(U(()=>{let h=n.get(a);h&&(e(h),n.delete(a));}),0),p.apply(this,[a])}});return i.push(()=>{r.FontFace=o;}),i.push(l),U(()=>{i.forEach(p=>p());})}function Qu(e){let{doc:t,mirror:r,blockClass:i,blockSelector:n,selectionCb:o}=e,l=true,p=U(()=>{let a=t.getSelection();if(!a||l&&a?.isCollapsed)return;l=a.isCollapsed||!1;let h=[],s=a.rangeCount||0;for(let f=0;f<s;f++){let c=a.getRangeAt(f),{startContainer:u,startOffset:m,endContainer:d,endOffset:g}=c;le(u,i,n,!0)||le(d,i,n,!0)||h.push({start:r.getId(u),startOffset:m,end:r.getId(d),endOffset:g});}o({ranges:h});});return p(),ae("selectionchange",p)}function ec({doc:e,customElementCb:t}){let r=e.defaultView;return !r||!r.customElements?()=>{}:Ue(r.customElements,"define",function(n){return function(o,l,p){try{t({define:{name:o}});}catch{console.warn(`Custom element callback failed for ${o}`);}return n.apply(this,[o,l,p])}})}function tc(e,t){let{mutationCb:r,mousemoveCb:i,mouseInteractionCb:n,scrollCb:o,viewportResizeCb:l,inputCb:p,mediaInteractionCb:a,styleSheetRuleCb:h,styleDeclarationCb:s,canvasMutationCb:f,fontCb:c,selectionCb:u,customElementCb:m}=e;e.mutationCb=(...d)=>{t.mutation&&t.mutation(...d),r(...d);},e.mousemoveCb=(...d)=>{t.mousemove&&t.mousemove(...d),i(...d);},e.mouseInteractionCb=(...d)=>{t.mouseInteraction&&t.mouseInteraction(...d),n(...d);},e.scrollCb=(...d)=>{t.scroll&&t.scroll(...d),o(...d);},e.viewportResizeCb=(...d)=>{t.viewportResize&&t.viewportResize(...d),l(...d);},e.inputCb=(...d)=>{t.input&&t.input(...d),p(...d);},e.mediaInteractionCb=(...d)=>{t.mediaInteaction&&t.mediaInteaction(...d),a(...d);},e.styleSheetRuleCb=(...d)=>{t.styleSheetRule&&t.styleSheetRule(...d),h(...d);},e.styleDeclarationCb=(...d)=>{t.styleDeclaration&&t.styleDeclaration(...d),s(...d);},e.canvasMutationCb=(...d)=>{t.canvasMutation&&t.canvasMutation(...d),f(...d);},e.fontCb=(...d)=>{t.font&&t.font(...d),c(...d);},e.selectionCb=(...d)=>{t.selection&&t.selection(...d),u(...d);},e.customElementCb=(...d)=>{t.customElement&&t.customElement(...d),m(...d);};}function rc(e,t={}){let r=e.doc.defaultView;if(!r)return ()=>{};tc(e,t);let i,n=()=>{};e.recordDOM&&([i,n]=To(e,e.doc));let o=Hu(e),l=ju(e),p=ko(e),a=Vu(e,{win:r}),h=Yu(e),s=Ku(e),f=()=>{},c=()=>{},u=()=>{},m=()=>{};e.recordDOM&&(f=Xu(e,{win:r}),c=Ao(e,e.doc),u=Ju(e,{win:r}),e.collectFonts&&(m=Zu(e)));let d=Qu(e),g=ec(e),S=[];for(let y of e.plugins)S.push(y.observer(y.callback,r,y.options));return U(()=>{Le.forEach(y=>y.reset()),i?.disconnect(),n(),o(),l(),p(),a(),h(),s(),f(),c(),u(),m(),d(),g(),S.forEach(y=>y());})}function xt(e){return typeof window[e]<"u"}function Rt(e){return !!(typeof window[e]<"u"&&window[e].prototype&&"insertRule"in window[e].prototype&&"deleteRule"in window[e].prototype)}var Lt=class{constructor(t){T(this,"iframeIdToRemoteIdMap",new WeakMap),T(this,"iframeRemoteIdToIdMap",new WeakMap),this.generateIdFn=t;}getId(t,r,i,n){let o=i||this.getIdToRemoteIdMap(t),l=n||this.getRemoteIdToIdMap(t),p=o.get(r);return p||(p=this.generateIdFn(),o.set(r,p),l.set(p,r)),p}getIds(t,r){let i=this.getIdToRemoteIdMap(t),n=this.getRemoteIdToIdMap(t);return r.map(o=>this.getId(t,o,i,n))}getRemoteId(t,r,i){let n=i||this.getRemoteIdToIdMap(t);if(typeof r!="number")return r;let o=n.get(r);return o||-1}getRemoteIds(t,r){let i=this.getRemoteIdToIdMap(t);return r.map(n=>this.getRemoteId(t,n,i))}reset(t){if(!t){this.iframeIdToRemoteIdMap=new WeakMap,this.iframeRemoteIdToIdMap=new WeakMap;return}this.iframeIdToRemoteIdMap.delete(t),this.iframeRemoteIdToIdMap.delete(t);}getIdToRemoteIdMap(t){let r=this.iframeIdToRemoteIdMap.get(t);return r||(r=new Map,this.iframeIdToRemoteIdMap.set(t,r)),r}getRemoteIdToIdMap(t){let r=this.iframeRemoteIdToIdMap.get(t);return r||(r=new Map,this.iframeRemoteIdToIdMap.set(t,r)),r}},In=class{constructor(t){T(this,"iframes",new WeakMap),T(this,"crossOriginIframeMap",new WeakMap),T(this,"crossOriginIframeMirror",new Lt(Xs)),T(this,"crossOriginIframeStyleMirror"),T(this,"crossOriginIframeRootIdMap",new WeakMap),T(this,"mirror"),T(this,"mutationCb"),T(this,"wrappedEmit"),T(this,"loadListener"),T(this,"stylesheetManager"),T(this,"recordCrossOriginIframes"),this.mutationCb=t.mutationCb,this.wrappedEmit=t.wrappedEmit,this.stylesheetManager=t.stylesheetManager,this.recordCrossOriginIframes=t.recordCrossOriginIframes,this.crossOriginIframeStyleMirror=new Lt(this.stylesheetManager.styleMirror.generateId.bind(this.stylesheetManager.styleMirror)),this.mirror=t.mirror,this.recordCrossOriginIframes&&window.addEventListener("message",this.handleMessage.bind(this));}addIframe(t){this.iframes.set(t,true),t.contentWindow&&this.crossOriginIframeMap.set(t.contentWindow,t);}addLoadListener(t){this.loadListener=t;}attachIframe(t,r){var i,n;this.mutationCb({adds:[{parentId:this.mirror.getId(t),nextId:null,node:r}],removes:[],texts:[],attributes:[],isAttachIframe:true}),this.recordCrossOriginIframes&&((i=t.contentWindow)==null||i.addEventListener("message",this.handleMessage.bind(this))),(n=this.loadListener)==null||n.call(this,t),t.contentDocument&&t.contentDocument.adoptedStyleSheets&&t.contentDocument.adoptedStyleSheets.length>0&&this.stylesheetManager.adoptStyleSheets(t.contentDocument.adoptedStyleSheets,this.mirror.getId(t.contentDocument));}handleMessage(t){let r=t;if(r.data.type!=="rrweb"||r.origin!==r.data.origin||!t.source)return;let n=this.crossOriginIframeMap.get(t.source);if(!n)return;let o=this.transformCrossOriginEvent(n,r.data.event);o&&this.wrappedEmit(o,r.data.isCheckout);}transformCrossOriginEvent(t,r){var i;switch(r.type){case q.FullSnapshot:{this.crossOriginIframeMirror.reset(t),this.crossOriginIframeStyleMirror.reset(t),this.replaceIdOnNode(r.data.node,t);let n=r.data.node.id;return this.crossOriginIframeRootIdMap.set(t,n),this.patchRootIdOnNode(r.data.node,n),{timestamp:r.timestamp,type:q.IncrementalSnapshot,data:{source:F.Mutation,adds:[{parentId:this.mirror.getId(t),nextId:null,node:r.data.node}],removes:[],texts:[],attributes:[],isAttachIframe:true}}}case q.Meta:case q.Load:case q.DomContentLoaded:return false;case q.Plugin:return r;case q.Custom:return this.replaceIds(r.data.payload,t,["id","parentId","previousId","nextId"]),r;case q.IncrementalSnapshot:switch(r.data.source){case F.Mutation:return r.data.adds.forEach(n=>{this.replaceIds(n,t,["parentId","nextId","previousId"]),this.replaceIdOnNode(n.node,t);let o=this.crossOriginIframeRootIdMap.get(t);o&&this.patchRootIdOnNode(n.node,o);}),r.data.removes.forEach(n=>{this.replaceIds(n,t,["parentId","id"]);}),r.data.attributes.forEach(n=>{this.replaceIds(n,t,["id"]);}),r.data.texts.forEach(n=>{this.replaceIds(n,t,["id"]);}),r;case F.Drag:case F.TouchMove:case F.MouseMove:return r.data.positions.forEach(n=>{this.replaceIds(n,t,["id"]);}),r;case F.ViewportResize:return false;case F.MediaInteraction:case F.MouseInteraction:case F.Scroll:case F.CanvasMutation:case F.Input:return this.replaceIds(r.data,t,["id"]),r;case F.StyleSheetRule:case F.StyleDeclaration:return this.replaceIds(r.data,t,["id"]),this.replaceStyleIds(r.data,t,["styleId"]),r;case F.Font:return r;case F.Selection:return r.data.ranges.forEach(n=>{this.replaceIds(n,t,["start","end"]);}),r;case F.AdoptedStyleSheet:return this.replaceIds(r.data,t,["id"]),this.replaceStyleIds(r.data,t,["styleIds"]),(i=r.data.styles)==null||i.forEach(n=>{this.replaceStyleIds(n,t,["styleId"]);}),r}}return false}replace(t,r,i,n){for(let o of n)!Array.isArray(r[o])&&typeof r[o]!="number"||(Array.isArray(r[o])?r[o]=t.getIds(i,r[o]):r[o]=t.getId(i,r[o]));return r}replaceIds(t,r,i){return this.replace(this.crossOriginIframeMirror,t,r,i)}replaceStyleIds(t,r,i){return this.replace(this.crossOriginIframeStyleMirror,t,r,i)}replaceIdOnNode(t,r){this.replaceIds(t,r,["id","rootId"]),"childNodes"in t&&t.childNodes.forEach(i=>{this.replaceIdOnNode(i,r);});}patchRootIdOnNode(t,r){t.type!==Io.Document&&!t.rootId&&(t.rootId=r),"childNodes"in t&&t.childNodes.forEach(i=>{this.patchRootIdOnNode(i,r);});}},Nn=class{constructor(t){T(this,"shadowDoms",new WeakSet),T(this,"mutationCb"),T(this,"scrollCb"),T(this,"bypassOptions"),T(this,"mirror"),T(this,"restoreHandlers",[]),this.mutationCb=t.mutationCb,this.scrollCb=t.scrollCb,this.bypassOptions=t.bypassOptions,this.mirror=t.mirror,this.init();}init(){this.reset(),this.patchAttachShadow(Element,document);}addShadowRoot(t,r){if(!rt(t)||this.shadowDoms.has(t))return;this.shadowDoms.add(t);let[i]=To({...this.bypassOptions,doc:r,mutationCb:this.mutationCb,mirror:this.mirror,shadowDomManager:this},t);this.restoreHandlers.push(()=>i.disconnect()),this.restoreHandlers.push(ko({...this.bypassOptions,scrollCb:this.scrollCb,doc:t,mirror:this.mirror})),setTimeout(()=>{t.adoptedStyleSheets&&t.adoptedStyleSheets.length>0&&this.bypassOptions.stylesheetManager.adoptStyleSheets(t.adoptedStyleSheets,this.mirror.getId(_.host(t))),this.restoreHandlers.push(Ao({mirror:this.mirror,stylesheetManager:this.bypassOptions.stylesheetManager},t));},0);}observeAttachShadow(t){!t.contentWindow||!t.contentDocument||this.patchAttachShadow(t.contentWindow.Element,t.contentDocument);}patchAttachShadow(t,r){let i=this;this.restoreHandlers.push(Ue(t.prototype,"attachShadow",function(n){return function(o){let l=n.call(this,o),p=_.shadowRoot(this);return p&&Mo(this)&&i.addShadowRoot(p,r),l}}));}reset(){this.restoreHandlers.forEach(t=>{try{t();}catch{}}),this.restoreHandlers=[],this.shadowDoms=new WeakSet;}},Ge="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",nc=typeof Uint8Array>"u"?[]:new Uint8Array(256);for(et=0;et<Ge.length;et++)nc[Ge.charCodeAt(et)]=et;var et,ic=function(e){var t=new Uint8Array(e),r,i=t.length,n="";for(r=0;r<i;r+=3)n+=Ge[t[r]>>2],n+=Ge[(t[r]&3)<<4|t[r+1]>>4],n+=Ge[(t[r+1]&15)<<2|t[r+2]>>6],n+=Ge[t[r+2]&63];return i%3===2?n=n.substring(0,n.length-1)+"=":i%3===1&&(n=n.substring(0,n.length-2)+"=="),n};var Us=new Map;function sc(e,t){let r=Us.get(e);return r||(r=new Map,Us.set(e,r)),r.has(t)||r.set(t,[]),r.get(t)}var Oo=(e,t,r)=>{if(!e||!(Lo(e,t)||typeof e=="object"))return;let i=e.constructor.name,n=sc(r,i),o=n.indexOf(e);return o===-1&&(o=n.length,n.push(e)),o};function Mt(e,t,r){if(e instanceof Array)return e.map(i=>Mt(i,t,r));if(e===null)return e;if(e instanceof Float32Array||e instanceof Float64Array||e instanceof Int32Array||e instanceof Uint32Array||e instanceof Uint8Array||e instanceof Uint16Array||e instanceof Int16Array||e instanceof Int8Array||e instanceof Uint8ClampedArray)return {rr_type:e.constructor.name,args:[Object.values(e)]};if(e instanceof ArrayBuffer){let i=e.constructor.name,n=ic(e);return {rr_type:i,base64:n}}else {if(e instanceof DataView)return {rr_type:e.constructor.name,args:[Mt(e.buffer,t,r),e.byteOffset,e.byteLength]};if(e instanceof HTMLImageElement){let i=e.constructor.name,{src:n}=e;return {rr_type:i,src:n}}else if(e instanceof HTMLCanvasElement){let i="HTMLImageElement",n=e.toDataURL();return {rr_type:i,src:n}}else {if(e instanceof ImageData)return {rr_type:e.constructor.name,args:[Mt(e.data,t,r),e.width,e.height]};if(Lo(e,t)||typeof e=="object"){let i=e.constructor.name,n=Oo(e,t,r);return {rr_type:i,index:n}}}}return e}var Do=(e,t,r)=>e.map(i=>Mt(i,t,r)),Lo=(e,t)=>!!["WebGLActiveInfo","WebGLBuffer","WebGLFramebuffer","WebGLProgram","WebGLRenderbuffer","WebGLShader","WebGLShaderPrecisionFormat","WebGLTexture","WebGLUniformLocation","WebGLVertexArrayObject","WebGLVertexArrayObjectOES"].filter(n=>typeof t[n]=="function").find(n=>e instanceof t[n]);function oc(e,t,r,i){let n=[],o=Object.getOwnPropertyNames(t.CanvasRenderingContext2D.prototype);for(let l of o)try{if(typeof t.CanvasRenderingContext2D.prototype[l]!="function")continue;let p=Ue(t.CanvasRenderingContext2D.prototype,l,function(a){return function(...h){return le(this.canvas,r,i,!0)||setTimeout(()=>{let s=Do(h,t,this);e(this.canvas,{type:Ye["2D"],property:l,args:s});},0),a.apply(this,h)}});n.push(p);}catch{let p=Vt(t.CanvasRenderingContext2D.prototype,l,{set(a){e(this.canvas,{type:Ye["2D"],property:l,args:[a],setter:true});}});n.push(p);}return ()=>{n.forEach(l=>l());}}function ac(e){return e==="experimental-webgl"?"webgl":e}function Bs(e,t,r,i){let n=[];try{let o=Ue(e.HTMLCanvasElement.prototype,"getContext",function(l){return function(p,...a){if(!le(this,t,r,!0)){let h=ac(p);if("__context"in this||(this.__context=h),i&&["webgl","webgl2"].includes(h))if(a[0]&&typeof a[0]=="object"){let s=a[0];s.preserveDrawingBuffer||(s.preserveDrawingBuffer=!0);}else a.splice(0,1,{preserveDrawingBuffer:!0});}return l.apply(this,[p,...a])}});n.push(o);}catch{console.error("failed to patch HTMLCanvasElement.prototype.getContext");}return ()=>{n.forEach(o=>o());}}function qs(e,t,r,i,n,o){let l=[],p=Object.getOwnPropertyNames(e);for(let a of p)if(!["isContextLost","canvas","drawingBufferWidth","drawingBufferHeight"].includes(a))try{if(typeof e[a]!="function")continue;let h=Ue(e,a,function(s){return function(...f){let c=s.apply(this,f);if(Oo(c,o,this),"tagName"in this.canvas&&!le(this.canvas,i,n,!0)){let u=Do(f,o,this),m={type:t,property:a,args:u};r(this.canvas,m);}return c}});l.push(h);}catch{let h=Vt(e,a,{set(s){r(this.canvas,{type:t,property:a,args:[s],setter:true});}});l.push(h);}return l}function lc(e,t,r,i){let n=[];return typeof t.WebGLRenderingContext<"u"&&n.push(...qs(t.WebGLRenderingContext.prototype,Ye.WebGL,e,r,i,t)),typeof t.WebGL2RenderingContext<"u"&&n.push(...qs(t.WebGL2RenderingContext.prototype,Ye.WebGL2,e,r,i,t)),()=>{n.forEach(o=>o());}}var Po=`(function() {
53
+ or you can use record.mirror to access the mirror instance during recording.`,Ds={map:{},getId(){return console.error(We),-1},getNode(){return console.error(We),null},removeNodeFromMap(){console.error(We);},has(){return console.error(We),false},reset(){console.error(We);}};typeof window<"u"&&window.Proxy&&window.Reflect&&(Ds=new Proxy(Ds,{get(e,t,r){return t==="map"&&console.error(We),Reflect.get(e,t,r)}}));function ot(e,t,r={}){let i=null,n=0;return function(...o){let l=Date.now();!n&&r.leading===false&&(n=l);let d=t-(l-n),a=this;d<=0||d>t?(i&&(clearTimeout(i),i=null),n=l,e.apply(a,o)):!i&&r.trailing!==false&&(i=setTimeout(()=>{n=r.leading===false?0:Date.now(),i=null,e.apply(a,o);},d));}}function Vt(e,t,r,i,n=window){let o=n.Object.getOwnPropertyDescriptor(e,t);return n.Object.defineProperty(e,t,i?r:{set(l){setTimeout(()=>{r.set.call(this,l);},0),o&&o.set&&o.set.call(this,l);}}),()=>Vt(e,t,o||{},true)}function wo(e){var t,r,i,n;let o=e.document;return {left:o.scrollingElement?o.scrollingElement.scrollLeft:e.pageXOffset!==void 0?e.pageXOffset:o.documentElement.scrollLeft||o?.body&&((t=_.parentElement(o.body))==null?void 0:t.scrollLeft)||((r=o?.body)==null?void 0:r.scrollLeft)||0,top:o.scrollingElement?o.scrollingElement.scrollTop:e.pageYOffset!==void 0?e.pageYOffset:o?.documentElement.scrollTop||o?.body&&((i=_.parentElement(o.body))==null?void 0:i.scrollTop)||((n=o?.body)==null?void 0:n.scrollTop)||0}}function bo(){return window.innerHeight||document.documentElement&&document.documentElement.clientHeight||document.body&&document.body.clientHeight}function So(){return window.innerWidth||document.documentElement&&document.documentElement.clientWidth||document.body&&document.body.clientWidth}function Co(e){return e?e.nodeType===e.ELEMENT_NODE?e:_.parentElement(e):null}function le(e,t,r,i){if(!e)return false;let n=Co(e);if(!n)return false;try{if(typeof t=="string"){if(n.classList.contains(t)||i&&n.closest("."+t)!==null)return !0}else if(Ot(n,t,i))return !0}catch{}return !!(r&&(n.matches(r)||i&&n.closest(r)!==null))}function Fu(e,t){return t.getId(e)!==-1}function yn(e,t,r){return e.tagName==="TITLE"&&r.headTitleMutations?true:t.getId(e)===it}function Eo(e,t){if(tt(e))return false;let r=t.getId(e);if(!t.has(r))return true;let i=_.parentNode(e);return i&&i.nodeType===e.DOCUMENT_NODE?false:i?Eo(i,t):true}function Sn(e){return !!e.changedTouches}function Uu(e=window){"NodeList"in e&&!e.NodeList.prototype.forEach&&(e.NodeList.prototype.forEach=Array.prototype.forEach),"DOMTokenList"in e&&!e.DOMTokenList.prototype.forEach&&(e.DOMTokenList.prototype.forEach=Array.prototype.forEach);}function xo(e,t){return !!(e.nodeName==="IFRAME"&&t.getMeta(e))}function Ro(e,t){return !!(e.nodeName==="LINK"&&e.nodeType===e.ELEMENT_NODE&&e.getAttribute&&e.getAttribute("rel")==="stylesheet"&&t.getMeta(e))}function Cn(e){return e?e instanceof bn&&"shadowRoot"in e?!!e.shadowRoot:!!_.shadowRoot(e):false}var En=class{constructor(){T(this,"id",1),T(this,"styleIDMap",new WeakMap),T(this,"idStyleMap",new Map);}getId(t){return this.styleIDMap.get(t)??-1}has(t){return this.styleIDMap.has(t)}add(t,r){if(this.has(t))return this.getId(t);let i;return r===void 0?i=this.id++:i=r,this.styleIDMap.set(t,i),this.idStyleMap.set(i,t),i}getStyle(t){return this.idStyleMap.get(t)||null}reset(){this.styleIDMap=new WeakMap,this.idStyleMap=new Map,this.id=1;}generateId(){return this.id++}};function Io(e){var t;let r=null;return "getRootNode"in e&&((t=_.getRootNode(e))==null?void 0:t.nodeType)===Node.DOCUMENT_FRAGMENT_NODE&&_.host(_.getRootNode(e))&&(r=_.host(_.getRootNode(e))),r}function Bu(e){let t=e,r;for(;r=Io(t);)t=r;return t}function qu(e){let t=_.ownerDocument(e);if(!t)return false;let r=Bu(e);return _.contains(t,r)}function Mo(e){let t=_.ownerDocument(e);return t?_.contains(t,e)||qu(e):false}var q=(e=>(e[e.DomContentLoaded=0]="DomContentLoaded",e[e.Load=1]="Load",e[e.FullSnapshot=2]="FullSnapshot",e[e.IncrementalSnapshot=3]="IncrementalSnapshot",e[e.Meta=4]="Meta",e[e.Custom=5]="Custom",e[e.Plugin=6]="Plugin",e[e.Asset=7]="Asset",e))(q||{}),F=(e=>(e[e.Mutation=0]="Mutation",e[e.MouseMove=1]="MouseMove",e[e.MouseInteraction=2]="MouseInteraction",e[e.Scroll=3]="Scroll",e[e.ViewportResize=4]="ViewportResize",e[e.Input=5]="Input",e[e.TouchMove=6]="TouchMove",e[e.MediaInteraction=7]="MediaInteraction",e[e.StyleSheetRule=8]="StyleSheetRule",e[e.CanvasMutation=9]="CanvasMutation",e[e.Font=10]="Font",e[e.Log=11]="Log",e[e.Drag=12]="Drag",e[e.StyleDeclaration=13]="StyleDeclaration",e[e.Selection=14]="Selection",e[e.AdoptedStyleSheet=15]="AdoptedStyleSheet",e[e.CustomElement=16]="CustomElement",e))(F||{}),fe=(e=>(e[e.MouseUp=0]="MouseUp",e[e.MouseDown=1]="MouseDown",e[e.Click=2]="Click",e[e.ContextMenu=3]="ContextMenu",e[e.DblClick=4]="DblClick",e[e.Focus=5]="Focus",e[e.Blur=6]="Blur",e[e.TouchStart=7]="TouchStart",e[e.TouchMove_Departed=8]="TouchMove_Departed",e[e.TouchEnd=9]="TouchEnd",e[e.TouchCancel=10]="TouchCancel",e))(fe||{}),Ne=(e=>(e[e.Mouse=0]="Mouse",e[e.Pen=1]="Pen",e[e.Touch=2]="Touch",e))(Ne||{}),Ye=(e=>(e[e["2D"]=0]="2D",e[e.WebGL=1]="WebGL",e[e.WebGL2=2]="WebGL2",e))(Ye||{}),He=(e=>(e[e.Play=0]="Play",e[e.Pause=1]="Pause",e[e.Seeked=2]="Seeked",e[e.VolumeChange=3]="VolumeChange",e[e.RateChange=4]="RateChange",e))(He||{});var No=(e=>(e[e.Document=0]="Document",e[e.DocumentType=1]="DocumentType",e[e.Element=2]="Element",e[e.Text=3]="Text",e[e.CDATA=4]="CDATA",e[e.Comment=5]="Comment",e))(No||{});function Ls(e){return "__ln"in e}var xn=class{constructor(){T(this,"length",0),T(this,"head",null),T(this,"tail",null);}get(t){if(t>=this.length)throw new Error("Position outside of list range");let r=this.head;for(let i=0;i<t;i++)r=r?.next||null;return r}addNode(t){let r={value:t,previous:null,next:null};if(t.__ln=r,t.previousSibling&&Ls(t.previousSibling)){let i=t.previousSibling.__ln.next;r.next=i,r.previous=t.previousSibling.__ln,t.previousSibling.__ln.next=r,i&&(i.previous=r);}else if(t.nextSibling&&Ls(t.nextSibling)&&t.nextSibling.__ln.previous){let i=t.nextSibling.__ln.previous;r.previous=i,r.next=t.nextSibling.__ln,t.nextSibling.__ln.previous=r,i&&(i.next=r);}else this.head&&(this.head.previous=r),r.next=this.head,this.head=r;r.next===null&&(this.tail=r),this.length++;}removeNode(t){let r=t.__ln;this.head&&(r.previous?(r.previous.next=r.next,r.next?r.next.previous=r.previous:this.tail=r.previous):(this.head=r.next,this.head?this.head.previous=null:this.tail=null),t.__ln&&delete t.__ln,this.length--);}},Ps=(e,t)=>`${e}@${t}`,Rn=class{constructor(){T(this,"frozen",false),T(this,"locked",false),T(this,"texts",[]),T(this,"attributes",[]),T(this,"attributeMap",new WeakMap),T(this,"removes",[]),T(this,"mapRemoves",[]),T(this,"movedMap",{}),T(this,"addedSet",new Set),T(this,"movedSet",new Set),T(this,"droppedSet",new Set),T(this,"removesSubTreeCache",new Set),T(this,"mutationCb"),T(this,"blockClass"),T(this,"blockSelector"),T(this,"maskTextClass"),T(this,"maskTextSelector"),T(this,"inlineStylesheet"),T(this,"maskInputOptions"),T(this,"maskTextFn"),T(this,"maskInputFn"),T(this,"keepIframeSrcFn"),T(this,"recordCanvas"),T(this,"inlineImages"),T(this,"slimDOMOptions"),T(this,"dataURLOptions"),T(this,"doc"),T(this,"mirror"),T(this,"iframeManager"),T(this,"stylesheetManager"),T(this,"shadowDomManager"),T(this,"canvasManager"),T(this,"processedNodeManager"),T(this,"unattachedDoc"),T(this,"processMutations",t=>{t.forEach(this.processMutation),this.emit();}),T(this,"emit",()=>{if(this.frozen||this.locked)return;let t=[],r=new Set,i=new xn,n=a=>{let h=a,s=it;for(;s===it;)h=h&&h.nextSibling,s=h&&this.mirror.getId(h);return s},o=a=>{let h=_.parentNode(a);if(!h||!Mo(a))return;let s=false;if(a.nodeType===Node.TEXT_NODE){let m=h.tagName;if(m==="TEXTAREA")return;m==="STYLE"&&this.addedSet.has(h)&&(s=true);}let f=tt(h)?this.mirror.getId(Io(a)):this.mirror.getId(h),c=n(a);if(f===-1||c===-1)return i.addNode(a);let u=Ve(a,{doc:this.doc,mirror:this.mirror,blockClass:this.blockClass,blockSelector:this.blockSelector,maskTextClass:this.maskTextClass,maskTextSelector:this.maskTextSelector,skipChild:true,newlyAddedElement:true,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:m=>{xo(m,this.mirror)&&this.iframeManager.addIframe(m),Ro(m,this.mirror)&&this.stylesheetManager.trackLinkElement(m),Cn(a)&&this.shadowDomManager.addShadowRoot(_.shadowRoot(a),this.doc);},onIframeLoad:(m,p)=>{this.iframeManager.attachIframe(m,p),this.shadowDomManager.observeAttachShadow(m);},onStylesheetLoad:(m,p)=>{this.stylesheetManager.attachLinkElement(m,p);},cssCaptured:s});u&&(t.push({parentId:f,nextId:c,node:u}),r.add(u.id));};for(;this.mapRemoves.length;)this.mirror.removeNodeFromMap(this.mapRemoves.shift());for(let a of this.movedSet)_s(this.removesSubTreeCache,a,this.mirror)&&!this.movedSet.has(_.parentNode(a))||o(a);for(let a of this.addedSet)!Fs(this.droppedSet,a)&&!_s(this.removesSubTreeCache,a,this.mirror)||Fs(this.movedSet,a)?o(a):this.droppedSet.add(a);let l=null;for(;i.length;){let a=null;if(l){let h=this.mirror.getId(_.parentNode(l.value)),s=n(l.value);h!==-1&&s!==-1&&(a=l);}if(!a){let h=i.tail;for(;h;){let s=h;if(h=h.previous,s){let f=this.mirror.getId(_.parentNode(s.value));if(n(s.value)===-1)continue;if(f!==-1){a=s;break}else {let u=s.value,m=_.parentNode(u);if(m&&m.nodeType===Node.DOCUMENT_FRAGMENT_NODE){let p=_.host(m);if(this.mirror.getId(p)!==-1){a=s;break}}}}}}if(!a){for(;i.head;)i.removeNode(i.head.value);break}l=a.previous,i.removeNode(a.value),o(a.value);}let d={texts:this.texts.map(a=>{let h=a.node,s=_.parentNode(h);return s&&s.tagName==="TEXTAREA"&&this.genTextAreaValueMutation(s),{id:this.mirror.getId(h),value:a.value}}).filter(a=>!r.has(a.id)).filter(a=>this.mirror.has(a.id)),attributes:this.attributes.map(a=>{let{attributes:h}=a;if(typeof h.style=="string"){let s=JSON.stringify(a.styleDiff),f=JSON.stringify(a._unchangedStyles);s.length<h.style.length&&(s+f).split("var(").length===h.style.split("var(").length&&(h.style=a.styleDiff);}return {id:this.mirror.getId(a.node),attributes:h}}).filter(a=>!r.has(a.id)).filter(a=>this.mirror.has(a.id)),removes:this.removes,adds:t};!d.texts.length&&!d.attributes.length&&!d.removes.length&&!d.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(d));}),T(this,"genTextAreaValueMutation",t=>{let r=this.attributeMap.get(t);r||(r={node:t,attributes:{},styleDiff:{},_unchangedStyles:{}},this.attributes.push(r),this.attributeMap.set(t,r));let i=Array.from(_.childNodes(t),n=>_.textContent(n)||"").join("");r.attributes.value=Tt({element:t,maskInputOptions:this.maskInputOptions,tagName:t.tagName,type:kt(t),value:i,maskInputFn:this.maskInputFn});}),T(this,"processMutation",t=>{if(!yn(t.target,this.mirror,this.slimDOMOptions))switch(t.type){case "characterData":{let r=_.textContent(t.target);!le(t.target,this.blockClass,this.blockSelector,false)&&r!==t.oldValue&&this.texts.push({value:Qs(t.target,this.maskTextClass,this.maskTextSelector,true)&&r?this.maskTextFn?this.maskTextFn(r,Co(t.target)):r.replace(/[\S]/g,"*"):r,node:t.target});break}case "attributes":{let r=t.target,i=t.attributeName,n=t.target.getAttribute(i);if(i==="value"){let l=kt(r);n=Tt({element:r,maskInputOptions:this.maskInputOptions,tagName:r.tagName,type:l,value:n,maskInputFn:this.maskInputFn});}if(le(t.target,this.blockClass,this.blockSelector,false)||n===t.oldValue)return;let o=this.attributeMap.get(t.target);if(r.tagName==="IFRAME"&&i==="src"&&!this.keepIframeSrcFn(n))if(!r.contentDocument)i="rr_src";else return;if(o||(o={node:t.target,attributes:{},styleDiff:{},_unchangedStyles:{}},this.attributes.push(o),this.attributeMap.set(t.target,o)),i==="type"&&r.tagName==="INPUT"&&(t.oldValue||"").toLowerCase()==="password"&&r.setAttribute("data-rr-is-password","true"),!Zs(r.tagName,i))if(o.attributes[i]=Ks(this.doc,Pe(r.tagName),Pe(i),n),i==="style"){if(!this.unattachedDoc)try{this.unattachedDoc=document.implementation.createHTMLDocument();}catch{this.unattachedDoc=this.doc;}let l=this.unattachedDoc.createElement("span");t.oldValue&&l.setAttribute("style",t.oldValue);for(let d of Array.from(r.style)){let a=r.style.getPropertyValue(d),h=r.style.getPropertyPriority(d);a!==l.style.getPropertyValue(d)||h!==l.style.getPropertyPriority(d)?h===""?o.styleDiff[d]=a:o.styleDiff[d]=[a,h]:o._unchangedStyles[d]=[a,h];}for(let d of Array.from(l.style))r.style.getPropertyValue(d)===""&&(o.styleDiff[d]=false);}else i==="open"&&r.tagName==="DIALOG"&&(r.matches("dialog:modal")?o.attributes.rr_open_mode="modal":o.attributes.rr_open_mode="non-modal");break}case "childList":{if(le(t.target,this.blockClass,this.blockSelector,true))return;if(t.target.tagName==="TEXTAREA"){this.genTextAreaValueMutation(t.target);return}t.addedNodes.forEach(r=>this.genAdds(r,t.target)),t.removedNodes.forEach(r=>{let i=this.mirror.getId(r),n=tt(t.target)?this.mirror.getId(_.host(t.target)):this.mirror.getId(t.target);le(t.target,this.blockClass,this.blockSelector,false)||yn(r,this.mirror,this.slimDOMOptions)||!Fu(r,this.mirror)||(this.addedSet.has(r)?(In(this.addedSet,r),this.droppedSet.add(r)):this.addedSet.has(t.target)&&i===-1||Eo(t.target,this.mirror)||(this.movedSet.has(r)&&this.movedMap[Ps(i,n)]?In(this.movedSet,r):(this.removes.push({parentId:n,id:i,isShadow:tt(t.target)&&rt(t.target)?true:void 0}),zu(r,this.removesSubTreeCache))),this.mapRemoves.push(r));});break}}}),T(this,"genAdds",(t,r)=>{if(!this.processedNodeManager.inOtherBuffer(t,this)&&!(this.addedSet.has(t)||this.movedSet.has(t))){if(this.mirror.hasNode(t)){if(yn(t,this.mirror,this.slimDOMOptions))return;this.movedSet.add(t);let i=null;r&&this.mirror.hasNode(r)&&(i=this.mirror.getId(r)),i&&i!==-1&&(this.movedMap[Ps(this.mirror.getId(t),i)]=true);}else this.addedSet.add(t),this.droppedSet.delete(t);le(t,this.blockClass,this.blockSelector,false)||(_.childNodes(t).forEach(i=>this.genAdds(i)),Cn(t)&&_.childNodes(_.shadowRoot(t)).forEach(i=>{this.processedNodeManager.add(i,this),this.genAdds(i,t);}));}});}init(t){["mutationCb","blockClass","blockSelector","maskTextClass","maskTextSelector","inlineStylesheet","maskInputOptions","maskTextFn","maskInputFn","keepIframeSrcFn","recordCanvas","inlineImages","slimDOMOptions","dataURLOptions","doc","mirror","iframeManager","stylesheetManager","shadowDomManager","canvasManager","processedNodeManager"].forEach(r=>{this[r]=t[r];});}freeze(){this.frozen=true,this.canvasManager.freeze();}unfreeze(){this.frozen=false,this.canvasManager.unfreeze(),this.emit();}isFrozen(){return this.frozen}lock(){this.locked=true,this.canvasManager.lock();}unlock(){this.locked=false,this.canvasManager.unlock(),this.emit();}reset(){this.shadowDomManager.reset(),this.canvasManager.reset();}};function In(e,t){e.delete(t),_.childNodes(t).forEach(r=>In(e,r));}function zu(e,t){let r=[e];for(;r.length;){let i=r.pop();t.has(i)||(t.add(i),_.childNodes(i).forEach(n=>r.push(n)));}}function _s(e,t,r){return e.size===0?false:$u(e,t)}function $u(e,t,r){let i=_.parentNode(t);return i?e.has(i):false}function Fs(e,t){return e.size===0?false:To(e,t)}function To(e,t){let r=_.parentNode(t);return r?e.has(r)?true:To(e,r):false}var nt;function Wu(e){nt=e;}function Hu(){nt=void 0;}var U=e=>nt?(...r)=>{try{return e(...r)}catch(i){if(nt&&nt(i)===true)return;throw i}}:e,Le=[];function ut(e){try{if("composedPath"in e){let t=e.composedPath();if(t.length)return t[0]}else if("path"in e&&e.path.length)return e.path[0]}catch{}return e&&e.target}function ko(e,t){let r=new Rn;Le.push(r),r.init(e);let[i,n]=vo(),o=new i(U(r.processMutations.bind(r)));return o.observe(t,{attributes:true,attributeOldValue:true,characterData:true,characterDataOldValue:true,childList:true,subtree:true}),[o,n]}function ju({mousemoveCb:e,sampling:t,doc:r,mirror:i}){if(t.mousemove===false)return ()=>{};let n=typeof t.mousemove=="number"?t.mousemove:50,o=typeof t.mousemoveCallback=="number"?t.mousemoveCallback:500,l=[],d,a=ot(U(f=>{let c=Date.now()-d;e(l.map(u=>(u.timeOffset-=c,u)),f),l=[],d=null;}),o),h=U(ot(U(f=>{let c=ut(f),{clientX:u,clientY:m}=Sn(f)?f.changedTouches[0]:f;d||(d=st()),l.push({x:u,y:m,id:i.getId(c),timeOffset:st()-d}),a(typeof DragEvent<"u"&&f instanceof DragEvent?F.Drag:f instanceof MouseEvent?F.MouseMove:F.TouchMove);}),n,{trailing:!1})),s=[ae("mousemove",h,r),ae("touchmove",h,r),ae("drag",h,r)];return U(()=>{s.forEach(f=>f());})}function Vu({mouseInteractionCb:e,doc:t,mirror:r,blockClass:i,blockSelector:n,sampling:o}){if(o.mouseInteraction===false)return ()=>{};let l=o.mouseInteraction===true||o.mouseInteraction===void 0?{}:o.mouseInteraction,d=[],a=null,h=s=>f=>{let c=ut(f);if(le(c,i,n,true))return;let u=null,m=s;if("pointerType"in f){switch(f.pointerType){case "mouse":u=Ne.Mouse;break;case "touch":u=Ne.Touch;break;case "pen":u=Ne.Pen;break}u===Ne.Touch?fe[s]===fe.MouseDown?m="TouchStart":fe[s]===fe.MouseUp&&(m="TouchEnd"):Ne.Pen;}else Sn(f)&&(u=Ne.Touch);u!==null?(a=u,(m.startsWith("Touch")&&u===Ne.Touch||m.startsWith("Mouse")&&u===Ne.Mouse)&&(u=null)):fe[s]===fe.Click&&(u=a,a=null);let p=Sn(f)?f.changedTouches[0]:f;if(!p)return;let g=r.getId(c),{clientX:S,clientY:y}=p;U(e)({type:fe[m],id:g,x:S,y,...u!==null&&{pointerType:u}});};return Object.keys(fe).filter(s=>Number.isNaN(Number(s))&&!s.endsWith("_Departed")&&l[s]!==false).forEach(s=>{let f=Pe(s),c=h(s);if(window.PointerEvent)switch(fe[s]){case fe.MouseDown:case fe.MouseUp:f=f.replace("mouse","pointer");break;case fe.TouchStart:case fe.TouchEnd:return}d.push(ae(f,c,t));}),U(()=>{d.forEach(s=>s());})}function Ao({scrollCb:e,doc:t,mirror:r,blockClass:i,blockSelector:n,sampling:o}){let l=U(ot(U(d=>{let a=ut(d);if(!a||le(a,i,n,!0))return;let h=r.getId(a);if(a===t&&t.defaultView){let s=wo(t.defaultView);e({id:h,x:s.left,y:s.top});}else e({id:h,x:a.scrollLeft,y:a.scrollTop});}),o.scroll||100));return ae("scroll",l,t)}function Gu({viewportResizeCb:e},{win:t}){let r=-1,i=-1,n=U(ot(U(()=>{let o=bo(),l=So();(r!==o||i!==l)&&(e({width:Number(l),height:Number(o)}),r=o,i=l);}),200));return ae("resize",n,t)}var Yu=["INPUT","TEXTAREA","SELECT"],Us=new WeakMap;function Xu({inputCb:e,doc:t,mirror:r,blockClass:i,blockSelector:n,ignoreClass:o,ignoreSelector:l,maskInputOptions:d,maskInputFn:a,sampling:h,userTriggeredOnInput:s}){function f(y){let b=ut(y),E=y.isTrusted,w=b&&b.tagName;if(b&&w==="OPTION"&&(b=_.parentElement(b)),!b||!w||Yu.indexOf(w)<0||le(b,i,n,true)||b.classList.contains(o)||l&&b.matches(l))return;let v=b.value,C=false,R=kt(b)||"";R==="radio"||R==="checkbox"?C=b.checked:(d[w.toLowerCase()]||d[R])&&(v=Tt({element:b,maskInputOptions:d,tagName:w,type:R,value:v,maskInputFn:a})),c(b,s?{text:v,isChecked:C,userTriggered:E}:{text:v,isChecked:C});let M=b.name;R==="radio"&&M&&C&&t.querySelectorAll(`input[type="radio"][name="${M}"]`).forEach(I=>{if(I!==b){let O=I.value;c(I,s?{text:O,isChecked:!C,userTriggered:false}:{text:O,isChecked:!C});}});}function c(y,b){let E=Us.get(y);if(!E||E.text!==b.text||E.isChecked!==b.isChecked){Us.set(y,b);let w=r.getId(y);U(e)({...b,id:w});}}let m=(h.input==="last"?["change"]:["input","change"]).map(y=>ae(y,U(f),t)),p=t.defaultView;if(!p)return ()=>{m.forEach(y=>y());};let g=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 g&&g.set&&m.push(...S.map(y=>Vt(y[0],y[1],{set(){U(f)({target:this,isTrusted:false});}},false,p))),U(()=>{m.forEach(y=>y());})}function Dt(e){let t=[];function r(i,n){if(xt("CSSGroupingRule")&&i.parentRule instanceof CSSGroupingRule||xt("CSSMediaRule")&&i.parentRule instanceof CSSMediaRule||xt("CSSSupportsRule")&&i.parentRule instanceof CSSSupportsRule||xt("CSSConditionRule")&&i.parentRule instanceof CSSConditionRule){let l=Array.from(i.parentRule.cssRules).indexOf(i);return n.unshift(l),r(i.parentRule,n)}else if(i.parentStyleSheet){let l=Array.from(i.parentStyleSheet.cssRules).indexOf(i);n.unshift(l);}return n}return r(e,t)}function Oe(e,t,r){let i,n;return e?(e.ownerNode?i=t.getId(e.ownerNode):n=r.getId(e),{styleId:n,id:i}):{}}function Ju({styleSheetRuleCb:e,mirror:t,stylesheetManager:r},{win:i}){if(!i.CSSStyleSheet||!i.CSSStyleSheet.prototype)return ()=>{};let n=i.CSSStyleSheet.prototype.insertRule;i.CSSStyleSheet.prototype.insertRule=new Proxy(n,{apply:U((s,f,c)=>{let[u,m]=c,{id:p,styleId:g}=Oe(f,t,r.styleMirror);return (p&&p!==-1||g&&g!==-1)&&e({id:p,styleId:g,adds:[{rule:u,index:m}]}),s.apply(f,c)})}),i.CSSStyleSheet.prototype.addRule=function(s,f,c=this.cssRules.length){let u=`${s} { ${f} }`;return i.CSSStyleSheet.prototype.insertRule.apply(this,[u,c])};let o=i.CSSStyleSheet.prototype.deleteRule;i.CSSStyleSheet.prototype.deleteRule=new Proxy(o,{apply:U((s,f,c)=>{let[u]=c,{id:m,styleId:p}=Oe(f,t,r.styleMirror);return (m&&m!==-1||p&&p!==-1)&&e({id:m,styleId:p,removes:[{index:u}]}),s.apply(f,c)})}),i.CSSStyleSheet.prototype.removeRule=function(s){return i.CSSStyleSheet.prototype.deleteRule.apply(this,[s])};let l;i.CSSStyleSheet.prototype.replace&&(l=i.CSSStyleSheet.prototype.replace,i.CSSStyleSheet.prototype.replace=new Proxy(l,{apply:U((s,f,c)=>{let[u]=c,{id:m,styleId:p}=Oe(f,t,r.styleMirror);return (m&&m!==-1||p&&p!==-1)&&e({id:m,styleId:p,replace:u}),s.apply(f,c)})}));let d;i.CSSStyleSheet.prototype.replaceSync&&(d=i.CSSStyleSheet.prototype.replaceSync,i.CSSStyleSheet.prototype.replaceSync=new Proxy(d,{apply:U((s,f,c)=>{let[u]=c,{id:m,styleId:p}=Oe(f,t,r.styleMirror);return (m&&m!==-1||p&&p!==-1)&&e({id:m,styleId:p,replaceSync:u}),s.apply(f,c)})}));let a={};Rt("CSSGroupingRule")?a.CSSGroupingRule=i.CSSGroupingRule:(Rt("CSSMediaRule")&&(a.CSSMediaRule=i.CSSMediaRule),Rt("CSSConditionRule")&&(a.CSSConditionRule=i.CSSConditionRule),Rt("CSSSupportsRule")&&(a.CSSSupportsRule=i.CSSSupportsRule));let h={};return Object.entries(a).forEach(([s,f])=>{h[s]={insertRule:f.prototype.insertRule,deleteRule:f.prototype.deleteRule},f.prototype.insertRule=new Proxy(h[s].insertRule,{apply:U((c,u,m)=>{let[p,g]=m,{id:S,styleId:y}=Oe(u.parentStyleSheet,t,r.styleMirror);return (S&&S!==-1||y&&y!==-1)&&e({id:S,styleId:y,adds:[{rule:p,index:[...Dt(u),g||0]}]}),c.apply(u,m)})}),f.prototype.deleteRule=new Proxy(h[s].deleteRule,{apply:U((c,u,m)=>{let[p]=m,{id:g,styleId:S}=Oe(u.parentStyleSheet,t,r.styleMirror);return (g&&g!==-1||S&&S!==-1)&&e({id:g,styleId:S,removes:[{index:[...Dt(u),p]}]}),c.apply(u,m)})});}),U(()=>{i.CSSStyleSheet.prototype.insertRule=n,i.CSSStyleSheet.prototype.deleteRule=o,l&&(i.CSSStyleSheet.prototype.replace=l),d&&(i.CSSStyleSheet.prototype.replaceSync=d),Object.entries(a).forEach(([s,f])=>{f.prototype.insertRule=h[s].insertRule,f.prototype.deleteRule=h[s].deleteRule;});})}function Oo({mirror:e,stylesheetManager:t},r){var i,n,o;let l=null;r.nodeName==="#document"?l=e.getId(r):l=e.getId(_.host(r));let d=r.nodeName==="#document"?(i=r.defaultView)==null?void 0:i.Document:(o=(n=r.ownerDocument)==null?void 0:n.defaultView)==null?void 0:o.ShadowRoot,a=d?.prototype?Object.getOwnPropertyDescriptor(d?.prototype,"adoptedStyleSheets"):void 0;return l===null||l===-1||!d||!a?()=>{}:(Object.defineProperty(r,"adoptedStyleSheets",{configurable:a.configurable,enumerable:a.enumerable,get(){var h;return (h=a.get)==null?void 0:h.call(this)},set(h){var s;let f=(s=a.set)==null?void 0:s.call(this,h);if(l!==null&&l!==-1)try{t.adoptStyleSheets(h,l);}catch{}return f}}),U(()=>{Object.defineProperty(r,"adoptedStyleSheets",{configurable:a.configurable,enumerable:a.enumerable,get:a.get,set:a.set});}))}function Ku({styleDeclarationCb:e,mirror:t,ignoreCSSAttributes:r,stylesheetManager:i},{win:n}){let o=n.CSSStyleDeclaration.prototype.setProperty;n.CSSStyleDeclaration.prototype.setProperty=new Proxy(o,{apply:U((d,a,h)=>{var s;let[f,c,u]=h;if(r.has(f))return o.apply(a,[f,c,u]);let{id:m,styleId:p}=Oe((s=a.parentRule)==null?void 0:s.parentStyleSheet,t,i.styleMirror);return (m&&m!==-1||p&&p!==-1)&&e({id:m,styleId:p,set:{property:f,value:c,priority:u},index:Dt(a.parentRule)}),d.apply(a,h)})});let l=n.CSSStyleDeclaration.prototype.removeProperty;return n.CSSStyleDeclaration.prototype.removeProperty=new Proxy(l,{apply:U((d,a,h)=>{var s;let[f]=h;if(r.has(f))return l.apply(a,[f]);let{id:c,styleId:u}=Oe((s=a.parentRule)==null?void 0:s.parentStyleSheet,t,i.styleMirror);return (c&&c!==-1||u&&u!==-1)&&e({id:c,styleId:u,remove:{property:f},index:Dt(a.parentRule)}),d.apply(a,h)})}),U(()=>{n.CSSStyleDeclaration.prototype.setProperty=o,n.CSSStyleDeclaration.prototype.removeProperty=l;})}function Zu({mediaInteractionCb:e,blockClass:t,blockSelector:r,mirror:i,sampling:n,doc:o}){let l=U(a=>ot(U(h=>{let s=ut(h);if(!s||le(s,t,r,!0))return;let{currentTime:f,volume:c,muted:u,playbackRate:m,loop:p}=s;e({type:a,id:i.getId(s),currentTime:f,volume:c,muted:u,playbackRate:m,loop:p});}),n.media||500)),d=[ae("play",l(He.Play),o),ae("pause",l(He.Pause),o),ae("seeked",l(He.Seeked),o),ae("volumechange",l(He.VolumeChange),o),ae("ratechange",l(He.RateChange),o)];return U(()=>{d.forEach(a=>a());})}function Qu({fontCb:e,doc:t}){let r=t.defaultView;if(!r)return ()=>{};let i=[],n=new WeakMap,o=r.FontFace;r.FontFace=function(a,h,s){let f=new o(a,h,s);return n.set(f,{family:a,buffer:typeof h!="string",descriptors:s,fontSource:typeof h=="string"?h:JSON.stringify(Array.from(new Uint8Array(h)))}),f};let l=Ue(t.fonts,"add",function(d){return function(a){return setTimeout(U(()=>{let h=n.get(a);h&&(e(h),n.delete(a));}),0),d.apply(this,[a])}});return i.push(()=>{r.FontFace=o;}),i.push(l),U(()=>{i.forEach(d=>d());})}function ec(e){let{doc:t,mirror:r,blockClass:i,blockSelector:n,selectionCb:o}=e,l=true,d=U(()=>{let a=t.getSelection();if(!a||l&&a?.isCollapsed)return;l=a.isCollapsed||!1;let h=[],s=a.rangeCount||0;for(let f=0;f<s;f++){let c=a.getRangeAt(f),{startContainer:u,startOffset:m,endContainer:p,endOffset:g}=c;le(u,i,n,!0)||le(p,i,n,!0)||h.push({start:r.getId(u),startOffset:m,end:r.getId(p),endOffset:g});}o({ranges:h});});return d(),ae("selectionchange",d)}function tc({doc:e,customElementCb:t}){let r=e.defaultView;return !r||!r.customElements?()=>{}:Ue(r.customElements,"define",function(n){return function(o,l,d){try{t({define:{name:o}});}catch{console.warn(`Custom element callback failed for ${o}`);}return n.apply(this,[o,l,d])}})}function rc(e,t){let{mutationCb:r,mousemoveCb:i,mouseInteractionCb:n,scrollCb:o,viewportResizeCb:l,inputCb:d,mediaInteractionCb:a,styleSheetRuleCb:h,styleDeclarationCb:s,canvasMutationCb:f,fontCb:c,selectionCb:u,customElementCb:m}=e;e.mutationCb=(...p)=>{t.mutation&&t.mutation(...p),r(...p);},e.mousemoveCb=(...p)=>{t.mousemove&&t.mousemove(...p),i(...p);},e.mouseInteractionCb=(...p)=>{t.mouseInteraction&&t.mouseInteraction(...p),n(...p);},e.scrollCb=(...p)=>{t.scroll&&t.scroll(...p),o(...p);},e.viewportResizeCb=(...p)=>{t.viewportResize&&t.viewportResize(...p),l(...p);},e.inputCb=(...p)=>{t.input&&t.input(...p),d(...p);},e.mediaInteractionCb=(...p)=>{t.mediaInteaction&&t.mediaInteaction(...p),a(...p);},e.styleSheetRuleCb=(...p)=>{t.styleSheetRule&&t.styleSheetRule(...p),h(...p);},e.styleDeclarationCb=(...p)=>{t.styleDeclaration&&t.styleDeclaration(...p),s(...p);},e.canvasMutationCb=(...p)=>{t.canvasMutation&&t.canvasMutation(...p),f(...p);},e.fontCb=(...p)=>{t.font&&t.font(...p),c(...p);},e.selectionCb=(...p)=>{t.selection&&t.selection(...p),u(...p);},e.customElementCb=(...p)=>{t.customElement&&t.customElement(...p),m(...p);};}function nc(e,t={}){let r=e.doc.defaultView;if(!r)return ()=>{};rc(e,t);let i,n=()=>{};e.recordDOM&&([i,n]=ko(e,e.doc));let o=ju(e),l=Vu(e),d=Ao(e),a=Gu(e,{win:r}),h=Xu(e),s=Zu(e),f=()=>{},c=()=>{},u=()=>{},m=()=>{};e.recordDOM&&(f=Ju(e,{win:r}),c=Oo(e,e.doc),u=Ku(e,{win:r}),e.collectFonts&&(m=Qu(e)));let p=ec(e),g=tc(e),S=[];for(let y of e.plugins)S.push(y.observer(y.callback,r,y.options));return U(()=>{Le.forEach(y=>y.reset()),i?.disconnect(),n(),o(),l(),d(),a(),h(),s(),f(),c(),u(),m(),p(),g(),S.forEach(y=>y());})}function xt(e){return typeof window[e]<"u"}function Rt(e){return !!(typeof window[e]<"u"&&window[e].prototype&&"insertRule"in window[e].prototype&&"deleteRule"in window[e].prototype)}var Lt=class{constructor(t){T(this,"iframeIdToRemoteIdMap",new WeakMap),T(this,"iframeRemoteIdToIdMap",new WeakMap),this.generateIdFn=t;}getId(t,r,i,n){let o=i||this.getIdToRemoteIdMap(t),l=n||this.getRemoteIdToIdMap(t),d=o.get(r);return d||(d=this.generateIdFn(),o.set(r,d),l.set(d,r)),d}getIds(t,r){let i=this.getIdToRemoteIdMap(t),n=this.getRemoteIdToIdMap(t);return r.map(o=>this.getId(t,o,i,n))}getRemoteId(t,r,i){let n=i||this.getRemoteIdToIdMap(t);if(typeof r!="number")return r;let o=n.get(r);return o||-1}getRemoteIds(t,r){let i=this.getRemoteIdToIdMap(t);return r.map(n=>this.getRemoteId(t,n,i))}reset(t){if(!t){this.iframeIdToRemoteIdMap=new WeakMap,this.iframeRemoteIdToIdMap=new WeakMap;return}this.iframeIdToRemoteIdMap.delete(t),this.iframeRemoteIdToIdMap.delete(t);}getIdToRemoteIdMap(t){let r=this.iframeIdToRemoteIdMap.get(t);return r||(r=new Map,this.iframeIdToRemoteIdMap.set(t,r)),r}getRemoteIdToIdMap(t){let r=this.iframeRemoteIdToIdMap.get(t);return r||(r=new Map,this.iframeRemoteIdToIdMap.set(t,r)),r}},Mn=class{constructor(t){T(this,"iframes",new WeakMap),T(this,"crossOriginIframeMap",new WeakMap),T(this,"crossOriginIframeMirror",new Lt(Js)),T(this,"crossOriginIframeStyleMirror"),T(this,"crossOriginIframeRootIdMap",new WeakMap),T(this,"mirror"),T(this,"mutationCb"),T(this,"wrappedEmit"),T(this,"loadListener"),T(this,"stylesheetManager"),T(this,"recordCrossOriginIframes"),this.mutationCb=t.mutationCb,this.wrappedEmit=t.wrappedEmit,this.stylesheetManager=t.stylesheetManager,this.recordCrossOriginIframes=t.recordCrossOriginIframes,this.crossOriginIframeStyleMirror=new Lt(this.stylesheetManager.styleMirror.generateId.bind(this.stylesheetManager.styleMirror)),this.mirror=t.mirror,this.recordCrossOriginIframes&&window.addEventListener("message",this.handleMessage.bind(this));}addIframe(t){this.iframes.set(t,true),t.contentWindow&&this.crossOriginIframeMap.set(t.contentWindow,t);}addLoadListener(t){this.loadListener=t;}attachIframe(t,r){var i,n;this.mutationCb({adds:[{parentId:this.mirror.getId(t),nextId:null,node:r}],removes:[],texts:[],attributes:[],isAttachIframe:true}),this.recordCrossOriginIframes&&((i=t.contentWindow)==null||i.addEventListener("message",this.handleMessage.bind(this))),(n=this.loadListener)==null||n.call(this,t),t.contentDocument&&t.contentDocument.adoptedStyleSheets&&t.contentDocument.adoptedStyleSheets.length>0&&this.stylesheetManager.adoptStyleSheets(t.contentDocument.adoptedStyleSheets,this.mirror.getId(t.contentDocument));}handleMessage(t){let r=t;if(r.data.type!=="rrweb"||r.origin!==r.data.origin||!t.source)return;let n=this.crossOriginIframeMap.get(t.source);if(!n)return;let o=this.transformCrossOriginEvent(n,r.data.event);o&&this.wrappedEmit(o,r.data.isCheckout);}transformCrossOriginEvent(t,r){var i;switch(r.type){case q.FullSnapshot:{this.crossOriginIframeMirror.reset(t),this.crossOriginIframeStyleMirror.reset(t),this.replaceIdOnNode(r.data.node,t);let n=r.data.node.id;return this.crossOriginIframeRootIdMap.set(t,n),this.patchRootIdOnNode(r.data.node,n),{timestamp:r.timestamp,type:q.IncrementalSnapshot,data:{source:F.Mutation,adds:[{parentId:this.mirror.getId(t),nextId:null,node:r.data.node}],removes:[],texts:[],attributes:[],isAttachIframe:true}}}case q.Meta:case q.Load:case q.DomContentLoaded:return false;case q.Plugin:return r;case q.Custom:return this.replaceIds(r.data.payload,t,["id","parentId","previousId","nextId"]),r;case q.IncrementalSnapshot:switch(r.data.source){case F.Mutation:return r.data.adds.forEach(n=>{this.replaceIds(n,t,["parentId","nextId","previousId"]),this.replaceIdOnNode(n.node,t);let o=this.crossOriginIframeRootIdMap.get(t);o&&this.patchRootIdOnNode(n.node,o);}),r.data.removes.forEach(n=>{this.replaceIds(n,t,["parentId","id"]);}),r.data.attributes.forEach(n=>{this.replaceIds(n,t,["id"]);}),r.data.texts.forEach(n=>{this.replaceIds(n,t,["id"]);}),r;case F.Drag:case F.TouchMove:case F.MouseMove:return r.data.positions.forEach(n=>{this.replaceIds(n,t,["id"]);}),r;case F.ViewportResize:return false;case F.MediaInteraction:case F.MouseInteraction:case F.Scroll:case F.CanvasMutation:case F.Input:return this.replaceIds(r.data,t,["id"]),r;case F.StyleSheetRule:case F.StyleDeclaration:return this.replaceIds(r.data,t,["id"]),this.replaceStyleIds(r.data,t,["styleId"]),r;case F.Font:return r;case F.Selection:return r.data.ranges.forEach(n=>{this.replaceIds(n,t,["start","end"]);}),r;case F.AdoptedStyleSheet:return this.replaceIds(r.data,t,["id"]),this.replaceStyleIds(r.data,t,["styleIds"]),(i=r.data.styles)==null||i.forEach(n=>{this.replaceStyleIds(n,t,["styleId"]);}),r}}return false}replace(t,r,i,n){for(let o of n)!Array.isArray(r[o])&&typeof r[o]!="number"||(Array.isArray(r[o])?r[o]=t.getIds(i,r[o]):r[o]=t.getId(i,r[o]));return r}replaceIds(t,r,i){return this.replace(this.crossOriginIframeMirror,t,r,i)}replaceStyleIds(t,r,i){return this.replace(this.crossOriginIframeStyleMirror,t,r,i)}replaceIdOnNode(t,r){this.replaceIds(t,r,["id","rootId"]),"childNodes"in t&&t.childNodes.forEach(i=>{this.replaceIdOnNode(i,r);});}patchRootIdOnNode(t,r){t.type!==No.Document&&!t.rootId&&(t.rootId=r),"childNodes"in t&&t.childNodes.forEach(i=>{this.patchRootIdOnNode(i,r);});}},Nn=class{constructor(t){T(this,"shadowDoms",new WeakSet),T(this,"mutationCb"),T(this,"scrollCb"),T(this,"bypassOptions"),T(this,"mirror"),T(this,"restoreHandlers",[]),this.mutationCb=t.mutationCb,this.scrollCb=t.scrollCb,this.bypassOptions=t.bypassOptions,this.mirror=t.mirror,this.init();}init(){this.reset(),this.patchAttachShadow(Element,document);}addShadowRoot(t,r){if(!rt(t)||this.shadowDoms.has(t))return;this.shadowDoms.add(t);let[i]=ko({...this.bypassOptions,doc:r,mutationCb:this.mutationCb,mirror:this.mirror,shadowDomManager:this},t);this.restoreHandlers.push(()=>i.disconnect()),this.restoreHandlers.push(Ao({...this.bypassOptions,scrollCb:this.scrollCb,doc:t,mirror:this.mirror})),setTimeout(()=>{t.adoptedStyleSheets&&t.adoptedStyleSheets.length>0&&this.bypassOptions.stylesheetManager.adoptStyleSheets(t.adoptedStyleSheets,this.mirror.getId(_.host(t))),this.restoreHandlers.push(Oo({mirror:this.mirror,stylesheetManager:this.bypassOptions.stylesheetManager},t));},0);}observeAttachShadow(t){!t.contentWindow||!t.contentDocument||this.patchAttachShadow(t.contentWindow.Element,t.contentDocument);}patchAttachShadow(t,r){let i=this;this.restoreHandlers.push(Ue(t.prototype,"attachShadow",function(n){return function(o){let l=n.call(this,o),d=_.shadowRoot(this);return d&&Mo(this)&&i.addShadowRoot(d,r),l}}));}reset(){this.restoreHandlers.forEach(t=>{try{t();}catch{}}),this.restoreHandlers=[],this.shadowDoms=new WeakSet;}},Ge="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",ic=typeof Uint8Array>"u"?[]:new Uint8Array(256);for(et=0;et<Ge.length;et++)ic[Ge.charCodeAt(et)]=et;var et,sc=function(e){var t=new Uint8Array(e),r,i=t.length,n="";for(r=0;r<i;r+=3)n+=Ge[t[r]>>2],n+=Ge[(t[r]&3)<<4|t[r+1]>>4],n+=Ge[(t[r+1]&15)<<2|t[r+2]>>6],n+=Ge[t[r+2]&63];return i%3===2?n=n.substring(0,n.length-1)+"=":i%3===1&&(n=n.substring(0,n.length-2)+"=="),n};var Bs=new Map;function oc(e,t){let r=Bs.get(e);return r||(r=new Map,Bs.set(e,r)),r.has(t)||r.set(t,[]),r.get(t)}var Do=(e,t,r)=>{if(!e||!(Po(e,t)||typeof e=="object"))return;let i=e.constructor.name,n=oc(r,i),o=n.indexOf(e);return o===-1&&(o=n.length,n.push(e)),o};function It(e,t,r){if(e instanceof Array)return e.map(i=>It(i,t,r));if(e===null)return e;if(e instanceof Float32Array||e instanceof Float64Array||e instanceof Int32Array||e instanceof Uint32Array||e instanceof Uint8Array||e instanceof Uint16Array||e instanceof Int16Array||e instanceof Int8Array||e instanceof Uint8ClampedArray)return {rr_type:e.constructor.name,args:[Object.values(e)]};if(e instanceof ArrayBuffer){let i=e.constructor.name,n=sc(e);return {rr_type:i,base64:n}}else {if(e instanceof DataView)return {rr_type:e.constructor.name,args:[It(e.buffer,t,r),e.byteOffset,e.byteLength]};if(e instanceof HTMLImageElement){let i=e.constructor.name,{src:n}=e;return {rr_type:i,src:n}}else if(e instanceof HTMLCanvasElement){let i="HTMLImageElement",n=e.toDataURL();return {rr_type:i,src:n}}else {if(e instanceof ImageData)return {rr_type:e.constructor.name,args:[It(e.data,t,r),e.width,e.height]};if(Po(e,t)||typeof e=="object"){let i=e.constructor.name,n=Do(e,t,r);return {rr_type:i,index:n}}}}return e}var Lo=(e,t,r)=>e.map(i=>It(i,t,r)),Po=(e,t)=>!!["WebGLActiveInfo","WebGLBuffer","WebGLFramebuffer","WebGLProgram","WebGLRenderbuffer","WebGLShader","WebGLShaderPrecisionFormat","WebGLTexture","WebGLUniformLocation","WebGLVertexArrayObject","WebGLVertexArrayObjectOES"].filter(n=>typeof t[n]=="function").find(n=>e instanceof t[n]);function ac(e,t,r,i){let n=[],o=Object.getOwnPropertyNames(t.CanvasRenderingContext2D.prototype);for(let l of o)try{if(typeof t.CanvasRenderingContext2D.prototype[l]!="function")continue;let d=Ue(t.CanvasRenderingContext2D.prototype,l,function(a){return function(...h){return le(this.canvas,r,i,!0)||setTimeout(()=>{let s=Lo(h,t,this);e(this.canvas,{type:Ye["2D"],property:l,args:s});},0),a.apply(this,h)}});n.push(d);}catch{let d=Vt(t.CanvasRenderingContext2D.prototype,l,{set(a){e(this.canvas,{type:Ye["2D"],property:l,args:[a],setter:true});}});n.push(d);}return ()=>{n.forEach(l=>l());}}function lc(e){return e==="experimental-webgl"?"webgl":e}function qs(e,t,r,i){let n=[];try{let o=Ue(e.HTMLCanvasElement.prototype,"getContext",function(l){return function(d,...a){if(!le(this,t,r,!0)){let h=lc(d);if("__context"in this||(this.__context=h),i&&["webgl","webgl2"].includes(h))if(a[0]&&typeof a[0]=="object"){let s=a[0];s.preserveDrawingBuffer||(s.preserveDrawingBuffer=!0);}else a.splice(0,1,{preserveDrawingBuffer:!0});}return l.apply(this,[d,...a])}});n.push(o);}catch{console.error("failed to patch HTMLCanvasElement.prototype.getContext");}return ()=>{n.forEach(o=>o());}}function zs(e,t,r,i,n,o){let l=[],d=Object.getOwnPropertyNames(e);for(let a of d)if(!["isContextLost","canvas","drawingBufferWidth","drawingBufferHeight"].includes(a))try{if(typeof e[a]!="function")continue;let h=Ue(e,a,function(s){return function(...f){let c=s.apply(this,f);if(Do(c,o,this),"tagName"in this.canvas&&!le(this.canvas,i,n,!0)){let u=Lo(f,o,this),m={type:t,property:a,args:u};r(this.canvas,m);}return c}});l.push(h);}catch{let h=Vt(e,a,{set(s){r(this.canvas,{type:t,property:a,args:[s],setter:true});}});l.push(h);}return l}function uc(e,t,r,i){let n=[];return typeof t.WebGLRenderingContext<"u"&&n.push(...zs(t.WebGLRenderingContext.prototype,Ye.WebGL,e,r,i,t)),typeof t.WebGL2RenderingContext<"u"&&n.push(...zs(t.WebGL2RenderingContext.prototype,Ye.WebGL2,e,r,i,t)),()=>{n.forEach(o=>o());}}var _o=`(function() {
54
54
  "use strict";
55
55
  var chars = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/";
56
56
  var lookup = typeof Uint8Array === "undefined" ? [] : new Uint8Array(256);
@@ -125,8 +125,8 @@ or you can use record.mirror to access the mirror instance during recording.`,Os
125
125
  };
126
126
  })();
127
127
  //# sourceMappingURL=image-bitmap-data-url-worker-IJpC7g_b.js.map
128
- `,zs=typeof self<"u"&&self.Blob&&new Blob([Po],{type:"text/javascript;charset=utf-8"});function uc(e){let t;try{if(t=zs&&(self.URL||self.webkitURL).createObjectURL(zs),!t)throw "";let r=new Worker(t,{name:e?.name});return r.addEventListener("error",()=>{(self.URL||self.webkitURL).revokeObjectURL(t);}),r}catch{return new Worker("data:text/javascript;charset=utf-8,"+encodeURIComponent(Po),{name:e?.name})}finally{t&&(self.URL||self.webkitURL).revokeObjectURL(t);}}var Tn=class{constructor(t){T(this,"pendingCanvasMutations",new Map),T(this,"rafStamps",{latestId:0,invokeId:null}),T(this,"mirror"),T(this,"mutationCb"),T(this,"resetObservers"),T(this,"frozen",false),T(this,"locked",false),T(this,"processMutation",(a,h)=>{(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(h);});let{sampling:r="all",win:i,blockClass:n,blockSelector:o,recordCanvas:l,dataURLOptions:p}=t;this.mutationCb=t.mutationCb,this.mirror=t.mirror,l&&r==="all"&&this.initCanvasMutationObserver(i,n,o),l&&typeof r=="number"&&this.initCanvasFPSObserver(r,i,n,o,{dataURLOptions:p});}reset(){this.pendingCanvasMutations.clear(),this.resetObservers&&this.resetObservers();}freeze(){this.frozen=true;}unfreeze(){this.frozen=false;}lock(){this.locked=true;}unlock(){this.locked=false;}initCanvasFPSObserver(t,r,i,n,o){let l=Bs(r,i,n,true),p=new Map,a=new uc;a.onmessage=m=>{let{id:d}=m.data;if(p.set(d,false),!("base64"in m.data))return;let{base64:g,type:S,width:y,height:b}=m.data;this.mutationCb({id:d,type:Ye["2D"],commands:[{property:"clearRect",args:[0,0,y,b]},{property:"drawImage",args:[{rr_type:"ImageBitmap",args:[{rr_type:"Blob",data:[{rr_type:"ArrayBuffer",base64:g}],type:S}]},0,0]}]});};let h=1e3/t,s=0,f,c=()=>{let m=[];return r.document.querySelectorAll("canvas").forEach(d=>{le(d,i,n,true)||m.push(d);}),m},u=m=>{if(s&&m-s<h){f=requestAnimationFrame(u);return}s=m,c().forEach(async d=>{var g;let S=this.mirror.getId(d);if(p.get(S)||d.width===0||d.height===0)return;if(p.set(S,true),["webgl","webgl2"].includes(d.__context)){let b=d.getContext(d.__context);((g=b?.getContextAttributes())==null?void 0:g.preserveDrawingBuffer)===false&&b.clear(b.COLOR_BUFFER_BIT);}let y=await createImageBitmap(d);a.postMessage({id:S,bitmap:y,width:d.width,height:d.height,dataURLOptions:o.dataURLOptions},[y]);}),f=requestAnimationFrame(u);};f=requestAnimationFrame(u),this.resetObservers=()=>{l(),cancelAnimationFrame(f);};}initCanvasMutationObserver(t,r,i){this.startRAFTimestamping(),this.startPendingCanvasMutationFlusher();let n=Bs(t,r,i,false),o=oc(this.processMutation.bind(this),t,r,i),l=lc(this.processMutation.bind(this),t,r,i);this.resetObservers=()=>{n(),o(),l();};}startPendingCanvasMutationFlusher(){requestAnimationFrame(()=>this.flushPendingCanvasMutations());}startRAFTimestamping(){let t=r=>{this.rafStamps.latestId=r,requestAnimationFrame(t);};requestAnimationFrame(t);}flushPendingCanvasMutations(){this.pendingCanvasMutations.forEach((t,r)=>{let i=this.mirror.getId(r);this.flushPendingCanvasMutationFor(r,i);}),requestAnimationFrame(()=>this.flushPendingCanvasMutations());}flushPendingCanvasMutationFor(t,r){if(this.frozen||this.locked)return;let i=this.pendingCanvasMutations.get(t);if(!i||r===-1)return;let n=i.map(l=>{let{type:p,...a}=l;return a}),{type:o}=i[0];this.mutationCb({id:r,type:o,commands:n}),this.pendingCanvasMutations.delete(t);}},kn=class{constructor(t){T(this,"trackedLinkElements",new WeakSet),T(this,"mutationCb"),T(this,"adoptedStyleSheetCb"),T(this,"styleMirror",new En),this.mutationCb=t.mutationCb,this.adoptedStyleSheetCb=t.adoptedStyleSheetCb;}attachLinkElement(t,r){"_cssText"in r.attributes&&this.mutationCb({adds:[],removes:[],texts:[],attributes:[{id:r.id,attributes:r.attributes}]}),this.trackLinkElement(t);}trackLinkElement(t){this.trackedLinkElements.has(t)||(this.trackedLinkElements.add(t),this.trackStylesheetInLinkElement(t));}adoptStyleSheets(t,r){if(t.length===0)return;let i={id:r,styleIds:[]},n=[];for(let o of t){let l;this.styleMirror.has(o)?l=this.styleMirror.getId(o):(l=this.styleMirror.add(o),n.push({styleId:l,rules:Array.from(o.rules||CSSRule,(p,a)=>({rule:Gs(p,o.href),index:a}))})),i.styleIds.push(l);}n.length>0&&(i.styles=n),this.adoptedStyleSheetCb(i);}reset(){this.styleMirror.reset(),this.trackedLinkElements=new WeakSet;}trackStylesheetInLinkElement(t){}},An=class{constructor(){T(this,"nodeMap",new WeakMap),T(this,"active",false);}inOtherBuffer(t,r){let i=this.nodeMap.get(t);return i&&Array.from(i).some(n=>n!==r)}add(t,r){this.active||(this.active=true,requestAnimationFrame(()=>{this.nodeMap=new WeakMap,this.active=false;})),this.nodeMap.set(t,(this.nodeMap.get(t)||new Set).add(r));}destroy(){}},te,It,vn,Pt=false;try{if(Array.from([1],e=>e*2)[0]!==2){let e=document.createElement("iframe");document.body.appendChild(e),Array.from=((wi=e.contentWindow)==null?void 0:wi.Array.from)||Array.from,document.body.removeChild(e);}}catch(e){console.debug("Unable to override Array.from",e);}var Se=El();function xe(e={}){let{emit:t,checkoutEveryNms:r,checkoutEveryNth:i,blockClass:n="rr-block",blockSelector:o=null,ignoreClass:l="rr-ignore",ignoreSelector:p=null,maskTextClass:a="rr-mask",maskTextSelector:h=null,inlineStylesheet:s=true,maskAllInputs:f,maskInputOptions:c,slimDOMOptions:u,maskInputFn:m,maskTextFn:d,hooks:g,packFn:S,sampling:y={},dataURLOptions:b={},mousemoveWait:E,recordDOM:w=true,recordCanvas:v=false,recordCrossOriginIframes:C=false,recordAfter:R=e.recordAfter==="DOMContentLoaded"?e.recordAfter:"load",userTriggeredOnInput:I=false,collectFonts:M=false,inlineImages:O=false,plugins:k,keepIframeSrcFn:x=()=>false,ignoreCSSAttributes:Q=new Set([]),errorHandler:Y}=e;$u(Y);let L=C?window.parent===window:true,A=false;if(!L)try{window.parent.document&&(A=!1);}catch{A=true;}if(L&&!t)throw new Error("emit function is required");if(!L&&!A)return ()=>{};E!==void 0&&y.mousemove===void 0&&(y.mousemove=E),Se.reset();let B=f===true?{color:true,date:true,"datetime-local":true,email:true,month:true,number:true,range:true,search:true,tel:true,text:true,time:true,url:true,week:true,textarea:true,select:true,password:true}:c!==void 0?c:{password:true},X=Qs(u);Fu();let J,P=0,ce=D=>{for(let ee of k||[])ee.eventProcessor&&(D=ee.eventProcessor(D));return S&&!A&&(D=S(D)),D};te=(D,ee)=>{var z;let V=D;if(V.timestamp=st(),(z=Le[0])!=null&&z.isFrozen()&&V.type!==q.FullSnapshot&&!(V.type===q.IncrementalSnapshot&&V.data.source===F.Mutation)&&Le.forEach(he=>he.unfreeze()),L)t?.(ce(V),ee);else if(A){let he={type:"rrweb",event:ce(V),origin:window.location.origin,isCheckout:ee};window.parent.postMessage(he,"*");}if(V.type===q.FullSnapshot)J=V,P=0;else if(V.type===q.IncrementalSnapshot){if(V.data.source===F.Mutation&&V.data.isAttachIframe)return;P++;let he=i&&P>=i,j=r&&V.timestamp-J.timestamp>r;(he||j)&&It(true);}};let N=D=>{te({type:q.IncrementalSnapshot,data:{source:F.Mutation,...D}});},re=D=>te({type:q.IncrementalSnapshot,data:{source:F.Scroll,...D}}),H=D=>te({type:q.IncrementalSnapshot,data:{source:F.CanvasMutation,...D}}),me=D=>te({type:q.IncrementalSnapshot,data:{source:F.AdoptedStyleSheet,...D}}),ie=new kn({mutationCb:N,adoptedStyleSheetCb:me}),oe=new In({mirror:Se,mutationCb:N,stylesheetManager:ie,recordCrossOriginIframes:C,wrappedEmit:te});for(let D of k||[])D.getMirror&&D.getMirror({nodeMirror:Se,crossOriginIframeMirror:oe.crossOriginIframeMirror,crossOriginIframeStyleMirror:oe.crossOriginIframeStyleMirror});let Re=new An;vn=new Tn({recordCanvas:v,mutationCb:H,win:window,blockClass:n,blockSelector:o,mirror:Se,sampling:y.canvas,dataURLOptions:b});let we=new Nn({mutationCb:N,scrollCb:re,bypassOptions:{blockClass:n,blockSelector:o,maskTextClass:a,maskTextSelector:h,inlineStylesheet:s,maskInputOptions:B,dataURLOptions:b,maskTextFn:d,maskInputFn:m,recordCanvas:v,inlineImages:O,sampling:y,slimDOMOptions:X,iframeManager:oe,stylesheetManager:ie,canvasManager:vn,keepIframeSrcFn:x,processedNodeManager:Re},mirror:Se});It=(D=false)=>{if(!w)return;te({type:q.Meta,data:{href:window.location.href,width:bo(),height:wo()}},D),ie.reset(),we.init(),Le.forEach(z=>z.lock());let ee=Gl(document,{mirror:Se,blockClass:n,blockSelector:o,maskTextClass:a,maskTextSelector:h,inlineStylesheet:s,maskAllInputs:B,maskTextFn:d,maskInputFn:m,slimDOM:X,dataURLOptions:b,recordCanvas:v,inlineImages:O,onSerialize:z=>{Eo(z,Se)&&oe.addIframe(z),xo(z,Se)&&ie.trackLinkElement(z),Cn(z)&&we.addShadowRoot(_.shadowRoot(z),document);},onIframeLoad:(z,V)=>{oe.attachIframe(z,V),we.observeAttachShadow(z);},onStylesheetLoad:(z,V)=>{ie.attachLinkElement(z,V);},keepIframeSrcFn:x});if(!ee)return console.warn("Failed to snapshot the document");te({type:q.FullSnapshot,data:{node:ee,initialOffset:vo(window)}},D),Le.forEach(z=>z.unlock()),document.adoptedStyleSheets&&document.adoptedStyleSheets.length>0&&ie.adoptStyleSheets(document.adoptedStyleSheets,Se.getId(document));};try{let D=[],ee=V=>{var he;return U(rc)({mutationCb:N,mousemoveCb:(j,Qt)=>te({type:q.IncrementalSnapshot,data:{source:Qt,positions:j}}),mouseInteractionCb:j=>te({type:q.IncrementalSnapshot,data:{source:F.MouseInteraction,...j}}),scrollCb:re,viewportResizeCb:j=>te({type:q.IncrementalSnapshot,data:{source:F.ViewportResize,...j}}),inputCb:j=>te({type:q.IncrementalSnapshot,data:{source:F.Input,...j}}),mediaInteractionCb:j=>te({type:q.IncrementalSnapshot,data:{source:F.MediaInteraction,...j}}),styleSheetRuleCb:j=>te({type:q.IncrementalSnapshot,data:{source:F.StyleSheetRule,...j}}),styleDeclarationCb:j=>te({type:q.IncrementalSnapshot,data:{source:F.StyleDeclaration,...j}}),canvasMutationCb:H,fontCb:j=>te({type:q.IncrementalSnapshot,data:{source:F.Font,...j}}),selectionCb:j=>{te({type:q.IncrementalSnapshot,data:{source:F.Selection,...j}});},customElementCb:j=>{te({type:q.IncrementalSnapshot,data:{source:F.CustomElement,...j}});},blockClass:n,ignoreClass:l,ignoreSelector:p,maskTextClass:a,maskTextSelector:h,maskInputOptions:B,inlineStylesheet:s,sampling:y,recordDOM:w,recordCanvas:v,inlineImages:O,userTriggeredOnInput:I,collectFonts:M,doc:V,maskInputFn:m,maskTextFn:d,keepIframeSrcFn:x,blockSelector:o,slimDOMOptions:X,dataURLOptions:b,mirror:Se,iframeManager:oe,stylesheetManager:ie,shadowDomManager:we,processedNodeManager:Re,canvasManager:vn,ignoreCSSAttributes:Q,plugins:((he=k?.filter(j=>j.observer))==null?void 0:he.map(j=>({observer:j.observer,options:j.options,callback:Qt=>te({type:q.Plugin,data:{plugin:j.name,payload:Qt}})})))||[]},g)};oe.addLoadListener(V=>{try{D.push(ee(V.contentDocument));}catch(he){console.warn(he);}});let z=()=>{It(),D.push(ee(document)),Pt=!0;};return ["interactive","complete"].includes(document.readyState)?z():(D.push(ae("DOMContentLoaded",()=>{te({type:q.DomContentLoaded,data:{}}),R==="DOMContentLoaded"&&z();})),D.push(ae("load",()=>{te({type:q.Load,data:{}}),R==="load"&&z();},window))),()=>{D.forEach(V=>{try{V();}catch(he){String(he).toLowerCase().includes("cross-origin")||console.warn(he);}}),Re.destroy(),Pt=!1,Wu();}}catch(D){console.warn(D);}}xe.addCustomEvent=(e,t)=>{if(!Pt)throw new Error("please add custom event after start recording");te({type:q.Custom,data:{tag:e,payload:t}});};xe.freezePage=()=>{Le.forEach(e=>e.freeze());};xe.takeFullSnapshot=e=>{if(!Pt)throw new Error("please take full snapshot after start recording");It(e);};xe.mirror=Se;var $s;(function(e){e[e.NotStarted=0]="NotStarted",e[e.Running=1]="Running",e[e.Stopped=2]="Stopped";})($s||($s={}));var{addCustomEvent:mf}=xe,{freezePage:gf}=xe,{takeFullSnapshot:yf}=xe;function $(){return typeof crypto<"u"&&"randomUUID"in crypto?crypto.randomUUID():"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,e=>{let t=Math.random()*16|0;return (e==="x"?t:t&3|8).toString(16)})}var ct=class{constructor(t,r){let i=Date.now();this.startedAt=t??i,this.perfStart=typeof performance<"u"?performance.now():0,this.baseT=Math.max(0,i-this.startedAt,r??0);}now(){let t=typeof performance<"u"?performance.now():Date.now()-this.startedAt;return Math.max(0,this.baseT+Math.round(t-this.perfStart))}wall(){return Date.now()}fromPerf(t){return Math.max(0,this.baseT+Math.round(t-this.perfStart))}};async function _o(e){if(typeof crypto<"u"&&crypto.subtle){let r=await crypto.subtle.digest("SHA-256",new TextEncoder().encode(e));return Array.from(new Uint8Array(r)).map(i=>i.toString(16).padStart(2,"0")).join("")}let t=0;for(let r=0;r<e.length;r++)t=Math.imul(31,t)+e.charCodeAt(r)|0;return (t>>>0).toString(16)}function Fo(){let e=navigator.userAgent,t={w:window.innerWidth,h:window.innerHeight},r,i;try{r=Intl.DateTimeFormat().resolvedOptions().timeZone||void 0,i=-new Date().getTimezoneOffset();}catch{}let n="desktop";/iPad|Tablet/i.test(e)?n="tablet":/Mobi|Android|iPhone/i.test(e)&&(n="mobile");let o;/Windows/i.test(e)?o="Windows":/Mac OS X|Macintosh/i.test(e)?o="macOS":/Android/i.test(e)?o="Android":/iPhone|iPad|iOS/i.test(e)?o="iOS":/Linux/i.test(e)&&(o="Linux");let l;return /Edg\//.test(e)?l="Edge":/Chrome\//.test(e)?l="Chrome":/Firefox\//.test(e)?l="Firefox":/Safari\//.test(e)&&(l="Safari"),{type:n,os:o,browser:l,viewport:t,tz:r,tzOffset:i}}function Xn(){let e=navigator;return e.globalPrivacyControl===true||e.doNotTrack==="1"||window.doNotTrack==="1"}var cc=3;function Uo(e){let t=xe({emit(r){let i=e.clock.fromPerf(fc());r.timestamp=e.clock.startedAt+i;let n={id:$(),sessionId:e.sessionId,type:"dom",t:i,ts:e.clock.wall(),data:r};e.emit(n),r.type===cc&&e.markActivity();},maskAllInputs:e.config.maskAllInputs,maskInputOptions:{password:true},maskTextSelector:e.config.maskTextSelector,blockSelector:e.config.blockSelector,recordCanvas:e.config.recordCanvas,checkoutEveryNms:3e4,sampling:{mousemove:50,scroll:150,input:"last"}});return ()=>{try{t?.();}catch{}}}function Bo(){try{xe.takeFullSnapshot(!0);}catch{}}function fc(){return typeof performance<"u"?performance.now():Date.now()}var hc=8*1024,dc=2e3;function pc(e){return new Blob([e]).size}function qo(e,t){if(pc(e)<=t)return {value:e,truncated:false};let r=Math.max(16,Math.floor(t*.95));return {value:e.slice(0,r),truncated:true}}function zo(e,t=hc){if(e===null)return {kind:"primitive",value:null};let r=typeof e;if(r==="number"||r==="boolean")return {kind:"primitive",value:e};if(r==="string"){let i=e,n=i.length>t*2?i.slice(0,t*2):i,o=ge(n),{value:l,truncated:p}=qo(o,t);return {kind:"string",value:l,truncated:p||n!==i}}if(e instanceof Error)return {kind:"error",name:e.name,message:ge(e.message),stack:e.stack?ge(e.stack):void 0};if(e instanceof Element)return {kind:"dom",selector:Be(e)};if(r==="object"||r==="function"||r==="symbol"||r==="bigint"){let i={nodes:dc,bytes:t*2,exhausted:false},n=Jn(e,i),o,l=i.exhausted;try{let p=JSON.stringify(n,mc()),a=qo(p??"undefined",t);o=a.value,l=l||a.truncated;}catch{o=void 0;}return {kind:"object",preview:gc(e),json:o,truncated:l}}return {kind:"primitive",value:String(e)}}function Jn(e,t,r=0){if(t.exhausted)return "\xABtruncated\xBB";if(r>6)return "\xABdepth\xBB";if(--t.nodes<=0&&(t.exhausted=true),typeof e=="string"){let n=e.length>t.bytes?e.slice(0,Math.max(0,t.bytes)):e;n!==e&&(t.exhausted=true);let o=ge(n);return (t.bytes-=o.length+2)<=0&&(t.exhausted=true),o}if(e===null||typeof e!="object")return e;if(Array.isArray(e)){let n=[];for(let o of e){if(t.exhausted){n.push("\xABtruncated\xBB");break}n.push(Jn(o,t,r+1));}return n}let i={};for(let n of Object.keys(e)){if(t.exhausted){i["\u2026"]="\xABtruncated\xBB";break}(t.bytes-=n.length+4)<=0&&(t.exhausted=true),i[n]=Ze(n)?"\xABredacted\xBB":Jn(e[n],t,r+1);}return i}function mc(){let e=new WeakSet;return (t,r)=>{if(typeof r=="bigint")return `${r.toString()}n`;if(typeof r=="function")return `\u0192 ${r.name||"anonymous"}`;if(typeof r=="object"&&r!==null){if(e.has(r))return "\xABcircular\xBB";e.add(r);}return r}}function gc(e){if(Array.isArray(e))return `Array(${e.length})`;if(e&&typeof e=="object"){let t=Object.keys(e);return `{ ${t.slice(0,4).join(", ")}${t.length>4?", \u2026":""} }`}return String(e)}function Be(e){let t=[],r=e,i=0;for(;r&&r.nodeType===1&&i<5;){let n=r.tagName.toLowerCase();if(r.id){n+=`#${r.id}`,t.unshift(n);break}let o=(r.getAttribute("class")||"").trim().split(/\s+/).filter(Boolean)[0];o&&(n+=`.${o}`),t.unshift(n),r=r.parentElement,i++;}return t.join(" > ")}function Gt(e){if(!e)return;let t=e.split(`
129
- `).map(r=>r.trim());for(let r of t){let i=r.match(/\((https?:\/\/[^)]+):(\d+):(\d+)\)/)||r.match(/at (https?:\/\/\S+):(\d+):(\d+)/)||r.match(/(https?:\/\/\S+):(\d+):(\d+)/);if(i)return {url:i[1],line:Number(i[2]),col:Number(i[3])}}}var $o=["log","info","warn","error","debug"],yc=100;function Wo(e){let t={},r=e.clock.now(),i=0,n=0;function o(){let p=e.clock.now();return p-r>=1e3&&(n>0&&(l("warn",[{kind:"string",value:`Obsrviq: suppressed ${n} console messages (flood cap)`}]),n=0),r=p,i=0),i>=yc?(n++,true):(i++,false)}function l(p,a,h){let s=Gt(h),f={id:$(),sessionId:e.sessionId,type:"console",t:e.clock.now(),ts:e.clock.wall(),level:p,args:a,stack:p==="error"?h:void 0,source:s};e.emit(f);}for(let p of $o){let a=console[p];t[p]=a,console[p]=(...h)=>{try{a.apply(console,h);}catch{}try{if(o())return;let s=h.map(c=>zo(c,e.config.maxArgBytes)),f;p==="error"&&(f=h.find(u=>u instanceof Error)?.stack??new Error().stack),l(p,s,f);}catch{}};}return ()=>{for(let p of $o)t[p]&&(console[p]=t[p]);}}function Ho(e,t){return {id:$(),sessionId:e.sessionId,type:"console",t:t.t,ts:t.ts,level:"error",args:[{kind:"error",name:t.name,message:t.message,stack:t.stack}],stack:t.stack,source:t.source}}function Yt(e,t){let r=t,i=Date.now();return {take(){let n=Date.now();return r=Math.min(t,r+(n-i)/1e3*e),i=n,r<1?false:(r-=1,true)}}}function jo(e){let t=new Uint8Array(e);if(typeof crypto<"u"&&typeof crypto.getRandomValues=="function")crypto.getRandomValues(t);else for(let i=0;i<e;i++)t[i]=Math.random()*256|0;let r="";for(let i=0;i<e;i++)r+=t[i].toString(16).padStart(2,"0");return r}function Kn(){let e=jo(16),t=jo(8);return {traceId:e,spanId:t,header:`00-${e}-${t}-01`}}function Zn(e,t){if(!t.tracePropagation)return false;let r;try{r=new URL(e,typeof location<"u"?location.href:void 0);}catch{return false}return r.protocol!=="http:"&&r.protocol!=="https:"?false:typeof location<"u"&&r.origin===location.origin?true:vc(r.hostname,t.traceHosts)}function vc(e,t){let r=e.toLowerCase();for(let i of t){let n=String(i).trim().toLowerCase();if(n){if(n.includes("://"))try{n=new URL(n).hostname;}catch{}if(n=n.replace(/^\*?\./,""),r===n||r.endsWith("."+n))return true}}return false}function Vo(e,t,r){let i=!!t&&"headers"in t&&t.headers!=null;if(e instanceof Request&&!i){let o=new Headers(e.headers);return o.has("traceparent")||o.set("traceparent",r),{input:new Request(e,{headers:o}),init:t}}let n=new Headers(t?.headers??void 0);return n.has("traceparent")||n.set("traceparent",r),{input:e,init:{...t||{},headers:n}}}var ht=4*1024,wc=50,bc=100,Yo=new Set(["content-type","content-length","accept","accept-encoding","cache-control","etag","last-modified","content-encoding","x-request-id","x-correlation-id","traceparent","server","vary"]);function Jt(e){try{let t=new URL(e,location.href);return t.search&&(t.search="?\u2026"),t.toString()}catch{return e.split("?")[0]??e}}function Xo(e){if(e===0)return "network";if(e>=500)return "http_5xx";if(e>=400)return "http_4xx"}function Qn(e,t){let r={},i=new Set(e.map(n=>n.toLowerCase()));for(let[n,o]of t){let l=n.toLowerCase();i.has(l)?r[l]="redacted":Yo.has(l)&&(r[l]=o);}return r}function Xt(e,t){if(e==null)return;let r=e.length>ht*2?e.slice(0,ht*2):e,i=ge(r),n=r!==e||i.length>ht;return {contentType:t,preview:n?i.slice(0,ht):i,truncated:n,redacted:i!==r}}async function Sc(e,t){let r=e.body;if(!r||typeof r.getReader!="function")return {text:await e.text(),overflow:false};let i=r.getReader(),n=new TextDecoder,o="",l=0,p=false;try{for(;;){let{done:a,value:h}=await i.read();if(a||!h){o+=n.decode();break}let s=t+1-l;if(h.byteLength>=s){o+=n.decode(h.subarray(0,s),{stream:!0}),p=!0;break}o+=n.decode(h,{stream:!0}),l+=h.byteLength;}}finally{i.cancel().catch(()=>{});}return {text:o,overflow:p}}function Jo(){return typeof performance<"u"?performance.now():0}function Cc(e){try{return new URL(e,typeof location<"u"?location.href:void 0).href}catch{return e}}function Go(e,t){let r={...t},i=n=>Math.round(n);return e.domainLookupStart>0&&e.domainLookupEnd>e.domainLookupStart&&(r.dns=i(e.domainLookupEnd-e.domainLookupStart)),e.connectStart>0&&e.connectEnd>e.connectStart&&(r.tcp=i(e.connectEnd-e.connectStart)),e.secureConnectionStart>0&&e.connectEnd>e.secureConnectionStart&&(r.tls=i(e.connectEnd-e.secureConnectionStart)),e.requestStart>0&&e.responseStart>e.requestStart&&(r.ttfb=i(e.responseStart-e.requestStart)),e.responseStart>0&&e.responseEnd>e.responseStart&&(r.download=i(e.responseEnd-e.responseStart)),r}function Ec(e,t,r){let i,n=1/0;for(let o of r){if(o.name!==e||o.startTime<t-4)continue;let l=o.startTime-t;l<n&&(n=l,i=o);}return i}var xc=300;function Rc(){let e=[],t,r=()=>{if(t){try{t.disconnect();}catch{}t=void 0;}},i=(l,p)=>{let a=e.indexOf(l);a!==-1&&(e.splice(a,1),clearTimeout(l.timer),l.resolve(p),e.length===0&&r());},n=l=>{for(let p of l){let a,h=1/0;for(let s of e){if(p.name!==s.name||p.startTime<s.perfStart-4)continue;let f=p.startTime-s.perfStart;f<h&&(h=f,a=s);}a&&i(a,Go(p,a.base));}},o=()=>{if(!(t||typeof PerformanceObserver>"u"))try{t=new PerformanceObserver(l=>n(l.getEntries())),t.observe({type:"resource",buffered:!1});}catch{t=void 0;}};return {resolve(l,p,a){if(typeof performance>"u")return Promise.resolve(a);let h=Cc(l);try{let s=performance.getEntriesByType("resource"),f=Ec(h,p,s);if(f)return Promise.resolve(Go(f,a))}catch{}return typeof PerformanceObserver>"u"?Promise.resolve(a):new Promise(s=>{let f={name:h,perfStart:p,base:a,resolve:s,timer:setTimeout(()=>i(f,a),xc)};e.push(f),o();})},flushPending(){for(let l of [...e])i(l,l.base);},teardown(){this.flushPending(),r();}}}function Ko(e){let t=Rc(),r=Yt(wc,bc),i=0,n=a=>{if(!r.take()){i++;return}i>0&&(a.droppedEvents=i,i=0),e.emit(a);},o=()=>t.flushPending(),l=()=>{typeof document<"u"&&document.visibilityState==="hidden"&&t.flushPending();};typeof window<"u"&&window.addEventListener("pagehide",o),typeof document<"u"&&document.addEventListener("visibilitychange",l);let p=[];return p.push(Mc(e,t,n)),p.push(Nc(e,t,n)),p.push(Ac(e,n)),p.push(Dc(e,n)),p.push(()=>{typeof window<"u"&&window.removeEventListener("pagehide",o),typeof document<"u"&&document.removeEventListener("visibilitychange",l),t.teardown();}),()=>p.forEach(a=>a())}function Mc(e,t,r){let i=window.fetch;return i?(window.fetch=async function(n,o){let l=n instanceof Request?n.url:String(n);if(l.includes("/v1/batch")||l.includes("/v1/config"))return i.call(window,n,o);let p=e.clock.now(),a=Jo(),h=(o?.method||(n instanceof Request?n.method:"GET")).toUpperCase(),s=Jt(l),f;if(Zn(l,e.config))try{let m=Kn(),d=Vo(n,o,m.header);n=d.input,o=d.init,f=m.traceId;}catch{}let c=Qn(e.config.redactHeaders,Lc(o?.headers??(n instanceof Request?n.headers:void 0))),u=m=>{let d=e.clock.now(),g={startT:p,endT:d,duration:d-p};e.markActivity(),t.resolve(l,a,g).then(S=>{let y={id:$(),sessionId:e.sessionId,type:"network",t:p,ts:e.clock.wall(),initiator:"fetch",method:h,url:s,status:0,ok:false,resourceType:"fetch",requestHeaders:c,traceId:f,timing:S,...m};r(y);});};try{let m=await i.call(window,n,o),d=m.status,g=Qn(e.config.redactHeaders,m.headers.entries()),S=m.headers.get("content-length"),y;if(e.config.captureNetworkBodies&&Zo(m.headers.get("content-type")))try{let{text:b,overflow:E}=await Sc(m.clone(),ht);y=Xt(b,m.headers.get("content-type")||void 0),y&&E&&(y.truncated=!0);}catch{}return u({status:d,ok:m.ok,responseSize:S?Number(S):void 0,responseHeaders:g,requestBody:e.config.captureNetworkBodies?Xt(Qo(o?.body),void 0):void 0,responseBody:y,error:Xo(d)}),m}catch(m){throw u({status:0,ok:false,error:Ic(m)}),m}},()=>{window.fetch=i;}):()=>{}}function Ic(e){if(e?.name==="AbortError")return "aborted";let r=String(e?.message||"").toLowerCase();return r.includes("cors")?"cors":r.includes("timeout")?"timeout":"network"}function Nc(e,t,r){let i=XMLHttpRequest.prototype,n=i.open,o=i.send,l=i.setRequestHeader,p=new WeakMap;return i.open=function(a,h,...s){let f=String(h);return p.set(this,{method:String(a).toUpperCase(),rawUrl:f,url:Jt(f),startT:0,perfStart:0,reqHeaders:{}}),n.apply(this,[a,h,...s])},i.setRequestHeader=function(a,h){let s=p.get(this);if(s){let f=a.toLowerCase();e.config.redactHeaders.map(c=>c.toLowerCase()).includes(f)?s.reqHeaders[f]="redacted":Yo.has(f)&&(s.reqHeaders[f]=h);}return l.apply(this,[a,h])},i.send=function(a){let h=p.get(this);if(h){if(h.startT=e.clock.now(),h.perfStart=Jo(),e.config.captureNetworkBodies&&(h.body=Qo(a)),Zn(h.rawUrl,e.config))try{let f=Kn();this.setRequestHeader("traceparent",f.header),h.traceId=f.traceId;}catch{}let s=f=>{let c=e.clock.now(),u={startT:h.startT,endT:c,duration:c-h.startT},m=this.status,d=kc(e,this.getAllResponseHeaders()),g;if(e.config.captureNetworkBodies&&Zo(this.getResponseHeader("content-type")))try{(this.responseType===""||this.responseType==="text")&&(g=Xt(this.responseText,this.getResponseHeader("content-type")||void 0));}catch{}let S=Tc(this);e.markActivity(),t.resolve(h.rawUrl,h.perfStart,u).then(y=>{let b={id:$(),sessionId:e.sessionId,type:"network",t:h.startT,ts:e.clock.wall(),initiator:"xhr",method:h.method,url:h.url,status:m,ok:m>=200&&m<400,resourceType:"xhr",requestHeaders:h.reqHeaders,traceId:h.traceId,responseHeaders:d,responseSize:S,requestBody:e.config.captureNetworkBodies?Xt(h.body,void 0):void 0,responseBody:g,timing:y,error:f||Xo(m)};r(b);});};this.addEventListener("loadend",()=>s()),this.addEventListener("error",()=>s("network")),this.addEventListener("timeout",()=>s("timeout")),this.addEventListener("abort",()=>s("aborted"));}return o.apply(this,[a])},()=>{i.open=n,i.send=o,i.setRequestHeader=l;}}function Tc(e){try{if(e.responseType===""||e.responseType==="text")return new Blob([e.responseText]).size}catch{}let t=e.getResponseHeader("content-length");return t?Number(t):void 0}function kc(e,t){let r=[];for(let i of t.trim().split(/[\r\n]+/)){let n=i.indexOf(":");n>0&&r.push([i.slice(0,n).trim(),i.slice(n+1).trim()]);}return Qn(e.config.redactHeaders,r)}function Ac(e,t){let r=navigator.sendBeacon;return r?(navigator.sendBeacon=function(i,n){let o=e.clock.now(),l=false;try{l=r.call(navigator,i,n);}finally{let p=String(i);if(!p.includes("/v1/batch")){let a={id:$(),sessionId:e.sessionId,type:"network",t:o,ts:e.clock.wall(),initiator:"beacon",method:"POST",url:Jt(p),status:l?202:0,ok:l,resourceType:"other",timing:{startT:o,endT:e.clock.now(),duration:0},error:l?void 0:"network"};t(a);}}return l},()=>{navigator.sendBeacon=r;}):()=>{}}var Oc={script:"script",link:"stylesheet",css:"stylesheet",img:"image",image:"image",font:"font",audio:"media",video:"media",track:"media"};function Dc(e,t){if(typeof PerformanceObserver>"u")return ()=>{};let r;try{r=new PerformanceObserver(i=>{for(let n of i.getEntries()){let o=n.initiatorType;if(o==="fetch"||o==="xmlhttprequest"||o==="beacon")continue;let l=Oc[o]||"other",p=e.clock.fromPerf(n.startTime),a=e.clock.fromPerf(n.responseEnd||n.startTime),h={startT:p,endT:a,duration:Math.max(0,a-p),dns:ft(n.domainLookupEnd-n.domainLookupStart),tcp:ft(n.connectEnd-n.connectStart),tls:n.secureConnectionStart?ft(n.connectEnd-n.secureConnectionStart):void 0,ttfb:ft(n.responseStart-n.requestStart),download:ft(n.responseEnd-n.responseStart)},s={id:$(),sessionId:e.sessionId,type:"network",t:p,ts:e.clock.wall(),initiator:"resource",method:"GET",url:Jt(n.name),status:n.responseStatus||200,ok:!n.responseStatus||n.responseStatus<400,resourceType:l,responseSize:n.transferSize||n.encodedBodySize||void 0,timing:h};t(s);}}),r.observe({type:"resource",buffered:!0});}catch{return ()=>{}}return ()=>r?.disconnect()}function ft(e){return Number.isFinite(e)&&e>0?Math.round(e):void 0}function Zo(e){return e?/json|text|xml|x-www-form-urlencoded/i.test(e):false}function Qo(e){if(e!=null){if(typeof e=="string")return e;if(e instanceof URLSearchParams)return e.toString();if(e instanceof FormData){let t={};return e.forEach((r,i)=>t[i]=typeof r=="string"?r:"\xABfile\xBB"),JSON.stringify(t)}try{return JSON.stringify(e)}catch{return}}}function Lc(e){return e?e instanceof Headers?e.entries():Array.isArray(e)?e:Object.entries(e):[]}var Kt=4*1024,Pc=20,_c=40;function Fc(e){try{let t=new URL(e,location.href);return t.search&&(t.search="?\u2026"),t.toString()}catch{return e.split("?")[0]??e}}function Uc(e){try{return new TextEncoder().encode(e).length}catch{return e.length}}function Bc(e,t){if(typeof e=="string"){let i={encoding:"text",size:Uc(e)};if(t){let n=e.length>Kt*2?e.slice(0,Kt*2):e,o=ge(n),l=n!==e||o.length>Kt;i.body={preview:l?o.slice(0,Kt):o,truncated:l,redacted:o!==n};}return i}let r=0;return typeof Blob<"u"&&e instanceof Blob?r=e.size:(e instanceof ArrayBuffer||ArrayBuffer.isView(e))&&(r=e.byteLength),{encoding:"binary",size:r}}function ea(e){let t=typeof window<"u"?window.WebSocket:void 0;if(!t)return ()=>{};let r=n=>{try{let o={id:$(),sessionId:e.sessionId,type:"ws",t:e.clock.now(),ts:e.clock.wall(),...n};e.emit(o);}catch{}};class i extends t{constructor(o,l){super(o,l);try{let p=$(),a=Fc(String(o)),h=l?Array.isArray(l)?l:[l]:void 0,s=e.config.captureNetworkBodies,f=Yt(Pc,_c),c=0,u=(d,g)=>{if(e.markActivity(),!f.take()){c++;return}let S=Bc(g,s),y=c;c=0,r({connId:p,url:a,kind:"message",dir:d,...S,droppedFrames:y||void 0});};this.addEventListener("open",()=>r({connId:p,url:a,kind:"open",protocols:h})),this.addEventListener("close",d=>r({connId:p,url:a,kind:"close",code:d.code,reason:d.reason||void 0,wasClean:d.wasClean,droppedFrames:c||void 0})),this.addEventListener("error",()=>r({connId:p,url:a,kind:"error"})),this.addEventListener("message",d=>u("recv",d.data));let m=super.send.bind(this);this.send=d=>{m(d);try{u("send",d);}catch{}};}catch{}}}return window.WebSocket=i,()=>{window.WebSocket=t;}}function ta(e){function t(n){let o={id:$(),sessionId:e.sessionId,type:"error",t:e.clock.now(),ts:e.clock.wall(),name:n.name,message:ge(n.message),stack:n.stack?ge(n.stack):void 0,source:n.source,handled:n.handled};e.emit(o),e.emit(Ho(e,o));}let r=n=>{let o=n.error;t({name:o?.name||"Error",message:o?.message||n.message||"Unknown error",stack:o?.stack,source:{url:n.filename,line:n.lineno,col:n.colno},handled:false});},i=n=>{let o=n.reason;o instanceof Error?t({name:o.name,message:o.message,stack:o.stack,source:Gt(o.stack),handled:false}):t({name:"UnhandledRejection",message:typeof o=="string"?o:qc(o),handled:false});};return window.addEventListener("error",r,true),window.addEventListener("unhandledrejection",i,true),()=>{window.removeEventListener("error",r,true),window.removeEventListener("unhandledrejection",i,true);}}function qc(e){try{return JSON.stringify(e)??String(e)}catch{return String(e)}}function zc(e,t){let i={LCP:[2500,4e3],INP:[200,500],CLS:[.1,.25],FCP:[1800,3e3],TTFB:[800,1800]}[e];if(i)return t<=i[0]?"good":t<=i[1]?"needs-improvement":"poor"}function ra(e){if(typeof PerformanceObserver>"u")return ()=>{};let t=[],r=(h,s,f)=>{let c={id:$(),sessionId:e.sessionId,type:"perf",t:e.clock.now(),ts:e.clock.wall(),metric:h,value:Math.round(s*1e3)/1e3,rating:zc(h,s),detail:f};e.emit(c);},i=(h,s,f)=>{try{let c=new PerformanceObserver(u=>s(u.getEntries()));c.observe({type:h,buffered:!0,...f}),t.push(c);}catch{}};i("paint",h=>{for(let s of h)s.name==="first-contentful-paint"&&r("FCP",s.startTime);});let n=0;i("largest-contentful-paint",h=>{let s=h[h.length-1];s&&(n=s.startTime);});let o=0;i("layout-shift",h=>{for(let s of h)s.hadRecentInput||(o+=s.value);});let l=0;i("event",h=>{for(let s of h)s.duration>l&&(l=s.duration);},{durationThreshold:40}),i("navigation",h=>{let s=h[0];s&&(r("TTFB",s.responseStart),r("navigation",s.duration,{domInteractive:Math.round(s.domInteractive),domComplete:Math.round(s.domComplete),loadEvent:Math.round(s.loadEventEnd)}));});let p=()=>{n&&r("LCP",n),r("CLS",o),l&&r("INP",l);},a=()=>{document.visibilityState==="hidden"&&p();};return document.addEventListener("visibilitychange",a,true),()=>{t.forEach(h=>h.disconnect()),document.removeEventListener("visibilitychange",a,true);}}var na=1e3,$c=3,Wc=3e3;function Hc(e){if(!e)return false;let t=e;for(let r=0;r<4&&t;r++){let i=t.tagName.toLowerCase();if(["a","button","input","select","textarea","label","summary"].includes(i)||t.getAttribute("role")==="button"||t.hasAttribute("onclick")||t.getAttribute("contenteditable")==="true")return true;t=t.parentElement;}return false}function ia(e){let t=[],r=-1/0,i=(o,l,p)=>{let a={id:$(),sessionId:e.sessionId,type:"custom",t:p,ts:e.clock.wall(),name:o,props:l};e.emit(a);},n=o=>{let l=o.target;if(!l||!(l instanceof Element))return;let p=e.clock.now(),a=Be(l);{let s=l.getBoundingClientRect(),f=s.width>0?Math.min(1,Math.max(0,(o.clientX-s.left)/s.width)):.5,c=s.height>0?Math.min(1,Math.max(0,(o.clientY-s.top)/s.height)):.5,u=(l.textContent||"").replace(/\s+/g," ").trim().slice(0,40);i("_click",{selector:a,path:location.pathname,vw:window.innerWidth,vh:window.innerHeight,rx:Math.round(f*1e3)/1e3,ry:Math.round(c*1e3)/1e3,tag:l.tagName.toLowerCase(),label:u},p);}t=t.filter(s=>p-s.t<=na),t.push({el:l,t:p});let h=t.filter(s=>s.el===l);if(h.length>=$c&&p-r>na&&(r=p,i("rage_click",{selector:a,count:h.length},p)),!Hc(l)){let s=e.lastActivityT();window.setTimeout(()=>{e.lastActivityT()<=Math.max(s,p)&&i("dead_click",{selector:a},p);},Wc);}};return window.addEventListener("click",n,true),()=>window.removeEventListener("click",n,true)}var aa=new Set(["INPUT","TEXTAREA","SELECT"]),jc=new Set(["hidden","submit","button","reset","image","file"]),sa=80,ei=60,Vc=3e5,Gc=100;function Yc(e){return !(!(e instanceof HTMLElement)||!aa.has(e.tagName)||e instanceof HTMLInputElement&&jc.has(e.type))}function Xc(e){return e instanceof HTMLTextAreaElement?"textarea":e instanceof HTMLSelectElement?"select":e.type||"text"}function Jc(e){return e instanceof HTMLInputElement?e.type==="checkbox"||e.type==="radio"?e.checked:e.value.trim().length>0:e instanceof HTMLSelectElement?e.value!=="":e.value.trim().length>0}function ue(e){let t=e.trim().replace(/\s+/g," ");return t.length>sa?t.slice(0,sa):t}function Kc(e){let t=e.getAttribute("name");if(t)return ue(t);if(e.id)return ue(e.id);let r=e.getAttribute("aria-label");if(r)return ue(r);let i=e.getAttribute("aria-labelledby");if(i){let o=i.split(/\s+/).map(l=>e.ownerDocument.getElementById(l)?.textContent||"").join(" ").trim();if(o)return ue(o)}if(e.labels&&e.labels.length){let o=e.labels[0].textContent?.trim();if(o)return ue(o)}let n=e.getAttribute("placeholder");return ue(n||Be(e))}function Ae(e){if(!e)return;let t=e.trim().replace(/\s+/g," ");if(t)return t.length>ei?t.slice(0,ei):t}function Zc(e){if(e.labels&&e.labels.length){let n=Ae(e.labels[0].textContent);if(n)return n}let t=Ae(e.getAttribute("aria-label"));if(t)return t;let r=e.previousElementSibling;for(let n=0;r&&n<3;n++,r=r.previousElementSibling){if(aa.has(r.tagName)||/^(BUTTON|SCRIPT|STYLE|SVG)$/.test(r.tagName))continue;let o=Ae(r.textContent);if(o)return o}let i=e.parentElement;if(i){let n=Ae(Array.from(i.childNodes).filter(l=>l.nodeType===3).map(l=>l.textContent||"").join(" "));if(n)return n;let o=Ae(i.querySelector("label,legend")?.textContent);if(o)return o}return Ae(e.getAttribute("placeholder"))}function Qc(e){let t=e.closest('form,fieldset,section,[role="form"],[role="group"]');if(t){let r=Ae(t.querySelector('legend,h1,h2,h3,h4,[role="heading"]')?.textContent);if(r)return r;let i=Ae(t.getAttribute("aria-label"));if(i)return i}return Ae(typeof document<"u"?document.title:void 0)}function ef(e){let t={},r=(e.getAttribute("autocomplete")||"").trim().toLowerCase();r&&r!=="off"&&r!=="on"&&(t.autocomplete=r.slice(0,ei));let i=Zc(e);i&&(t.near=i);let n=Qc(e);return n&&(t.formTitle=n),t}function oa(e){let t=e.form;if(t){if(t.getAttribute("name"))return ue(t.getAttribute("name"));if(t.id)return ue(t.id);let r=t.getAttribute("aria-label");if(r)return ue(r);let i=t.getAttribute("action");if(i)try{return ue(new URL(i,location.href).pathname)}catch{return ue(i)}return ue(Be(t))}return ue(`page:${location.pathname}`)}function la(e){let t=e.config.blockSelector,r=null,i=(s,f)=>{let c={id:$(),sessionId:e.sessionId,type:"custom",t:e.clock.now(),ts:e.clock.wall(),name:s,props:f};e.emit(c);},n=s=>{try{return !!t&&!!s.closest(t)}catch{return false}},o=()=>{if(!r)return;let{el:s,start:f,changed:c}=r;r=null;let u=Math.min(Vc,Math.max(0,e.clock.now()-f));u<Gc&&!c||i("form_field",{form:oa(s),field:Kc(s),type:Xc(s),ms:u,changed:c,filled:Jc(s),...ef(s)});},l=s=>{let f=s.target;!Yc(f)||n(f)||(r&&r.el!==f&&o(),r={el:f,start:e.clock.now(),changed:false});},p=s=>{r&&s.target===r.el&&(r.changed=true);},a=s=>{r&&s.target===r.el&&o();},h=s=>{let f=s.target;if(!(f instanceof HTMLFormElement)||n(f))return;o();let c=f.querySelector("input,textarea,select"),u=c&&!n(c)?oa(c):ue(f.getAttribute("name")||f.id||Be(f));i("form_submit",{form:u});};return document.addEventListener("focusin",l,true),document.addEventListener("focusout",a,true),document.addEventListener("input",p,true),document.addEventListener("submit",h,true),window.addEventListener("pagehide",o,true),()=>{o(),document.removeEventListener("focusin",l,true),document.removeEventListener("focusout",a,true),document.removeEventListener("input",p,true),document.removeEventListener("submit",h,true),window.removeEventListener("pagehide",o,true);}}function ua(e){let t=location.pathname,r=0,i=false,n=(a,h,s)=>{let f={id:$(),sessionId:e.sessionId,type:"custom",t:e.clock.now(),ts:e.clock.wall(),name:"_scroll",props:{path:t,depth:a,h,vh:s}};e.emit(f);},o=()=>{let a=document.documentElement,h=document.body;return Math.max(a.scrollHeight,h?h.scrollHeight:0,a.clientHeight)||1},l=()=>{i=false,location.pathname!==t&&(t=location.pathname,r=0);let a=window.innerHeight||document.documentElement.clientHeight||1,h=o(),s=Math.min(1,(window.scrollY+a)/h),f=Math.min(100,Math.round(s*10)*10);f>r&&(r=f,n(f,h,a));},p=()=>{i||(i=true,requestAnimationFrame(l));};return window.addEventListener("scroll",p,{passive:true,capture:true}),l(),()=>{window.removeEventListener("scroll",p,true);}}function ca(e){let t=null,r=()=>{let p=location.hash;return location.pathname+(p.startsWith("#/")?p:"")},i=()=>{let p=r();if(p===t)return;let a=t??"";t=p;let h={id:$(),sessionId:e.sessionId,type:"pageview",t:e.clock.now(),ts:e.clock.wall(),url:location.href,path:p,title:document.title||void 0,referrer:a||void 0};e.emit(h),e.markActivity();},n=history.pushState,o=history.replaceState,l=p=>function(h,s,f){let c=p.call(this,h,s,f);return queueMicrotask(i),c};return history.pushState=l(n),history.replaceState=l(o),window.addEventListener("popstate",i),window.addEventListener("hashchange",i),i(),()=>{history.pushState=n,history.replaceState=o,window.removeEventListener("popstate",i),window.removeEventListener("hashchange",i);}}function tf(e){let t=/\.([A-Za-z0-9_-]+)/.exec(e||"");return ["obsrviq-block",t&&t[1]?t[1]:""].filter(Boolean).join(" ")}function fa(e){let t=document.createElement("div");t.className=tf(e),t.setAttribute("data-obsrviq-ui",""),t.style.cssText="all:initial";let r=t.attachShadow({mode:"open"});return {host:t,root:r}}function ha(e,t){try{let r=new CSSStyleSheet;r.replaceSync(t),e.adoptedStyleSheets=[r];}catch{let r=document.createElement("style");r.textContent=t,e.appendChild(r);}}function da(e){(document.body||document.documentElement).appendChild(e);}var ti="#6e76f1",rf=`
128
+ `,$s=typeof self<"u"&&self.Blob&&new Blob([_o],{type:"text/javascript;charset=utf-8"});function cc(e){let t;try{if(t=$s&&(self.URL||self.webkitURL).createObjectURL($s),!t)throw "";let r=new Worker(t,{name:e?.name});return r.addEventListener("error",()=>{(self.URL||self.webkitURL).revokeObjectURL(t);}),r}catch{return new Worker("data:text/javascript;charset=utf-8,"+encodeURIComponent(_o),{name:e?.name})}finally{t&&(self.URL||self.webkitURL).revokeObjectURL(t);}}var Tn=class{constructor(t){T(this,"pendingCanvasMutations",new Map),T(this,"rafStamps",{latestId:0,invokeId:null}),T(this,"mirror"),T(this,"mutationCb"),T(this,"resetObservers"),T(this,"frozen",false),T(this,"locked",false),T(this,"processMutation",(a,h)=>{(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(h);});let{sampling:r="all",win:i,blockClass:n,blockSelector:o,recordCanvas:l,dataURLOptions:d}=t;this.mutationCb=t.mutationCb,this.mirror=t.mirror,l&&r==="all"&&this.initCanvasMutationObserver(i,n,o),l&&typeof r=="number"&&this.initCanvasFPSObserver(r,i,n,o,{dataURLOptions:d});}reset(){this.pendingCanvasMutations.clear(),this.resetObservers&&this.resetObservers();}freeze(){this.frozen=true;}unfreeze(){this.frozen=false;}lock(){this.locked=true;}unlock(){this.locked=false;}initCanvasFPSObserver(t,r,i,n,o){let l=qs(r,i,n,true),d=new Map,a=new cc;a.onmessage=m=>{let{id:p}=m.data;if(d.set(p,false),!("base64"in m.data))return;let{base64:g,type:S,width:y,height:b}=m.data;this.mutationCb({id:p,type:Ye["2D"],commands:[{property:"clearRect",args:[0,0,y,b]},{property:"drawImage",args:[{rr_type:"ImageBitmap",args:[{rr_type:"Blob",data:[{rr_type:"ArrayBuffer",base64:g}],type:S}]},0,0]}]});};let h=1e3/t,s=0,f,c=()=>{let m=[];return r.document.querySelectorAll("canvas").forEach(p=>{le(p,i,n,true)||m.push(p);}),m},u=m=>{if(s&&m-s<h){f=requestAnimationFrame(u);return}s=m,c().forEach(async p=>{var g;let S=this.mirror.getId(p);if(d.get(S)||p.width===0||p.height===0)return;if(d.set(S,true),["webgl","webgl2"].includes(p.__context)){let b=p.getContext(p.__context);((g=b?.getContextAttributes())==null?void 0:g.preserveDrawingBuffer)===false&&b.clear(b.COLOR_BUFFER_BIT);}let y=await createImageBitmap(p);a.postMessage({id:S,bitmap:y,width:p.width,height:p.height,dataURLOptions:o.dataURLOptions},[y]);}),f=requestAnimationFrame(u);};f=requestAnimationFrame(u),this.resetObservers=()=>{l(),cancelAnimationFrame(f);};}initCanvasMutationObserver(t,r,i){this.startRAFTimestamping(),this.startPendingCanvasMutationFlusher();let n=qs(t,r,i,false),o=ac(this.processMutation.bind(this),t,r,i),l=uc(this.processMutation.bind(this),t,r,i);this.resetObservers=()=>{n(),o(),l();};}startPendingCanvasMutationFlusher(){requestAnimationFrame(()=>this.flushPendingCanvasMutations());}startRAFTimestamping(){let t=r=>{this.rafStamps.latestId=r,requestAnimationFrame(t);};requestAnimationFrame(t);}flushPendingCanvasMutations(){this.pendingCanvasMutations.forEach((t,r)=>{let i=this.mirror.getId(r);this.flushPendingCanvasMutationFor(r,i);}),requestAnimationFrame(()=>this.flushPendingCanvasMutations());}flushPendingCanvasMutationFor(t,r){if(this.frozen||this.locked)return;let i=this.pendingCanvasMutations.get(t);if(!i||r===-1)return;let n=i.map(l=>{let{type:d,...a}=l;return a}),{type:o}=i[0];this.mutationCb({id:r,type:o,commands:n}),this.pendingCanvasMutations.delete(t);}},kn=class{constructor(t){T(this,"trackedLinkElements",new WeakSet),T(this,"mutationCb"),T(this,"adoptedStyleSheetCb"),T(this,"styleMirror",new En),this.mutationCb=t.mutationCb,this.adoptedStyleSheetCb=t.adoptedStyleSheetCb;}attachLinkElement(t,r){"_cssText"in r.attributes&&this.mutationCb({adds:[],removes:[],texts:[],attributes:[{id:r.id,attributes:r.attributes}]}),this.trackLinkElement(t);}trackLinkElement(t){this.trackedLinkElements.has(t)||(this.trackedLinkElements.add(t),this.trackStylesheetInLinkElement(t));}adoptStyleSheets(t,r){if(t.length===0)return;let i={id:r,styleIds:[]},n=[];for(let o of t){let l;this.styleMirror.has(o)?l=this.styleMirror.getId(o):(l=this.styleMirror.add(o),n.push({styleId:l,rules:Array.from(o.rules||CSSRule,(d,a)=>({rule:Ys(d,o.href),index:a}))})),i.styleIds.push(l);}n.length>0&&(i.styles=n),this.adoptedStyleSheetCb(i);}reset(){this.styleMirror.reset(),this.trackedLinkElements=new WeakSet;}trackStylesheetInLinkElement(t){}},An=class{constructor(){T(this,"nodeMap",new WeakMap),T(this,"active",false);}inOtherBuffer(t,r){let i=this.nodeMap.get(t);return i&&Array.from(i).some(n=>n!==r)}add(t,r){this.active||(this.active=true,requestAnimationFrame(()=>{this.nodeMap=new WeakMap,this.active=false;})),this.nodeMap.set(t,(this.nodeMap.get(t)||new Set).add(r));}destroy(){}},te,Mt,vn,Pt=false;try{if(Array.from([1],e=>e*2)[0]!==2){let e=document.createElement("iframe");document.body.appendChild(e),Array.from=((bi=e.contentWindow)==null?void 0:bi.Array.from)||Array.from,document.body.removeChild(e);}}catch(e){console.debug("Unable to override Array.from",e);}var Se=xl();function xe(e={}){let{emit:t,checkoutEveryNms:r,checkoutEveryNth:i,blockClass:n="rr-block",blockSelector:o=null,ignoreClass:l="rr-ignore",ignoreSelector:d=null,maskTextClass:a="rr-mask",maskTextSelector:h=null,inlineStylesheet:s=true,maskAllInputs:f,maskInputOptions:c,slimDOMOptions:u,maskInputFn:m,maskTextFn:p,hooks:g,packFn:S,sampling:y={},dataURLOptions:b={},mousemoveWait:E,recordDOM:w=true,recordCanvas:v=false,recordCrossOriginIframes:C=false,recordAfter:R=e.recordAfter==="DOMContentLoaded"?e.recordAfter:"load",userTriggeredOnInput:M=false,collectFonts:I=false,inlineImages:O=false,plugins:k,keepIframeSrcFn:x=()=>false,ignoreCSSAttributes:Q=new Set([]),errorHandler:Y}=e;Wu(Y);let L=C?window.parent===window:true,A=false;if(!L)try{window.parent.document&&(A=!1);}catch{A=true;}if(L&&!t)throw new Error("emit function is required");if(!L&&!A)return ()=>{};E!==void 0&&y.mousemove===void 0&&(y.mousemove=E),Se.reset();let B=f===true?{color:true,date:true,"datetime-local":true,email:true,month:true,number:true,range:true,search:true,tel:true,text:true,time:true,url:true,week:true,textarea:true,select:true,password:true}:c!==void 0?c:{password:true},X=eo(u);Uu();let J,P=0,ce=D=>{for(let ee of k||[])ee.eventProcessor&&(D=ee.eventProcessor(D));return S&&!A&&(D=S(D)),D};te=(D,ee)=>{var z;let V=D;if(V.timestamp=st(),(z=Le[0])!=null&&z.isFrozen()&&V.type!==q.FullSnapshot&&!(V.type===q.IncrementalSnapshot&&V.data.source===F.Mutation)&&Le.forEach(he=>he.unfreeze()),L)t?.(ce(V),ee);else if(A){let he={type:"rrweb",event:ce(V),origin:window.location.origin,isCheckout:ee};window.parent.postMessage(he,"*");}if(V.type===q.FullSnapshot)J=V,P=0;else if(V.type===q.IncrementalSnapshot){if(V.data.source===F.Mutation&&V.data.isAttachIframe)return;P++;let he=i&&P>=i,j=r&&V.timestamp-J.timestamp>r;(he||j)&&Mt(true);}};let N=D=>{te({type:q.IncrementalSnapshot,data:{source:F.Mutation,...D}});},re=D=>te({type:q.IncrementalSnapshot,data:{source:F.Scroll,...D}}),H=D=>te({type:q.IncrementalSnapshot,data:{source:F.CanvasMutation,...D}}),me=D=>te({type:q.IncrementalSnapshot,data:{source:F.AdoptedStyleSheet,...D}}),ie=new kn({mutationCb:N,adoptedStyleSheetCb:me}),oe=new Mn({mirror:Se,mutationCb:N,stylesheetManager:ie,recordCrossOriginIframes:C,wrappedEmit:te});for(let D of k||[])D.getMirror&&D.getMirror({nodeMirror:Se,crossOriginIframeMirror:oe.crossOriginIframeMirror,crossOriginIframeStyleMirror:oe.crossOriginIframeStyleMirror});let Re=new An;vn=new Tn({recordCanvas:v,mutationCb:H,win:window,blockClass:n,blockSelector:o,mirror:Se,sampling:y.canvas,dataURLOptions:b});let we=new Nn({mutationCb:N,scrollCb:re,bypassOptions:{blockClass:n,blockSelector:o,maskTextClass:a,maskTextSelector:h,inlineStylesheet:s,maskInputOptions:B,dataURLOptions:b,maskTextFn:p,maskInputFn:m,recordCanvas:v,inlineImages:O,sampling:y,slimDOMOptions:X,iframeManager:oe,stylesheetManager:ie,canvasManager:vn,keepIframeSrcFn:x,processedNodeManager:Re},mirror:Se});Mt=(D=false)=>{if(!w)return;te({type:q.Meta,data:{href:window.location.href,width:So(),height:bo()}},D),ie.reset(),we.init(),Le.forEach(z=>z.lock());let ee=Yl(document,{mirror:Se,blockClass:n,blockSelector:o,maskTextClass:a,maskTextSelector:h,inlineStylesheet:s,maskAllInputs:B,maskTextFn:p,maskInputFn:m,slimDOM:X,dataURLOptions:b,recordCanvas:v,inlineImages:O,onSerialize:z=>{xo(z,Se)&&oe.addIframe(z),Ro(z,Se)&&ie.trackLinkElement(z),Cn(z)&&we.addShadowRoot(_.shadowRoot(z),document);},onIframeLoad:(z,V)=>{oe.attachIframe(z,V),we.observeAttachShadow(z);},onStylesheetLoad:(z,V)=>{ie.attachLinkElement(z,V);},keepIframeSrcFn:x});if(!ee)return console.warn("Failed to snapshot the document");te({type:q.FullSnapshot,data:{node:ee,initialOffset:wo(window)}},D),Le.forEach(z=>z.unlock()),document.adoptedStyleSheets&&document.adoptedStyleSheets.length>0&&ie.adoptStyleSheets(document.adoptedStyleSheets,Se.getId(document));};try{let D=[],ee=V=>{var he;return U(nc)({mutationCb:N,mousemoveCb:(j,Qt)=>te({type:q.IncrementalSnapshot,data:{source:Qt,positions:j}}),mouseInteractionCb:j=>te({type:q.IncrementalSnapshot,data:{source:F.MouseInteraction,...j}}),scrollCb:re,viewportResizeCb:j=>te({type:q.IncrementalSnapshot,data:{source:F.ViewportResize,...j}}),inputCb:j=>te({type:q.IncrementalSnapshot,data:{source:F.Input,...j}}),mediaInteractionCb:j=>te({type:q.IncrementalSnapshot,data:{source:F.MediaInteraction,...j}}),styleSheetRuleCb:j=>te({type:q.IncrementalSnapshot,data:{source:F.StyleSheetRule,...j}}),styleDeclarationCb:j=>te({type:q.IncrementalSnapshot,data:{source:F.StyleDeclaration,...j}}),canvasMutationCb:H,fontCb:j=>te({type:q.IncrementalSnapshot,data:{source:F.Font,...j}}),selectionCb:j=>{te({type:q.IncrementalSnapshot,data:{source:F.Selection,...j}});},customElementCb:j=>{te({type:q.IncrementalSnapshot,data:{source:F.CustomElement,...j}});},blockClass:n,ignoreClass:l,ignoreSelector:d,maskTextClass:a,maskTextSelector:h,maskInputOptions:B,inlineStylesheet:s,sampling:y,recordDOM:w,recordCanvas:v,inlineImages:O,userTriggeredOnInput:M,collectFonts:I,doc:V,maskInputFn:m,maskTextFn:p,keepIframeSrcFn:x,blockSelector:o,slimDOMOptions:X,dataURLOptions:b,mirror:Se,iframeManager:oe,stylesheetManager:ie,shadowDomManager:we,processedNodeManager:Re,canvasManager:vn,ignoreCSSAttributes:Q,plugins:((he=k?.filter(j=>j.observer))==null?void 0:he.map(j=>({observer:j.observer,options:j.options,callback:Qt=>te({type:q.Plugin,data:{plugin:j.name,payload:Qt}})})))||[]},g)};oe.addLoadListener(V=>{try{D.push(ee(V.contentDocument));}catch(he){console.warn(he);}});let z=()=>{Mt(),D.push(ee(document)),Pt=!0;};return ["interactive","complete"].includes(document.readyState)?z():(D.push(ae("DOMContentLoaded",()=>{te({type:q.DomContentLoaded,data:{}}),R==="DOMContentLoaded"&&z();})),D.push(ae("load",()=>{te({type:q.Load,data:{}}),R==="load"&&z();},window))),()=>{D.forEach(V=>{try{V();}catch(he){String(he).toLowerCase().includes("cross-origin")||console.warn(he);}}),Re.destroy(),Pt=!1,Hu();}}catch(D){console.warn(D);}}xe.addCustomEvent=(e,t)=>{if(!Pt)throw new Error("please add custom event after start recording");te({type:q.Custom,data:{tag:e,payload:t}});};xe.freezePage=()=>{Le.forEach(e=>e.freeze());};xe.takeFullSnapshot=e=>{if(!Pt)throw new Error("please take full snapshot after start recording");Mt(e);};xe.mirror=Se;var Ws;(function(e){e[e.NotStarted=0]="NotStarted",e[e.Running=1]="Running",e[e.Stopped=2]="Stopped";})(Ws||(Ws={}));var{addCustomEvent:yf}=xe,{freezePage:vf}=xe,{takeFullSnapshot:wf}=xe;function $(){return typeof crypto<"u"&&"randomUUID"in crypto?crypto.randomUUID():"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,e=>{let t=Math.random()*16|0;return (e==="x"?t:t&3|8).toString(16)})}var ct=class{constructor(t,r){let i=Date.now();this.startedAt=t??i,this.perfStart=typeof performance<"u"?performance.now():0,this.baseT=Math.max(0,i-this.startedAt,r??0);}now(){let t=typeof performance<"u"?performance.now():Date.now()-this.startedAt;return Math.max(0,this.baseT+Math.round(t-this.perfStart))}wall(){return Date.now()}fromPerf(t){return Math.max(0,this.baseT+Math.round(t-this.perfStart))}};async function Fo(e){if(typeof crypto<"u"&&crypto.subtle){let r=await crypto.subtle.digest("SHA-256",new TextEncoder().encode(e));return Array.from(new Uint8Array(r)).map(i=>i.toString(16).padStart(2,"0")).join("")}let t=0;for(let r=0;r<e.length;r++)t=Math.imul(31,t)+e.charCodeAt(r)|0;return (t>>>0).toString(16)}function Uo(){let e=navigator.userAgent,t={w:window.innerWidth,h:window.innerHeight},r,i;try{r=Intl.DateTimeFormat().resolvedOptions().timeZone||void 0,i=-new Date().getTimezoneOffset();}catch{}let n="desktop";/iPad|Tablet/i.test(e)?n="tablet":/Mobi|Android|iPhone/i.test(e)&&(n="mobile");let o;/Windows/i.test(e)?o="Windows":/Mac OS X|Macintosh/i.test(e)?o="macOS":/Android/i.test(e)?o="Android":/iPhone|iPad|iOS/i.test(e)?o="iOS":/Linux/i.test(e)&&(o="Linux");let l;return /Edg\//.test(e)?l="Edge":/Chrome\//.test(e)?l="Chrome":/Firefox\//.test(e)?l="Firefox":/Safari\//.test(e)&&(l="Safari"),{type:n,os:o,browser:l,viewport:t,tz:r,tzOffset:i}}function Xn(){let e=navigator;return e.globalPrivacyControl===true||e.doNotTrack==="1"||window.doNotTrack==="1"}var fc=3;function Bo(e){let t=xe({emit(r){let i=e.clock.fromPerf(hc());r.timestamp=e.clock.startedAt+i;let n={id:$(),sessionId:e.sessionId,type:"dom",t:i,ts:e.clock.wall(),data:r};e.emit(n),r.type===fc&&e.markActivity();},maskAllInputs:e.config.maskAllInputs,maskInputOptions:{password:true},maskTextSelector:e.config.maskTextSelector,blockSelector:e.config.blockSelector,recordCanvas:e.config.recordCanvas,checkoutEveryNms:3e4,sampling:{mousemove:50,scroll:150,input:"last"}});return ()=>{try{t?.();}catch{}}}function qo(){try{xe.takeFullSnapshot(!0);}catch{}}function hc(){return typeof performance<"u"?performance.now():Date.now()}var dc=8*1024,pc=2e3;function mc(e){return new Blob([e]).size}function zo(e,t){if(mc(e)<=t)return {value:e,truncated:false};let r=Math.max(16,Math.floor(t*.95));return {value:e.slice(0,r),truncated:true}}function $o(e,t=dc){if(e===null)return {kind:"primitive",value:null};let r=typeof e;if(r==="number"||r==="boolean")return {kind:"primitive",value:e};if(r==="string"){let i=e,n=i.length>t*2?i.slice(0,t*2):i,o=ge(n),{value:l,truncated:d}=zo(o,t);return {kind:"string",value:l,truncated:d||n!==i}}if(e instanceof Error)return {kind:"error",name:e.name,message:ge(e.message),stack:e.stack?ge(e.stack):void 0};if(e instanceof Element)return {kind:"dom",selector:Be(e)};if(r==="object"||r==="function"||r==="symbol"||r==="bigint"){let i={nodes:pc,bytes:t*2,exhausted:false},n=Jn(e,i),o,l=i.exhausted;try{let d=JSON.stringify(n,gc()),a=zo(d??"undefined",t);o=a.value,l=l||a.truncated;}catch{o=void 0;}return {kind:"object",preview:yc(e),json:o,truncated:l}}return {kind:"primitive",value:String(e)}}function Jn(e,t,r=0){if(t.exhausted)return "\xABtruncated\xBB";if(r>6)return "\xABdepth\xBB";if(--t.nodes<=0&&(t.exhausted=true),typeof e=="string"){let n=e.length>t.bytes?e.slice(0,Math.max(0,t.bytes)):e;n!==e&&(t.exhausted=true);let o=ge(n);return (t.bytes-=o.length+2)<=0&&(t.exhausted=true),o}if(e===null||typeof e!="object")return e;if(Array.isArray(e)){let n=[];for(let o of e){if(t.exhausted){n.push("\xABtruncated\xBB");break}n.push(Jn(o,t,r+1));}return n}let i={};for(let n of Object.keys(e)){if(t.exhausted){i["\u2026"]="\xABtruncated\xBB";break}(t.bytes-=n.length+4)<=0&&(t.exhausted=true),i[n]=Ze(n)?"\xABredacted\xBB":Jn(e[n],t,r+1);}return i}function gc(){let e=new WeakSet;return (t,r)=>{if(typeof r=="bigint")return `${r.toString()}n`;if(typeof r=="function")return `\u0192 ${r.name||"anonymous"}`;if(typeof r=="object"&&r!==null){if(e.has(r))return "\xABcircular\xBB";e.add(r);}return r}}function yc(e){if(Array.isArray(e))return `Array(${e.length})`;if(e&&typeof e=="object"){let t=Object.keys(e);return `{ ${t.slice(0,4).join(", ")}${t.length>4?", \u2026":""} }`}return String(e)}function Be(e){let t=[],r=e,i=0;for(;r&&r.nodeType===1&&i<5;){let n=r.tagName.toLowerCase();if(r.id){n+=`#${r.id}`,t.unshift(n);break}let o=(r.getAttribute("class")||"").trim().split(/\s+/).filter(Boolean)[0];o&&(n+=`.${o}`),t.unshift(n),r=r.parentElement,i++;}return t.join(" > ")}function Gt(e){if(!e)return;let t=e.split(`
129
+ `).map(r=>r.trim());for(let r of t){let i=r.match(/\((https?:\/\/[^)]+):(\d+):(\d+)\)/)||r.match(/at (https?:\/\/\S+):(\d+):(\d+)/)||r.match(/(https?:\/\/\S+):(\d+):(\d+)/);if(i)return {url:i[1],line:Number(i[2]),col:Number(i[3])}}}var Wo=["log","info","warn","error","debug"],vc=100;function Ho(e){let t={},r=e.clock.now(),i=0,n=0;function o(){let d=e.clock.now();return d-r>=1e3&&(n>0&&(l("warn",[{kind:"string",value:`Obsrviq: suppressed ${n} console messages (flood cap)`}]),n=0),r=d,i=0),i>=vc?(n++,true):(i++,false)}function l(d,a,h){let s=Gt(h),f={id:$(),sessionId:e.sessionId,type:"console",t:e.clock.now(),ts:e.clock.wall(),level:d,args:a,stack:d==="error"?h:void 0,source:s};e.emit(f);}for(let d of Wo){let a=console[d];t[d]=a,console[d]=(...h)=>{try{a.apply(console,h);}catch{}try{if(o())return;let s=h.map(c=>$o(c,e.config.maxArgBytes)),f;d==="error"&&(f=h.find(u=>u instanceof Error)?.stack??new Error().stack),l(d,s,f);}catch{}};}return ()=>{for(let d of Wo)t[d]&&(console[d]=t[d]);}}function jo(e,t){return {id:$(),sessionId:e.sessionId,type:"console",t:t.t,ts:t.ts,level:"error",args:[{kind:"error",name:t.name,message:t.message,stack:t.stack}],stack:t.stack,source:t.source}}function Yt(e,t){let r=t,i=Date.now();return {take(){let n=Date.now();return r=Math.min(t,r+(n-i)/1e3*e),i=n,r<1?false:(r-=1,true)}}}function Vo(e){let t=new Uint8Array(e);if(typeof crypto<"u"&&typeof crypto.getRandomValues=="function")crypto.getRandomValues(t);else for(let i=0;i<e;i++)t[i]=Math.random()*256|0;let r="";for(let i=0;i<e;i++)r+=t[i].toString(16).padStart(2,"0");return r}function Kn(){let e=Vo(16),t=Vo(8);return {traceId:e,spanId:t,header:`00-${e}-${t}-01`}}function Zn(e,t){if(!t.tracePropagation)return false;let r;try{r=new URL(e,typeof location<"u"?location.href:void 0);}catch{return false}return r.protocol!=="http:"&&r.protocol!=="https:"?false:typeof location<"u"&&r.origin===location.origin?true:wc(r.hostname,t.traceHosts)}function wc(e,t){let r=e.toLowerCase();for(let i of t){let n=String(i).trim().toLowerCase();if(n){if(n.includes("://"))try{n=new URL(n).hostname;}catch{}if(n=n.replace(/^\*?\./,""),r===n||r.endsWith("."+n))return true}}return false}function Qn(e){if(!e)return null;let t=e.split("-");return t.length>=2&&/^[0-9a-f]{32}$/.test(t[1])?t[1]:null}function bc(e,t){let i=!!t&&"headers"in t&&t.headers!=null?t.headers:e instanceof Request?e.headers:void 0;if(!i)return null;try{return new Headers(i).get("traceparent")}catch{return null}}function Go(e,t){let r=bc(e,t);if(r)return {input:e,init:t,traceId:Qn(r)??""};let i=Kn(),n=!!t&&"headers"in t&&t.headers!=null;if(e instanceof Request&&!n){let l=new Headers(e.headers);return l.set("traceparent",i.header),{input:new Request(e,{headers:l}),init:t,traceId:i.traceId}}let o=new Headers(t?.headers??void 0);return o.set("traceparent",i.header),{input:e,init:{...t||{},headers:o},traceId:i.traceId}}var ht=4*1024,Sc=50,Cc=100,Xo=new Set(["content-type","content-length","accept","accept-encoding","cache-control","etag","last-modified","content-encoding","x-request-id","x-correlation-id","traceparent","server","vary"]);function Jt(e){try{let t=new URL(e,location.href);return t.search&&(t.search="?\u2026"),t.toString()}catch{return e.split("?")[0]??e}}function Jo(e){if(e===0)return "network";if(e>=500)return "http_5xx";if(e>=400)return "http_4xx"}function ei(e,t){let r={},i=new Set(e.map(n=>n.toLowerCase()));for(let[n,o]of t){let l=n.toLowerCase();i.has(l)?r[l]="redacted":Xo.has(l)&&(r[l]=o);}return r}function Xt(e,t){if(e==null)return;let r=e.length>ht*2?e.slice(0,ht*2):e,i=ge(r),n=r!==e||i.length>ht;return {contentType:t,preview:n?i.slice(0,ht):i,truncated:n,redacted:i!==r}}async function Ec(e,t){let r=e.body;if(!r||typeof r.getReader!="function")return {text:await e.text(),overflow:false};let i=r.getReader(),n=new TextDecoder,o="",l=0,d=false;try{for(;;){let{done:a,value:h}=await i.read();if(a||!h){o+=n.decode();break}let s=t+1-l;if(h.byteLength>=s){o+=n.decode(h.subarray(0,s),{stream:!0}),d=!0;break}o+=n.decode(h,{stream:!0}),l+=h.byteLength;}}finally{i.cancel().catch(()=>{});}return {text:o,overflow:d}}function Ko(){return typeof performance<"u"?performance.now():0}function xc(e){try{return new URL(e,typeof location<"u"?location.href:void 0).href}catch{return e}}function Yo(e,t){let r={...t},i=n=>Math.round(n);return e.domainLookupStart>0&&e.domainLookupEnd>e.domainLookupStart&&(r.dns=i(e.domainLookupEnd-e.domainLookupStart)),e.connectStart>0&&e.connectEnd>e.connectStart&&(r.tcp=i(e.connectEnd-e.connectStart)),e.secureConnectionStart>0&&e.connectEnd>e.secureConnectionStart&&(r.tls=i(e.connectEnd-e.secureConnectionStart)),e.requestStart>0&&e.responseStart>e.requestStart&&(r.ttfb=i(e.responseStart-e.requestStart)),e.responseStart>0&&e.responseEnd>e.responseStart&&(r.download=i(e.responseEnd-e.responseStart)),r}function Rc(e,t,r){let i,n=1/0;for(let o of r){if(o.name!==e||o.startTime<t-4)continue;let l=o.startTime-t;l<n&&(n=l,i=o);}return i}var Ic=300;function Mc(){let e=[],t,r=()=>{if(t){try{t.disconnect();}catch{}t=void 0;}},i=(l,d)=>{let a=e.indexOf(l);a!==-1&&(e.splice(a,1),clearTimeout(l.timer),l.resolve(d),e.length===0&&r());},n=l=>{for(let d of l){let a,h=1/0;for(let s of e){if(d.name!==s.name||d.startTime<s.perfStart-4)continue;let f=d.startTime-s.perfStart;f<h&&(h=f,a=s);}a&&i(a,Yo(d,a.base));}},o=()=>{if(!(t||typeof PerformanceObserver>"u"))try{t=new PerformanceObserver(l=>n(l.getEntries())),t.observe({type:"resource",buffered:!1});}catch{t=void 0;}};return {resolve(l,d,a){if(typeof performance>"u")return Promise.resolve(a);let h=xc(l);try{let s=performance.getEntriesByType("resource"),f=Rc(h,d,s);if(f)return Promise.resolve(Yo(f,a))}catch{}return typeof PerformanceObserver>"u"?Promise.resolve(a):new Promise(s=>{let f={name:h,perfStart:d,base:a,resolve:s,timer:setTimeout(()=>i(f,a),Ic)};e.push(f),o();})},flushPending(){for(let l of [...e])i(l,l.base);},teardown(){this.flushPending(),r();}}}function Zo(e){let t=Mc(),r=Yt(Sc,Cc),i=0,n=a=>{if(!r.take()){i++;return}i>0&&(a.droppedEvents=i,i=0),e.emit(a);},o=()=>t.flushPending(),l=()=>{typeof document<"u"&&document.visibilityState==="hidden"&&t.flushPending();};typeof window<"u"&&window.addEventListener("pagehide",o),typeof document<"u"&&document.addEventListener("visibilitychange",l);let d=[];return d.push(Nc(e,t,n)),d.push(kc(e,t,n)),d.push(Dc(e,n)),d.push(Pc(e,n)),d.push(()=>{typeof window<"u"&&window.removeEventListener("pagehide",o),typeof document<"u"&&document.removeEventListener("visibilitychange",l),t.teardown();}),()=>d.forEach(a=>a())}function Nc(e,t,r){let i=window.fetch;return i?(window.fetch=async function(n,o){let l=n instanceof Request?n.url:String(n);if(l.includes("/v1/batch")||l.includes("/v1/config"))return i.call(window,n,o);let d=e.clock.now(),a=Ko(),h=(o?.method||(n instanceof Request?n.method:"GET")).toUpperCase(),s=Jt(l),f;if(Zn(l,e.config))try{let m=Go(n,o);n=m.input,o=m.init,f=m.traceId||void 0;}catch{}let c=ei(e.config.redactHeaders,_c(o?.headers??(n instanceof Request?n.headers:void 0))),u=m=>{let p=e.clock.now(),g={startT:d,endT:p,duration:p-d};e.markActivity(),t.resolve(l,a,g).then(S=>{let y={id:$(),sessionId:e.sessionId,type:"network",t:d,ts:e.clock.wall(),initiator:"fetch",method:h,url:s,status:0,ok:false,resourceType:"fetch",requestHeaders:c,traceId:f,timing:S,...m};r(y);});};try{let m=await i.call(window,n,o),p=m.status,g=ei(e.config.redactHeaders,m.headers.entries()),S=m.headers.get("content-length"),y;if(e.config.captureNetworkBodies&&Qo(m.headers.get("content-type")))try{let{text:b,overflow:E}=await Ec(m.clone(),ht);y=Xt(b,m.headers.get("content-type")||void 0),y&&E&&(y.truncated=!0);}catch{}return u({status:p,ok:m.ok,responseSize:S?Number(S):void 0,responseHeaders:g,requestBody:e.config.captureNetworkBodies?Xt(ea(o?.body),void 0):void 0,responseBody:y,error:Jo(p)}),m}catch(m){throw u({status:0,ok:false,error:Tc(m)}),m}},()=>{window.fetch=i;}):()=>{}}function Tc(e){if(e?.name==="AbortError")return "aborted";let r=String(e?.message||"").toLowerCase();return r.includes("cors")?"cors":r.includes("timeout")?"timeout":"network"}function kc(e,t,r){let i=XMLHttpRequest.prototype,n=i.open,o=i.send,l=i.setRequestHeader,d=new WeakMap;return i.open=function(a,h,...s){let f=String(h);return d.set(this,{method:String(a).toUpperCase(),rawUrl:f,url:Jt(f),startT:0,perfStart:0,reqHeaders:{}}),n.apply(this,[a,h,...s])},i.setRequestHeader=function(a,h){let s=d.get(this);if(s){let f=a.toLowerCase();e.config.redactHeaders.map(c=>c.toLowerCase()).includes(f)?s.reqHeaders[f]="redacted":Xo.has(f)&&(s.reqHeaders[f]=h);}return l.apply(this,[a,h])},i.send=function(a){let h=d.get(this);if(h){if(h.startT=e.clock.now(),h.perfStart=Ko(),e.config.captureNetworkBodies&&(h.body=ea(a)),Zn(h.rawUrl,e.config))try{let f=h.reqHeaders.traceparent;if(f)h.traceId=Qn(f)??void 0;else {let c=Kn();this.setRequestHeader("traceparent",c.header),h.traceId=c.traceId;}}catch{}let s=f=>{let c=e.clock.now(),u={startT:h.startT,endT:c,duration:c-h.startT},m=this.status,p=Oc(e,this.getAllResponseHeaders()),g;if(e.config.captureNetworkBodies&&Qo(this.getResponseHeader("content-type")))try{(this.responseType===""||this.responseType==="text")&&(g=Xt(this.responseText,this.getResponseHeader("content-type")||void 0));}catch{}let S=Ac(this);e.markActivity(),t.resolve(h.rawUrl,h.perfStart,u).then(y=>{let b={id:$(),sessionId:e.sessionId,type:"network",t:h.startT,ts:e.clock.wall(),initiator:"xhr",method:h.method,url:h.url,status:m,ok:m>=200&&m<400,resourceType:"xhr",requestHeaders:h.reqHeaders,traceId:h.traceId,responseHeaders:p,responseSize:S,requestBody:e.config.captureNetworkBodies?Xt(h.body,void 0):void 0,responseBody:g,timing:y,error:f||Jo(m)};r(b);});};this.addEventListener("loadend",()=>s()),this.addEventListener("error",()=>s("network")),this.addEventListener("timeout",()=>s("timeout")),this.addEventListener("abort",()=>s("aborted"));}return o.apply(this,[a])},()=>{i.open=n,i.send=o,i.setRequestHeader=l;}}function Ac(e){try{if(e.responseType===""||e.responseType==="text")return new Blob([e.responseText]).size}catch{}let t=e.getResponseHeader("content-length");return t?Number(t):void 0}function Oc(e,t){let r=[];for(let i of t.trim().split(/[\r\n]+/)){let n=i.indexOf(":");n>0&&r.push([i.slice(0,n).trim(),i.slice(n+1).trim()]);}return ei(e.config.redactHeaders,r)}function Dc(e,t){let r=navigator.sendBeacon;return r?(navigator.sendBeacon=function(i,n){let o=e.clock.now(),l=false;try{l=r.call(navigator,i,n);}finally{let d=String(i);if(!d.includes("/v1/batch")){let a={id:$(),sessionId:e.sessionId,type:"network",t:o,ts:e.clock.wall(),initiator:"beacon",method:"POST",url:Jt(d),status:l?202:0,ok:l,resourceType:"other",timing:{startT:o,endT:e.clock.now(),duration:0},error:l?void 0:"network"};t(a);}}return l},()=>{navigator.sendBeacon=r;}):()=>{}}var Lc={script:"script",link:"stylesheet",css:"stylesheet",img:"image",image:"image",font:"font",audio:"media",video:"media",track:"media"};function Pc(e,t){if(typeof PerformanceObserver>"u")return ()=>{};let r;try{r=new PerformanceObserver(i=>{for(let n of i.getEntries()){let o=n.initiatorType;if(o==="fetch"||o==="xmlhttprequest"||o==="beacon")continue;let l=Lc[o]||"other",d=e.clock.fromPerf(n.startTime),a=e.clock.fromPerf(n.responseEnd||n.startTime),h={startT:d,endT:a,duration:Math.max(0,a-d),dns:ft(n.domainLookupEnd-n.domainLookupStart),tcp:ft(n.connectEnd-n.connectStart),tls:n.secureConnectionStart?ft(n.connectEnd-n.secureConnectionStart):void 0,ttfb:ft(n.responseStart-n.requestStart),download:ft(n.responseEnd-n.responseStart)},s={id:$(),sessionId:e.sessionId,type:"network",t:d,ts:e.clock.wall(),initiator:"resource",method:"GET",url:Jt(n.name),status:n.responseStatus||200,ok:!n.responseStatus||n.responseStatus<400,resourceType:l,responseSize:n.transferSize||n.encodedBodySize||void 0,timing:h};t(s);}}),r.observe({type:"resource",buffered:!0});}catch{return ()=>{}}return ()=>r?.disconnect()}function ft(e){return Number.isFinite(e)&&e>0?Math.round(e):void 0}function Qo(e){return e?/json|text|xml|x-www-form-urlencoded/i.test(e):false}function ea(e){if(e!=null){if(typeof e=="string")return e;if(e instanceof URLSearchParams)return e.toString();if(e instanceof FormData){let t={};return e.forEach((r,i)=>t[i]=typeof r=="string"?r:"\xABfile\xBB"),JSON.stringify(t)}try{return JSON.stringify(e)}catch{return}}}function _c(e){return e?e instanceof Headers?e.entries():Array.isArray(e)?e:Object.entries(e):[]}var Kt=4*1024,Fc=20,Uc=40;function Bc(e){try{let t=new URL(e,location.href);return t.search&&(t.search="?\u2026"),t.toString()}catch{return e.split("?")[0]??e}}function qc(e){try{return new TextEncoder().encode(e).length}catch{return e.length}}function zc(e,t){if(typeof e=="string"){let i={encoding:"text",size:qc(e)};if(t){let n=e.length>Kt*2?e.slice(0,Kt*2):e,o=ge(n),l=n!==e||o.length>Kt;i.body={preview:l?o.slice(0,Kt):o,truncated:l,redacted:o!==n};}return i}let r=0;return typeof Blob<"u"&&e instanceof Blob?r=e.size:(e instanceof ArrayBuffer||ArrayBuffer.isView(e))&&(r=e.byteLength),{encoding:"binary",size:r}}function ta(e){let t=typeof window<"u"?window.WebSocket:void 0;if(!t)return ()=>{};let r=n=>{try{let o={id:$(),sessionId:e.sessionId,type:"ws",t:e.clock.now(),ts:e.clock.wall(),...n};e.emit(o);}catch{}};class i extends t{constructor(o,l){super(o,l);try{let d=$(),a=Bc(String(o)),h=l?Array.isArray(l)?l:[l]:void 0,s=e.config.captureNetworkBodies,f=Yt(Fc,Uc),c=0,u=(p,g)=>{if(e.markActivity(),!f.take()){c++;return}let S=zc(g,s),y=c;c=0,r({connId:d,url:a,kind:"message",dir:p,...S,droppedFrames:y||void 0});};this.addEventListener("open",()=>r({connId:d,url:a,kind:"open",protocols:h})),this.addEventListener("close",p=>r({connId:d,url:a,kind:"close",code:p.code,reason:p.reason||void 0,wasClean:p.wasClean,droppedFrames:c||void 0})),this.addEventListener("error",()=>r({connId:d,url:a,kind:"error"})),this.addEventListener("message",p=>u("recv",p.data));let m=super.send.bind(this);this.send=p=>{m(p);try{u("send",p);}catch{}};}catch{}}}return window.WebSocket=i,()=>{window.WebSocket=t;}}function ra(e){function t(n){let o={id:$(),sessionId:e.sessionId,type:"error",t:e.clock.now(),ts:e.clock.wall(),name:n.name,message:ge(n.message),stack:n.stack?ge(n.stack):void 0,source:n.source,handled:n.handled};e.emit(o),e.emit(jo(e,o));}let r=n=>{let o=n.error;t({name:o?.name||"Error",message:o?.message||n.message||"Unknown error",stack:o?.stack,source:{url:n.filename,line:n.lineno,col:n.colno},handled:false});},i=n=>{let o=n.reason;o instanceof Error?t({name:o.name,message:o.message,stack:o.stack,source:Gt(o.stack),handled:false}):t({name:"UnhandledRejection",message:typeof o=="string"?o:$c(o),handled:false});};return window.addEventListener("error",r,true),window.addEventListener("unhandledrejection",i,true),()=>{window.removeEventListener("error",r,true),window.removeEventListener("unhandledrejection",i,true);}}function $c(e){try{return JSON.stringify(e)??String(e)}catch{return String(e)}}function Wc(e,t){let i={LCP:[2500,4e3],INP:[200,500],CLS:[.1,.25],FCP:[1800,3e3],TTFB:[800,1800]}[e];if(i)return t<=i[0]?"good":t<=i[1]?"needs-improvement":"poor"}function na(e){if(typeof PerformanceObserver>"u")return ()=>{};let t=[],r=(h,s,f)=>{let c={id:$(),sessionId:e.sessionId,type:"perf",t:e.clock.now(),ts:e.clock.wall(),metric:h,value:Math.round(s*1e3)/1e3,rating:Wc(h,s),detail:f};e.emit(c);},i=(h,s,f)=>{try{let c=new PerformanceObserver(u=>s(u.getEntries()));c.observe({type:h,buffered:!0,...f}),t.push(c);}catch{}};i("paint",h=>{for(let s of h)s.name==="first-contentful-paint"&&r("FCP",s.startTime);});let n=0;i("largest-contentful-paint",h=>{let s=h[h.length-1];s&&(n=s.startTime);});let o=0;i("layout-shift",h=>{for(let s of h)s.hadRecentInput||(o+=s.value);});let l=0;i("event",h=>{for(let s of h)s.duration>l&&(l=s.duration);},{durationThreshold:40}),i("navigation",h=>{let s=h[0];s&&(r("TTFB",s.responseStart),r("navigation",s.duration,{domInteractive:Math.round(s.domInteractive),domComplete:Math.round(s.domComplete),loadEvent:Math.round(s.loadEventEnd)}));});let d=()=>{n&&r("LCP",n),r("CLS",o),l&&r("INP",l);},a=()=>{document.visibilityState==="hidden"&&d();};return document.addEventListener("visibilitychange",a,true),()=>{t.forEach(h=>h.disconnect()),document.removeEventListener("visibilitychange",a,true);}}var ia=1e3,Hc=3,jc=3e3;function Vc(e){if(!e)return false;let t=e;for(let r=0;r<4&&t;r++){let i=t.tagName.toLowerCase();if(["a","button","input","select","textarea","label","summary"].includes(i)||t.getAttribute("role")==="button"||t.hasAttribute("onclick")||t.getAttribute("contenteditable")==="true")return true;t=t.parentElement;}return false}function sa(e){let t=[],r=-1/0,i=(o,l,d)=>{let a={id:$(),sessionId:e.sessionId,type:"custom",t:d,ts:e.clock.wall(),name:o,props:l};e.emit(a);},n=o=>{let l=o.target;if(!l||!(l instanceof Element))return;let d=e.clock.now(),a=Be(l);{let s=l.getBoundingClientRect(),f=s.width>0?Math.min(1,Math.max(0,(o.clientX-s.left)/s.width)):.5,c=s.height>0?Math.min(1,Math.max(0,(o.clientY-s.top)/s.height)):.5,u=(l.textContent||"").replace(/\s+/g," ").trim().slice(0,40);i("_click",{selector:a,path:location.pathname,vw:window.innerWidth,vh:window.innerHeight,rx:Math.round(f*1e3)/1e3,ry:Math.round(c*1e3)/1e3,tag:l.tagName.toLowerCase(),label:u},d);}t=t.filter(s=>d-s.t<=ia),t.push({el:l,t:d});let h=t.filter(s=>s.el===l);if(h.length>=Hc&&d-r>ia&&(r=d,i("rage_click",{selector:a,count:h.length},d)),!Vc(l)){let s=e.lastActivityT();window.setTimeout(()=>{e.lastActivityT()<=Math.max(s,d)&&i("dead_click",{selector:a},d);},jc);}};return window.addEventListener("click",n,true),()=>window.removeEventListener("click",n,true)}var la=new Set(["INPUT","TEXTAREA","SELECT"]),Gc=new Set(["hidden","submit","button","reset","image","file"]),oa=80,ti=60,Yc=3e5,Xc=100;function Jc(e){return !(!(e instanceof HTMLElement)||!la.has(e.tagName)||e instanceof HTMLInputElement&&Gc.has(e.type))}function Kc(e){return e instanceof HTMLTextAreaElement?"textarea":e instanceof HTMLSelectElement?"select":e.type||"text"}function Zc(e){return e instanceof HTMLInputElement?e.type==="checkbox"||e.type==="radio"?e.checked:e.value.trim().length>0:e instanceof HTMLSelectElement?e.value!=="":e.value.trim().length>0}function ue(e){let t=e.trim().replace(/\s+/g," ");return t.length>oa?t.slice(0,oa):t}function Qc(e){let t=e.getAttribute("name");if(t)return ue(t);if(e.id)return ue(e.id);let r=e.getAttribute("aria-label");if(r)return ue(r);let i=e.getAttribute("aria-labelledby");if(i){let o=i.split(/\s+/).map(l=>e.ownerDocument.getElementById(l)?.textContent||"").join(" ").trim();if(o)return ue(o)}if(e.labels&&e.labels.length){let o=e.labels[0].textContent?.trim();if(o)return ue(o)}let n=e.getAttribute("placeholder");return ue(n||Be(e))}function Ae(e){if(!e)return;let t=e.trim().replace(/\s+/g," ");if(t)return t.length>ti?t.slice(0,ti):t}function ef(e){if(e.labels&&e.labels.length){let n=Ae(e.labels[0].textContent);if(n)return n}let t=Ae(e.getAttribute("aria-label"));if(t)return t;let r=e.previousElementSibling;for(let n=0;r&&n<3;n++,r=r.previousElementSibling){if(la.has(r.tagName)||/^(BUTTON|SCRIPT|STYLE|SVG)$/.test(r.tagName))continue;let o=Ae(r.textContent);if(o)return o}let i=e.parentElement;if(i){let n=Ae(Array.from(i.childNodes).filter(l=>l.nodeType===3).map(l=>l.textContent||"").join(" "));if(n)return n;let o=Ae(i.querySelector("label,legend")?.textContent);if(o)return o}return Ae(e.getAttribute("placeholder"))}function tf(e){let t=e.closest('form,fieldset,section,[role="form"],[role="group"]');if(t){let r=Ae(t.querySelector('legend,h1,h2,h3,h4,[role="heading"]')?.textContent);if(r)return r;let i=Ae(t.getAttribute("aria-label"));if(i)return i}return Ae(typeof document<"u"?document.title:void 0)}function rf(e){let t={},r=(e.getAttribute("autocomplete")||"").trim().toLowerCase();r&&r!=="off"&&r!=="on"&&(t.autocomplete=r.slice(0,ti));let i=ef(e);i&&(t.near=i);let n=tf(e);return n&&(t.formTitle=n),t}function aa(e){let t=e.form;if(t){if(t.getAttribute("name"))return ue(t.getAttribute("name"));if(t.id)return ue(t.id);let r=t.getAttribute("aria-label");if(r)return ue(r);let i=t.getAttribute("action");if(i)try{return ue(new URL(i,location.href).pathname)}catch{return ue(i)}return ue(Be(t))}return ue(`page:${location.pathname}`)}function ua(e){let t=e.config.blockSelector,r=null,i=(s,f)=>{let c={id:$(),sessionId:e.sessionId,type:"custom",t:e.clock.now(),ts:e.clock.wall(),name:s,props:f};e.emit(c);},n=s=>{try{return !!t&&!!s.closest(t)}catch{return false}},o=()=>{if(!r)return;let{el:s,start:f,changed:c}=r;r=null;let u=Math.min(Yc,Math.max(0,e.clock.now()-f));u<Xc&&!c||i("form_field",{form:aa(s),field:Qc(s),type:Kc(s),ms:u,changed:c,filled:Zc(s),...rf(s)});},l=s=>{let f=s.target;!Jc(f)||n(f)||(r&&r.el!==f&&o(),r={el:f,start:e.clock.now(),changed:false});},d=s=>{r&&s.target===r.el&&(r.changed=true);},a=s=>{r&&s.target===r.el&&o();},h=s=>{let f=s.target;if(!(f instanceof HTMLFormElement)||n(f))return;o();let c=f.querySelector("input,textarea,select"),u=c&&!n(c)?aa(c):ue(f.getAttribute("name")||f.id||Be(f));i("form_submit",{form:u});};return document.addEventListener("focusin",l,true),document.addEventListener("focusout",a,true),document.addEventListener("input",d,true),document.addEventListener("submit",h,true),window.addEventListener("pagehide",o,true),()=>{o(),document.removeEventListener("focusin",l,true),document.removeEventListener("focusout",a,true),document.removeEventListener("input",d,true),document.removeEventListener("submit",h,true),window.removeEventListener("pagehide",o,true);}}function ca(e){let t=location.pathname,r=0,i=false,n=(a,h,s)=>{let f={id:$(),sessionId:e.sessionId,type:"custom",t:e.clock.now(),ts:e.clock.wall(),name:"_scroll",props:{path:t,depth:a,h,vh:s}};e.emit(f);},o=()=>{let a=document.documentElement,h=document.body;return Math.max(a.scrollHeight,h?h.scrollHeight:0,a.clientHeight)||1},l=()=>{i=false,location.pathname!==t&&(t=location.pathname,r=0);let a=window.innerHeight||document.documentElement.clientHeight||1,h=o(),s=Math.min(1,(window.scrollY+a)/h),f=Math.min(100,Math.round(s*10)*10);f>r&&(r=f,n(f,h,a));},d=()=>{i||(i=true,requestAnimationFrame(l));};return window.addEventListener("scroll",d,{passive:true,capture:true}),l(),()=>{window.removeEventListener("scroll",d,true);}}function fa(e){let t=null,r=()=>{let d=location.hash;return location.pathname+(d.startsWith("#/")?d:"")},i=()=>{let d=r();if(d===t)return;let a=t??"";t=d;let h={id:$(),sessionId:e.sessionId,type:"pageview",t:e.clock.now(),ts:e.clock.wall(),url:location.href,path:d,title:document.title||void 0,referrer:a||void 0};e.emit(h),e.markActivity();},n=history.pushState,o=history.replaceState,l=d=>function(h,s,f){let c=d.call(this,h,s,f);return queueMicrotask(i),c};return history.pushState=l(n),history.replaceState=l(o),window.addEventListener("popstate",i),window.addEventListener("hashchange",i),i(),()=>{history.pushState=n,history.replaceState=o,window.removeEventListener("popstate",i),window.removeEventListener("hashchange",i);}}function nf(e){let t=/\.([A-Za-z0-9_-]+)/.exec(e||"");return ["obsrviq-block",t&&t[1]?t[1]:""].filter(Boolean).join(" ")}function ha(e){let t=document.createElement("div");t.className=nf(e),t.setAttribute("data-obsrviq-ui",""),t.style.cssText="all:initial";let r=t.attachShadow({mode:"open"});return {host:t,root:r}}function da(e,t){try{let r=new CSSStyleSheet;r.replaceSync(t),e.adoptedStyleSheets=[r];}catch{let r=document.createElement("style");r.textContent=t,e.appendChild(r);}}function pa(e){(document.body||document.documentElement).appendChild(e);}var ri="#6e76f1",sf=`
130
130
  :host { all: initial; }
131
131
  .card {
132
132
  position: fixed; bottom: 20px; right: 20px; z-index: 2147483647;
@@ -140,7 +140,7 @@ or you can use record.mirror to access the mirror instance during recording.`,Os
140
140
  }
141
141
  .card.in { opacity: 1; transform: none; }
142
142
  .dot { grid-area: dot; width: 9px; height: 9px; margin-top: 5px; border-radius: 50%;
143
- background: ${ti}; box-shadow: 0 0 0 4px rgba(110,118,241,.18); }
143
+ background: ${ri}; box-shadow: 0 0 0 4px rgba(110,118,241,.18); }
144
144
  .txt { grid-area: txt; min-width: 0; }
145
145
  .title { font-size: 13.5px; font-weight: 600; line-height: 1.35; }
146
146
  .body { margin-top: 3px; font-size: 12px; line-height: 1.45; color: #a9adbe; }
@@ -149,12 +149,12 @@ button { font: inherit; font-size: 12.5px; font-weight: 600; padding: 7px 15px;
149
149
  cursor: pointer; border: 1px solid transparent; transition: background .15s ease, color .15s ease; }
150
150
  .deny { background: transparent; color: #a9adbe; border-color: rgba(255,255,255,.14); }
151
151
  .deny:hover { color: #f4f5fb; background: rgba(255,255,255,.05); }
152
- .allow { background: ${ti}; color: #fff; }
152
+ .allow { background: ${ri}; color: #fff; }
153
153
  .allow:hover { background: #5a62e0; }
154
- button:focus-visible { outline: 2px solid ${ti}; outline-offset: 2px; }
154
+ button:focus-visible { outline: 2px solid ${ri}; outline-offset: 2px; }
155
155
  @media (prefers-reduced-motion: reduce) { .card { transition: none; } }
156
156
  @media (max-width: 480px) { .card { left: 16px; right: 16px; bottom: 16px; max-width: none; } }
157
- `,nf=`
157
+ `,of=`
158
158
  :host { all: initial; }
159
159
  .recdot {
160
160
  position: fixed; bottom: 16px; right: 16px; z-index: 2147483647;
@@ -168,7 +168,7 @@ button:focus-visible { outline: 2px solid ${ti}; outline-offset: 2px; }
168
168
  100% { box-shadow: 0 0 0 0 rgba(239,68,68,0); }
169
169
  }
170
170
  @media (prefers-reduced-motion: reduce) { .recdot { animation: none; } }
171
- `;function pa(e,t,r,i){let{host:n,root:o}=fa(e);ha(o,rf);let l=t??{},p=document.createElement("div");p.className="card",p.setAttribute("role","dialog"),p.setAttribute("aria-label",l.title||"Session recording consent");let a=document.createElement("div");a.className="dot",a.setAttribute("aria-hidden","true");let h=document.createElement("div");h.className="txt";let s=document.createElement("div");s.className="title",s.textContent=l.title||"We record this session to improve the experience.";let f=document.createElement("div");f.className="body",f.textContent=l.body||"No passwords or typed input are captured.",h.append(s,f);let c=document.createElement("div");c.className="actions";let u=document.createElement("button");u.type="button",u.className="deny",u.textContent=l.deny||"Decline";let m=document.createElement("button");m.type="button",m.className="allow",m.textContent=l.allow||"Allow",c.append(u,m),p.append(a,h,c),o.appendChild(p),da(n),requestAnimationFrame(()=>p.classList.add("in"));let d=false,g=()=>{n.parentNode&&n.parentNode.removeChild(n);},S=y=>()=>{d||(d=true,g(),y());};return m.addEventListener("click",S(r)),u.addEventListener("click",S(i)),g}function ma(e){let{host:t,root:r}=fa(e);ha(r,nf);let i=document.createElement("div");return i.className="recdot",i.setAttribute("role","status"),i.setAttribute("aria-label","Session recording in progress"),r.appendChild(i),da(t),()=>{t.parentNode&&t.parentNode.removeChild(t);}}var ga="obsrviq.visitor",ri="obsrviq.session";function ya(){let e=ba(ri);if(!e)return null;try{let t=JSON.parse(e);if(t&&typeof t.id=="string"&&t.id&&typeof t.startedAt=="number")return {id:t.id,startedAt:t.startedAt,lastActivity:typeof t.lastActivity=="number"?t.lastActivity:t.startedAt,seq:typeof t.seq=="number"&&t.seq>=0?t.seq:0,lastT:typeof t.lastT=="number"&&t.lastT>=0?t.lastT:void 0,userId:typeof t.userId=="string"?t.userId:void 0}}catch{}return null}function va(e){Sa(ri,JSON.stringify(e));}function wa(){if(!(typeof window>"u"))try{window.localStorage.removeItem(ri);}catch{}}function ba(e){if(typeof window>"u")return null;try{return window.localStorage.getItem(e)}catch{return null}}function Sa(e,t){if(!(typeof window>"u"))try{window.localStorage.setItem(e,t);}catch{}}function Ca(e){let t=null,r=ba(ga);if(r)try{let n=JSON.parse(r);n&&typeof n.id=="string"&&n.id&&(t={id:n.id,firstSeenAt:typeof n.firstSeenAt=="number"?n.firstSeenAt:e,lastSeenAt:typeof n.lastSeenAt=="number"?n.lastSeenAt:e,visits:typeof n.visits=="number"&&n.visits>0?n.visits:1});}catch{}let i=t?{...t,visits:t.visits+1,lastSeenAt:e}:{id:$(),firstSeenAt:e,lastSeenAt:e,visits:1};return Sa(ga,JSON.stringify(i)),i}var sf={maskAllInputs:true,blockSelector:".obsrviq-block",noPrivacy:false,captureNetworkBodies:false,redactHeaders:["authorization","cookie","set-cookie"],tracePropagation:false,traceHosts:[],sampleRate:1,recordCanvas:false,endpoint:"https://in.lumera.app",flushIntervalMs:5e3,continueSession:false,sessionTimeoutMs:1800*1e3,requireConsent:false,askPermission:false,showRecording:false,autoStart:true,maxArgBytes:8*1024},ni=class{constructor(){this.config=null;this.clock=null;this.transport=null;this.teardowns=[];this.meta=null;this.recording=false;this.consent=null;this.sampledIn=true;this.manualStartRequested=false;this.lastActivity=0;this.nextSeq=0;this.openTasks=new Map;this.consentUnmount=null;this.recDotUnmount=null;this.diag={recording:false,sessionId:null,flushes:0,bytesSent:0,eventsSent:0,eventsQueued:0};}get sessionId(){return this.diag.sessionId}init(t){if(this.config)return;if(!t.siteKey){console.warn("[obsrviq] init() called without siteKey \u2014 recording disabled.");return}this.config={...sf,...of(t)},this.config.noPrivacy&&t.maskAllInputs===void 0&&(this.config.maskAllInputs=false),this.config.askPermission&&(this.config.requireConsent=true);let r=Array.isArray(t.maskKeys)?t.maskKeys:[];if(ur(r),this.loadRemoteMaskKeys(r),this.startSession(),t.userId!=null&&this.applyUserId(t.userId),t.metadata&&this.meta&&(this.meta.metadata={...t.metadata}),Xn()){this.consent=false;return}this.config.requireConsent?this.config.askPermission&&(this.consentUnmount=pa(this.config.blockSelector,this.config.consentText,()=>this.setConsent(true),()=>this.setConsent(false))):this.maybeStart();}async loadRemoteMaskKeys(t){let r=this.config;if(!r||typeof fetch>"u"){cr();return}try{let i=new AbortController,n=setTimeout(()=>i.abort(),2e3);try{let o=`${r.endpoint.replace(/\/$/,"")}/v1/config?key=${encodeURIComponent(r.siteKey)}`,l=await fetch(o,{credentials:"omit",mode:"cors",signal:i.signal});if(l.ok){let p=await l.json(),a=Array.isArray(p.maskKeys)?p.maskKeys.filter(h=>typeof h=="string"):[];ur([...t,...a]);}}finally{clearTimeout(n);}}catch{}finally{cr();}}startSession(t=true){let r=this.config,i=Date.now(),n=null;if(r.continueSession){let l=ya();l&&i-l.lastActivity<r.sessionTimeoutMs&&!(r.userId!=null&&l.userId!=null&&l.userId!==String(r.userId))&&(n=l);}let o=n?n.id:$();this.clock=n?new ct(n.startedAt,n.lastT):new ct,this.currentUserId=n?.userId??(t&&r.userId!=null?String(r.userId):void 0),this.nextSeq=n?n.seq:0,this.diag.sessionId=o,this.meta={startedAt:this.clock.startedAt,entryUrl:location.href,device:Fo()},this.sampledIn=n?true:Math.random()<(r.sampleRate??1),this.transport=new gt({endpoint:r.endpoint,siteKey:r.siteKey,sessionId:o,getMeta:()=>this.meta??void 0,beforeSend:r.beforeSend,flushIntervalMs:r.flushIntervalMs,startSeq:this.nextSeq,onSeqDispatch:l=>{this.nextSeq=l,this.persistSession();},onDomDrop:()=>Bo(),onFlush:({bytes:l,events:p,ok:a})=>{a&&(this.diag.flushes++,this.diag.bytesSent+=l,this.diag.eventsSent+=p);}}),this.recording=false,this.diag.recording=false;}persistSession(){!this.config?.continueSession||!this.recording||!this.clock||!this.diag.sessionId||va({id:this.diag.sessionId,startedAt:this.clock.startedAt,lastActivity:Date.now(),seq:this.nextSeq,lastT:this.clock.now(),userId:this.currentUserId});}maybeStart(){if(this.recording||!this.config||!this.clock||!this.transport||this.config.autoStart===false&&!this.manualStartRequested||this.config.requireConsent&&this.consent!==true||this.consent===false||!this.sampledIn)return;if(this.meta&&this.meta.visitorId==null){let r=Ca(Date.now());this.meta.visitorId=r.id,this.meta.visitCount=r.visits,this.meta.firstSeenAt=r.firstSeenAt;}let t={clock:this.clock,sessionId:this.diag.sessionId,config:this.config,emit:r=>{this.transport.enqueue(r),this.diag.eventsQueued++;},markActivity:()=>{this.lastActivity=this.clock.now();},lastActivityT:()=>this.lastActivity};this.transport.start(),this.teardowns.push(Wo(t)),this.teardowns.push(Ko(t)),this.teardowns.push(ea(t)),this.teardowns.push(ta(t)),this.teardowns.push(ra(t)),this.teardowns.push(ia(t)),this.teardowns.push(la(t)),this.teardowns.push(ua(t)),this.teardowns.push(ca(t)),this.teardowns.push(Uo(t)),this.recording=true,this.diag.recording=true,this.persistSession(),this.config.showRecording&&!this.recDotUnmount&&(this.recDotUnmount=ma(this.config.blockSelector));}identify(t,r){if(!this.meta)return;let i=String(t);this.config?.continueSession&&this.currentUserId!=null&&this.currentUserId!==i&&this.reset(),this.currentUserId=i,this.applyUserId(i),r&&this.mergeMetadata(r),this.track("identify",{hasTraits:!!r}),this.flush(),this.persistSession();}setMetadata(t){this.meta&&(this.mergeMetadata(t),this.track("metadata",{keys:Object.keys(t)}),this.flush());}reset(){if(!this.config)return;let t=this.recording;this.recording&&this.teardown(),wa(),this.currentUserId=void 0,this.startSession(false),t&&this.consent!==false&&!Xn()&&this.maybeStart();}applyUserId(t){let r=String(t);this.meta&&(this.meta.userId=r),_o(r).then(i=>{this.meta&&this.meta.userId===r&&(this.meta.identityHash=i);});}mergeMetadata(t){this.meta&&(this.meta.metadata={...this.meta.metadata??{},...t});}track(t,r){!this.recording||!this.clock||!this.transport||(this.transport.enqueue({id:$(),sessionId:this.diag.sessionId,type:"custom",t:this.clock.now(),ts:this.clock.wall(),name:t,props:r}),this.diag.eventsQueued++);}conversion(t,r){let i=String(t).trim();i&&this.track(i,{...r,conversion:true});}tag(...t){let r=t.map(i=>String(i).trim()).filter(Boolean);r.length&&(this.track("_tag",{tags:r}),this.flush());}startTask(t,r){let i=String(t).trim(),n=$(),o=this.clock?this.clock.now():0;return i&&(this.openTasks.set(i,{spanId:n,startT:o}),this.track(`${i}:started`,{...r,spanId:n,task:i})),{end:l=>this.endTask(i,l)}}endTask(t,r){let i=String(t).trim();if(!i)return;let n=this.openTasks.get(i);this.openTasks.delete(i);let o=n?.spanId??$();this.track(`${i}:ended`,{...r,spanId:o,task:i,...n?{startT:n.startT}:{}});}setConsent(t){this.consent=t,this.consentUnmount?.(),this.consentUnmount=null,t?this.maybeStart():this.recording&&this.teardown();}startRecording(){this.manualStartRequested=true,this.maybeStart();}stopRecording(){this.manualStartRequested=false,this.recording&&this.teardown();}stop(){this.teardown();}flush(){return this.transport?this.transport.flush("manual"):Promise.resolve(true)}getDiagnostics(){return {...this.diag}}teardown(){for(let t of this.teardowns.splice(0))try{t();}catch{}this.recDotUnmount?.(),this.recDotUnmount=null,this.transport?.stop(),this.recording=false,this.diag.recording=false;}};function of(e){let t={};for(let[r,i]of Object.entries(e))i!==void 0&&(t[r]=i);return t}var Zt=new ni;var pe=document.currentScript;function qe(e,t){return e==null?t:e==="true"||e==="1"}function ve(e,t){return e.getAttribute(`data-obsrviq-${t}`)??e.getAttribute(`data-lumera-${t}`)}if(pe){let e=ve(pe,"key");if(e){let t={siteKey:e,endpoint:ve(pe,"endpoint")||void 0,maskAllInputs:qe(ve(pe,"mask-inputs"),true),captureNetworkBodies:qe(ve(pe,"capture-bodies"),false),requireConsent:qe(ve(pe,"require-consent"),false),askPermission:qe(ve(pe,"ask-permission"),false),showRecording:qe(ve(pe,"show-recording"),false),recordCanvas:qe(ve(pe,"record-canvas"),false),autoStart:qe(ve(pe,"auto-start"),true)},r=ve(pe,"sample-rate");r&&(t.sampleRate=Number(r));let i=ve(pe,"user-id");i&&(t.userId=i);let n=ve(pe,"metadata");if(n)try{t.metadata=JSON.parse(n);}catch{console.warn("[obsrviq] data-obsrviq-metadata is not valid JSON \u2014 ignored.");}Zt.init(t);}}window.Obsrviq=Zt;window.Lumera=Zt;/*! Bundled license information:
171
+ `;function ma(e,t,r,i){let{host:n,root:o}=ha(e);da(o,sf);let l=t??{},d=document.createElement("div");d.className="card",d.setAttribute("role","dialog"),d.setAttribute("aria-label",l.title||"Session recording consent");let a=document.createElement("div");a.className="dot",a.setAttribute("aria-hidden","true");let h=document.createElement("div");h.className="txt";let s=document.createElement("div");s.className="title",s.textContent=l.title||"We record this session to improve the experience.";let f=document.createElement("div");f.className="body",f.textContent=l.body||"No passwords or typed input are captured.",h.append(s,f);let c=document.createElement("div");c.className="actions";let u=document.createElement("button");u.type="button",u.className="deny",u.textContent=l.deny||"Decline";let m=document.createElement("button");m.type="button",m.className="allow",m.textContent=l.allow||"Allow",c.append(u,m),d.append(a,h,c),o.appendChild(d),pa(n),requestAnimationFrame(()=>d.classList.add("in"));let p=false,g=()=>{n.parentNode&&n.parentNode.removeChild(n);},S=y=>()=>{p||(p=true,g(),y());};return m.addEventListener("click",S(r)),u.addEventListener("click",S(i)),g}function ga(e){let{host:t,root:r}=ha(e);da(r,of);let i=document.createElement("div");return i.className="recdot",i.setAttribute("role","status"),i.setAttribute("aria-label","Session recording in progress"),r.appendChild(i),pa(t),()=>{t.parentNode&&t.parentNode.removeChild(t);}}var ya="obsrviq.visitor",ni="obsrviq.session";function va(){let e=Sa(ni);if(!e)return null;try{let t=JSON.parse(e);if(t&&typeof t.id=="string"&&t.id&&typeof t.startedAt=="number")return {id:t.id,startedAt:t.startedAt,lastActivity:typeof t.lastActivity=="number"?t.lastActivity:t.startedAt,seq:typeof t.seq=="number"&&t.seq>=0?t.seq:0,lastT:typeof t.lastT=="number"&&t.lastT>=0?t.lastT:void 0,userId:typeof t.userId=="string"?t.userId:void 0}}catch{}return null}function wa(e){Ca(ni,JSON.stringify(e));}function ba(){if(!(typeof window>"u"))try{window.localStorage.removeItem(ni);}catch{}}function Sa(e){if(typeof window>"u")return null;try{return window.localStorage.getItem(e)}catch{return null}}function Ca(e,t){if(!(typeof window>"u"))try{window.localStorage.setItem(e,t);}catch{}}function Ea(e){let t=null,r=Sa(ya);if(r)try{let n=JSON.parse(r);n&&typeof n.id=="string"&&n.id&&(t={id:n.id,firstSeenAt:typeof n.firstSeenAt=="number"?n.firstSeenAt:e,lastSeenAt:typeof n.lastSeenAt=="number"?n.lastSeenAt:e,visits:typeof n.visits=="number"&&n.visits>0?n.visits:1});}catch{}let i=t?{...t,visits:t.visits+1,lastSeenAt:e}:{id:$(),firstSeenAt:e,lastSeenAt:e,visits:1};return Ca(ya,JSON.stringify(i)),i}var af={maskAllInputs:true,blockSelector:".obsrviq-block",noPrivacy:false,captureNetworkBodies:false,redactHeaders:["authorization","cookie","set-cookie"],tracePropagation:false,traceHosts:[],sampleRate:1,recordCanvas:false,endpoint:"https://in.lumera.app",flushIntervalMs:5e3,continueSession:false,sessionTimeoutMs:1800*1e3,requireConsent:false,askPermission:false,showRecording:false,autoStart:true,maxArgBytes:8*1024},ii=class{constructor(){this.config=null;this.clock=null;this.transport=null;this.teardowns=[];this.meta=null;this.recording=false;this.consent=null;this.sampledIn=true;this.manualStartRequested=false;this.lastActivity=0;this.nextSeq=0;this.openTasks=new Map;this.consentUnmount=null;this.recDotUnmount=null;this.diag={recording:false,sessionId:null,flushes:0,bytesSent:0,eventsSent:0,eventsQueued:0};}get sessionId(){return this.diag.sessionId}init(t){if(this.config)return;if(!t.siteKey){console.warn("[obsrviq] init() called without siteKey \u2014 recording disabled.");return}this.config={...af,...lf(t)},this.config.noPrivacy&&t.maskAllInputs===void 0&&(this.config.maskAllInputs=false),this.config.askPermission&&(this.config.requireConsent=true);let r=Array.isArray(t.maskKeys)?t.maskKeys:[];if(ur(r),this.loadRemoteMaskKeys(r),this.startSession(),t.userId!=null&&this.applyUserId(t.userId),t.metadata&&this.meta&&(this.meta.metadata={...t.metadata}),Xn()){this.consent=false;return}this.config.requireConsent?this.config.askPermission&&(this.consentUnmount=ma(this.config.blockSelector,this.config.consentText,()=>this.setConsent(true),()=>this.setConsent(false))):this.maybeStart();}async loadRemoteMaskKeys(t){let r=this.config;if(!r||typeof fetch>"u"){cr();return}try{let i=new AbortController,n=setTimeout(()=>i.abort(),2e3);try{let o=`${r.endpoint.replace(/\/$/,"")}/v1/config?key=${encodeURIComponent(r.siteKey)}`,l=await fetch(o,{credentials:"omit",mode:"cors",signal:i.signal});if(l.ok){let d=await l.json(),a=Array.isArray(d.maskKeys)?d.maskKeys.filter(h=>typeof h=="string"):[];ur([...t,...a]);}}finally{clearTimeout(n);}}catch{}finally{cr();}}startSession(t=true){let r=this.config,i=Date.now(),n=null;if(r.continueSession){let l=va();l&&i-l.lastActivity<r.sessionTimeoutMs&&!(r.userId!=null&&l.userId!=null&&l.userId!==String(r.userId))&&(n=l);}let o=n?n.id:$();this.clock=n?new ct(n.startedAt,n.lastT):new ct,this.currentUserId=n?.userId??(t&&r.userId!=null?String(r.userId):void 0),this.nextSeq=n?n.seq:0,this.diag.sessionId=o,this.meta={startedAt:this.clock.startedAt,entryUrl:location.href,device:Uo()},this.sampledIn=n?true:Math.random()<(r.sampleRate??1),this.transport=new gt({endpoint:r.endpoint,siteKey:r.siteKey,sessionId:o,getMeta:()=>this.meta??void 0,beforeSend:r.beforeSend,flushIntervalMs:r.flushIntervalMs,startSeq:this.nextSeq,onSeqDispatch:l=>{this.nextSeq=l,this.persistSession();},onDomDrop:()=>qo(),onFlush:({bytes:l,events:d,ok:a})=>{a&&(this.diag.flushes++,this.diag.bytesSent+=l,this.diag.eventsSent+=d);}}),this.recording=false,this.diag.recording=false;}persistSession(){!this.config?.continueSession||!this.recording||!this.clock||!this.diag.sessionId||wa({id:this.diag.sessionId,startedAt:this.clock.startedAt,lastActivity:Date.now(),seq:this.nextSeq,lastT:this.clock.now(),userId:this.currentUserId});}maybeStart(){if(this.recording||!this.config||!this.clock||!this.transport||this.config.autoStart===false&&!this.manualStartRequested||this.config.requireConsent&&this.consent!==true||this.consent===false||!this.sampledIn)return;if(this.meta&&this.meta.visitorId==null){let r=Ea(Date.now());this.meta.visitorId=r.id,this.meta.visitCount=r.visits,this.meta.firstSeenAt=r.firstSeenAt;}let t={clock:this.clock,sessionId:this.diag.sessionId,config:this.config,emit:r=>{this.transport.enqueue(r),this.diag.eventsQueued++;},markActivity:()=>{this.lastActivity=this.clock.now();},lastActivityT:()=>this.lastActivity};this.transport.start(),this.teardowns.push(Ho(t)),this.teardowns.push(Zo(t)),this.teardowns.push(ta(t)),this.teardowns.push(ra(t)),this.teardowns.push(na(t)),this.teardowns.push(sa(t)),this.teardowns.push(ua(t)),this.teardowns.push(ca(t)),this.teardowns.push(fa(t)),this.teardowns.push(Bo(t)),this.recording=true,this.diag.recording=true,this.persistSession(),this.config.showRecording&&!this.recDotUnmount&&(this.recDotUnmount=ga(this.config.blockSelector));}identify(t,r){if(!this.meta)return;let i=String(t);this.config?.continueSession&&this.currentUserId!=null&&this.currentUserId!==i&&this.reset(),this.currentUserId=i,this.applyUserId(i),r&&this.mergeMetadata(r),this.track("identify",{hasTraits:!!r}),this.flush(),this.persistSession();}setMetadata(t){this.meta&&(this.mergeMetadata(t),this.track("metadata",{keys:Object.keys(t)}),this.flush());}reset(){if(!this.config)return;let t=this.recording;this.recording&&this.teardown(),ba(),this.currentUserId=void 0,this.startSession(false),t&&this.consent!==false&&!Xn()&&this.maybeStart();}applyUserId(t){let r=String(t);this.meta&&(this.meta.userId=r),Fo(r).then(i=>{this.meta&&this.meta.userId===r&&(this.meta.identityHash=i);});}mergeMetadata(t){this.meta&&(this.meta.metadata={...this.meta.metadata??{},...t});}track(t,r){!this.recording||!this.clock||!this.transport||(this.transport.enqueue({id:$(),sessionId:this.diag.sessionId,type:"custom",t:this.clock.now(),ts:this.clock.wall(),name:t,props:r}),this.diag.eventsQueued++);}conversion(t,r){let i=String(t).trim();i&&this.track(i,{...r,conversion:true});}tag(...t){let r=t.map(i=>String(i).trim()).filter(Boolean);r.length&&(this.track("_tag",{tags:r}),this.flush());}startTask(t,r){let i=String(t).trim(),n=$(),o=this.clock?this.clock.now():0;return i&&(this.openTasks.set(i,{spanId:n,startT:o}),this.track(`${i}:started`,{...r,spanId:n,task:i})),{end:l=>this.endTask(i,l)}}endTask(t,r){let i=String(t).trim();if(!i)return;let n=this.openTasks.get(i);this.openTasks.delete(i);let o=n?.spanId??$();this.track(`${i}:ended`,{...r,spanId:o,task:i,...n?{startT:n.startT}:{}});}setConsent(t){this.consent=t,this.consentUnmount?.(),this.consentUnmount=null,t?this.maybeStart():this.recording&&this.teardown();}startRecording(){this.manualStartRequested=true,this.maybeStart();}stopRecording(){this.manualStartRequested=false,this.recording&&this.teardown();}stop(){this.teardown();}flush(){return this.transport?this.transport.flush("manual"):Promise.resolve(true)}getDiagnostics(){return {...this.diag}}teardown(){for(let t of this.teardowns.splice(0))try{t();}catch{}this.recDotUnmount?.(),this.recDotUnmount=null,this.transport?.stop(),this.recording=false,this.diag.recording=false;}};function lf(e){let t={};for(let[r,i]of Object.entries(e))i!==void 0&&(t[r]=i);return t}var Zt=new ii;var pe=document.currentScript;function qe(e,t){return e==null?t:e==="true"||e==="1"}function ve(e,t){return e.getAttribute(`data-obsrviq-${t}`)??e.getAttribute(`data-lumera-${t}`)}if(pe){let e=ve(pe,"key");if(e){let t={siteKey:e,endpoint:ve(pe,"endpoint")||void 0,maskAllInputs:qe(ve(pe,"mask-inputs"),true),captureNetworkBodies:qe(ve(pe,"capture-bodies"),false),requireConsent:qe(ve(pe,"require-consent"),false),askPermission:qe(ve(pe,"ask-permission"),false),showRecording:qe(ve(pe,"show-recording"),false),recordCanvas:qe(ve(pe,"record-canvas"),false),autoStart:qe(ve(pe,"auto-start"),true)},r=ve(pe,"sample-rate");r&&(t.sampleRate=Number(r));let i=ve(pe,"user-id");i&&(t.userId=i);let n=ve(pe,"metadata");if(n)try{t.metadata=JSON.parse(n);}catch{console.warn("[obsrviq] data-obsrviq-metadata is not valid JSON \u2014 ignored.");}Zt.init(t);}}window.Obsrviq=Zt;window.Lumera=Zt;/*! Bundled license information:
172
172
 
173
173
  rrweb/dist/rrweb.js:
174
174
  (*! *****************************************************************************