mixpanel-browser 2.62.0 → 2.63.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,39 +1,2 @@
1
- (function(){"use strict";var x;if(typeof window>"u"){var Pt={hostname:""};x={crypto:{randomUUID:function(){throw Error("unsupported")}},navigator:{userAgent:"",onLine:!0},document:{createElement:function(){return{}},location:Pt,referrer:""},screen:{width:0,height:0},location:Pt,addEventListener:function(){},removeEventListener:function(){}}}else x=window;var P;(function(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"})(P||(P={}));function Vr(e){return e.nodeType===e.ELEMENT_NODE}function Ee(e){const t=e?.host;return t?.shadowRoot===e}function Re(e){return Object.prototype.toString.call(e)==="[object ShadowRoot]"}function Jr(e){return e.includes(" background-clip: text;")&&!e.includes(" -webkit-background-clip: text;")&&(e=e.replace(" background-clip: text;"," -webkit-background-clip: text; background-clip: text;")),e}function Xr(e){const{cssText:t}=e;if(t.split('"').length<3)return t;const 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 ze(e){try{const t=e.rules||e.cssRules;return t?Jr(Array.from(t,Ft).join("")):null}catch{return null}}function Ft(e){let t;if(Qr(e))try{t=ze(e.styleSheet)||Xr(e)}catch{}else if(Yr(e)&&e.selectorText.includes(":"))return Kr(e.cssText);return t||e.cssText}function Kr(e){const t=/(\[(?:[\w-]+)[^\\])(:(?:[\w-]+)\])/gm;return e.replace(t,"$1\\$2")}function Qr(e){return"styleSheet"in e}function Yr(e){return"selectorText"in e}class Bt{constructor(){this.idNodeMap=new Map,this.nodeMetaMap=new WeakMap}getId(t){var r;if(!t)return-1;const n=(r=this.getMeta(t))===null||r===void 0?void 0:r.id;return n??-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){const r=this.getId(t);this.idNodeMap.delete(r),t.childNodes&&t.childNodes.forEach(n=>this.removeNodeFromMap(n))}has(t){return this.idNodeMap.has(t)}hasNode(t){return this.nodeMetaMap.has(t)}add(t,r){const n=r.id;this.idNodeMap.set(n,t),this.nodeMetaMap.set(t,r)}replace(t,r){const n=this.getNode(t);if(n){const i=this.nodeMetaMap.get(n);i&&this.nodeMetaMap.set(r,i)}this.idNodeMap.set(t,r)}reset(){this.idNodeMap=new Map,this.nodeMetaMap=new WeakMap}}function Zr(){return new Bt}function lt({element:e,maskInputOptions:t,tagName:r,type:n,value:i,maskInputFn:o}){let a=i||"";const u=n&&ce(n);return(t[r.toLowerCase()]||u&&t[u])&&(o?a=o(a,e):a="*".repeat(a.length)),a}function ce(e){return e.toLowerCase()}const Ut="__rrweb_original__";function en(e){const t=e.getContext("2d");if(!t)return!0;const r=50;for(let n=0;n<e.width;n+=r)for(let i=0;i<e.height;i+=r){const o=t.getImageData,a=Ut in o?o[Ut]:o;if(new Uint32Array(a.call(t,n,i,Math.min(r,e.width-n),Math.min(r,e.height-i)).data.buffer).some(s=>s!==0))return!1}return!0}function dt(e){const t=e.type;return e.hasAttribute("data-rr-is-password")?"password":t?ce(t):null}function Wt(e,t){var r;let n;try{n=new URL(e,t??window.location.href)}catch{return null}const i=/\.([0-9a-z]+)(?:$)/i,o=n.pathname.match(i);return(r=o?.[1])!==null&&r!==void 0?r:null}let tn=1;const rn=new RegExp("[^a-z0-9-_:]"),Oe=-2;function qt(){return tn++}function nn(e){if(e instanceof HTMLFormElement)return"form";const t=ce(e.tagName);return rn.test(t)?"div":t}function on(e){let t="";return e.indexOf("//")>-1?t=e.split("/").slice(0,3).join("/"):t=e.split("/")[0],t=t.split("?")[0],t}let ge,zt;const sn=/url\((?:(')([^']*)'|(")(.*?)"|([^)]*))\)/gm,an=/^(?:[a-z+]+:)?\/\//i,un=/^www\..*/i,cn=/^(data:)([^,]*),(.*)/i;function $e(e,t){return(e||"").replace(sn,(r,n,i,o,a,u)=>{const s=i||a||u,d=n||o||"";if(!s)return r;if(an.test(s)||un.test(s))return`url(${d}${s}${d})`;if(cn.test(s))return`url(${d}${s}${d})`;if(s[0]==="/")return`url(${d}${on(t)+s}${d})`;const l=t.split("/"),h=s.split("/");l.pop();for(const p of h)p!=="."&&(p===".."?l.pop():l.push(p));return`url(${d}${l.join("/")}${d})`})}const ln=/^[^ \t\n\r\u000c]+/,dn=/^[, \t\n\r\u000c]+/;function fn(e,t){if(t.trim()==="")return t;let r=0;function n(o){let a;const u=o.exec(t.substring(r));return u?(a=u[0],r+=a.length,a):""}const i=[];for(;n(dn),!(r>=t.length);){let o=n(ln);if(o.slice(-1)===",")o=ye(e,o.substring(0,o.length-1)),i.push(o);else{let a="";o=ye(e,o);let u=!1;for(;;){const s=t.charAt(r);if(s===""){i.push((o+a).trim());break}else if(u)s===")"&&(u=!1);else if(s===","){r+=1,i.push((o+a).trim());break}else s==="("&&(u=!0);a+=s,r+=1}}}return i.join(", ")}function ye(e,t){if(!t||t.trim()==="")return t;const r=e.createElement("a");return r.href=t,r.href}function hn(e){return!!(e.tagName==="svg"||e.ownerSVGElement)}function ft(){const e=document.createElement("a");return e.href="",e.href}function $t(e,t,r,n){return n&&(r==="src"||r==="href"&&!(t==="use"&&n[0]==="#")||r==="xlink:href"&&n[0]!=="#"||r==="background"&&(t==="table"||t==="td"||t==="th")?ye(e,n):r==="srcset"?fn(e,n):r==="style"?$e(n,ft()):t==="object"&&r==="data"?ye(e,n):n)}function Ht(e,t,r){return(e==="video"||e==="audio")&&t==="autoplay"}function pn(e,t,r){try{if(typeof t=="string"){if(e.classList.contains(t))return!0}else for(let n=e.classList.length;n--;){const i=e.classList[n];if(t.test(i))return!0}if(r)return e.matches(r)}catch{}return!1}function He(e,t,r){if(!e)return!1;if(e.nodeType!==e.ELEMENT_NODE)return r?He(e.parentNode,t,r):!1;for(let n=e.classList.length;n--;){const i=e.classList[n];if(t.test(i))return!0}return r?He(e.parentNode,t,r):!1}function jt(e,t,r,n){try{const i=e.nodeType===e.ELEMENT_NODE?e:e.parentElement;if(i===null)return!1;if(typeof t=="string"){if(n){if(i.closest(`.${t}`))return!0}else if(i.classList.contains(t))return!0}else if(He(i,t,n))return!0;if(r){if(n){if(i.closest(r))return!0}else if(i.matches(r))return!0}}catch{}return!1}function mn(e,t,r){const n=e.contentWindow;if(!n)return;let i=!1,o;try{o=n.document.readyState}catch{return}if(o!=="complete"){const u=setTimeout(()=>{i||(t(),i=!0)},r);e.addEventListener("load",()=>{clearTimeout(u),i=!0,t()});return}const a="about:blank";if(n.location.href!==a||e.src===a||e.src==="")return setTimeout(t,0),e.addEventListener("load",t);e.addEventListener("load",t)}function gn(e,t,r){let n=!1,i;try{i=e.sheet}catch{return}if(i)return;const o=setTimeout(()=>{n||(t(),n=!0)},r);e.addEventListener("load",()=>{clearTimeout(o),n=!0,t()})}function yn(e,t){const{doc:r,mirror:n,blockClass:i,blockSelector:o,needsMask:a,inlineStylesheet:u,maskInputOptions:s={},maskTextFn:d,maskInputFn:l,dataURLOptions:h={},inlineImages:p,recordCanvas:f,keepIframeSrcFn:g,newlyAddedElement:m=!1}=t,v=vn(r,n);switch(e.nodeType){case e.DOCUMENT_NODE:return e.compatMode!=="CSS1Compat"?{type:P.Document,childNodes:[],compatMode:e.compatMode}:{type:P.Document,childNodes:[]};case e.DOCUMENT_TYPE_NODE:return{type:P.DocumentType,name:e.name,publicId:e.publicId,systemId:e.systemId,rootId:v};case e.ELEMENT_NODE:return Sn(e,{doc:r,blockClass:i,blockSelector:o,inlineStylesheet:u,maskInputOptions:s,maskInputFn:l,dataURLOptions:h,inlineImages:p,recordCanvas:f,keepIframeSrcFn:g,newlyAddedElement:m,rootId:v});case e.TEXT_NODE:return bn(e,{needsMask:a,maskTextFn:d,rootId:v});case e.CDATA_SECTION_NODE:return{type:P.CDATA,textContent:"",rootId:v};case e.COMMENT_NODE:return{type:P.Comment,textContent:e.textContent||"",rootId:v};default:return!1}}function vn(e,t){if(!t.hasNode(e))return;const r=t.getId(e);return r===1?void 0:r}function bn(e,t){var r;const{needsMask:n,maskTextFn:i,rootId:o}=t,a=e.parentNode&&e.parentNode.tagName;let u=e.textContent;const s=a==="STYLE"?!0:void 0,d=a==="SCRIPT"?!0:void 0;if(s&&u){try{e.nextSibling||e.previousSibling||!((r=e.parentNode.sheet)===null||r===void 0)&&r.cssRules&&(u=ze(e.parentNode.sheet))}catch(l){console.warn(`Cannot get CSS styles from text's parentNode. Error: ${l}`,e)}u=$e(u,ft())}return d&&(u="SCRIPT_PLACEHOLDER"),!s&&!d&&u&&n&&(u=i?i(u,e.parentElement):u.replace(/[\S]/g,"*")),{type:P.Text,textContent:u||"",isStyle:s,rootId:o}}function Sn(e,t){const{doc:r,blockClass:n,blockSelector:i,inlineStylesheet:o,maskInputOptions:a={},maskInputFn:u,dataURLOptions:s={},inlineImages:d,recordCanvas:l,keepIframeSrcFn:h,newlyAddedElement:p=!1,rootId:f}=t,g=pn(e,n,i),m=nn(e);let v={};const w=e.attributes.length;for(let y=0;y<w;y++){const b=e.attributes[y];Ht(m,b.name,b.value)||(v[b.name]=$t(r,m,ce(b.name),b.value))}if(m==="link"&&o){const y=Array.from(r.styleSheets).find(I=>I.href===e.href);let b=null;y&&(b=ze(y)),b&&(delete v.rel,delete v.href,v._cssText=$e(b,y.href))}if(m==="style"&&e.sheet&&!(e.innerText||e.textContent||"").trim().length){const y=ze(e.sheet);y&&(v._cssText=$e(y,ft()))}if(m==="input"||m==="textarea"||m==="select"){const y=e.value,b=e.checked;v.type!=="radio"&&v.type!=="checkbox"&&v.type!=="submit"&&v.type!=="button"&&y?v.value=lt({element:e,type:dt(e),tagName:m,value:y,maskInputOptions:a,maskInputFn:u}):b&&(v.checked=b)}if(m==="option"&&(e.selected&&!a.select?v.selected=!0:delete v.selected),m==="canvas"&&l){if(e.__context==="2d")en(e)||(v.rr_dataURL=e.toDataURL(s.type,s.quality));else if(!("__context"in e)){const y=e.toDataURL(s.type,s.quality),b=document.createElement("canvas");b.width=e.width,b.height=e.height;const I=b.toDataURL(s.type,s.quality);y!==I&&(v.rr_dataURL=y)}}if(m==="img"&&d){ge||(ge=r.createElement("canvas"),zt=ge.getContext("2d"));const y=e,b=y.crossOrigin;y.crossOrigin="anonymous";const I=()=>{y.removeEventListener("load",I);try{ge.width=y.naturalWidth,ge.height=y.naturalHeight,zt.drawImage(y,0,0),v.rr_dataURL=ge.toDataURL(s.type,s.quality)}catch(U){console.warn(`Cannot inline img src=${y.currentSrc}! Error: ${U}`)}b?v.crossOrigin=b:y.removeAttribute("crossorigin")};y.complete&&y.naturalWidth!==0?I():y.addEventListener("load",I)}if(m==="audio"||m==="video"){const y=v;y.rr_mediaState=e.paused?"paused":"played",y.rr_mediaCurrentTime=e.currentTime,y.rr_mediaPlaybackRate=e.playbackRate,y.rr_mediaMuted=e.muted,y.rr_mediaLoop=e.loop,y.rr_mediaVolume=e.volume}if(p||(e.scrollLeft&&(v.rr_scrollLeft=e.scrollLeft),e.scrollTop&&(v.rr_scrollTop=e.scrollTop)),g){const{width:y,height:b}=e.getBoundingClientRect();v={class:v.class,rr_width:`${y}px`,rr_height:`${b}px`}}m==="iframe"&&!h(v.src)&&(e.contentDocument||(v.rr_src=v.src),delete v.src);let S;try{customElements.get(m)&&(S=!0)}catch{}return{type:P.Element,tagName:m,attributes:v,childNodes:[],isSVG:hn(e)||void 0,needBlock:g,rootId:f,isCustom:S}}function T(e){return e==null?"":e.toLowerCase()}function wn(e,t){if(t.comment&&e.type===P.Comment)return!0;if(e.type===P.Element){if(t.script&&(e.tagName==="script"||e.tagName==="link"&&(e.attributes.rel==="preload"||e.attributes.rel==="modulepreload")&&e.attributes.as==="script"||e.tagName==="link"&&e.attributes.rel==="prefetch"&&typeof e.attributes.href=="string"&&Wt(e.attributes.href)==="js"))return!0;if(t.headFavicon&&(e.tagName==="link"&&e.attributes.rel==="shortcut icon"||e.tagName==="meta"&&(T(e.attributes.name).match(/^msapplication-tile(image|color)$/)||T(e.attributes.name)==="application-name"||T(e.attributes.rel)==="icon"||T(e.attributes.rel)==="apple-touch-icon"||T(e.attributes.rel)==="shortcut icon")))return!0;if(e.tagName==="meta"){if(t.headMetaDescKeywords&&T(e.attributes.name).match(/^description|keywords$/))return!0;if(t.headMetaSocial&&(T(e.attributes.property).match(/^(og|twitter|fb):/)||T(e.attributes.name).match(/^(og|twitter):/)||T(e.attributes.name)==="pinterest"))return!0;if(t.headMetaRobots&&(T(e.attributes.name)==="robots"||T(e.attributes.name)==="googlebot"||T(e.attributes.name)==="bingbot"))return!0;if(t.headMetaHttpEquiv&&e.attributes["http-equiv"]!==void 0)return!0;if(t.headMetaAuthorship&&(T(e.attributes.name)==="author"||T(e.attributes.name)==="generator"||T(e.attributes.name)==="framework"||T(e.attributes.name)==="publisher"||T(e.attributes.name)==="progid"||T(e.attributes.property).match(/^article:/)||T(e.attributes.property).match(/^product:/)))return!0;if(t.headMetaVerification&&(T(e.attributes.name)==="google-site-verification"||T(e.attributes.name)==="yandex-verification"||T(e.attributes.name)==="csrf-token"||T(e.attributes.name)==="p:domain_verify"||T(e.attributes.name)==="verify-v1"||T(e.attributes.name)==="verification"||T(e.attributes.name)==="shopify-checkout-api-token"))return!0}}return!1}function ve(e,t){const{doc:r,mirror:n,blockClass:i,blockSelector:o,maskTextClass:a,maskTextSelector:u,skipChild:s=!1,inlineStylesheet:d=!0,maskInputOptions:l={},maskTextFn:h,maskInputFn:p,slimDOMOptions:f,dataURLOptions:g={},inlineImages:m=!1,recordCanvas:v=!1,onSerialize:w,onIframeLoad:S,iframeLoadTimeout:y=5e3,onStylesheetLoad:b,stylesheetLoadTimeout:I=5e3,keepIframeSrcFn:U=()=>!1,newlyAddedElement:B=!1}=t;let{needsMask:k}=t,{preserveWhiteSpace:N=!0}=t;!k&&e.childNodes&&(k=jt(e,a,u,k===void 0));const V=yn(e,{doc:r,mirror:n,blockClass:i,blockSelector:o,needsMask:k,inlineStylesheet:d,maskInputOptions:l,maskTextFn:h,maskInputFn:p,dataURLOptions:g,inlineImages:m,recordCanvas:v,keepIframeSrcFn:U,newlyAddedElement:B});if(!V)return console.warn(e,"not serialized"),null;let J;n.hasNode(e)?J=n.getId(e):wn(V,f)||!N&&V.type===P.Text&&!V.isStyle&&!V.textContent.replace(/^\s+|\s+$/gm,"").length?J=Oe:J=qt();const O=Object.assign(V,{id:J});if(n.add(e,O),J===Oe)return null;w&&w(e);let fe=!s;if(O.type===P.Element){fe=fe&&!O.needBlock,delete O.needBlock;const $=e.shadowRoot;$&&Re($)&&(O.isShadowHost=!0)}if((O.type===P.Document||O.type===P.Element)&&fe){f.headWhitespace&&O.type===P.Element&&O.tagName==="head"&&(N=!1);const $={doc:r,mirror:n,blockClass:i,blockSelector:o,needsMask:k,maskTextClass:a,maskTextSelector:u,skipChild:s,inlineStylesheet:d,maskInputOptions:l,maskTextFn:h,maskInputFn:p,slimDOMOptions:f,dataURLOptions:g,inlineImages:m,recordCanvas:v,preserveWhiteSpace:N,onSerialize:w,onIframeLoad:S,iframeLoadTimeout:y,onStylesheetLoad:b,stylesheetLoadTimeout:I,keepIframeSrcFn:U};if(!(O.type===P.Element&&O.tagName==="textarea"&&O.attributes.value!==void 0))for(const ue of Array.from(e.childNodes)){const te=ve(ue,$);te&&O.childNodes.push(te)}if(Vr(e)&&e.shadowRoot)for(const ue of Array.from(e.shadowRoot.childNodes)){const te=ve(ue,$);te&&(Re(e.shadowRoot)&&(te.isShadow=!0),O.childNodes.push(te))}}return e.parentNode&&Ee(e.parentNode)&&Re(e.parentNode)&&(O.isShadow=!0),O.type===P.Element&&O.tagName==="iframe"&&mn(e,()=>{const $=e.contentDocument;if($&&S){const ue=ve($,{doc:$,mirror:n,blockClass:i,blockSelector:o,needsMask:k,maskTextClass:a,maskTextSelector:u,skipChild:!1,inlineStylesheet:d,maskInputOptions:l,maskTextFn:h,maskInputFn:p,slimDOMOptions:f,dataURLOptions:g,inlineImages:m,recordCanvas:v,preserveWhiteSpace:N,onSerialize:w,onIframeLoad:S,iframeLoadTimeout:y,onStylesheetLoad:b,stylesheetLoadTimeout:I,keepIframeSrcFn:U});ue&&S(e,ue)}},y),O.type===P.Element&&O.tagName==="link"&&typeof O.attributes.rel=="string"&&(O.attributes.rel==="stylesheet"||O.attributes.rel==="preload"&&typeof O.attributes.href=="string"&&Wt(O.attributes.href)==="css")&&gn(e,()=>{if(b){const $=ve(e,{doc:r,mirror:n,blockClass:i,blockSelector:o,needsMask:k,maskTextClass:a,maskTextSelector:u,skipChild:!1,inlineStylesheet:d,maskInputOptions:l,maskTextFn:h,maskInputFn:p,slimDOMOptions:f,dataURLOptions:g,inlineImages:m,recordCanvas:v,preserveWhiteSpace:N,onSerialize:w,onIframeLoad:S,iframeLoadTimeout:y,onStylesheetLoad:b,stylesheetLoadTimeout:I,keepIframeSrcFn:U});$&&b(e,$)}},I),O}function In(e,t){const{mirror:r=new Bt,blockClass:n="rr-block",blockSelector:i=null,maskTextClass:o="rr-mask",maskTextSelector:a=null,inlineStylesheet:u=!0,inlineImages:s=!1,recordCanvas:d=!1,maskAllInputs:l=!1,maskTextFn:h,maskInputFn:p,slimDOM:f=!1,dataURLOptions:g,preserveWhiteSpace:m,onSerialize:v,onIframeLoad:w,iframeLoadTimeout:S,onStylesheetLoad:y,stylesheetLoadTimeout:b,keepIframeSrcFn:I=()=>!1}=t||{};return ve(e,{doc:e,mirror:r,blockClass:n,blockSelector:i,maskTextClass:o,maskTextSelector:a,skipChild:!1,inlineStylesheet:u,maskInputOptions:l===!0?{color:!0,date:!0,"datetime-local":!0,email:!0,month:!0,number:!0,range:!0,search:!0,tel:!0,text:!0,time:!0,url:!0,week:!0,textarea:!0,select:!0,password:!0}:l===!1?{password:!0}:l,maskTextFn:h,maskInputFn:p,slimDOMOptions:f===!0||f==="all"?{script:!0,comment:!0,headFavicon:!0,headWhitespace:!0,headMetaDescKeywords:f==="all",headMetaSocial:!0,headMetaRobots:!0,headMetaHttpEquiv:!0,headMetaAuthorship:!0,headMetaVerification:!0}:f===!1?{}:f,dataURLOptions:g,inlineImages:s,recordCanvas:d,preserveWhiteSpace:m,onSerialize:v,onIframeLoad:w,iframeLoadTimeout:S,onStylesheetLoad:y,stylesheetLoadTimeout:b,keepIframeSrcFn:I,newlyAddedElement:!1})}function q(e,t,r=document){const n={capture:!0,passive:!0};return r.addEventListener(e,t,n),()=>r.removeEventListener(e,t,n)}const be=`Please stop import mirror directly. Instead of that,\r
2
- now you can use replayer.getMirror() to access the mirror instance of a replayer,\r
3
- or you can use record.mirror to access the mirror instance during recording.`;let Gt={map:{},getId(){return console.error(be),-1},getNode(){return console.error(be),null},removeNodeFromMap(){console.error(be)},has(){return console.error(be),!1},reset(){console.error(be)}};typeof window<"u"&&window.Proxy&&window.Reflect&&(Gt=new Proxy(Gt,{get(e,t,r){return t==="map"&&console.error(be),Reflect.get(e,t,r)}}));function xe(e,t,r={}){let n=null,i=0;return function(...o){const a=Date.now();!i&&r.leading===!1&&(i=a);const u=t-(a-i),s=this;u<=0||u>t?(n&&(clearTimeout(n),n=null),i=a,e.apply(s,o)):!n&&r.trailing!==!1&&(n=setTimeout(()=>{i=r.leading===!1?0:Date.now(),n=null,e.apply(s,o)},u))}}function je(e,t,r,n,i=window){const o=i.Object.getOwnPropertyDescriptor(e,t);return i.Object.defineProperty(e,t,n?r:{set(a){setTimeout(()=>{r.set.call(this,a)},0),o&&o.set&&o.set.call(this,a)}}),()=>je(e,t,o||{},!0)}function Se(e,t,r){try{if(!(t in e))return()=>{};const n=e[t],i=r(n);return typeof i=="function"&&(i.prototype=i.prototype||{},Object.defineProperties(i,{__rrweb_original__:{enumerable:!1,value:n}})),e[t]=i,()=>{e[t]=n}}catch{return()=>{}}}let Ge=Date.now;/[1-9][0-9]{12}/.test(Date.now().toString())||(Ge=()=>new Date().getTime());function Vt(e){var t,r,n,i,o,a;const u=e.document;return{left:u.scrollingElement?u.scrollingElement.scrollLeft:e.pageXOffset!==void 0?e.pageXOffset:u?.documentElement.scrollLeft||((r=(t=u?.body)===null||t===void 0?void 0:t.parentElement)===null||r===void 0?void 0:r.scrollLeft)||((n=u?.body)===null||n===void 0?void 0:n.scrollLeft)||0,top:u.scrollingElement?u.scrollingElement.scrollTop:e.pageYOffset!==void 0?e.pageYOffset:u?.documentElement.scrollTop||((o=(i=u?.body)===null||i===void 0?void 0:i.parentElement)===null||o===void 0?void 0:o.scrollTop)||((a=u?.body)===null||a===void 0?void 0:a.scrollTop)||0}}function Jt(){return window.innerHeight||document.documentElement&&document.documentElement.clientHeight||document.body&&document.body.clientHeight}function Xt(){return window.innerWidth||document.documentElement&&document.documentElement.clientWidth||document.body&&document.body.clientWidth}function Kt(e){return e?e.nodeType===e.ELEMENT_NODE?e:e.parentElement:null}function z(e,t,r,n){if(!e)return!1;const i=Kt(e);if(!i)return!1;try{if(typeof t=="string"){if(i.classList.contains(t)||n&&i.closest("."+t)!==null)return!0}else if(He(i,t,n))return!0}catch{}return!!(r&&(i.matches(r)||n&&i.closest(r)!==null))}function Mn(e,t){return t.getId(e)!==-1}function ht(e,t){return t.getId(e)===Oe}function Qt(e,t){if(Ee(e))return!1;const r=t.getId(e);return t.has(r)?e.parentNode&&e.parentNode.nodeType===e.DOCUMENT_NODE?!1:e.parentNode?Qt(e.parentNode,t):!0:!0}function pt(e){return!!e.changedTouches}function _n(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),Node.prototype.contains||(Node.prototype.contains=(...t)=>{let r=t[0];if(!(0 in t))throw new TypeError("1 argument is required");do if(this===r)return!0;while(r=r&&r.parentNode);return!1})}function Yt(e,t){return!!(e.nodeName==="IFRAME"&&t.getMeta(e))}function Zt(e,t){return!!(e.nodeName==="LINK"&&e.nodeType===e.ELEMENT_NODE&&e.getAttribute&&e.getAttribute("rel")==="stylesheet"&&t.getMeta(e))}function mt(e){return!!e?.shadowRoot}class Cn{constructor(){this.id=1,this.styleIDMap=new WeakMap,this.idStyleMap=new Map}getId(t){var r;return(r=this.styleIDMap.get(t))!==null&&r!==void 0?r:-1}has(t){return this.styleIDMap.has(t)}add(t,r){if(this.has(t))return this.getId(t);let n;return r===void 0?n=this.id++:n=r,this.styleIDMap.set(t,n),this.idStyleMap.set(n,t),n}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 er(e){var t,r;let n=null;return((r=(t=e.getRootNode)===null||t===void 0?void 0:t.call(e))===null||r===void 0?void 0:r.nodeType)===Node.DOCUMENT_FRAGMENT_NODE&&e.getRootNode().host&&(n=e.getRootNode().host),n}function En(e){let t=e,r;for(;r=er(t);)t=r;return t}function Rn(e){const t=e.ownerDocument;if(!t)return!1;const r=En(e);return t.contains(r)}function tr(e){const t=e.ownerDocument;return t?t.contains(e)||Rn(e):!1}var E=(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||{}),_=(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))(_||{}),j=(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))(j||{}),re=(e=>(e[e.Mouse=0]="Mouse",e[e.Pen=1]="Pen",e[e.Touch=2]="Touch",e))(re||{}),we=(e=>(e[e["2D"]=0]="2D",e[e.WebGL=1]="WebGL",e[e.WebGL2=2]="WebGL2",e))(we||{});function rr(e){return"__ln"in e}class On{constructor(){this.length=0,this.head=null,this.tail=null}get(t){if(t>=this.length)throw new Error("Position outside of list range");let r=this.head;for(let n=0;n<t;n++)r=r?.next||null;return r}addNode(t){const r={value:t,previous:null,next:null};if(t.__ln=r,t.previousSibling&&rr(t.previousSibling)){const n=t.previousSibling.__ln.next;r.next=n,r.previous=t.previousSibling.__ln,t.previousSibling.__ln.next=r,n&&(n.previous=r)}else if(t.nextSibling&&rr(t.nextSibling)&&t.nextSibling.__ln.previous){const n=t.nextSibling.__ln.previous;r.previous=n,r.next=t.nextSibling.__ln,t.nextSibling.__ln.previous=r,n&&(n.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){const 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--)}}const nr=(e,t)=>`${e}@${t}`;class xn{constructor(){this.frozen=!1,this.locked=!1,this.texts=[],this.attributes=[],this.attributeMap=new WeakMap,this.removes=[],this.mapRemoves=[],this.movedMap={},this.addedSet=new Set,this.movedSet=new Set,this.droppedSet=new Set,this.processMutations=t=>{t.forEach(this.processMutation),this.emit()},this.emit=()=>{if(this.frozen||this.locked)return;const t=[],r=new Set,n=new On,i=s=>{let d=s,l=Oe;for(;l===Oe;)d=d&&d.nextSibling,l=d&&this.mirror.getId(d);return l},o=s=>{if(!s.parentNode||!tr(s)||s.parentNode.tagName==="TEXTAREA")return;const d=Ee(s.parentNode)?this.mirror.getId(er(s)):this.mirror.getId(s.parentNode),l=i(s);if(d===-1||l===-1)return n.addNode(s);const h=ve(s,{doc:this.doc,mirror:this.mirror,blockClass:this.blockClass,blockSelector:this.blockSelector,maskTextClass:this.maskTextClass,maskTextSelector:this.maskTextSelector,skipChild:!0,newlyAddedElement:!0,inlineStylesheet:this.inlineStylesheet,maskInputOptions:this.maskInputOptions,maskTextFn:this.maskTextFn,maskInputFn:this.maskInputFn,slimDOMOptions:this.slimDOMOptions,dataURLOptions:this.dataURLOptions,recordCanvas:this.recordCanvas,inlineImages:this.inlineImages,onSerialize:p=>{Yt(p,this.mirror)&&this.iframeManager.addIframe(p),Zt(p,this.mirror)&&this.stylesheetManager.trackLinkElement(p),mt(s)&&this.shadowDomManager.addShadowRoot(s.shadowRoot,this.doc)},onIframeLoad:(p,f)=>{this.iframeManager.attachIframe(p,f),this.shadowDomManager.observeAttachShadow(p)},onStylesheetLoad:(p,f)=>{this.stylesheetManager.attachLinkElement(p,f)}});h&&(t.push({parentId:d,nextId:l,node:h}),r.add(h.id))};for(;this.mapRemoves.length;)this.mirror.removeNodeFromMap(this.mapRemoves.shift());for(const s of this.movedSet)ir(this.removes,s,this.mirror)&&!this.movedSet.has(s.parentNode)||o(s);for(const s of this.addedSet)!sr(this.droppedSet,s)&&!ir(this.removes,s,this.mirror)||sr(this.movedSet,s)?o(s):this.droppedSet.add(s);let a=null;for(;n.length;){let s=null;if(a){const d=this.mirror.getId(a.value.parentNode),l=i(a.value);d!==-1&&l!==-1&&(s=a)}if(!s){let d=n.tail;for(;d;){const l=d;if(d=d.previous,l){const h=this.mirror.getId(l.value.parentNode);if(i(l.value)===-1)continue;if(h!==-1){s=l;break}else{const f=l.value;if(f.parentNode&&f.parentNode.nodeType===Node.DOCUMENT_FRAGMENT_NODE){const g=f.parentNode.host;if(this.mirror.getId(g)!==-1){s=l;break}}}}}}if(!s){for(;n.head;)n.removeNode(n.head.value);break}a=s.previous,n.removeNode(s.value),o(s.value)}const u={texts:this.texts.map(s=>{const d=s.node;return d.parentNode&&d.parentNode.tagName==="TEXTAREA"&&this.genTextAreaValueMutation(d.parentNode),{id:this.mirror.getId(d),value:s.value}}).filter(s=>!r.has(s.id)).filter(s=>this.mirror.has(s.id)),attributes:this.attributes.map(s=>{const{attributes:d}=s;if(typeof d.style=="string"){const l=JSON.stringify(s.styleDiff),h=JSON.stringify(s._unchangedStyles);l.length<d.style.length&&(l+h).split("var(").length===d.style.split("var(").length&&(d.style=s.styleDiff)}return{id:this.mirror.getId(s.node),attributes:d}}).filter(s=>!r.has(s.id)).filter(s=>this.mirror.has(s.id)),removes:this.removes,adds:t};!u.texts.length&&!u.attributes.length&&!u.removes.length&&!u.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.movedMap={},this.mutationCb(u))},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)),r.attributes.value=Array.from(t.childNodes,n=>n.textContent||"").join("")},this.processMutation=t=>{if(!ht(t.target,this.mirror))switch(t.type){case"characterData":{const r=t.target.textContent;!z(t.target,this.blockClass,this.blockSelector,!1)&&r!==t.oldValue&&this.texts.push({value:jt(t.target,this.maskTextClass,this.maskTextSelector,!0)&&r?this.maskTextFn?this.maskTextFn(r,Kt(t.target)):r.replace(/[\S]/g,"*"):r,node:t.target});break}case"attributes":{const r=t.target;let n=t.attributeName,i=t.target.getAttribute(n);if(n==="value"){const a=dt(r);i=lt({element:r,maskInputOptions:this.maskInputOptions,tagName:r.tagName,type:a,value:i,maskInputFn:this.maskInputFn})}if(z(t.target,this.blockClass,this.blockSelector,!1)||i===t.oldValue)return;let o=this.attributeMap.get(t.target);if(r.tagName==="IFRAME"&&n==="src"&&!this.keepIframeSrcFn(i))if(!r.contentDocument)n="rr_src";else return;if(o||(o={node:t.target,attributes:{},styleDiff:{},_unchangedStyles:{}},this.attributes.push(o),this.attributeMap.set(t.target,o)),n==="type"&&r.tagName==="INPUT"&&(t.oldValue||"").toLowerCase()==="password"&&r.setAttribute("data-rr-is-password","true"),!Ht(r.tagName,n)&&(o.attributes[n]=$t(this.doc,ce(r.tagName),ce(n),i),n==="style")){if(!this.unattachedDoc)try{this.unattachedDoc=document.implementation.createHTMLDocument()}catch{this.unattachedDoc=this.doc}const a=this.unattachedDoc.createElement("span");t.oldValue&&a.setAttribute("style",t.oldValue);for(const u of Array.from(r.style)){const s=r.style.getPropertyValue(u),d=r.style.getPropertyPriority(u);s!==a.style.getPropertyValue(u)||d!==a.style.getPropertyPriority(u)?d===""?o.styleDiff[u]=s:o.styleDiff[u]=[s,d]:o._unchangedStyles[u]=[s,d]}for(const u of Array.from(a.style))r.style.getPropertyValue(u)===""&&(o.styleDiff[u]=!1)}break}case"childList":{if(z(t.target,this.blockClass,this.blockSelector,!0))return;if(t.target.tagName==="TEXTAREA"){this.genTextAreaValueMutation(t.target);return}t.addedNodes.forEach(r=>this.genAdds(r,t.target)),t.removedNodes.forEach(r=>{const n=this.mirror.getId(r),i=Ee(t.target)?this.mirror.getId(t.target.host):this.mirror.getId(t.target);z(t.target,this.blockClass,this.blockSelector,!1)||ht(r,this.mirror)||!Mn(r,this.mirror)||(this.addedSet.has(r)?(gt(this.addedSet,r),this.droppedSet.add(r)):this.addedSet.has(t.target)&&n===-1||Qt(t.target,this.mirror)||(this.movedSet.has(r)&&this.movedMap[nr(n,i)]?gt(this.movedSet,r):this.removes.push({parentId:i,id:n,isShadow:Ee(t.target)&&Re(t.target)?!0:void 0})),this.mapRemoves.push(r))});break}}},this.genAdds=(t,r)=>{if(!this.processedNodeManager.inOtherBuffer(t,this)&&!(this.addedSet.has(t)||this.movedSet.has(t))){if(this.mirror.hasNode(t)){if(ht(t,this.mirror))return;this.movedSet.add(t);let n=null;r&&this.mirror.hasNode(r)&&(n=this.mirror.getId(r)),n&&n!==-1&&(this.movedMap[nr(this.mirror.getId(t),n)]=!0)}else this.addedSet.add(t),this.droppedSet.delete(t);z(t,this.blockClass,this.blockSelector,!1)||(t.childNodes.forEach(n=>this.genAdds(n)),mt(t)&&t.shadowRoot.childNodes.forEach(n=>{this.processedNodeManager.add(n,this),this.genAdds(n,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=!0,this.canvasManager.freeze()}unfreeze(){this.frozen=!1,this.canvasManager.unfreeze(),this.emit()}isFrozen(){return this.frozen}lock(){this.locked=!0,this.canvasManager.lock()}unlock(){this.locked=!1,this.canvasManager.unlock(),this.emit()}reset(){this.shadowDomManager.reset(),this.canvasManager.reset()}}function gt(e,t){e.delete(t),t.childNodes.forEach(r=>gt(e,r))}function ir(e,t,r){return e.length===0?!1:or(e,t,r)}function or(e,t,r){const{parentNode:n}=t;if(!n)return!1;const i=r.getId(n);return e.some(o=>o.id===i)?!0:or(e,n,r)}function sr(e,t){return e.size===0?!1:ar(e,t)}function ar(e,t){const{parentNode:r}=t;return r?e.has(r)?!0:ar(e,r):!1}let Te;function Tn(e){Te=e}function kn(){Te=void 0}const C=e=>Te?(...r)=>{try{return e(...r)}catch(n){if(Te&&Te(n)===!0)return;throw n}}:e,le=[];function ke(e){try{if("composedPath"in e){const 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 ur(e,t){var r,n;const i=new xn;le.push(i),i.init(e);let o=window.MutationObserver||window.__rrMutationObserver;const a=(n=(r=window?.Zone)===null||r===void 0?void 0:r.__symbol__)===null||n===void 0?void 0:n.call(r,"MutationObserver");a&&window[a]&&(o=window[a]);const u=new o(C(i.processMutations.bind(i)));return u.observe(t,{attributes:!0,attributeOldValue:!0,characterData:!0,characterDataOldValue:!0,childList:!0,subtree:!0}),u}function Nn({mousemoveCb:e,sampling:t,doc:r,mirror:n}){if(t.mousemove===!1)return()=>{};const i=typeof t.mousemove=="number"?t.mousemove:50,o=typeof t.mousemoveCallback=="number"?t.mousemoveCallback:500;let a=[],u;const s=xe(C(h=>{const p=Date.now()-u;e(a.map(f=>(f.timeOffset-=p,f)),h),a=[],u=null}),o),d=C(xe(C(h=>{const p=ke(h),{clientX:f,clientY:g}=pt(h)?h.changedTouches[0]:h;u||(u=Ge()),a.push({x:f,y:g,id:n.getId(p),timeOffset:Ge()-u}),s(typeof DragEvent<"u"&&h instanceof DragEvent?_.Drag:h instanceof MouseEvent?_.MouseMove:_.TouchMove)}),i,{trailing:!1})),l=[q("mousemove",d,r),q("touchmove",d,r),q("drag",d,r)];return C(()=>{l.forEach(h=>h())})}function Dn({mouseInteractionCb:e,doc:t,mirror:r,blockClass:n,blockSelector:i,sampling:o}){if(o.mouseInteraction===!1)return()=>{};const a=o.mouseInteraction===!0||o.mouseInteraction===void 0?{}:o.mouseInteraction,u=[];let s=null;const d=l=>h=>{const p=ke(h);if(z(p,n,i,!0))return;let f=null,g=l;if("pointerType"in h){switch(h.pointerType){case"mouse":f=re.Mouse;break;case"touch":f=re.Touch;break;case"pen":f=re.Pen;break}f===re.Touch?j[l]===j.MouseDown?g="TouchStart":j[l]===j.MouseUp&&(g="TouchEnd"):re.Pen}else pt(h)&&(f=re.Touch);f!==null?(s=f,(g.startsWith("Touch")&&f===re.Touch||g.startsWith("Mouse")&&f===re.Mouse)&&(f=null)):j[l]===j.Click&&(f=s,s=null);const m=pt(h)?h.changedTouches[0]:h;if(!m)return;const v=r.getId(p),{clientX:w,clientY:S}=m;C(e)(Object.assign({type:j[g],id:v,x:w,y:S},f!==null&&{pointerType:f}))};return Object.keys(j).filter(l=>Number.isNaN(Number(l))&&!l.endsWith("_Departed")&&a[l]!==!1).forEach(l=>{let h=ce(l);const p=d(l);if(window.PointerEvent)switch(j[l]){case j.MouseDown:case j.MouseUp:h=h.replace("mouse","pointer");break;case j.TouchStart:case j.TouchEnd:return}u.push(q(h,p,t))}),C(()=>{u.forEach(l=>l())})}function cr({scrollCb:e,doc:t,mirror:r,blockClass:n,blockSelector:i,sampling:o}){const a=C(xe(C(u=>{const s=ke(u);if(!s||z(s,n,i,!0))return;const d=r.getId(s);if(s===t&&t.defaultView){const l=Vt(t.defaultView);e({id:d,x:l.left,y:l.top})}else e({id:d,x:s.scrollLeft,y:s.scrollTop})}),o.scroll||100));return q("scroll",a,t)}function An({viewportResizeCb:e},{win:t}){let r=-1,n=-1;const i=C(xe(C(()=>{const o=Jt(),a=Xt();(r!==o||n!==a)&&(e({width:Number(a),height:Number(o)}),r=o,n=a)}),200));return q("resize",i,t)}const Ln=["INPUT","TEXTAREA","SELECT"],lr=new WeakMap;function Pn({inputCb:e,doc:t,mirror:r,blockClass:n,blockSelector:i,ignoreClass:o,ignoreSelector:a,maskInputOptions:u,maskInputFn:s,sampling:d,userTriggeredOnInput:l}){function h(S){let y=ke(S);const b=S.isTrusted,I=y&&y.tagName;if(y&&I==="OPTION"&&(y=y.parentElement),!y||!I||Ln.indexOf(I)<0||z(y,n,i,!0)||y.classList.contains(o)||a&&y.matches(a))return;let U=y.value,B=!1;const k=dt(y)||"";k==="radio"||k==="checkbox"?B=y.checked:(u[I.toLowerCase()]||u[k])&&(U=lt({element:y,maskInputOptions:u,tagName:I,type:k,value:U,maskInputFn:s})),p(y,l?{text:U,isChecked:B,userTriggered:b}:{text:U,isChecked:B});const N=y.name;k==="radio"&&N&&B&&t.querySelectorAll(`input[type="radio"][name="${N}"]`).forEach(V=>{if(V!==y){const J=V.value;p(V,l?{text:J,isChecked:!B,userTriggered:!1}:{text:J,isChecked:!B})}})}function p(S,y){const b=lr.get(S);if(!b||b.text!==y.text||b.isChecked!==y.isChecked){lr.set(S,y);const I=r.getId(S);C(e)(Object.assign(Object.assign({},y),{id:I}))}}const g=(d.input==="last"?["change"]:["input","change"]).map(S=>q(S,C(h),t)),m=t.defaultView;if(!m)return()=>{g.forEach(S=>S())};const v=m.Object.getOwnPropertyDescriptor(m.HTMLInputElement.prototype,"value"),w=[[m.HTMLInputElement.prototype,"value"],[m.HTMLInputElement.prototype,"checked"],[m.HTMLSelectElement.prototype,"value"],[m.HTMLTextAreaElement.prototype,"value"],[m.HTMLSelectElement.prototype,"selectedIndex"],[m.HTMLOptionElement.prototype,"selected"]];return v&&v.set&&g.push(...w.map(S=>je(S[0],S[1],{set(){C(h)({target:this,isTrusted:!1})}},!1,m))),C(()=>{g.forEach(S=>S())})}function Ve(e){const t=[];function r(n,i){if(Je("CSSGroupingRule")&&n.parentRule instanceof CSSGroupingRule||Je("CSSMediaRule")&&n.parentRule instanceof CSSMediaRule||Je("CSSSupportsRule")&&n.parentRule instanceof CSSSupportsRule||Je("CSSConditionRule")&&n.parentRule instanceof CSSConditionRule){const a=Array.from(n.parentRule.cssRules).indexOf(n);i.unshift(a)}else if(n.parentStyleSheet){const a=Array.from(n.parentStyleSheet.cssRules).indexOf(n);i.unshift(a)}return i}return r(e,t)}function oe(e,t,r){let n,i;return e?(e.ownerNode?n=t.getId(e.ownerNode):i=r.getId(e),{styleId:i,id:n}):{}}function Fn({styleSheetRuleCb:e,mirror:t,stylesheetManager:r},{win:n}){if(!n.CSSStyleSheet||!n.CSSStyleSheet.prototype)return()=>{};const i=n.CSSStyleSheet.prototype.insertRule;n.CSSStyleSheet.prototype.insertRule=new Proxy(i,{apply:C((l,h,p)=>{const[f,g]=p,{id:m,styleId:v}=oe(h,t,r.styleMirror);return(m&&m!==-1||v&&v!==-1)&&e({id:m,styleId:v,adds:[{rule:f,index:g}]}),l.apply(h,p)})});const o=n.CSSStyleSheet.prototype.deleteRule;n.CSSStyleSheet.prototype.deleteRule=new Proxy(o,{apply:C((l,h,p)=>{const[f]=p,{id:g,styleId:m}=oe(h,t,r.styleMirror);return(g&&g!==-1||m&&m!==-1)&&e({id:g,styleId:m,removes:[{index:f}]}),l.apply(h,p)})});let a;n.CSSStyleSheet.prototype.replace&&(a=n.CSSStyleSheet.prototype.replace,n.CSSStyleSheet.prototype.replace=new Proxy(a,{apply:C((l,h,p)=>{const[f]=p,{id:g,styleId:m}=oe(h,t,r.styleMirror);return(g&&g!==-1||m&&m!==-1)&&e({id:g,styleId:m,replace:f}),l.apply(h,p)})}));let u;n.CSSStyleSheet.prototype.replaceSync&&(u=n.CSSStyleSheet.prototype.replaceSync,n.CSSStyleSheet.prototype.replaceSync=new Proxy(u,{apply:C((l,h,p)=>{const[f]=p,{id:g,styleId:m}=oe(h,t,r.styleMirror);return(g&&g!==-1||m&&m!==-1)&&e({id:g,styleId:m,replaceSync:f}),l.apply(h,p)})}));const s={};Xe("CSSGroupingRule")?s.CSSGroupingRule=n.CSSGroupingRule:(Xe("CSSMediaRule")&&(s.CSSMediaRule=n.CSSMediaRule),Xe("CSSConditionRule")&&(s.CSSConditionRule=n.CSSConditionRule),Xe("CSSSupportsRule")&&(s.CSSSupportsRule=n.CSSSupportsRule));const d={};return Object.entries(s).forEach(([l,h])=>{d[l]={insertRule:h.prototype.insertRule,deleteRule:h.prototype.deleteRule},h.prototype.insertRule=new Proxy(d[l].insertRule,{apply:C((p,f,g)=>{const[m,v]=g,{id:w,styleId:S}=oe(f.parentStyleSheet,t,r.styleMirror);return(w&&w!==-1||S&&S!==-1)&&e({id:w,styleId:S,adds:[{rule:m,index:[...Ve(f),v||0]}]}),p.apply(f,g)})}),h.prototype.deleteRule=new Proxy(d[l].deleteRule,{apply:C((p,f,g)=>{const[m]=g,{id:v,styleId:w}=oe(f.parentStyleSheet,t,r.styleMirror);return(v&&v!==-1||w&&w!==-1)&&e({id:v,styleId:w,removes:[{index:[...Ve(f),m]}]}),p.apply(f,g)})})}),C(()=>{n.CSSStyleSheet.prototype.insertRule=i,n.CSSStyleSheet.prototype.deleteRule=o,a&&(n.CSSStyleSheet.prototype.replace=a),u&&(n.CSSStyleSheet.prototype.replaceSync=u),Object.entries(s).forEach(([l,h])=>{h.prototype.insertRule=d[l].insertRule,h.prototype.deleteRule=d[l].deleteRule})})}function dr({mirror:e,stylesheetManager:t},r){var n,i,o;let a=null;r.nodeName==="#document"?a=e.getId(r):a=e.getId(r.host);const u=r.nodeName==="#document"?(n=r.defaultView)===null||n===void 0?void 0:n.Document:(o=(i=r.ownerDocument)===null||i===void 0?void 0:i.defaultView)===null||o===void 0?void 0:o.ShadowRoot,s=u?.prototype?Object.getOwnPropertyDescriptor(u?.prototype,"adoptedStyleSheets"):void 0;return a===null||a===-1||!u||!s?()=>{}:(Object.defineProperty(r,"adoptedStyleSheets",{configurable:s.configurable,enumerable:s.enumerable,get(){var d;return(d=s.get)===null||d===void 0?void 0:d.call(this)},set(d){var l;const h=(l=s.set)===null||l===void 0?void 0:l.call(this,d);if(a!==null&&a!==-1)try{t.adoptStyleSheets(d,a)}catch{}return h}}),C(()=>{Object.defineProperty(r,"adoptedStyleSheets",{configurable:s.configurable,enumerable:s.enumerable,get:s.get,set:s.set})}))}function Bn({styleDeclarationCb:e,mirror:t,ignoreCSSAttributes:r,stylesheetManager:n},{win:i}){const o=i.CSSStyleDeclaration.prototype.setProperty;i.CSSStyleDeclaration.prototype.setProperty=new Proxy(o,{apply:C((u,s,d)=>{var l;const[h,p,f]=d;if(r.has(h))return o.apply(s,[h,p,f]);const{id:g,styleId:m}=oe((l=s.parentRule)===null||l===void 0?void 0:l.parentStyleSheet,t,n.styleMirror);return(g&&g!==-1||m&&m!==-1)&&e({id:g,styleId:m,set:{property:h,value:p,priority:f},index:Ve(s.parentRule)}),u.apply(s,d)})});const a=i.CSSStyleDeclaration.prototype.removeProperty;return i.CSSStyleDeclaration.prototype.removeProperty=new Proxy(a,{apply:C((u,s,d)=>{var l;const[h]=d;if(r.has(h))return a.apply(s,[h]);const{id:p,styleId:f}=oe((l=s.parentRule)===null||l===void 0?void 0:l.parentStyleSheet,t,n.styleMirror);return(p&&p!==-1||f&&f!==-1)&&e({id:p,styleId:f,remove:{property:h},index:Ve(s.parentRule)}),u.apply(s,d)})}),C(()=>{i.CSSStyleDeclaration.prototype.setProperty=o,i.CSSStyleDeclaration.prototype.removeProperty=a})}function Un({mediaInteractionCb:e,blockClass:t,blockSelector:r,mirror:n,sampling:i,doc:o}){const a=C(s=>xe(C(d=>{const l=ke(d);if(!l||z(l,t,r,!0))return;const{currentTime:h,volume:p,muted:f,playbackRate:g,loop:m}=l;e({type:s,id:n.getId(l),currentTime:h,volume:p,muted:f,playbackRate:g,loop:m})}),i.media||500)),u=[q("play",a(0),o),q("pause",a(1),o),q("seeked",a(2),o),q("volumechange",a(3),o),q("ratechange",a(4),o)];return C(()=>{u.forEach(s=>s())})}function Wn({fontCb:e,doc:t}){const r=t.defaultView;if(!r)return()=>{};const n=[],i=new WeakMap,o=r.FontFace;r.FontFace=function(s,d,l){const h=new o(s,d,l);return i.set(h,{family:s,buffer:typeof d!="string",descriptors:l,fontSource:typeof d=="string"?d:JSON.stringify(Array.from(new Uint8Array(d)))}),h};const a=Se(t.fonts,"add",function(u){return function(s){return setTimeout(C(()=>{const d=i.get(s);d&&(e(d),i.delete(s))}),0),u.apply(this,[s])}});return n.push(()=>{r.FontFace=o}),n.push(a),C(()=>{n.forEach(u=>u())})}function qn(e){const{doc:t,mirror:r,blockClass:n,blockSelector:i,selectionCb:o}=e;let a=!0;const u=C(()=>{const s=t.getSelection();if(!s||a&&s?.isCollapsed)return;a=s.isCollapsed||!1;const d=[],l=s.rangeCount||0;for(let h=0;h<l;h++){const p=s.getRangeAt(h),{startContainer:f,startOffset:g,endContainer:m,endOffset:v}=p;z(f,n,i,!0)||z(m,n,i,!0)||d.push({start:r.getId(f),startOffset:g,end:r.getId(m),endOffset:v})}o({ranges:d})});return u(),q("selectionchange",u)}function zn({doc:e,customElementCb:t}){const r=e.defaultView;return!r||!r.customElements?()=>{}:Se(r.customElements,"define",function(i){return function(o,a,u){try{t({define:{name:o}})}catch{console.warn(`Custom element callback failed for ${o}`)}return i.apply(this,[o,a,u])}})}function $n(e,t){const{mutationCb:r,mousemoveCb:n,mouseInteractionCb:i,scrollCb:o,viewportResizeCb:a,inputCb:u,mediaInteractionCb:s,styleSheetRuleCb:d,styleDeclarationCb:l,canvasMutationCb:h,fontCb:p,selectionCb:f,customElementCb:g}=e;e.mutationCb=(...m)=>{t.mutation&&t.mutation(...m),r(...m)},e.mousemoveCb=(...m)=>{t.mousemove&&t.mousemove(...m),n(...m)},e.mouseInteractionCb=(...m)=>{t.mouseInteraction&&t.mouseInteraction(...m),i(...m)},e.scrollCb=(...m)=>{t.scroll&&t.scroll(...m),o(...m)},e.viewportResizeCb=(...m)=>{t.viewportResize&&t.viewportResize(...m),a(...m)},e.inputCb=(...m)=>{t.input&&t.input(...m),u(...m)},e.mediaInteractionCb=(...m)=>{t.mediaInteaction&&t.mediaInteaction(...m),s(...m)},e.styleSheetRuleCb=(...m)=>{t.styleSheetRule&&t.styleSheetRule(...m),d(...m)},e.styleDeclarationCb=(...m)=>{t.styleDeclaration&&t.styleDeclaration(...m),l(...m)},e.canvasMutationCb=(...m)=>{t.canvasMutation&&t.canvasMutation(...m),h(...m)},e.fontCb=(...m)=>{t.font&&t.font(...m),p(...m)},e.selectionCb=(...m)=>{t.selection&&t.selection(...m),f(...m)},e.customElementCb=(...m)=>{t.customElement&&t.customElement(...m),g(...m)}}function Hn(e,t={}){const r=e.doc.defaultView;if(!r)return()=>{};$n(e,t);let n;e.recordDOM&&(n=ur(e,e.doc));const i=Nn(e),o=Dn(e),a=cr(e),u=An(e,{win:r}),s=Pn(e),d=Un(e);let l=()=>{},h=()=>{},p=()=>{},f=()=>{};e.recordDOM&&(l=Fn(e,{win:r}),h=dr(e,e.doc),p=Bn(e,{win:r}),e.collectFonts&&(f=Wn(e)));const g=qn(e),m=zn(e),v=[];for(const w of e.plugins)v.push(w.observer(w.callback,r,w.options));return C(()=>{le.forEach(w=>w.reset()),n?.disconnect(),i(),o(),a(),u(),s(),d(),l(),h(),p(),f(),g(),m(),v.forEach(w=>w())})}function Je(e){return typeof window[e]<"u"}function Xe(e){return!!(typeof window[e]<"u"&&window[e].prototype&&"insertRule"in window[e].prototype&&"deleteRule"in window[e].prototype)}class fr{constructor(t){this.generateIdFn=t,this.iframeIdToRemoteIdMap=new WeakMap,this.iframeRemoteIdToIdMap=new WeakMap}getId(t,r,n,i){const o=n||this.getIdToRemoteIdMap(t),a=i||this.getRemoteIdToIdMap(t);let u=o.get(r);return u||(u=this.generateIdFn(),o.set(r,u),a.set(u,r)),u}getIds(t,r){const n=this.getIdToRemoteIdMap(t),i=this.getRemoteIdToIdMap(t);return r.map(o=>this.getId(t,o,n,i))}getRemoteId(t,r,n){const i=n||this.getRemoteIdToIdMap(t);if(typeof r!="number")return r;const o=i.get(r);return o||-1}getRemoteIds(t,r){const n=this.getRemoteIdToIdMap(t);return r.map(i=>this.getRemoteId(t,i,n))}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}}class jn{constructor(t){this.iframes=new WeakMap,this.crossOriginIframeMap=new WeakMap,this.crossOriginIframeMirror=new fr(qt),this.crossOriginIframeRootIdMap=new WeakMap,this.mutationCb=t.mutationCb,this.wrappedEmit=t.wrappedEmit,this.stylesheetManager=t.stylesheetManager,this.recordCrossOriginIframes=t.recordCrossOriginIframes,this.crossOriginIframeStyleMirror=new fr(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,!0),t.contentWindow&&this.crossOriginIframeMap.set(t.contentWindow,t)}addLoadListener(t){this.loadListener=t}attachIframe(t,r){var n;this.mutationCb({adds:[{parentId:this.mirror.getId(t),nextId:null,node:r}],removes:[],texts:[],attributes:[],isAttachIframe:!0}),(n=this.loadListener)===null||n===void 0||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){const r=t;if(r.data.type!=="rrweb"||r.origin!==r.data.origin||!t.source)return;const i=this.crossOriginIframeMap.get(t.source);if(!i)return;const o=this.transformCrossOriginEvent(i,r.data.event);o&&this.wrappedEmit(o,r.data.isCheckout)}transformCrossOriginEvent(t,r){var n;switch(r.type){case E.FullSnapshot:{this.crossOriginIframeMirror.reset(t),this.crossOriginIframeStyleMirror.reset(t),this.replaceIdOnNode(r.data.node,t);const i=r.data.node.id;return this.crossOriginIframeRootIdMap.set(t,i),this.patchRootIdOnNode(r.data.node,i),{timestamp:r.timestamp,type:E.IncrementalSnapshot,data:{source:_.Mutation,adds:[{parentId:this.mirror.getId(t),nextId:null,node:r.data.node}],removes:[],texts:[],attributes:[],isAttachIframe:!0}}}case E.Meta:case E.Load:case E.DomContentLoaded:return!1;case E.Plugin:return r;case E.Custom:return this.replaceIds(r.data.payload,t,["id","parentId","previousId","nextId"]),r;case E.IncrementalSnapshot:switch(r.data.source){case _.Mutation:return r.data.adds.forEach(i=>{this.replaceIds(i,t,["parentId","nextId","previousId"]),this.replaceIdOnNode(i.node,t);const o=this.crossOriginIframeRootIdMap.get(t);o&&this.patchRootIdOnNode(i.node,o)}),r.data.removes.forEach(i=>{this.replaceIds(i,t,["parentId","id"])}),r.data.attributes.forEach(i=>{this.replaceIds(i,t,["id"])}),r.data.texts.forEach(i=>{this.replaceIds(i,t,["id"])}),r;case _.Drag:case _.TouchMove:case _.MouseMove:return r.data.positions.forEach(i=>{this.replaceIds(i,t,["id"])}),r;case _.ViewportResize:return!1;case _.MediaInteraction:case _.MouseInteraction:case _.Scroll:case _.CanvasMutation:case _.Input:return this.replaceIds(r.data,t,["id"]),r;case _.StyleSheetRule:case _.StyleDeclaration:return this.replaceIds(r.data,t,["id"]),this.replaceStyleIds(r.data,t,["styleId"]),r;case _.Font:return r;case _.Selection:return r.data.ranges.forEach(i=>{this.replaceIds(i,t,["start","end"])}),r;case _.AdoptedStyleSheet:return this.replaceIds(r.data,t,["id"]),this.replaceStyleIds(r.data,t,["styleIds"]),(n=r.data.styles)===null||n===void 0||n.forEach(i=>{this.replaceStyleIds(i,t,["styleId"])}),r}}return!1}replace(t,r,n,i){for(const o of i)!Array.isArray(r[o])&&typeof r[o]!="number"||(Array.isArray(r[o])?r[o]=t.getIds(n,r[o]):r[o]=t.getId(n,r[o]));return r}replaceIds(t,r,n){return this.replace(this.crossOriginIframeMirror,t,r,n)}replaceStyleIds(t,r,n){return this.replace(this.crossOriginIframeStyleMirror,t,r,n)}replaceIdOnNode(t,r){this.replaceIds(t,r,["id","rootId"]),"childNodes"in t&&t.childNodes.forEach(n=>{this.replaceIdOnNode(n,r)})}patchRootIdOnNode(t,r){t.type!==P.Document&&!t.rootId&&(t.rootId=r),"childNodes"in t&&t.childNodes.forEach(n=>{this.patchRootIdOnNode(n,r)})}}class Gn{constructor(t){this.shadowDoms=new WeakSet,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(!Re(t)||this.shadowDoms.has(t))return;this.shadowDoms.add(t);const n=ur(Object.assign(Object.assign({},this.bypassOptions),{doc:r,mutationCb:this.mutationCb,mirror:this.mirror,shadowDomManager:this}),t);this.restoreHandlers.push(()=>n.disconnect()),this.restoreHandlers.push(cr(Object.assign(Object.assign({},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(t.host)),this.restoreHandlers.push(dr({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){const n=this;this.restoreHandlers.push(Se(t.prototype,"attachShadow",function(i){return function(o){const a=i.call(this,o);return this.shadowRoot&&tr(this)&&n.addShadowRoot(this.shadowRoot,r),a}}))}reset(){this.restoreHandlers.forEach(t=>{try{t()}catch{}}),this.restoreHandlers=[],this.shadowDoms=new WeakSet}}/*! *****************************************************************************
4
- Copyright (c) Microsoft Corporation.
5
-
6
- Permission to use, copy, modify, and/or distribute this software for any
7
- purpose with or without fee is hereby granted.
8
-
9
- THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
10
- REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
11
- AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
12
- INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
13
- LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
14
- OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
15
- PERFORMANCE OF THIS SOFTWARE.
16
- ***************************************************************************** */function Vn(e,t){var r={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var i=0,n=Object.getOwnPropertySymbols(e);i<n.length;i++)t.indexOf(n[i])<0&&Object.prototype.propertyIsEnumerable.call(e,n[i])&&(r[n[i]]=e[n[i]]);return r}function Jn(e,t,r,n){function i(o){return o instanceof r?o:new r(function(a){a(o)})}return new(r||(r=Promise))(function(o,a){function u(l){try{d(n.next(l))}catch(h){a(h)}}function s(l){try{d(n.throw(l))}catch(h){a(h)}}function d(l){l.done?o(l.value):i(l.value).then(u,s)}d((n=n.apply(e,t||[])).next())})}for(var Ie="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",Xn=typeof Uint8Array>"u"?[]:new Uint8Array(256),Ke=0;Ke<Ie.length;Ke++)Xn[Ie.charCodeAt(Ke)]=Ke;var Kn=function(e){var t=new Uint8Array(e),r,n=t.length,i="";for(r=0;r<n;r+=3)i+=Ie[t[r]>>2],i+=Ie[(t[r]&3)<<4|t[r+1]>>4],i+=Ie[(t[r+1]&15)<<2|t[r+2]>>6],i+=Ie[t[r+2]&63];return n%3===2?i=i.substring(0,i.length-1)+"=":n%3===1&&(i=i.substring(0,i.length-2)+"=="),i};const hr=new Map;function Qn(e,t){let r=hr.get(e);return r||(r=new Map,hr.set(e,r)),r.has(t)||r.set(t,[]),r.get(t)}const pr=(e,t,r)=>{if(!e||!(gr(e,t)||typeof e=="object"))return;const n=e.constructor.name,i=Qn(r,n);let o=i.indexOf(e);return o===-1&&(o=i.length,i.push(e)),o};function Qe(e,t,r){if(e instanceof Array)return e.map(n=>Qe(n,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){const n=e.constructor.name,i=Kn(e);return{rr_type:n,base64:i}}else{if(e instanceof DataView)return{rr_type:e.constructor.name,args:[Qe(e.buffer,t,r),e.byteOffset,e.byteLength]};if(e instanceof HTMLImageElement){const n=e.constructor.name,{src:i}=e;return{rr_type:n,src:i}}else if(e instanceof HTMLCanvasElement){const n="HTMLImageElement",i=e.toDataURL();return{rr_type:n,src:i}}else{if(e instanceof ImageData)return{rr_type:e.constructor.name,args:[Qe(e.data,t,r),e.width,e.height]};if(gr(e,t)||typeof e=="object"){const n=e.constructor.name,i=pr(e,t,r);return{rr_type:n,index:i}}}}return e}const mr=(e,t,r)=>e.map(n=>Qe(n,t,r)),gr=(e,t)=>!!["WebGLActiveInfo","WebGLBuffer","WebGLFramebuffer","WebGLProgram","WebGLRenderbuffer","WebGLShader","WebGLShaderPrecisionFormat","WebGLTexture","WebGLUniformLocation","WebGLVertexArrayObject","WebGLVertexArrayObjectOES"].filter(i=>typeof t[i]=="function").find(i=>e instanceof t[i]);function Yn(e,t,r,n){const i=[],o=Object.getOwnPropertyNames(t.CanvasRenderingContext2D.prototype);for(const a of o)try{if(typeof t.CanvasRenderingContext2D.prototype[a]!="function")continue;const u=Se(t.CanvasRenderingContext2D.prototype,a,function(s){return function(...d){return z(this.canvas,r,n,!0)||setTimeout(()=>{const l=mr(d,t,this);e(this.canvas,{type:we["2D"],property:a,args:l})},0),s.apply(this,d)}});i.push(u)}catch{const s=je(t.CanvasRenderingContext2D.prototype,a,{set(d){e(this.canvas,{type:we["2D"],property:a,args:[d],setter:!0})}});i.push(s)}return()=>{i.forEach(a=>a())}}function Zn(e){return e==="experimental-webgl"?"webgl":e}function yr(e,t,r,n){const i=[];try{const o=Se(e.HTMLCanvasElement.prototype,"getContext",function(a){return function(u,...s){if(!z(this,t,r,!0)){const d=Zn(u);if("__context"in this||(this.__context=d),n&&["webgl","webgl2"].includes(d))if(s[0]&&typeof s[0]=="object"){const l=s[0];l.preserveDrawingBuffer||(l.preserveDrawingBuffer=!0)}else s.splice(0,1,{preserveDrawingBuffer:!0})}return a.apply(this,[u,...s])}});i.push(o)}catch{console.error("failed to patch HTMLCanvasElement.prototype.getContext")}return()=>{i.forEach(o=>o())}}function vr(e,t,r,n,i,o,a){const u=[],s=Object.getOwnPropertyNames(e);for(const d of s)if(!["isContextLost","canvas","drawingBufferWidth","drawingBufferHeight"].includes(d))try{if(typeof e[d]!="function")continue;const l=Se(e,d,function(h){return function(...p){const f=h.apply(this,p);if(pr(f,a,this),"tagName"in this.canvas&&!z(this.canvas,n,i,!0)){const g=mr(p,a,this),m={type:t,property:d,args:g};r(this.canvas,m)}return f}});u.push(l)}catch{const h=je(e,d,{set(p){r(this.canvas,{type:t,property:d,args:[p],setter:!0})}});u.push(h)}return u}function ei(e,t,r,n,i){const o=[];return o.push(...vr(t.WebGLRenderingContext.prototype,we.WebGL,e,r,n,i,t)),typeof t.WebGL2RenderingContext<"u"&&o.push(...vr(t.WebGL2RenderingContext.prototype,we.WebGL2,e,r,n,i,t)),()=>{o.forEach(a=>a())}}function ti(e,t){var r=t===void 0?null:t,n=e.toString(),i=n.split(`
17
- `);i.pop(),i.shift();for(var o=i[0].search(/\S/),a=/(['"])__worker_loader_strict__(['"])/g,u=0,s=i.length;u<s;++u)i[u]=i[u].substring(o).replace(a,"$1use strict$2")+`
18
- `;return r&&i.push("//# sourceMappingURL="+r+`
19
- `),i}function ri(e,t){var r=ti(e,t),n=new Blob(r,{type:"application/javascript"});return URL.createObjectURL(n)}function ni(e,t){var r;return function(i){return r=r||ri(e,t),new Worker(r,i)}}var ii=ni(function(){(function(){"__worker_loader_strict__";/*! *****************************************************************************
20
- Copyright (c) Microsoft Corporation.
21
-
22
- Permission to use, copy, modify, and/or distribute this software for any
23
- purpose with or without fee is hereby granted.
24
-
25
- THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
26
- REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
27
- AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
28
- INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
29
- LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
30
- OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
31
- PERFORMANCE OF THIS SOFTWARE.
32
- ***************************************************************************** */function e(d,l,h,p){function f(g){return g instanceof h?g:new h(function(m){m(g)})}return new(h||(h=Promise))(function(g,m){function v(y){try{S(p.next(y))}catch(b){m(b)}}function w(y){try{S(p.throw(y))}catch(b){m(b)}}function S(y){y.done?g(y.value):f(y.value).then(v,w)}S((p=p.apply(d,l||[])).next())})}for(var t="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",r=typeof Uint8Array>"u"?[]:new Uint8Array(256),n=0;n<t.length;n++)r[t.charCodeAt(n)]=n;var i=function(d){var l=new Uint8Array(d),h,p=l.length,f="";for(h=0;h<p;h+=3)f+=t[l[h]>>2],f+=t[(l[h]&3)<<4|l[h+1]>>4],f+=t[(l[h+1]&15)<<2|l[h+2]>>6],f+=t[l[h+2]&63];return p%3===2?f=f.substring(0,f.length-1)+"=":p%3===1&&(f=f.substring(0,f.length-2)+"=="),f};const o=new Map,a=new Map;function u(d,l,h){return e(this,void 0,void 0,function*(){const p=`${d}-${l}`;if("OffscreenCanvas"in globalThis){if(a.has(p))return a.get(p);const f=new OffscreenCanvas(d,l);f.getContext("2d");const m=yield(yield f.convertToBlob(h)).arrayBuffer(),v=i(m);return a.set(p,v),v}else return""})}const s=self;s.onmessage=function(d){return e(this,void 0,void 0,function*(){if("OffscreenCanvas"in globalThis){const{id:l,bitmap:h,width:p,height:f,dataURLOptions:g}=d.data,m=u(p,f,g),v=new OffscreenCanvas(p,f);v.getContext("2d").drawImage(h,0,0),h.close();const S=yield v.convertToBlob(g),y=S.type,b=yield S.arrayBuffer(),I=i(b);if(!o.has(l)&&(yield m)===I)return o.set(l,I),s.postMessage({id:l});if(o.get(l)===I)return s.postMessage({id:l});s.postMessage({id:l,type:y,base64:I,width:p,height:f}),o.set(l,I)}else return s.postMessage({id:d.data.id})})}})()},null);class oi{reset(){this.pendingCanvasMutations.clear(),this.resetObservers&&this.resetObservers()}freeze(){this.frozen=!0}unfreeze(){this.frozen=!1}lock(){this.locked=!0}unlock(){this.locked=!1}constructor(t){this.pendingCanvasMutations=new Map,this.rafStamps={latestId:0,invokeId:null},this.frozen=!1,this.locked=!1,this.processMutation=(s,d)=>{(this.rafStamps.invokeId&&this.rafStamps.latestId!==this.rafStamps.invokeId||!this.rafStamps.invokeId)&&(this.rafStamps.invokeId=this.rafStamps.latestId),this.pendingCanvasMutations.has(s)||this.pendingCanvasMutations.set(s,[]),this.pendingCanvasMutations.get(s).push(d)};const{sampling:r="all",win:n,blockClass:i,blockSelector:o,recordCanvas:a,dataURLOptions:u}=t;this.mutationCb=t.mutationCb,this.mirror=t.mirror,a&&r==="all"&&this.initCanvasMutationObserver(n,i,o),a&&typeof r=="number"&&this.initCanvasFPSObserver(r,n,i,o,{dataURLOptions:u})}initCanvasFPSObserver(t,r,n,i,o){const a=yr(r,n,i,!0),u=new Map,s=new ii;s.onmessage=g=>{const{id:m}=g.data;if(u.set(m,!1),!("base64"in g.data))return;const{base64:v,type:w,width:S,height:y}=g.data;this.mutationCb({id:m,type:we["2D"],commands:[{property:"clearRect",args:[0,0,S,y]},{property:"drawImage",args:[{rr_type:"ImageBitmap",args:[{rr_type:"Blob",data:[{rr_type:"ArrayBuffer",base64:v}],type:w}]},0,0]}]})};const d=1e3/t;let l=0,h;const p=()=>{const g=[];return r.document.querySelectorAll("canvas").forEach(m=>{z(m,n,i,!0)||g.push(m)}),g},f=g=>{if(l&&g-l<d){h=requestAnimationFrame(f);return}l=g,p().forEach(m=>Jn(this,void 0,void 0,function*(){var v;const w=this.mirror.getId(m);if(u.get(w)||m.width===0||m.height===0)return;if(u.set(w,!0),["webgl","webgl2"].includes(m.__context)){const y=m.getContext(m.__context);((v=y?.getContextAttributes())===null||v===void 0?void 0:v.preserveDrawingBuffer)===!1&&y.clear(y.COLOR_BUFFER_BIT)}const S=yield createImageBitmap(m);s.postMessage({id:w,bitmap:S,width:m.width,height:m.height,dataURLOptions:o.dataURLOptions},[S])})),h=requestAnimationFrame(f)};h=requestAnimationFrame(f),this.resetObservers=()=>{a(),cancelAnimationFrame(h)}}initCanvasMutationObserver(t,r,n){this.startRAFTimestamping(),this.startPendingCanvasMutationFlusher();const i=yr(t,r,n,!1),o=Yn(this.processMutation.bind(this),t,r,n),a=ei(this.processMutation.bind(this),t,r,n,this.mirror);this.resetObservers=()=>{i(),o(),a()}}startPendingCanvasMutationFlusher(){requestAnimationFrame(()=>this.flushPendingCanvasMutations())}startRAFTimestamping(){const t=r=>{this.rafStamps.latestId=r,requestAnimationFrame(t)};requestAnimationFrame(t)}flushPendingCanvasMutations(){this.pendingCanvasMutations.forEach((t,r)=>{const n=this.mirror.getId(r);this.flushPendingCanvasMutationFor(r,n)}),requestAnimationFrame(()=>this.flushPendingCanvasMutations())}flushPendingCanvasMutationFor(t,r){if(this.frozen||this.locked)return;const n=this.pendingCanvasMutations.get(t);if(!n||r===-1)return;const i=n.map(a=>Vn(a,["type"])),{type:o}=n[0];this.mutationCb({id:r,type:o,commands:i}),this.pendingCanvasMutations.delete(t)}}class si{constructor(t){this.trackedLinkElements=new WeakSet,this.styleMirror=new Cn,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;const n={id:r,styleIds:[]},i=[];for(const o of t){let a;this.styleMirror.has(o)?a=this.styleMirror.getId(o):(a=this.styleMirror.add(o),i.push({styleId:a,rules:Array.from(o.rules||CSSRule,(u,s)=>({rule:Ft(u),index:s}))})),n.styleIds.push(a)}i.length>0&&(n.styles=i),this.adoptedStyleSheetCb(n)}reset(){this.styleMirror.reset(),this.trackedLinkElements=new WeakSet}trackStylesheetInLinkElement(t){}}class ai{constructor(){this.nodeMap=new WeakMap,this.loop=!0,this.periodicallyClear()}periodicallyClear(){requestAnimationFrame(()=>{this.clear(),this.loop&&this.periodicallyClear()})}inOtherBuffer(t,r){const n=this.nodeMap.get(t);return n&&Array.from(n).some(i=>i!==r)}add(t,r){this.nodeMap.set(t,(this.nodeMap.get(t)||new Set).add(r))}clear(){this.nodeMap=new WeakMap}destroy(){this.loop=!1}}function F(e){return Object.assign(Object.assign({},e),{timestamp:Ge()})}let L,Ye,yt,Ze=!1;const X=Zr();function Ne(e={}){const{emit:t,checkoutEveryNms:r,checkoutEveryNth:n,blockClass:i="rr-block",blockSelector:o=null,ignoreClass:a="rr-ignore",ignoreSelector:u=null,maskTextClass:s="rr-mask",maskTextSelector:d=null,inlineStylesheet:l=!0,maskAllInputs:h,maskInputOptions:p,slimDOMOptions:f,maskInputFn:g,maskTextFn:m,hooks:v,packFn:w,sampling:S={},dataURLOptions:y={},mousemoveWait:b,recordDOM:I=!0,recordCanvas:U=!1,recordCrossOriginIframes:B=!1,recordAfter:k=e.recordAfter==="DOMContentLoaded"?e.recordAfter:"load",userTriggeredOnInput:N=!1,collectFonts:V=!1,inlineImages:J=!1,plugins:O,keepIframeSrcFn:fe=()=>!1,ignoreCSSAttributes:$=new Set([]),errorHandler:ue}=e;Tn(ue);const te=B?window.parent===window:!0;let at=!1;if(!te)try{window.parent.document&&(at=!1)}catch{at=!0}if(te&&!t)throw new Error("emit function is required");b!==void 0&&S.mousemove===void 0&&(S.mousemove=b),X.reset();const kt=h===!0?{color:!0,date:!0,"datetime-local":!0,email:!0,month:!0,number:!0,range:!0,search:!0,tel:!0,text:!0,time:!0,url:!0,week:!0,textarea:!0,select:!0,password:!0}:p!==void 0?p:{password:!0},Nt=f===!0||f==="all"?{script:!0,comment:!0,headFavicon:!0,headWhitespace:!0,headMetaSocial:!0,headMetaRobots:!0,headMetaHttpEquiv:!0,headMetaVerification:!0,headMetaAuthorship:f==="all",headMetaDescKeywords:f==="all"}:f||{};_n();let $r,Dt=0;const Hr=M=>{for(const Y of O||[])Y.eventProcessor&&(M=Y.eventProcessor(M));return w&&!at&&(M=w(M)),M};L=(M,Y)=>{var A;if(!((A=le[0])===null||A===void 0)&&A.isFrozen()&&M.type!==E.FullSnapshot&&!(M.type===E.IncrementalSnapshot&&M.data.source===_.Mutation)&&le.forEach(H=>H.unfreeze()),te)t?.(Hr(M),Y);else if(at){const H={type:"rrweb",event:Hr(M),origin:window.location.origin,isCheckout:Y};window.parent.postMessage(H,"*")}if(M.type===E.FullSnapshot)$r=M,Dt=0;else if(M.type===E.IncrementalSnapshot){if(M.data.source===_.Mutation&&M.data.isAttachIframe)return;Dt++;const H=n&&Dt>=n,me=r&&M.timestamp-$r.timestamp>r;(H||me)&&Ye(!0)}};const ut=M=>{L(F({type:E.IncrementalSnapshot,data:Object.assign({source:_.Mutation},M)}))},jr=M=>L(F({type:E.IncrementalSnapshot,data:Object.assign({source:_.Scroll},M)})),Gr=M=>L(F({type:E.IncrementalSnapshot,data:Object.assign({source:_.CanvasMutation},M)})),Bi=M=>L(F({type:E.IncrementalSnapshot,data:Object.assign({source:_.AdoptedStyleSheet},M)})),he=new si({mutationCb:ut,adoptedStyleSheetCb:Bi}),pe=new jn({mirror:X,mutationCb:ut,stylesheetManager:he,recordCrossOriginIframes:B,wrappedEmit:L});for(const M of O||[])M.getMirror&&M.getMirror({nodeMirror:X,crossOriginIframeMirror:pe.crossOriginIframeMirror,crossOriginIframeStyleMirror:pe.crossOriginIframeStyleMirror});const At=new ai;yt=new oi({recordCanvas:U,mutationCb:Gr,win:window,blockClass:i,blockSelector:o,mirror:X,sampling:S.canvas,dataURLOptions:y});const ct=new Gn({mutationCb:ut,scrollCb:jr,bypassOptions:{blockClass:i,blockSelector:o,maskTextClass:s,maskTextSelector:d,inlineStylesheet:l,maskInputOptions:kt,dataURLOptions:y,maskTextFn:m,maskInputFn:g,recordCanvas:U,inlineImages:J,sampling:S,slimDOMOptions:Nt,iframeManager:pe,stylesheetManager:he,canvasManager:yt,keepIframeSrcFn:fe,processedNodeManager:At},mirror:X});Ye=(M=!1)=>{if(!I)return;L(F({type:E.Meta,data:{href:window.location.href,width:Xt(),height:Jt()}}),M),he.reset(),ct.init(),le.forEach(A=>A.lock());const Y=In(document,{mirror:X,blockClass:i,blockSelector:o,maskTextClass:s,maskTextSelector:d,inlineStylesheet:l,maskAllInputs:kt,maskTextFn:m,slimDOM:Nt,dataURLOptions:y,recordCanvas:U,inlineImages:J,onSerialize:A=>{Yt(A,X)&&pe.addIframe(A),Zt(A,X)&&he.trackLinkElement(A),mt(A)&&ct.addShadowRoot(A.shadowRoot,document)},onIframeLoad:(A,H)=>{pe.attachIframe(A,H),ct.observeAttachShadow(A)},onStylesheetLoad:(A,H)=>{he.attachLinkElement(A,H)},keepIframeSrcFn:fe});if(!Y)return console.warn("Failed to snapshot the document");L(F({type:E.FullSnapshot,data:{node:Y,initialOffset:Vt(window)}}),M),le.forEach(A=>A.unlock()),document.adoptedStyleSheets&&document.adoptedStyleSheets.length>0&&he.adoptStyleSheets(document.adoptedStyleSheets,X.getId(document))};try{const M=[],Y=H=>{var me;return C(Hn)({mutationCb:ut,mousemoveCb:(D,Lt)=>L(F({type:E.IncrementalSnapshot,data:{source:Lt,positions:D}})),mouseInteractionCb:D=>L(F({type:E.IncrementalSnapshot,data:Object.assign({source:_.MouseInteraction},D)})),scrollCb:jr,viewportResizeCb:D=>L(F({type:E.IncrementalSnapshot,data:Object.assign({source:_.ViewportResize},D)})),inputCb:D=>L(F({type:E.IncrementalSnapshot,data:Object.assign({source:_.Input},D)})),mediaInteractionCb:D=>L(F({type:E.IncrementalSnapshot,data:Object.assign({source:_.MediaInteraction},D)})),styleSheetRuleCb:D=>L(F({type:E.IncrementalSnapshot,data:Object.assign({source:_.StyleSheetRule},D)})),styleDeclarationCb:D=>L(F({type:E.IncrementalSnapshot,data:Object.assign({source:_.StyleDeclaration},D)})),canvasMutationCb:Gr,fontCb:D=>L(F({type:E.IncrementalSnapshot,data:Object.assign({source:_.Font},D)})),selectionCb:D=>{L(F({type:E.IncrementalSnapshot,data:Object.assign({source:_.Selection},D)}))},customElementCb:D=>{L(F({type:E.IncrementalSnapshot,data:Object.assign({source:_.CustomElement},D)}))},blockClass:i,ignoreClass:a,ignoreSelector:u,maskTextClass:s,maskTextSelector:d,maskInputOptions:kt,inlineStylesheet:l,sampling:S,recordDOM:I,recordCanvas:U,inlineImages:J,userTriggeredOnInput:N,collectFonts:V,doc:H,maskInputFn:g,maskTextFn:m,keepIframeSrcFn:fe,blockSelector:o,slimDOMOptions:Nt,dataURLOptions:y,mirror:X,iframeManager:pe,stylesheetManager:he,shadowDomManager:ct,processedNodeManager:At,canvasManager:yt,ignoreCSSAttributes:$,plugins:((me=O?.filter(D=>D.observer))===null||me===void 0?void 0:me.map(D=>({observer:D.observer,options:D.options,callback:Lt=>L(F({type:E.Plugin,data:{plugin:D.name,payload:Lt}}))})))||[]},v)};pe.addLoadListener(H=>{try{M.push(Y(H.contentDocument))}catch(me){console.warn(me)}});const A=()=>{Ye(),M.push(Y(document)),Ze=!0};return document.readyState==="interactive"||document.readyState==="complete"?A():(M.push(q("DOMContentLoaded",()=>{L(F({type:E.DomContentLoaded,data:{}})),k==="DOMContentLoaded"&&A()})),M.push(q("load",()=>{L(F({type:E.Load,data:{}})),k==="load"&&A()},window))),()=>{M.forEach(H=>H()),At.destroy(),Ze=!1,kn()}}catch(M){console.warn(M)}}Ne.addCustomEvent=(e,t)=>{if(!Ze)throw new Error("please add custom event after start recording");L(F({type:E.Custom,data:{tag:e,payload:t}}))},Ne.freezePage=()=>{le.forEach(e=>e.freeze())},Ne.takeFullSnapshot=e=>{if(!Ze)throw new Error("please take full snapshot after start recording");Ye(e)},Ne.mirror=X;var br=x.setImmediate,se,vt,bt,Sr=Object.prototype.toString,ui=typeof br<"u"?function(t){return br(t)}:setTimeout;try{Object.defineProperty({},"x",{}),se=function(t,r,n,i){return Object.defineProperty(t,r,{value:n,writable:!0,configurable:i!==!1})}}catch{se=function(r,n,i){return r[n]=i,r}}bt=function(){var t,r,n;function i(o,a){this.fn=o,this.self=a,this.next=void 0}return{add:function(a,u){n=new i(a,u),r?r.next=n:t=n,r=n,n=void 0},drain:function(){var a=t;for(t=r=vt=void 0;a;)a.fn.call(a.self),a=a.next}}}();function et(e,t){bt.add(e,t),vt||(vt=ui(bt.drain))}function wr(e){var t,r=typeof e;return e!==null&&(r==="object"||r==="function")&&(t=e.then),typeof t=="function"?t:!1}function St(){for(var e=0;e<this.chain.length;e++)ci(this,this.state===1?this.chain[e].success:this.chain[e].failure,this.chain[e]);this.chain.length=0}function ci(e,t,r){var n,i;try{t===!1?r.reject(e.msg):(t===!0?n=e.msg:n=t.call(void 0,e.msg),n===r.promise?r.reject(TypeError("Promise-chain cycle")):(i=wr(n))?i.call(n,r.resolve,r.reject):r.resolve(n))}catch(o){r.reject(o)}}function Ir(e){var t,r=this;if(!r.triggered){r.triggered=!0,r.def&&(r=r.def);try{(t=wr(e))?et(function(){var n=new _r(r);try{t.call(e,function(){Ir.apply(n,arguments)},function(){De.apply(n,arguments)})}catch(i){De.call(n,i)}}):(r.msg=e,r.state=1,r.chain.length>0&&et(St,r))}catch(n){De.call(new _r(r),n)}}}function De(e){var t=this;t.triggered||(t.triggered=!0,t.def&&(t=t.def),t.msg=e,t.state=2,t.chain.length>0&&et(St,t))}function Mr(e,t,r,n){for(var i=0;i<t.length;i++)(function(a){e.resolve(t[a]).then(function(s){r(a,s)},n)})(i)}function _r(e){this.def=e,this.triggered=!1}function li(e){this.promise=e,this.state=0,this.triggered=!1,this.chain=[],this.msg=void 0}function ae(e){if(typeof e!="function")throw TypeError("Not a function");if(this.__NPO__!==0)throw TypeError("Not a promise");this.__NPO__=1;var t=new li(this);this.then=function(n,i){var o={success:typeof n=="function"?n:!0,failure:typeof i=="function"?i:!1};return o.promise=new this.constructor(function(u,s){if(typeof u!="function"||typeof s!="function")throw TypeError("Not a function");o.resolve=u,o.reject=s}),t.chain.push(o),t.state!==0&&et(St,t),o.promise},this.catch=function(n){return this.then(void 0,n)};try{e.call(void 0,function(n){Ir.call(t,n)},function(n){De.call(t,n)})}catch(r){De.call(t,r)}}var Cr=se({},"constructor",ae,!1);ae.prototype=Cr,se(Cr,"__NPO__",0,!1),se(ae,"resolve",function(t){var r=this;return t&&typeof t=="object"&&t.__NPO__===1?t:new r(function(i,o){if(typeof i!="function"||typeof o!="function")throw TypeError("Not a function");i(t)})}),se(ae,"reject",function(t){return new this(function(n,i){if(typeof n!="function"||typeof i!="function")throw TypeError("Not a function");i(t)})}),se(ae,"all",function(t){var r=this;return Sr.call(t)!=="[object Array]"?r.reject(TypeError("Not an array")):t.length===0?r.resolve([]):new r(function(i,o){if(typeof i!="function"||typeof o!="function")throw TypeError("Not a function");var a=t.length,u=Array(a),s=0;Mr(r,t,function(l,h){u[l]=h,++s===a&&i(u)},o)})}),se(ae,"race",function(t){var r=this;return Sr.call(t)!=="[object Array]"?r.reject(TypeError("Not an array")):new r(function(i,o){if(typeof i!="function"||typeof o!="function")throw TypeError("Not a function");Mr(r,t,function(u,s){i(s)},o)})});var R;typeof Promise<"u"&&Promise.toString().indexOf("[native code]")!==-1?R=Promise:R=ae;var wt=(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))(wt||{}),Z=(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))(Z||{}),It={DEBUG:!1,LIB_VERSION:"2.62.0"},tt=24*60*60*1e3,Mt=8*1e3,rt=Array.prototype,di=Function.prototype,Er=Object.prototype,de=rt.slice,Ae=Er.toString,nt=Er.hasOwnProperty,Le=x.console,Pe=x.navigator,G=x.document,it=x.opera,Rr=x.screen,Me=Pe.userAgent,_t=di.bind,Or=rt.forEach,xr=rt.indexOf,Tr=rt.map,fi=Array.isArray,Ct={},c={trim:function(e){return e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"")}},K={log:function(){},warn:function(){},error:function(){},critical:function(){if(!c.isUndefined(Le)&&Le){var e=["Mixpanel error:"].concat(c.toArray(arguments));try{Le.error.apply(Le,e)}catch{c.each(e,function(r){Le.error(r)})}}}},Et=function(e,t){return function(){return arguments[0]="["+t+"] "+arguments[0],e.apply(K,arguments)}},Fe=function(e){return{log:Et(K.log,e),error:Et(K.error,e),critical:Et(K.critical,e)}};c.bind=function(e,t){var r,n;if(_t&&e.bind===_t)return _t.apply(e,de.call(arguments,1));if(!c.isFunction(e))throw new TypeError;return r=de.call(arguments,2),n=function(){if(!(this instanceof n))return e.apply(t,r.concat(de.call(arguments)));var i={};i.prototype=e.prototype;var o=new i;i.prototype=null;var a=e.apply(o,r.concat(de.call(arguments)));return Object(a)===a?a:o},n},c.each=function(e,t,r){if(e!=null){if(Or&&e.forEach===Or)e.forEach(t,r);else if(e.length===+e.length){for(var n=0,i=e.length;n<i;n++)if(n in e&&t.call(r,e[n],n,e)===Ct)return}else for(var o in e)if(nt.call(e,o)&&t.call(r,e[o],o,e)===Ct)return}},c.extend=function(e){return c.each(de.call(arguments,1),function(t){for(var r in t)t[r]!==void 0&&(e[r]=t[r])}),e},c.isArray=fi||function(e){return Ae.call(e)==="[object Array]"},c.isFunction=function(e){try{return/^\s*\bfunction\b/.test(e)}catch{return!1}},c.isArguments=function(e){return!!(e&&nt.call(e,"callee"))},c.toArray=function(e){return e?e.toArray?e.toArray():c.isArray(e)||c.isArguments(e)?de.call(e):c.values(e):[]},c.map=function(e,t,r){if(Tr&&e.map===Tr)return e.map(t,r);var n=[];return c.each(e,function(i){n.push(t.call(r,i))}),n},c.keys=function(e){var t=[];return e===null||c.each(e,function(r,n){t[t.length]=n}),t},c.values=function(e){var t=[];return e===null||c.each(e,function(r){t[t.length]=r}),t},c.include=function(e,t){var r=!1;return e===null?r:xr&&e.indexOf===xr?e.indexOf(t)!=-1:(c.each(e,function(n){if(r||(r=n===t))return Ct}),r)},c.includes=function(e,t){return e.indexOf(t)!==-1},c.inherit=function(e,t){return e.prototype=new t,e.prototype.constructor=e,e.superclass=t.prototype,e},c.isObject=function(e){return e===Object(e)&&!c.isArray(e)},c.isEmptyObject=function(e){if(c.isObject(e)){for(var t in e)if(nt.call(e,t))return!1;return!0}return!1},c.isUndefined=function(e){return e===void 0},c.isString=function(e){return Ae.call(e)=="[object String]"},c.isDate=function(e){return Ae.call(e)=="[object Date]"},c.isNumber=function(e){return Ae.call(e)=="[object Number]"},c.isElement=function(e){return!!(e&&e.nodeType===1)},c.encodeDates=function(e){return c.each(e,function(t,r){c.isDate(t)?e[r]=c.formatDate(t):c.isObject(t)&&(e[r]=c.encodeDates(t))}),e},c.timestamp=function(){return Date.now=Date.now||function(){return+new Date},Date.now()},c.formatDate=function(e){function t(r){return r<10?"0"+r:r}return e.getUTCFullYear()+"-"+t(e.getUTCMonth()+1)+"-"+t(e.getUTCDate())+"T"+t(e.getUTCHours())+":"+t(e.getUTCMinutes())+":"+t(e.getUTCSeconds())},c.strip_empty_properties=function(e){var t={};return c.each(e,function(r,n){c.isString(r)&&r.length>0&&(t[n]=r)}),t},c.truncate=function(e,t){var r;return typeof e=="string"?r=e.slice(0,t):c.isArray(e)?(r=[],c.each(e,function(n){r.push(c.truncate(n,t))})):c.isObject(e)?(r={},c.each(e,function(n,i){r[i]=c.truncate(n,t)})):r=e,r},c.JSONEncode=function(){return function(e){var t=e,r=function(i){var o=/[\\"\x00-\x1f\x7f-\x9f\u00ad\u0600-\u0604\u070f\u17b4\u17b5\u200c-\u200f\u2028-\u202f\u2060-\u206f\ufeff\ufff0-\uffff]/g,a={"\b":"\\b"," ":"\\t","\n":"\\n","\f":"\\f","\r":"\\r",'"':'\\"',"\\":"\\\\"};return o.lastIndex=0,o.test(i)?'"'+i.replace(o,function(u){var s=a[u];return typeof s=="string"?s:"\\u"+("0000"+u.charCodeAt(0).toString(16)).slice(-4)})+'"':'"'+i+'"'},n=function(i,o){var a="",u=" ",s=0,d="",l="",h=0,p=a,f=[],g=o[i];switch(g&&typeof g=="object"&&typeof g.toJSON=="function"&&(g=g.toJSON(i)),typeof g){case"string":return r(g);case"number":return isFinite(g)?String(g):"null";case"boolean":case"null":return String(g);case"object":if(!g)return"null";if(a+=u,f=[],Ae.apply(g)==="[object Array]"){for(h=g.length,s=0;s<h;s+=1)f[s]=n(s,g)||"null";return l=f.length===0?"[]":a?`[
33
- `+a+f.join(`,
34
- `+a)+`
35
- `+p+"]":"["+f.join(",")+"]",a=p,l}for(d in g)nt.call(g,d)&&(l=n(d,g),l&&f.push(r(d)+(a?": ":":")+l));return l=f.length===0?"{}":a?"{"+f.join(",")+p+"}":"{"+f.join(",")+"}",a=p,l}};return n("",{"":t})}}(),c.JSONDecode=function(){var e,t,r={'"':'"',"\\":"\\","/":"/",b:"\b",f:"\f",n:`
36
- `,r:"\r",t:" "},n,i=function(f){var g=new SyntaxError(f);throw g.at=e,g.text=n,g},o=function(f){return f&&f!==t&&i("Expected '"+f+"' instead of '"+t+"'"),t=n.charAt(e),e+=1,t},a=function(){var f,g="";for(t==="-"&&(g="-",o("-"));t>="0"&&t<="9";)g+=t,o();if(t===".")for(g+=".";o()&&t>="0"&&t<="9";)g+=t;if(t==="e"||t==="E")for(g+=t,o(),(t==="-"||t==="+")&&(g+=t,o());t>="0"&&t<="9";)g+=t,o();if(f=+g,!isFinite(f))i("Bad number");else return f},u=function(){var f,g,m="",v;if(t==='"')for(;o();){if(t==='"')return o(),m;if(t==="\\")if(o(),t==="u"){for(v=0,g=0;g<4&&(f=parseInt(o(),16),!!isFinite(f));g+=1)v=v*16+f;m+=String.fromCharCode(v)}else if(typeof r[t]=="string")m+=r[t];else break;else m+=t}i("Bad string")},s=function(){for(;t&&t<=" ";)o()},d=function(){switch(t){case"t":return o("t"),o("r"),o("u"),o("e"),!0;case"f":return o("f"),o("a"),o("l"),o("s"),o("e"),!1;case"n":return o("n"),o("u"),o("l"),o("l"),null}i('Unexpected "'+t+'"')},l,h=function(){var f=[];if(t==="["){if(o("["),s(),t==="]")return o("]"),f;for(;t;){if(f.push(l()),s(),t==="]")return o("]"),f;o(","),s()}}i("Bad array")},p=function(){var f,g={};if(t==="{"){if(o("{"),s(),t==="}")return o("}"),g;for(;t;){if(f=u(),s(),o(":"),Object.hasOwnProperty.call(g,f)&&i('Duplicate key "'+f+'"'),g[f]=l(),s(),t==="}")return o("}"),g;o(","),s()}}i("Bad object")};return l=function(){switch(s(),t){case"{":return p();case"[":return h();case'"':return u();case"-":return a();default:return t>="0"&&t<="9"?a():d()}},function(f){var g;return n=f,e=0,t=" ",g=l(),s(),t&&i("Syntax error"),g}}(),c.base64Encode=function(e){var t="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=",r,n,i,o,a,u,s,d,l=0,h=0,p="",f=[];if(!e)return e;e=c.utf8Encode(e);do r=e.charCodeAt(l++),n=e.charCodeAt(l++),i=e.charCodeAt(l++),d=r<<16|n<<8|i,o=d>>18&63,a=d>>12&63,u=d>>6&63,s=d&63,f[h++]=t.charAt(o)+t.charAt(a)+t.charAt(u)+t.charAt(s);while(l<e.length);switch(p=f.join(""),e.length%3){case 1:p=p.slice(0,-2)+"==";break;case 2:p=p.slice(0,-1)+"=";break}return p},c.utf8Encode=function(e){e=(e+"").replace(/\r\n/g,`
37
- `).replace(/\r/g,`
38
- `);var t="",r,n,i=0,o;for(r=n=0,i=e.length,o=0;o<i;o++){var a=e.charCodeAt(o),u=null;a<128?n++:a>127&&a<2048?u=String.fromCharCode(a>>6|192,a&63|128):u=String.fromCharCode(a>>12|224,a>>6&63|128,a&63|128),u!==null&&(n>r&&(t+=e.substring(r,n)),t+=u,r=n=o+1)}return n>r&&(t+=e.substring(r,e.length)),t},c.UUID=function(){try{return x.crypto.randomUUID()}catch{for(var e=new Array(36),t=0;t<36;t++)e[t]=Math.floor(Math.random()*16);return e[14]=4,e[19]=e[19]&=-5,e[19]=e[19]|=8,e[8]=e[13]=e[18]=e[23]="-",c.map(e,function(n){return n.toString(16)}).join("")}};var kr=["ahrefsbot","ahrefssiteaudit","amazonbot","baiduspider","bingbot","bingpreview","chrome-lighthouse","facebookexternal","petalbot","pinterest","screaming frog","yahoo! slurp","yandex","adsbot-google","apis-google","duplexweb-google","feedfetcher-google","google favicon","google web preview","google-read-aloud","googlebot","googleweblight","mediapartners-google","storebot-google"];c.isBlockedUA=function(e){var t;for(e=e.toLowerCase(),t=0;t<kr.length;t++)if(e.indexOf(kr[t])!==-1)return!0;return!1},c.HTTPBuildQuery=function(e,t){var r,n,i=[];return c.isUndefined(t)&&(t="&"),c.each(e,function(o,a){r=encodeURIComponent(o.toString()),n=encodeURIComponent(a),i[i.length]=n+"="+r}),i.join(t)},c.getQueryParam=function(e,t){t=t.replace(/[[]/g,"\\[").replace(/[\]]/g,"\\]");var r="[\\?&]"+t+"=([^&#]*)",n=new RegExp(r),i=n.exec(e);if(i===null||i&&typeof i[1]!="string"&&i[1].length)return"";var o=i[1];try{o=decodeURIComponent(o)}catch{K.error("Skipping decoding for malformed query param: "+o)}return o.replace(/\+/g," ")},c.cookie={get:function(e){for(var t=e+"=",r=G.cookie.split(";"),n=0;n<r.length;n++){for(var i=r[n];i.charAt(0)==" ";)i=i.substring(1,i.length);if(i.indexOf(t)===0)return decodeURIComponent(i.substring(t.length,i.length))}return null},parse:function(e){var t;try{t=c.JSONDecode(c.cookie.get(e))||{}}catch{}return t},set_seconds:function(e,t,r,n,i,o,a){var u="",s="",d="";if(a)u="; domain="+a;else if(n){var l=Ar(G.location.hostname);u=l?"; domain=."+l:""}if(r){var h=new Date;h.setTime(h.getTime()+r*1e3),s="; expires="+h.toGMTString()}o&&(i=!0,d="; SameSite=None"),i&&(d+="; secure"),G.cookie=e+"="+encodeURIComponent(t)+s+"; path=/"+u+d},set:function(e,t,r,n,i,o,a){var u="",s="",d="";if(a)u="; domain="+a;else if(n){var l=Ar(G.location.hostname);u=l?"; domain=."+l:""}if(r){var h=new Date;h.setTime(h.getTime()+r*24*60*60*1e3),s="; expires="+h.toGMTString()}o&&(i=!0,d="; SameSite=None"),i&&(d+="; secure");var p=e+"="+encodeURIComponent(t)+s+"; path=/"+u+d;return G.cookie=p,p},remove:function(e,t,r){c.cookie.set(e,"",-1,t,!1,!1,r)}};var Nr=function(e){var t=!0;try{var r="__mplss_"+xt(8),n="xyz";e.setItem(r,n),e.getItem(r)!==n&&(t=!1),e.removeItem(r)}catch{t=!1}return t},Rt=null,Be=function(e,t){return Rt!==null&&!t?Rt:Rt=Nr(e||x.localStorage)},Ot=null,hi=function(e,t){return Ot!==null&&!t?Ot:Ot=Nr(e||x.sessionStorage)};function Dr(e,t,r){var n=function(i){K.error(t+" error: "+i)};return{is_supported:function(i){var o=r(e,i);return o||K.error(t+" unsupported"),o},error:n,get:function(i){try{return e.getItem(i)}catch(o){n(o)}return null},parse:function(i){try{return c.JSONDecode(e.getItem(i))||{}}catch{}return null},set:function(i,o){try{e.setItem(i,o)}catch(a){n(a)}},remove:function(i){try{e.removeItem(i)}catch(o){n(o)}}}}c.localStorage=Dr(x.localStorage,"localStorage",Be),c.sessionStorage=Dr(x.sessionStorage,"sessionStorage",hi),c.register_event=function(){var e=function(n,i,o,a,u){if(!n){K.error("No valid element provided to register_event");return}if(n.addEventListener&&!a)n.addEventListener(i,o,!!u);else{var s="on"+i,d=n[s];n[s]=t(n,o,d)}};function t(n,i,o){var a=function(u){if(u=u||r(x.event),!!u){var s=!0,d,l;return c.isFunction(o)&&(d=o(u)),l=i.call(n,u),(d===!1||l===!1)&&(s=!1),s}};return a}function r(n){return n&&(n.preventDefault=r.preventDefault,n.stopPropagation=r.stopPropagation),n}return r.preventDefault=function(){this.returnValue=!1},r.stopPropagation=function(){this.cancelBubble=!0},e}();var pi=new RegExp('^(\\w*)\\[(\\w+)([=~\\|\\^\\$\\*]?)=?"?([^\\]"]*)"?\\]$');c.dom_query=function(){function e(i){return i.all?i.all:i.getElementsByTagName("*")}var t=/[\t\r\n]/g;function r(i,o){var a=" "+o+" ";return(" "+i.className+" ").replace(t," ").indexOf(a)>=0}function n(i){if(!G.getElementsByTagName)return[];var o=i.split(" "),a,u,s,d,l,h,p,f,g,m,v=[G];for(h=0;h<o.length;h++){if(a=o[h].replace(/^\s+/,"").replace(/\s+$/,""),a.indexOf("#")>-1){u=a.split("#"),s=u[0];var w=u[1],S=G.getElementById(w);if(!S||s&&S.nodeName.toLowerCase()!=s)return[];v=[S];continue}if(a.indexOf(".")>-1){u=a.split("."),s=u[0];var y=u[1];for(s||(s="*"),d=[],l=0,p=0;p<v.length;p++)for(s=="*"?g=e(v[p]):g=v[p].getElementsByTagName(s),f=0;f<g.length;f++)d[l++]=g[f];for(v=[],m=0,p=0;p<d.length;p++)d[p].className&&c.isString(d[p].className)&&r(d[p],y)&&(v[m++]=d[p]);continue}var b=a.match(pi);if(b){s=b[1];var I=b[2],U=b[3],B=b[4];for(s||(s="*"),d=[],l=0,p=0;p<v.length;p++)for(s=="*"?g=e(v[p]):g=v[p].getElementsByTagName(s),f=0;f<g.length;f++)d[l++]=g[f];v=[],m=0;var k;switch(U){case"=":k=function(N){return N.getAttribute(I)==B};break;case"~":k=function(N){return N.getAttribute(I).match(new RegExp("\\b"+B+"\\b"))};break;case"|":k=function(N){return N.getAttribute(I).match(new RegExp("^"+B+"-?"))};break;case"^":k=function(N){return N.getAttribute(I).indexOf(B)===0};break;case"$":k=function(N){return N.getAttribute(I).lastIndexOf(B)==N.getAttribute(I).length-B.length};break;case"*":k=function(N){return N.getAttribute(I).indexOf(B)>-1};break;default:k=function(N){return N.getAttribute(I)}}for(v=[],m=0,p=0;p<d.length;p++)k(d[p])&&(v[m++]=d[p]);continue}for(s=a,d=[],l=0,p=0;p<v.length;p++)for(g=v[p].getElementsByTagName(s),f=0;f<g.length;f++)d[l++]=g[f];v=d}return v}return function(i){return c.isElement(i)?[i]:c.isObject(i)&&!c.isUndefined(i.length)?i:n.call(this,i)}}();var mi=["utm_source","utm_medium","utm_campaign","utm_content","utm_term","utm_id","utm_source_platform","utm_campaign_id","utm_creative_format","utm_marketing_tactic"],gi=["dclid","fbclid","gclid","ko_click_id","li_fat_id","msclkid","sccid","ttclid","twclid","wbraid"];c.info={campaignParams:function(e){var t="",r={};return c.each(mi,function(n){t=c.getQueryParam(G.URL,n),t.length?r[n]=t:e!==void 0&&(r[n]=e)}),r},clickParams:function(){var e="",t={};return c.each(gi,function(r){e=c.getQueryParam(G.URL,r),e.length&&(t[r]=e)}),t},marketingParams:function(){return c.extend(c.info.campaignParams(),c.info.clickParams())},searchEngine:function(e){return e.search("https?://(.*)google.([^/?]*)")===0?"google":e.search("https?://(.*)bing.com")===0?"bing":e.search("https?://(.*)yahoo.com")===0?"yahoo":e.search("https?://(.*)duckduckgo.com")===0?"duckduckgo":null},searchInfo:function(e){var t=c.info.searchEngine(e),r=t!="yahoo"?"q":"p",n={};if(t!==null){n.$search_engine=t;var i=c.getQueryParam(e,r);i.length&&(n.mp_keyword=i)}return n},browser:function(e,t,r){return t=t||"",r||c.includes(e," OPR/")?c.includes(e,"Mini")?"Opera Mini":"Opera":/(BlackBerry|PlayBook|BB10)/i.test(e)?"BlackBerry":c.includes(e,"IEMobile")||c.includes(e,"WPDesktop")?"Internet Explorer Mobile":c.includes(e,"SamsungBrowser/")?"Samsung Internet":c.includes(e,"Edge")||c.includes(e,"Edg/")?"Microsoft Edge":c.includes(e,"FBIOS")?"Facebook Mobile":c.includes(e,"Chrome")?"Chrome":c.includes(e,"CriOS")?"Chrome iOS":c.includes(e,"UCWEB")||c.includes(e,"UCBrowser")?"UC Browser":c.includes(e,"FxiOS")?"Firefox iOS":c.includes(t,"Apple")?c.includes(e,"Mobile")?"Mobile Safari":"Safari":c.includes(e,"Android")?"Android Mobile":c.includes(e,"Konqueror")?"Konqueror":c.includes(e,"Firefox")?"Firefox":c.includes(e,"MSIE")||c.includes(e,"Trident/")?"Internet Explorer":c.includes(e,"Gecko")?"Mozilla":""},browserVersion:function(e,t,r){var n=c.info.browser(e,t,r),i={"Internet Explorer Mobile":/rv:(\d+(\.\d+)?)/,"Microsoft Edge":/Edge?\/(\d+(\.\d+)?)/,Chrome:/Chrome\/(\d+(\.\d+)?)/,"Chrome iOS":/CriOS\/(\d+(\.\d+)?)/,"UC Browser":/(UCBrowser|UCWEB)\/(\d+(\.\d+)?)/,Safari:/Version\/(\d+(\.\d+)?)/,"Mobile Safari":/Version\/(\d+(\.\d+)?)/,Opera:/(Opera|OPR)\/(\d+(\.\d+)?)/,Firefox:/Firefox\/(\d+(\.\d+)?)/,"Firefox iOS":/FxiOS\/(\d+(\.\d+)?)/,Konqueror:/Konqueror:(\d+(\.\d+)?)/,BlackBerry:/BlackBerry (\d+(\.\d+)?)/,"Android Mobile":/android\s(\d+(\.\d+)?)/,"Samsung Internet":/SamsungBrowser\/(\d+(\.\d+)?)/,"Internet Explorer":/(rv:|MSIE )(\d+(\.\d+)?)/,Mozilla:/rv:(\d+(\.\d+)?)/},o=i[n];if(o===void 0)return null;var a=e.match(o);return a?parseFloat(a[a.length-2]):null},os:function(){var e=Me;return/Windows/i.test(e)?/Phone/.test(e)||/WPDesktop/.test(e)?"Windows Phone":"Windows":/(iPhone|iPad|iPod)/.test(e)?"iOS":/Android/.test(e)?"Android":/(BlackBerry|PlayBook|BB10)/i.test(e)?"BlackBerry":/Mac/i.test(e)?"Mac OS X":/Linux/.test(e)?"Linux":/CrOS/.test(e)?"Chrome OS":""},device:function(e){return/Windows Phone/i.test(e)||/WPDesktop/.test(e)?"Windows Phone":/iPad/.test(e)?"iPad":/iPod/.test(e)?"iPod Touch":/iPhone/.test(e)?"iPhone":/(BlackBerry|PlayBook|BB10)/i.test(e)?"BlackBerry":/Android/.test(e)?"Android":""},referringDomain:function(e){var t=e.split("/");return t.length>=3?t[2]:""},currentUrl:function(){return x.location.href},properties:function(e){return typeof e!="object"&&(e={}),c.extend(c.strip_empty_properties({$os:c.info.os(),$browser:c.info.browser(Me,Pe.vendor,it),$referrer:G.referrer,$referring_domain:c.info.referringDomain(G.referrer),$device:c.info.device(Me)}),{$current_url:c.info.currentUrl(),$browser_version:c.info.browserVersion(Me,Pe.vendor,it),$screen_height:Rr.height,$screen_width:Rr.width,mp_lib:"web",$lib_version:It.LIB_VERSION,$insert_id:xt(),time:c.timestamp()/1e3},c.strip_empty_properties(e))},people_properties:function(){return c.extend(c.strip_empty_properties({$os:c.info.os(),$browser:c.info.browser(Me,Pe.vendor,it)}),{$browser_version:c.info.browserVersion(Me,Pe.vendor,it)})},mpPageViewProperties:function(){return c.strip_empty_properties({current_page_title:G.title,current_domain:x.location.hostname,current_url_path:x.location.pathname,current_url_protocol:x.location.protocol,current_url_search:x.location.search})}};var yi=function(e,t){var r=null,n=[];return function(i){var o=this;return n.push(i),r||(r=new R(function(a){setTimeout(function(){var u=e.apply(o,[n]);r=null,n=[],a(u)},t)})),r}},xt=function(e){var t=Math.random().toString(36).substring(2,10)+Math.random().toString(36).substring(2,10);return e?t.substring(0,e):t},vi=/[a-z0-9][a-z0-9-]*\.[a-z]+$/i,bi=/[a-z0-9][a-z0-9-]+\.[a-z.]{2,6}$/i,Ar=function(e){var t=bi,r=e.split("."),n=r[r.length-1];(n.length>4||n==="com"||n==="org")&&(t=vi);var i=e.match(t);return i?i[0]:""},Si=function(){var e=x.navigator.onLine;return c.isUndefined(e)||e},Tt=function(){},ot=null,st=null;typeof JSON<"u"&&(ot=JSON.stringify,st=JSON.parse),ot=ot||c.JSONEncode,st=st||c.JSONDecode,c.info=c.info,c.info.browser=c.info.browser,c.info.browserVersion=c.info.browserVersion,c.info.device=c.info.device,c.info.properties=c.info.properties,c.isBlockedUA=c.isBlockedUA,c.isEmptyObject=c.isEmptyObject,c.isObject=c.isObject,c.JSONDecode=c.JSONDecode,c.JSONEncode=c.JSONEncode,c.toArray=c.toArray,c.NPO=ae;var wi="mixpanelBrowserDb",Lr="mixpanelRecordingEvents",Pr="mixpanelRecordingRegistry",Ii=1,Mi=[Lr,Pr],ne=function(e){this.dbPromise=null,this.storeName=e};ne.prototype._openDb=function(){return new R(function(e,t){var r=x.indexedDB.open(wi,Ii);r.onerror=function(){t(r.error)},r.onsuccess=function(){e(r.result)},r.onupgradeneeded=function(n){var i=n.target.result;Mi.forEach(function(o){i.createObjectStore(o)})}})},ne.prototype.init=function(){return x.indexedDB?(this.dbPromise||(this.dbPromise=this._openDb()),this.dbPromise.then(function(e){return e instanceof x.IDBDatabase?R.resolve():R.reject(e)})):R.reject("indexedDB is not supported in this browser")},ne.prototype.makeTransaction=function(e,t){var r=this.storeName,n=function(i){return new R(function(o,a){var u=i.transaction(r,e);u.oncomplete=function(){o(u)},u.onabort=u.onerror=function(){a(u.error)},t(u.objectStore(r))})};return this.dbPromise.then(n).catch(function(i){return i&&i.name==="InvalidStateError"?(this.dbPromise=this._openDb(),this.dbPromise.then(n)):R.reject(i)}.bind(this))},ne.prototype.setItem=function(e,t){return this.makeTransaction("readwrite",function(r){r.put(t,e)})},ne.prototype.getItem=function(e){var t;return this.makeTransaction("readonly",function(r){t=r.get(e)}).then(function(){return t.result})},ne.prototype.removeItem=function(e){return this.makeTransaction("readwrite",function(t){t.delete(e)})},ne.prototype.getAll=function(){var e;return this.makeTransaction("readonly",function(t){e=t.getAll()}).then(function(){return e.result})};var _i="__mp_opt_in_out_";function Ci(e,t){if(Ti(t))return K.warn('This browser has "Do Not Track" enabled. This will prevent the Mixpanel SDK from sending any data. To ignore the "Do Not Track" browser setting, initialize the Mixpanel instance with the config "ignore_dnt: true"'),!0;var r=xi(e,t)==="0";return r&&K.warn("You are opted out of Mixpanel tracking. This will prevent the Mixpanel SDK from sending any data."),r}function Ei(e){return ki(e,function(t){return this.get_config(t)})}function Ri(e){return e=e||{},e.persistenceType==="localStorage"?c.localStorage:c.cookie}function Oi(e,t){return t=t||{},(t.persistencePrefix||_i)+e}function xi(e,t){return Ri(t).get(Oi(e,t))}function Ti(e){if(e&&e.ignoreDnt)return!1;var t=e&&e.window||x,r=t.navigator||{},n=!1;return c.each([r.doNotTrack,r.msDoNotTrack,t.doNotTrack],function(i){c.includes([!0,1,"1","yes"],i)&&(n=!0)}),n}function ki(e,t){return function(){var r=!1;try{var n=t.call(this,"token"),i=t.call(this,"ignore_dnt"),o=t.call(this,"opt_out_tracking_persistence_type"),a=t.call(this,"opt_out_tracking_cookie_prefix"),u=t.call(this,"window");n&&(r=Ci(n,{ignoreDnt:i,persistenceType:o,persistencePrefix:a,window:u}))}catch(d){K.error("Unexpected error when checking tracking opt-out status: "+d)}if(!r)return e.apply(this,arguments);var s=arguments[arguments.length-1];typeof s=="function"&&s(0)}}var Ni=Fe("lock"),Fr=function(e,t){t=t||{},this.storageKey=e,this.storage=t.storage||x.localStorage,this.pollIntervalMS=t.pollIntervalMS||100,this.timeoutMS=t.timeoutMS||2e3,this.promiseImpl=t.promiseImpl||R};Fr.prototype.withLock=function(e,t){var r=this.promiseImpl;return new r(c.bind(function(n,i){var o=t||new Date().getTime()+"|"+Math.random(),a=new Date().getTime(),u=this.storageKey,s=this.pollIntervalMS,d=this.timeoutMS,l=this.storage,h=u+":X",p=u+":Y",f=u+":Z",g=function(y){if(new Date().getTime()-a>d){Ni.error("Timeout waiting for mutex on "+u+"; clearing lock. ["+o+"]"),l.removeItem(f),l.removeItem(p),w();return}setTimeout(function(){try{y()}catch(b){i(b)}},s*(Math.random()+.1))},m=function(y,b){y()?b():g(function(){m(y,b)})},v=function(){var y=l.getItem(p);return y&&y!==o?!1:(l.setItem(p,o),l.getItem(p)===o?!0:(Be(l,!0)||i(new Error("localStorage support dropped while acquiring lock")),!1))},w=function(){l.setItem(h,o),m(v,function(){if(l.getItem(h)===o){S();return}g(function(){if(l.getItem(p)!==o){w();return}m(function(){return!l.getItem(f)},S)})})},S=function(){l.setItem(f,"1");var y=function(){l.removeItem(f),l.getItem(p)===o&&l.removeItem(p),l.getItem(h)===o&&l.removeItem(h)};e().then(function(b){y(),n(b)}).catch(function(b){y(),i(b)})};try{if(Be(l,!0))w();else throw new Error("localStorage support check failed")}catch(y){i(y)}},this))};var Ue=function(e){this.storage=e||localStorage};Ue.prototype.init=function(){return R.resolve()},Ue.prototype.setItem=function(e,t){return new R(c.bind(function(r,n){try{this.storage.setItem(e,ot(t))}catch(i){n(i)}r()},this))},Ue.prototype.getItem=function(e){return new R(c.bind(function(t,r){var n;try{n=st(this.storage.getItem(e))}catch(i){r(i)}t(n)},this))},Ue.prototype.removeItem=function(e){return new R(c.bind(function(t,r){try{this.storage.removeItem(e)}catch(n){r(n)}t()},this))};var Br=Fe("batch"),ee=function(e,t){t=t||{},this.storageKey=e,this.usePersistence=t.usePersistence,this.usePersistence&&(this.queueStorage=t.queueStorage||new Ue,this.lock=new Fr(e,{storage:t.sharedLockStorage||x.localStorage,timeoutMS:t.sharedLockTimeoutMS})),this.reportError=t.errorReporter||c.bind(Br.error,Br),this.pid=t.pid||null,this.memQueue=[],this.initialized=!1,t.enqueueThrottleMs?this.enqueuePersisted=yi(c.bind(this._enqueuePersisted,this),t.enqueueThrottleMs):this.enqueuePersisted=c.bind(function(r){return this._enqueuePersisted([r])},this)};ee.prototype.ensureInit=function(){return this.initialized?R.resolve():this.queueStorage.init().then(c.bind(function(){this.initialized=!0},this)).catch(c.bind(function(e){this.reportError("Error initializing queue persistence. Disabling persistence",e),this.initialized=!0,this.usePersistence=!1},this))},ee.prototype.enqueue=function(e,t){var r={id:xt(),flushAfter:new Date().getTime()+t*2,payload:e};return this.usePersistence?this.enqueuePersisted(r):(this.memQueue.push(r),R.resolve(!0))},ee.prototype._enqueuePersisted=function(e){var t=c.bind(function(){return this.ensureInit().then(c.bind(function(){return this.readFromStorage()},this)).then(c.bind(function(r){return this.saveToStorage(r.concat(e))},this)).then(c.bind(function(r){return r&&(this.memQueue=this.memQueue.concat(e)),r},this)).catch(c.bind(function(r){return this.reportError("Error enqueueing items",r,e),!1},this))},this);return this.lock.withLock(t,this.pid).catch(c.bind(function(r){return this.reportError("Error acquiring storage lock",r),!1},this))},ee.prototype.fillBatch=function(e){var t=this.memQueue.slice(0,e);return this.usePersistence&&t.length<e?this.ensureInit().then(c.bind(function(){return this.readFromStorage()},this)).then(c.bind(function(r){if(r.length){var n={};c.each(t,function(a){n[a.id]=!0});for(var i=0;i<r.length;i++){var o=r[i];if(new Date().getTime()>o.flushAfter&&!n[o.id]&&(o.orphaned=!0,t.push(o),t.length>=e))break}}return t},this)):R.resolve(t)};var Ur=function(e,t){var r=[];return c.each(e,function(n){n.id&&!t[n.id]&&r.push(n)}),r};ee.prototype.removeItemsByID=function(e){var t={};if(c.each(e,function(n){t[n]=!0}),this.memQueue=Ur(this.memQueue,t),this.usePersistence){var r=c.bind(function(){return this.ensureInit().then(c.bind(function(){return this.readFromStorage()},this)).then(c.bind(function(n){return n=Ur(n,t),this.saveToStorage(n)},this)).then(c.bind(function(){return this.readFromStorage()},this)).then(c.bind(function(n){for(var i=0;i<n.length;i++){var o=n[i];if(o.id&&t[o.id])throw new Error("Item not removed from storage")}return!0},this)).catch(c.bind(function(n){return this.reportError("Error removing items",n,e),!1},this))},this);return this.lock.withLock(r,this.pid).catch(c.bind(function(n){return this.reportError("Error acquiring storage lock",n),Be(this.lock.storage,!0)?!1:r().then(c.bind(function(i){return i||this.queueStorage.removeItem(this.storageKey).then(function(){return i})},this)).catch(c.bind(function(i){return this.reportError("Error clearing queue",i),!1},this))},this))}else return R.resolve(!0)};var Wr=function(e,t){var r=[];return c.each(e,function(n){var i=n.id;if(i in t){var o=t[i];o!==null&&(n.payload=o,r.push(n))}else r.push(n)}),r};ee.prototype.updatePayloads=function(e){return this.memQueue=Wr(this.memQueue,e),this.usePersistence?this.lock.withLock(c.bind(function(){return this.ensureInit().then(c.bind(function(){return this.readFromStorage()},this)).then(c.bind(function(r){return r=Wr(r,e),this.saveToStorage(r)},this)).catch(c.bind(function(r){return this.reportError("Error updating items",e,r),!1},this))},this),this.pid).catch(c.bind(function(t){return this.reportError("Error acquiring storage lock",t),!1},this)):R.resolve(!0)},ee.prototype.readFromStorage=function(){return this.ensureInit().then(c.bind(function(){return this.queueStorage.getItem(this.storageKey)},this)).then(c.bind(function(e){return e&&(c.isArray(e)||(this.reportError("Invalid storage entry:",e),e=null)),e||[]},this)).catch(c.bind(function(e){return this.reportError("Error retrieving queue",e),[]},this))},ee.prototype.saveToStorage=function(e){return this.ensureInit().then(c.bind(function(){return this.queueStorage.setItem(this.storageKey,e)},this)).then(function(){return!0}).catch(c.bind(function(t){return this.reportError("Error saving queue",t),!1},this))},ee.prototype.clear=function(){return this.memQueue=[],this.usePersistence?this.ensureInit().then(c.bind(function(){return this.queueStorage.removeItem(this.storageKey)},this)):R.resolve()};var Di=10*60*1e3,We=Fe("batch"),Q=function(e,t){this.errorReporter=t.errorReporter,this.queue=new ee(e,{errorReporter:c.bind(this.reportError,this),queueStorage:t.queueStorage,sharedLockStorage:t.sharedLockStorage,sharedLockTimeoutMS:t.sharedLockTimeoutMS,usePersistence:t.usePersistence,enqueueThrottleMs:t.enqueueThrottleMs}),this.libConfig=t.libConfig,this.sendRequest=t.sendRequestFunc,this.beforeSendHook=t.beforeSendHook,this.stopAllBatching=t.stopAllBatchingFunc,this.batchSize=this.libConfig.batch_size,this.flushInterval=this.libConfig.batch_flush_interval_ms,this.stopped=!this.libConfig.batch_autostart,this.consecutiveRemovalFailures=0,this.itemIdsSentSuccessfully={},this.flushOnlyOnInterval=t.flushOnlyOnInterval||!1,this._flushPromise=null};Q.prototype.enqueue=function(e){return this.queue.enqueue(e,this.flushInterval)},Q.prototype.start=function(){return this.stopped=!1,this.consecutiveRemovalFailures=0,this.flush()},Q.prototype.stop=function(){this.stopped=!0,this.timeoutID&&(clearTimeout(this.timeoutID),this.timeoutID=null)},Q.prototype.clear=function(){return this.queue.clear()},Q.prototype.resetBatchSize=function(){this.batchSize=this.libConfig.batch_size},Q.prototype.resetFlush=function(){this.scheduleFlush(this.libConfig.batch_flush_interval_ms)},Q.prototype.scheduleFlush=function(e){this.flushInterval=e,this.stopped||(this.timeoutID=setTimeout(c.bind(function(){this.stopped||(this._flushPromise=this.flush())},this),this.flushInterval))},Q.prototype.sendRequestPromise=function(e,t){return new R(c.bind(function(r){this.sendRequest(e,t,r)},this))},Q.prototype.flush=function(e){if(this.requestInProgress)return We.log("Flush: Request already in progress"),R.resolve();this.requestInProgress=!0,e=e||{};var t=this.libConfig.batch_request_timeout_ms,r=new Date().getTime(),n=this.batchSize;return this.queue.fillBatch(n).then(c.bind(function(i){var o=i.length===n,a=[],u={};if(c.each(i,function(h){var p=h.payload;if(this.beforeSendHook&&!h.orphaned&&(p=this.beforeSendHook(p)),p){p.event&&p.properties&&(p.properties=c.extend({},p.properties,{mp_sent_by_lib_version:It.LIB_VERSION}));var f=!0,g=h.id;g?(this.itemIdsSentSuccessfully[g]||0)>5&&(this.reportError("[dupe] item ID sent too many times, not sending",{item:h,batchSize:i.length,timesSent:this.itemIdsSentSuccessfully[g]}),f=!1):this.reportError("[dupe] found item with no ID",{item:h}),f&&a.push(p)}u[h.id]=p},this),a.length<1)return this.requestInProgress=!1,this.resetFlush(),R.resolve();var s=c.bind(function(){return this.queue.removeItemsByID(c.map(i,function(h){return h.id})).then(c.bind(function(h){return c.each(i,c.bind(function(p){var f=p.id;f?(this.itemIdsSentSuccessfully[f]=this.itemIdsSentSuccessfully[f]||0,this.itemIdsSentSuccessfully[f]++,this.itemIdsSentSuccessfully[f]>5&&this.reportError("[dupe] item ID sent too many times",{item:p,batchSize:i.length,timesSent:this.itemIdsSentSuccessfully[f]})):this.reportError("[dupe] found item with no ID while removing",{item:p})},this)),h?(this.consecutiveRemovalFailures=0,this.flushOnlyOnInterval&&!o?(this.resetFlush(),R.resolve()):this.flush()):(++this.consecutiveRemovalFailures>5?(this.reportError("Too many queue failures; disabling batching system."),this.stopAllBatching()):this.resetFlush(),R.resolve())},this))},this),d=c.bind(function(h){this.requestInProgress=!1;try{if(e.unloading)return this.queue.updatePayloads(u);if(c.isObject(h)&&h.error==="timeout"&&new Date().getTime()-r>=t)return this.reportError("Network timeout; retrying"),this.flush();if(c.isObject(h)&&(h.httpStatusCode>=500||h.httpStatusCode===429||h.httpStatusCode<=0&&!Si()||h.error==="timeout")){var p=this.flushInterval*2;return h.retryAfter&&(p=parseInt(h.retryAfter,10)*1e3||p),p=Math.min(Di,p),this.reportError("Error; retry in "+p+" ms"),this.scheduleFlush(p),R.resolve()}else if(c.isObject(h)&&h.httpStatusCode===413)if(i.length>1){var f=Math.max(1,Math.floor(n/2));return this.batchSize=Math.min(this.batchSize,f,i.length-1),this.reportError("413 response; reducing batch size to "+this.batchSize),this.resetFlush(),R.resolve()}else return this.reportError("Single-event request too large; dropping",i),this.resetBatchSize(),s();else return s()}catch(g){this.reportError("Error handling API response",g),this.resetFlush()}},this),l={method:"POST",verbose:!0,ignore_json_errors:!0,timeout_ms:t};return e.unloading&&(l.transport="sendBeacon"),We.log("MIXPANEL REQUEST:",a),this.sendRequestPromise(a,l).then(d)},this)).catch(c.bind(function(i){this.reportError("Error flushing request queue",i),this.resetFlush()},this))},Q.prototype.reportError=function(e,t){if(We.error.apply(We.error,arguments),this.errorReporter)try{t instanceof Error||(t=new Error(e)),this.errorReporter(e,t)}catch(r){We.error(r)}};var qr=function(e){var t=Date.now();return!e||t>e.maxExpires||t>e.idleExpires},Ai=250,_e=Fe("recorder"),zr=x.CompressionStream,Li={batch_size:1e3,batch_flush_interval_ms:10*1e3,batch_request_timeout_ms:90*1e3,batch_autostart:!0},Pi=new Set([Z.MouseMove,Z.MouseInteraction,Z.Scroll,Z.ViewportResize,Z.Input,Z.TouchMove,Z.MediaInteraction,Z.Drag,Z.Selection]);function Fi(e){return e.type===wt.IncrementalSnapshot&&Pi.has(e.data.source)}var W=function(e){this._mixpanel=e.mixpanelInstance,this._onIdleTimeout=e.onIdleTimeout||Tt,this._onMaxLengthReached=e.onMaxLengthReached||Tt,this._onBatchSent=e.onBatchSent||Tt,this._rrwebRecord=e.rrwebRecord||null,this._stopRecording=null,this.replayId=e.replayId,this.batchStartUrl=e.batchStartUrl||null,this.replayStartUrl=e.replayStartUrl||null,this.idleExpires=e.idleExpires||null,this.maxExpires=e.maxExpires||null,this.replayStartTime=e.replayStartTime||null,this.seqNo=e.seqNo||0,this.idleTimeoutId=null,this.maxTimeoutId=null,this.recordMaxMs=tt,this.recordMinMs=0;var t=Be(e.sharedLockStorage,!0);this.batcherKey="__mprec_"+this.getConfig("name")+"_"+this.getConfig("token")+"_"+this.replayId,this.queueStorage=new ne(Lr),this.batcher=new Q(this.batcherKey,{errorReporter:this.reportError.bind(this),flushOnlyOnInterval:!0,libConfig:Li,sendRequestFunc:this.flushEventsWithOptOut.bind(this),queueStorage:this.queueStorage,sharedLockStorage:e.sharedLockStorage,usePersistence:t,stopAllBatchingFunc:this.stopRecording.bind(this),enqueueThrottleMs:Ai,sharedLockTimeoutMS:10*1e3})};W.prototype.unloadPersistedData=function(){return this.batcher.stop(),this.batcher.flush().then(function(){return this.queueStorage.removeItem(this.batcherKey)}.bind(this))},W.prototype.getConfig=function(e){return this._mixpanel.get_config(e)},W.prototype.get_config=function(e){return this.getConfig(e)},W.prototype.startRecording=function(e){if(this._rrwebRecord===null){this.reportError("rrweb record function not provided. ");return}if(this._stopRecording!==null){_e.log("Recording already in progress, skipping startRecording.");return}this.recordMaxMs=this.getConfig("record_max_ms"),this.recordMaxMs>tt&&(this.recordMaxMs=tt,_e.critical("record_max_ms cannot be greater than "+tt+"ms. Capping value.")),this.maxExpires||(this.maxExpires=new Date().getTime()+this.recordMaxMs),this.recordMinMs=this.getConfig("record_min_ms"),this.recordMinMs>Mt&&(this.recordMinMs=Mt,_e.critical("record_min_ms cannot be greater than "+Mt+"ms. Capping value.")),this.replayStartTime||(this.replayStartTime=new Date().getTime(),this.batchStartUrl=c.info.currentUrl(),this.replayStartUrl=c.info.currentUrl()),e||this.recordMinMs>0?this.batcher.stop():this.batcher.start();var t=function(){clearTimeout(this.idleTimeoutId);var i=this.getConfig("record_idle_timeout_ms");this.idleTimeoutId=setTimeout(this._onIdleTimeout,i),this.idleExpires=new Date().getTime()+i}.bind(this);t();var r=this.getConfig("record_block_selector");(r===""||r===null)&&(r=void 0);try{this._stopRecording=this._rrwebRecord({emit:function(i){if(this.idleExpires&&this.idleExpires<i.timestamp){this._onIdleTimeout();return}Fi(i)&&(this.batcher.stopped&&new Date().getTime()-this.replayStartTime>=this.recordMinMs&&this.batcher.start(),t()),this.__enqueuePromise=this.batcher.enqueue(i)}.bind(this),blockClass:this.getConfig("record_block_class"),blockSelector:r,collectFonts:this.getConfig("record_collect_fonts"),dataURLOptions:{type:"image/webp",quality:.6},maskAllInputs:!0,maskTextClass:this.getConfig("record_mask_text_class"),maskTextSelector:this.getConfig("record_mask_text_selector"),recordCanvas:this.getConfig("record_canvas"),sampling:{canvas:15}})}catch(i){this.reportError("Unexpected error when starting rrweb recording.",i)}if(typeof this._stopRecording!="function"){this.reportError("rrweb failed to start, skipping this recording."),this._stopRecording=null,this.stopRecording();return}var n=this.maxExpires-new Date().getTime();this.maxTimeoutId=setTimeout(this._onMaxLengthReached.bind(this),n)},W.prototype.stopRecording=function(e){if(!this.isRrwebStopped()){try{this._stopRecording()}catch(r){this.reportError("Error with rrweb stopRecording",r)}this._stopRecording=null}var t;return this.batcher.stopped?t=this.batcher.clear():e||(t=this.batcher.flush()),this.batcher.stop(),clearTimeout(this.idleTimeoutId),clearTimeout(this.maxTimeoutId),t},W.prototype.isRrwebStopped=function(){return this._stopRecording===null},W.prototype.flushEventsWithOptOut=function(e,t,r){var n=function(i){i===0&&(this.stopRecording(),r({error:"Tracking has been opted out, stopping recording."}))}.bind(this);this._flushEvents(e,t,r,n)},W.prototype.serialize=function(){var e;try{e=this._mixpanel.get_tab_id()}catch(t){this.reportError("Error getting tab ID for serialization ",t),e=null}return{replayId:this.replayId,seqNo:this.seqNo,replayStartTime:this.replayStartTime,batchStartUrl:this.batchStartUrl,replayStartUrl:this.replayStartUrl,idleExpires:this.idleExpires,maxExpires:this.maxExpires,tabId:e}},W.deserialize=function(e,t){var r=new W(c.extend({},t,{replayId:e.replayId,batchStartUrl:e.batchStartUrl,replayStartUrl:e.replayStartUrl,idleExpires:e.idleExpires,maxExpires:e.maxExpires,replayStartTime:e.replayStartTime,seqNo:e.seqNo,sharedLockStorage:t.sharedLockStorage}));return r},W.prototype._sendRequest=function(e,t,r,n){var i=function(o,a){o.status===200&&this.replayId===e&&(this.seqNo++,this.batchStartUrl=c.info.currentUrl()),this._onBatchSent(),n({status:0,httpStatusCode:o.status,responseBody:a,retryAfter:o.headers.get("Retry-After")})}.bind(this);x.fetch(this.getConfig("api_host")+"/"+this.getConfig("api_routes").record+"?"+new URLSearchParams(t),{method:"POST",headers:{Authorization:"Basic "+btoa(this.getConfig("token")+":"),"Content-Type":"application/octet-stream"},body:r}).then(function(o){o.json().then(function(a){i(o,a)}).catch(function(a){n({error:a})})}).catch(function(o){n({error:o,httpStatusCode:0})})},W.prototype._flushEvents=Ei(function(e,t,r){var n=e.length;if(n>0){for(var i=this.replayId,o=1/0,a=-1/0,u=!1,s=0;s<n;s++)o=Math.min(o,e[s].timestamp),a=Math.max(a,e[s].timestamp),e[s].type===wt.FullSnapshot&&(u=!0);if(this.seqNo===0){if(!u){r({error:"First batch does not contain a full snapshot. Aborting recording."}),this.stopRecording(!0);return}this.replayStartTime=o}else this.replayStartTime||(this.reportError("Replay start time not set but seqNo is not 0. Using current batch start time as a fallback."),this.replayStartTime=o);var d=a-this.replayStartTime,l={$current_url:this.batchStartUrl,$lib_version:It.LIB_VERSION,batch_start_time:o/1e3,distinct_id:String(this._mixpanel.get_distinct_id()),mp_lib:"web",replay_id:i,replay_length_ms:d,replay_start_time:this.replayStartTime/1e3,replay_start_url:this.replayStartUrl,seq:this.seqNo},h=JSON.stringify(e),p=this._mixpanel.get_property("$device_id");p&&(l.$device_id=p);var f=this._mixpanel.get_property("$user_id");if(f&&(l.$user_id=f),zr){var g=new Blob([h],{type:"application/json"}).stream(),m=g.pipeThrough(new zr("gzip"));new Response(m).blob().then(function(v){l.format="gzip",this._sendRequest(i,l,v,r)}.bind(this))}else l.format="body",this._sendRequest(i,l,h,r)}}),W.prototype.reportError=function(e,t){_e.error.apply(_e.error,arguments);try{!t&&!(e instanceof Error)&&(e=new Error(e)),this.getConfig("error_reporter")(e,t)}catch(r){_e.error(r)}};var Ce=function(e){this.idb=new ne(Pr),this.errorReporter=e.errorReporter,this.mixpanelInstance=e.mixpanelInstance,this.sharedLockStorage=e.sharedLockStorage};Ce.prototype.handleError=function(e){this.errorReporter("IndexedDB error: ",e)},Ce.prototype.setActiveRecording=function(e){var t=e.tabId;return t?this.idb.init().then(function(){return this.idb.setItem(t,e)}.bind(this)).catch(this.handleError.bind(this)):(console.warn("No tab ID is set, cannot persist recording metadata."),R.resolve())},Ce.prototype.getActiveRecording=function(){return this.idb.init().then(function(){return this.idb.getItem(this.mixpanelInstance.get_tab_id())}.bind(this)).then(function(e){return qr(e)?null:e}.bind(this)).catch(this.handleError.bind(this))},Ce.prototype.clearActiveRecording=function(){return this.getActiveRecording().then(function(e){if(e)return e.maxExpires=0,this.setActiveRecording(e)}.bind(this)).catch(this.handleError.bind(this))},Ce.prototype.flushInactiveRecordings=function(){return this.idb.init().then(function(){return this.idb.getAll()}.bind(this)).then(function(e){var t=e.filter(function(r){return qr(r)}).map(function(r){var n=W.deserialize(r,{mixpanelInstance:this.mixpanelInstance,sharedLockStorage:this.sharedLockStorage});return n.unloadPersistedData().then(function(){return this.idb.removeItem(r.tabId)}.bind(this)).catch(this.handleError.bind(this))}.bind(this));return R.all(t)}.bind(this)).catch(this.handleError.bind(this))};var qe=Fe("recorder"),ie=function(e,t,r){this.mixpanelInstance=e,this.rrwebRecord=t||Ne,this.sharedLockStorage=r,this.recordingRegistry=new Ce({mixpanelInstance:this.mixpanelInstance,errorReporter:qe.error,sharedLockStorage:r}),this._flushInactivePromise=this.recordingRegistry.flushInactiveRecordings(),this.activeRecording=null};ie.prototype.startRecording=function(e){if(e=e||{},this.activeRecording&&!this.activeRecording.isRrwebStopped()){qe.log("Recording already in progress, skipping startRecording.");return}var t=function(){qe.log("Idle timeout reached, restarting recording."),this.resetRecording()}.bind(this),r=function(){qe.log("Max recording length reached, stopping recording."),this.resetRecording()}.bind(this),n=function(){this.recordingRegistry.setActiveRecording(this.activeRecording.serialize()),this.__flushPromise=this.activeRecording.batcher._flushPromise}.bind(this),i={mixpanelInstance:this.mixpanelInstance,onBatchSent:n,onIdleTimeout:t,onMaxLengthReached:r,replayId:c.UUID(),rrwebRecord:this.rrwebRecord,sharedLockStorage:this.sharedLockStorage};return e.activeSerializedRecording?this.activeRecording=W.deserialize(e.activeSerializedRecording,i):this.activeRecording=new W(i),this.activeRecording.startRecording(e.shouldStopBatcher),this.recordingRegistry.setActiveRecording(this.activeRecording.serialize())},ie.prototype.stopRecording=function(){var e=this._stopCurrentRecording(!1);return this.recordingRegistry.clearActiveRecording(),this.activeRecording=null,e},ie.prototype.pauseRecording=function(){return this._stopCurrentRecording(!1)},ie.prototype._stopCurrentRecording=function(e){return this.activeRecording?this.activeRecording.stopRecording(e):R.resolve()},ie.prototype.resumeRecording=function(e){return this.activeRecording&&this.activeRecording.isRrwebStopped()?(this.activeRecording.startRecording(!1),R.resolve(null)):this.recordingRegistry.getActiveRecording().then(function(t){return t?this.startRecording({activeSerializedRecording:t}):e?this.startRecording({shouldStopBatcher:!1}):(qe.log("No resumable recording found."),null)}.bind(this))},ie.prototype.resetRecording=function(){this.stopRecording(),this.startRecording({shouldStopBatcher:!0})},ie.prototype.getActiveReplayId=function(){return this.activeRecording&&!this.activeRecording.isRrwebStopped()?this.activeRecording.replayId:null},Object.defineProperty(ie.prototype,"replayId",{get:function(){return this.getActiveReplayId()}}),x.__mp_recorder=ie})();
1
+ (function(){"use strict";var W;if(typeof window=="undefined"){var to={hostname:""};W={crypto:{randomUUID:function(){throw Error("unsupported")}},navigator:{userAgent:"",onLine:!0},document:{createElement:function(){return{}},location:to,referrer:""},screen:{width:0,height:0},location:to,addEventListener:function(){},removeEventListener:function(){}}}else W=window;function ro(t,i){(i==null||i>t.length)&&(i=t.length);for(var o=0,e=new Array(i);o<i;o++)e[o]=t[o];return e}function no(t,i,o,e,r,n,s){try{var a=t[n](s),u=a.value}catch(l){o(l);return}a.done?i(u):Promise.resolve(u).then(e,r)}function gn(t){return function(){var i=this,o=arguments;return new Promise(function(e,r){var n=t.apply(i,o);function s(u){no(n,e,r,s,a,"next",u)}function a(u){no(n,e,r,s,a,"throw",u)}s(void 0)})}}function sr(t,i,o){return io()?sr=Reflect.construct:sr=function(r,n,s){var a=[null];a.push.apply(a,n);var u=Function.bind.apply(r,a),l=new u;return s&&xt(l,s.prototype),l},sr.apply(null,arguments)}function Ru(t,i){for(var o=0;o<i.length;o++){var e=i[o];e.enumerable=e.enumerable||!1,e.configurable=!0,"value"in e&&(e.writable=!0),Object.defineProperty(t,e.key,e)}}function oe(t,i,o){return i&&Ru(t.prototype,i),t}function F(){return F=Object.assign||function(t){for(var i=1;i<arguments.length;i++){var o=arguments[i];for(var e in o)Object.prototype.hasOwnProperty.call(o,e)&&(t[e]=o[e])}return t},F.apply(this,arguments)}function yn(t){return yn=Object.setPrototypeOf?Object.getPrototypeOf:function(o){return o.__proto__||Object.getPrototypeOf(o)},yn(t)}function ae(t,i){if(typeof i!="function"&&i!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(i&&i.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),i&&xt(t,i)}function T(t,i){return i!=null&&typeof Symbol!="undefined"&&i[Symbol.hasInstance]?!!i[Symbol.hasInstance](t):t instanceof i}function Eu(t){return Function.toString.call(t).indexOf("[native code]")!==-1}function Ot(t,i){if(t==null)return{};var o={},e=Object.keys(t),r,n;for(n=0;n<e.length;n++)r=e[n],!(i.indexOf(r)>=0)&&(o[r]=t[r]);return o}function xt(t,i){return xt=Object.setPrototypeOf||function(e,r){return e.__proto__=r,e},xt(t,i)}function N(t){"@swc/helpers - typeof";return t&&typeof Symbol!="undefined"&&t.constructor===Symbol?"symbol":typeof t}function Au(t,i){if(t){if(typeof t=="string")return ro(t,i);var o=Object.prototype.toString.call(t).slice(8,-1);if(o==="Object"&&t.constructor&&(o=t.constructor.name),o==="Map"||o==="Set")return Array.from(o);if(o==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(o))return ro(t,i)}}function ar(t){var i=typeof Map=="function"?new Map:void 0;return ar=function(e){if(e===null||!Eu(e))return e;if(typeof e!="function")throw new TypeError("Super expression must either be null or a function");if(typeof i!="undefined"){if(i.has(e))return i.get(e);i.set(e,r)}function r(){return sr(e,arguments,yn(this).constructor)}return r.prototype=Object.create(e.prototype,{constructor:{value:r,enumerable:!1,writable:!0,configurable:!0}}),xt(r,e)},ar(t)}function io(){try{var t=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch(i){}return(io=function(){return!!t})()}function O(t,i){var o=typeof Symbol!="undefined"&&t[Symbol.iterator]||t["@@iterator"];if(o)return(o=o.call(t)).next.bind(o);if(Array.isArray(t)||(o=Au(t))||i){o&&(t=o);var e=0;return function(){return e>=t.length?{done:!0}:{done:!1,value:t[e++]}}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function Rt(t,i){var o,e,r,n,s={label:0,sent:function(){if(r[0]&1)throw r[1];return r[1]},trys:[],ops:[]};return n={next:a(0),throw:a(1),return:a(2)},typeof Symbol=="function"&&(n[Symbol.iterator]=function(){return this}),n;function a(l){return function(c){return u([l,c])}}function u(l){if(o)throw new TypeError("Generator is already executing.");for(;s;)try{if(o=1,e&&(r=l[0]&2?e.return:l[0]?e.throw||((r=e.return)&&r.call(e),0):e.next)&&!(r=r.call(e,l[1])).done)return r;switch(e=0,r&&(l=[l[0]&2,r.value]),l[0]){case 0:case 1:r=l;break;case 4:return s.label++,{value:l[1],done:!1};case 5:s.label++,e=l[1],l=[0];continue;case 7:l=s.ops.pop(),s.trys.pop();continue;default:if(r=s.trys,!(r=r.length>0&&r[r.length-1])&&(l[0]===6||l[0]===2)){s=0;continue}if(l[0]===3&&(!r||l[1]>r[0]&&l[1]<r[3])){s.label=l[1];break}if(l[0]===6&&s.label<r[1]){s.label=r[1],r=l;break}if(r&&s.label<r[2]){s.label=r[2],s.ops.push(l);break}r[2]&&s.ops.pop(),s.trys.pop();continue}l=i.call(t,s)}catch(c){l=[6,c],e=0}finally{o=r=0}if(l[0]&5)throw l[1];return{value:l[0]?l[1]:void 0,done:!0}}}function oo(t){var i=typeof Symbol=="function"&&Symbol.iterator,o=i&&t[i],e=0;if(o)return o.call(t);if(t&&typeof t.length=="number")return{next:function(){return t&&e>=t.length&&(t=void 0),{value:t&&t[e++],done:!t}}};throw new TypeError(i?"Object is not iterable.":"Symbol.iterator is not defined.")}var Mu=Object.defineProperty,ku=function(t,i,o){return i in t?Mu(t,i,{enumerable:!0,configurable:!0,writable:!0,value:o}):t[i]=o},I=function(t,i,o){return ku(t,(typeof i=="undefined"?"undefined":N(i))!=="symbol"?i+"":i,o)},so,_u=Object.defineProperty,Tu=function(t,i,o){return i in t?_u(t,i,{enumerable:!0,configurable:!0,writable:!0,value:o}):t[i]=o},ao=function(t,i,o){return Tu(t,(typeof i=="undefined"?"undefined":N(i))!=="symbol"?i+"":i,o)},ie=function(t){return t[t.Document=0]="Document",t[t.DocumentType=1]="DocumentType",t[t.Element=2]="Element",t[t.Text=3]="Text",t[t.CDATA=4]="CDATA",t[t.Comment=5]="Comment",t}(ie||{}),uo={Node:["childNodes","parentNode","parentElement","textContent"],ShadowRoot:["host","styleSheets"],Element:["shadowRoot","querySelector","querySelectorAll"],MutationObserver:[]},lo={Node:["contains","getRootNode"],ShadowRoot:["getSelection"],Element:[],MutationObserver:["constructor"]},ur={},Pu=function(){return!!globalThis.Zone};function wn(t){if(ur[t])return ur[t];var i=globalThis[t],o=i.prototype,e=t in uo?uo[t]:void 0,r=!!(e&&e.every(function(c){var f,h;return!!((h=(f=Object.getOwnPropertyDescriptor(o,c))==null?void 0:f.get)!=null&&h.toString().includes("[native code]"))})),n=t in lo?lo[t]:void 0,s=!!(n&&n.every(function(c){var f;return typeof o[c]=="function"&&((f=o[c])==null?void 0:f.toString().includes("[native code]"))}));if(r&&s&&!Pu())return ur[t]=i.prototype,i.prototype;try{var a=document.createElement("iframe");document.body.appendChild(a);var u=a.contentWindow;if(!u)return i.prototype;var l=u[t].prototype;return document.body.removeChild(a),l?ur[t]=l:o}catch(c){return o}}var Sn={};function Ne(t,i,o){var e,r=t+"."+String(o);if(Sn[r])return Sn[r].call(i);var n=wn(t),s=(e=Object.getOwnPropertyDescriptor(n,o))==null?void 0:e.get;return s?(Sn[r]=s,s.call(i)):i[o]}var bn={};function co(t,i,o){var e=t+"."+String(o);if(bn[e])return bn[e].bind(i);var r=wn(t),n=r[o];return typeof n!="function"?i[o]:(bn[e]=n,n.bind(i))}function Nu(t){return Ne("Node",t,"childNodes")}function $u(t){return Ne("Node",t,"parentNode")}function Du(t){return Ne("Node",t,"parentElement")}function Lu(t){return Ne("Node",t,"textContent")}function Fu(t,i){return co("Node",t,"contains")(i)}function Bu(t){return co("Node",t,"getRootNode")()}function Uu(t){return!t||!("host"in t)?null:Ne("ShadowRoot",t,"host")}function zu(t){return t.styleSheets}function Wu(t){return!t||!("shadowRoot"in t)?null:Ne("Element",t,"shadowRoot")}function Gu(t,i){return Ne("Element",t,"querySelector")(i)}function ju(t,i){return Ne("Element",t,"querySelectorAll")(i)}function Vu(){return wn("MutationObserver").constructor}var ue={childNodes:Nu,parentNode:$u,parentElement:Du,textContent:Lu,contains:Fu,getRootNode:Bu,host:Uu,styleSheets:zu,shadowRoot:Wu,querySelector:Gu,querySelectorAll:ju,mutationObserver:Vu};function fo(t){return t.nodeType===t.ELEMENT_NODE}function Et(t){var i=t&&"host"in t&&"mode"in t&&ue.host(t)||null;return!!(i&&"shadowRoot"in i&&ue.shadowRoot(i)===t)}function At(t){return Object.prototype.toString.call(t)==="[object ShadowRoot]"}function Yu(t){return t.includes(" background-clip: text;")&&!t.includes(" -webkit-background-clip: text;")&&(t=t.replace(/\sbackground-clip:\s*text;/g," -webkit-background-clip: text; background-clip: text;")),t}function qu(t){var i=t.cssText;if(i.split('"').length<3)return i;var o=["@import","url("+JSON.stringify(t.href)+")"];return t.layerName===""?o.push("layer"):t.layerName&&o.push("layer("+t.layerName+")"),t.supportsText&&o.push("supports("+t.supportsText+")"),t.media.length&&o.push(t.media.mediaText),o.join(" ")+";"}function Cn(t){try{var i=t.rules||t.cssRules;if(!i)return null;var o=t.href;!o&&t.ownerNode&&t.ownerNode.ownerDocument&&(o=t.ownerNode.ownerDocument.location.href);var e=Array.from(i,function(r){return ho(r,o)}).join("");return Yu(e)}catch(r){return null}}function ho(t,i){if(Ju(t)){var o;try{o=Cn(t.styleSheet)||qu(t)}catch(r){o=t.cssText}return t.styleSheet.href?lr(o,t.styleSheet.href):o}else{var e=t.cssText;return Zu(t)&&t.selectorText.includes(":")&&(e=Hu(e)),i?lr(e,i):e}}function Hu(t){var i=/(\[(?:[\w-]+)[^\\])(:(?:[\w-]+)\])/gm;return t.replace(i,"$1\\$2")}function Ju(t){return"styleSheet"in t}function Zu(t){return"selectorText"in t}var po=function(){function t(){ao(this,"idNodeMap",new Map),ao(this,"nodeMetaMap",new WeakMap)}var i=t.prototype;return i.getId=function(e){var r;if(!e)return-1;var n=(r=this.getMeta(e))==null?void 0:r.id;return n!=null?n:-1},i.getNode=function(e){return this.idNodeMap.get(e)||null},i.getIds=function(){return Array.from(this.idNodeMap.keys())},i.getMeta=function(e){return this.nodeMetaMap.get(e)||null},i.removeNodeFromMap=function(e){var r=this,n=this.getId(e);this.idNodeMap.delete(n),e.childNodes&&e.childNodes.forEach(function(s){return r.removeNodeFromMap(s)})},i.has=function(e){return this.idNodeMap.has(e)},i.hasNode=function(e){return this.nodeMetaMap.has(e)},i.add=function(e,r){var n=r.id;this.idNodeMap.set(n,e),this.nodeMetaMap.set(e,r)},i.replace=function(e,r){var n=this.getNode(e);if(n){var s=this.nodeMetaMap.get(n);s&&this.nodeMetaMap.set(r,s)}this.idNodeMap.set(e,r)},i.reset=function(){this.idNodeMap=new Map,this.nodeMetaMap=new WeakMap},t}();function Ku(){return new po}function In(t){var i=t.element,o=t.maskInputOptions,e=t.tagName,r=t.type,n=t.value,s=t.maskInputFn,a=n||"",u=r&&Ge(r);return(o[e.toLowerCase()]||u&&o[u])&&(s?a=s(a,i):a="*".repeat(a.length)),a}function Ge(t){return t.toLowerCase()}var vo="__rrweb_original__";function Xu(t){var i=t.getContext("2d");if(!i)return!0;for(var o=50,e=0;e<t.width;e+=o)for(var r=0;r<t.height;r+=o){var n=i.getImageData,s=vo in n?n[vo]:n,a=new Uint32Array(s.call(i,e,r,Math.min(o,t.width-e),Math.min(o,t.height-r)).data.buffer);if(a.some(function(u){return u!==0}))return!1}return!0}function On(t){var i=t.type;return t.hasAttribute("data-rr-is-password")?"password":i?Ge(i):null}function mo(t,i){var o;try{o=new URL(t,i!=null?i:window.location.href)}catch(s){return null}var e=/\.([0-9a-z]+)(?:$)/i,r=o.pathname.match(e),n;return(n=r==null?void 0:r[1])!=null?n:null}function Qu(t){var i="";return t.indexOf("//")>-1?i=t.split("/").slice(0,3).join("/"):i=t.split("/")[0],i=i.split("?")[0],i}var el=/url\((?:(')([^']*)'|(")(.*?)"|([^)]*))\)/gm,tl=/^(?:[a-z+]+:)?\/\//i,rl=/^www\..*/i,nl=/^(data:)([^,]*),(.*)/i;function lr(t,i){return(t||"").replace(el,function(o,e,r,n,s,a){var u=r||s||a,l=e||n||"";if(!u)return o;if(tl.test(u)||rl.test(u)||nl.test(u))return"url("+l+u+l+")";if(u[0]==="/")return"url("+l+(Qu(i)+u)+l+")";var c=i.split("/"),f=u.split("/");c.pop();for(var h=O(f),v;!(v=h()).done;){var p=v.value;p!=="."&&(p===".."?c.pop():c.push(p))}return"url("+l+c.join("/")+l+")"})}function xn(t){return t.replace(/(\/\*[^*]*\*\/)|[\s;]/g,"")}function il(t,i){var o=Array.from(i.childNodes),e=[];if(o.length>1&&t&&typeof t=="string"){for(var r=xn(t),n=1;n<o.length;n++)if(o[n].textContent&&typeof o[n].textContent=="string")for(var s=xn(o[n].textContent),a=3;a<s.length;a++){var u=s.substring(0,a);if(r.split(u).length===2){for(var l=r.indexOf(u),c=l;c<t.length;c++)if(xn(t.substring(0,c)).length===l){e.push(t.substring(0,c)),t=t.substring(c);break}break}}}return e.push(t),e}function ol(t,i){return il(t,i).join("/* rr_split */")}var sl=1,al=new RegExp("[^a-z0-9-_:]"),Mt=-2;function go(){return sl++}function ul(t){if(T(t,HTMLFormElement))return"form";var i=Ge(t.tagName);return al.test(i)?"div":i}var nt,yo,ll=/^[^ \t\n\r\u000c]+/,cl=/^[, \t\n\r\u000c]+/;function fl(t,i){if(i.trim()==="")return i;var o=0;function e(l){var c,f=l.exec(i.substring(o));return f?(c=f[0],o+=c.length,c):""}for(var r=[];e(cl),!(o>=i.length);){var n=e(ll);if(n.slice(-1)===",")n=it(t,n.substring(0,n.length-1)),r.push(n);else{var s="";n=it(t,n);for(var a=!1;;){var u=i.charAt(o);if(u===""){r.push((n+s).trim());break}else if(a)u===")"&&(a=!1);else if(u===","){o+=1,r.push((n+s).trim());break}else u==="("&&(a=!0);s+=u,o+=1}}}return r.join(", ")}var wo=new WeakMap;function it(t,i){return!i||i.trim()===""?i:Rn(t,i)}function hl(t){return!!(t.tagName==="svg"||t.ownerSVGElement)}function Rn(t,i){var o=wo.get(t);if(o||(o=t.createElement("a"),wo.set(t,o)),!i)i="";else if(i.startsWith("blob:")||i.startsWith("data:"))return i;return o.setAttribute("href",i),o.href}function So(t,i,o,e){return e&&(o==="src"||o==="href"&&!(i==="use"&&e[0]==="#")||o==="xlink:href"&&e[0]!=="#"||o==="background"&&(i==="table"||i==="td"||i==="th")?it(t,e):o==="srcset"?fl(t,e):o==="style"?lr(e,Rn(t)):i==="object"&&o==="data"?it(t,e):e)}function bo(t,i,o){return(t==="video"||t==="audio")&&i==="autoplay"}function dl(t,i,o){try{if(typeof i=="string"){if(t.classList.contains(i))return!0}else for(var e=t.classList.length;e--;){var r=t.classList[e];if(i.test(r))return!0}if(o)return t.matches(o)}catch(n){}return!1}function cr(t,i,o){if(!t)return!1;if(t.nodeType!==t.ELEMENT_NODE)return o?cr(ue.parentNode(t),i,o):!1;for(var e=t.classList.length;e--;){var r=t.classList[e];if(i.test(r))return!0}return o?cr(ue.parentNode(t),i,o):!1}function Co(t,i,o,e){var r;if(fo(t)){if(r=t,!ue.childNodes(r).length)return!1}else{if(ue.parentElement(t)===null)return!1;r=ue.parentElement(t)}try{if(typeof i=="string"){if(e){if(r.closest("."+i))return!0}else if(r.classList.contains(i))return!0}else if(cr(r,i,e))return!0;if(o){if(e){if(r.closest(o))return!0}else if(r.matches(o))return!0}}catch(n){}return!1}function pl(t,i,o){var e=t.contentWindow;if(e){var r=!1,n;try{n=e.document.readyState}catch(u){return}if(n!=="complete"){var s=setTimeout(function(){r||(i(),r=!0)},o);t.addEventListener("load",function(){clearTimeout(s),r=!0,i()});return}var a="about:blank";if(e.location.href!==a||t.src===a||t.src==="")return setTimeout(i,0),t.addEventListener("load",i);t.addEventListener("load",i)}}function vl(t,i,o){var e=!1,r;try{r=t.sheet}catch(s){return}if(!r){var n=setTimeout(function(){e||(i(),e=!0)},o);t.addEventListener("load",function(){clearTimeout(n),e=!0,i()})}}function ml(t,i){var o=i.doc,e=i.mirror,r=i.blockClass,n=i.blockSelector,s=i.needsMask,a=i.inlineStylesheet,u=i.maskInputOptions,l=u===void 0?{}:u,c=i.maskTextFn,f=i.maskInputFn,h=i.dataURLOptions,v=h===void 0?{}:h,p=i.inlineImages,g=i.recordCanvas,d=i.keepIframeSrcFn,y=i.newlyAddedElement,w=y===void 0?!1:y,S=i.cssCaptured,b=S===void 0?!1:S,C=gl(o,e);switch(t.nodeType){case t.DOCUMENT_NODE:return t.compatMode!=="CSS1Compat"?{type:ie.Document,childNodes:[],compatMode:t.compatMode}:{type:ie.Document,childNodes:[]};case t.DOCUMENT_TYPE_NODE:return{type:ie.DocumentType,name:t.name,publicId:t.publicId,systemId:t.systemId,rootId:C};case t.ELEMENT_NODE:return wl(t,{doc:o,blockClass:r,blockSelector:n,inlineStylesheet:a,maskInputOptions:l,maskInputFn:f,dataURLOptions:v,inlineImages:p,recordCanvas:g,keepIframeSrcFn:d,newlyAddedElement:w,rootId:C});case t.TEXT_NODE:return yl(t,{doc:o,needsMask:s,maskTextFn:c,rootId:C,cssCaptured:b});case t.CDATA_SECTION_NODE:return{type:ie.CDATA,textContent:"",rootId:C};case t.COMMENT_NODE:return{type:ie.Comment,textContent:ue.textContent(t)||"",rootId:C};default:return!1}}function gl(t,i){if(i.hasNode(t)){var o=i.getId(t);return o===1?void 0:o}}function yl(t,i){var o=i.needsMask,e=i.maskTextFn,r=i.rootId,n=i.cssCaptured,s=ue.parentNode(t),a=s&&s.tagName,u="",l=a==="STYLE"?!0:void 0,c=a==="SCRIPT"?!0:void 0;return c?u="SCRIPT_PLACEHOLDER":n||(u=ue.textContent(t),l&&u&&(u=lr(u,Rn(i.doc)))),!l&&!c&&u&&o&&(u=e?e(u,ue.parentElement(t)):u.replace(/[\S]/g,"*")),{type:ie.Text,textContent:u||"",rootId:r}}function wl(t,i){for(var o=i.doc,e=i.blockClass,r=i.blockSelector,n=i.inlineStylesheet,s=i.maskInputOptions,a=s===void 0?{}:s,u=i.maskInputFn,l=i.dataURLOptions,c=l===void 0?{}:l,f=i.inlineImages,h=i.recordCanvas,v=i.keepIframeSrcFn,p=i.newlyAddedElement,g=p===void 0?!1:p,d=i.rootId,y=dl(t,e,r),w=ul(t),S={},b=t.attributes.length,C=0;C<b;C++){var x=t.attributes[C];bo(w,x.name,x.value)||(S[x.name]=So(o,w,Ge(x.name),x.value))}if(w==="link"&&n){var E=Array.from(o.styleSheets).find(function(ye){return ye.href===t.href}),R=null;E&&(R=Cn(E)),R&&(delete S.rel,delete S.href,S._cssText=R)}if(w==="style"&&t.sheet){var _=Cn(t.sheet);_&&(t.childNodes.length>1&&(_=ol(_,t)),S._cssText=_)}if(w==="input"||w==="textarea"||w==="select"){var B=t.value,M=t.checked;S.type!=="radio"&&S.type!=="checkbox"&&S.type!=="submit"&&S.type!=="button"&&B?S.value=In({element:t,type:On(t),tagName:w,value:B,maskInputOptions:a,maskInputFn:u}):M&&(S.checked=M)}if(w==="option"&&(t.selected&&!a.select?S.selected=!0:delete S.selected),w==="dialog"&&t.open&&(S.rr_open_mode=t.matches("dialog:modal")?"modal":"non-modal"),w==="canvas"&&h){if(t.__context==="2d")Xu(t)||(S.rr_dataURL=t.toDataURL(c.type,c.quality));else if(!("__context"in t)){var P=t.toDataURL(c.type,c.quality),G=o.createElement("canvas");G.width=t.width,G.height=t.height;var pe=G.toDataURL(c.type,c.quality);P!==pe&&(S.rr_dataURL=P)}}if(w==="img"&&f){nt||(nt=o.createElement("canvas"),yo=nt.getContext("2d"));var j=t,me=j.currentSrc||j.getAttribute("src")||"<unknown-src>",he=j.crossOrigin,Q=function(){j.removeEventListener("load",Q);try{nt.width=j.naturalWidth,nt.height=j.naturalHeight,yo.drawImage(j,0,0),S.rr_dataURL=nt.toDataURL(c.type,c.quality)}catch(ye){if(j.crossOrigin!=="anonymous"){j.crossOrigin="anonymous",j.complete&&j.naturalWidth!==0?Q():j.addEventListener("load",Q);return}else console.warn("Cannot inline img src="+me+"! Error: "+ye)}j.crossOrigin==="anonymous"&&(he?S.crossOrigin=he:j.removeAttribute("crossorigin"))};j.complete&&j.naturalWidth!==0?Q():j.addEventListener("load",Q)}if(w==="audio"||w==="video"){var se=S;se.rr_mediaState=t.paused?"paused":"played",se.rr_mediaCurrentTime=t.currentTime,se.rr_mediaPlaybackRate=t.playbackRate,se.rr_mediaMuted=t.muted,se.rr_mediaLoop=t.loop,se.rr_mediaVolume=t.volume}if(g||(t.scrollLeft&&(S.rr_scrollLeft=t.scrollLeft),t.scrollTop&&(S.rr_scrollTop=t.scrollTop)),y){var ge=t.getBoundingClientRect(),He=ge.width,Ee=ge.height;S={class:S.class,rr_width:""+He+"px",rr_height:""+Ee+"px"}}w==="iframe"&&!v(S.src)&&(t.contentDocument||(S.rr_src=S.src),delete S.src);var St;try{customElements.get(w)&&(St=!0)}catch(ye){}return{type:ie.Element,tagName:w,attributes:S,childNodes:[],isSVG:hl(t)||void 0,needBlock:y,rootId:d,isCustom:St}}function H(t){return t==null?"":t.toLowerCase()}function Sl(t,i){if(i.comment&&t.type===ie.Comment)return!0;if(t.type===ie.Element){if(i.script&&(t.tagName==="script"||t.tagName==="link"&&(t.attributes.rel==="preload"||t.attributes.rel==="modulepreload")&&t.attributes.as==="script"||t.tagName==="link"&&t.attributes.rel==="prefetch"&&typeof t.attributes.href=="string"&&mo(t.attributes.href)==="js"))return!0;if(i.headFavicon&&(t.tagName==="link"&&t.attributes.rel==="shortcut icon"||t.tagName==="meta"&&(H(t.attributes.name).match(/^msapplication-tile(image|color)$/)||H(t.attributes.name)==="application-name"||H(t.attributes.rel)==="icon"||H(t.attributes.rel)==="apple-touch-icon"||H(t.attributes.rel)==="shortcut icon")))return!0;if(t.tagName==="meta"){if(i.headMetaDescKeywords&&H(t.attributes.name).match(/^description|keywords$/))return!0;if(i.headMetaSocial&&(H(t.attributes.property).match(/^(og|twitter|fb):/)||H(t.attributes.name).match(/^(og|twitter):/)||H(t.attributes.name)==="pinterest"))return!0;if(i.headMetaRobots&&(H(t.attributes.name)==="robots"||H(t.attributes.name)==="googlebot"||H(t.attributes.name)==="bingbot"))return!0;if(i.headMetaHttpEquiv&&t.attributes["http-equiv"]!==void 0)return!0;if(i.headMetaAuthorship&&(H(t.attributes.name)==="author"||H(t.attributes.name)==="generator"||H(t.attributes.name)==="framework"||H(t.attributes.name)==="publisher"||H(t.attributes.name)==="progid"||H(t.attributes.property).match(/^article:/)||H(t.attributes.property).match(/^product:/)))return!0;if(i.headMetaVerification&&(H(t.attributes.name)==="google-site-verification"||H(t.attributes.name)==="yandex-verification"||H(t.attributes.name)==="csrf-token"||H(t.attributes.name)==="p:domain_verify"||H(t.attributes.name)==="verify-v1"||H(t.attributes.name)==="verification"||H(t.attributes.name)==="shopify-checkout-api-token"))return!0}}return!1}function ot(t,i){var o=i.doc,e=i.mirror,r=i.blockClass,n=i.blockSelector,s=i.maskTextClass,a=i.maskTextSelector,u=i.skipChild,l=u===void 0?!1:u,c=i.inlineStylesheet,f=c===void 0?!0:c,h=i.maskInputOptions,v=h===void 0?{}:h,p=i.maskTextFn,g=i.maskInputFn,d=i.slimDOMOptions,y=i.dataURLOptions,w=y===void 0?{}:y,S=i.inlineImages,b=S===void 0?!1:S,C=i.recordCanvas,x=C===void 0?!1:C,E=i.onSerialize,R=i.onIframeLoad,_=i.iframeLoadTimeout,B=_===void 0?5e3:_,M=i.onStylesheetLoad,P=i.stylesheetLoadTimeout,G=P===void 0?5e3:P,pe=i.keepIframeSrcFn,j=pe===void 0?function(){return!1}:pe,me=i.newlyAddedElement,he=me===void 0?!1:me,Q=i.cssCaptured,se=Q===void 0?!1:Q,ge=i.needsMask,He=i.preserveWhiteSpace,Ee=He===void 0?!0:He;if(!ge){var St=ge===void 0;ge=Co(t,s,a,St)}var ye=ml(t,{doc:o,mirror:e,blockClass:r,blockSelector:n,needsMask:ge,inlineStylesheet:f,maskInputOptions:v,maskTextFn:p,maskInputFn:g,dataURLOptions:w,inlineImages:b,recordCanvas:x,keepIframeSrcFn:j,newlyAddedElement:he,cssCaptured:se});if(!ye)return console.warn(t,"not serialized"),null;var Je;e.hasNode(t)?Je=e.getId(t):Sl(ye,d)||!Ee&&ye.type===ie.Text&&!ye.textContent.replace(/^\s+|\s+$/gm,"").length?Je=Mt:Je=go();var z=Object.assign(ye,{id:Je});if(e.add(t,z),Je===Mt)return null;E&&E(t);var Ze=!l;if(z.type===ie.Element){Ze=Ze&&!z.needBlock,delete z.needBlock;var Ke=ue.shadowRoot(t);Ke&&At(Ke)&&(z.isShadowHost=!0)}if((z.type===ie.Document||z.type===ie.Element)&&Ze){d.headWhitespace&&z.type===ie.Element&&z.tagName==="head"&&(Ee=!1);var bt={doc:o,mirror:e,blockClass:r,blockSelector:n,needsMask:ge,maskTextClass:s,maskTextSelector:a,skipChild:l,inlineStylesheet:f,maskInputOptions:v,maskTextFn:p,maskInputFn:g,slimDOMOptions:d,dataURLOptions:w,inlineImages:b,recordCanvas:x,preserveWhiteSpace:Ee,onSerialize:E,onIframeLoad:R,iframeLoadTimeout:B,onStylesheetLoad:M,stylesheetLoadTimeout:G,keepIframeSrcFn:j,cssCaptured:!1};if(!(z.type===ie.Element&&z.tagName==="textarea"&&z.attributes.value!==void 0)){z.type===ie.Element&&z.attributes._cssText!==void 0&&typeof z.attributes._cssText=="string"&&(bt.cssCaptured=!0);for(var rr=O(Array.from(ue.childNodes(t))),nr;!(nr=rr()).done;){var Xi=nr.value,vn=ot(Xi,bt);vn&&z.childNodes.push(vn)}}var We=null;if(fo(t)&&(We=ue.shadowRoot(t)))for(var Xe=O(Array.from(ue.childNodes(We))),Ct;!(Ct=Xe()).done;){var ir=Ct.value,It=ot(ir,bt);It&&(At(We)&&(It.isShadow=!0),z.childNodes.push(It))}}var Qe=ue.parentNode(t);return Qe&&Et(Qe)&&At(Qe)&&(z.isShadow=!0),z.type===ie.Element&&z.tagName==="iframe"&&pl(t,function(){var Pe=t.contentDocument;if(Pe&&R){var et=ot(Pe,{doc:Pe,mirror:e,blockClass:r,blockSelector:n,needsMask:ge,maskTextClass:s,maskTextSelector:a,skipChild:!1,inlineStylesheet:f,maskInputOptions:v,maskTextFn:p,maskInputFn:g,slimDOMOptions:d,dataURLOptions:w,inlineImages:b,recordCanvas:x,preserveWhiteSpace:Ee,onSerialize:E,onIframeLoad:R,iframeLoadTimeout:B,onStylesheetLoad:M,stylesheetLoadTimeout:G,keepIframeSrcFn:j});et&&R(t,et)}},B),z.type===ie.Element&&z.tagName==="link"&&typeof z.attributes.rel=="string"&&(z.attributes.rel==="stylesheet"||z.attributes.rel==="preload"&&typeof z.attributes.href=="string"&&mo(z.attributes.href)==="css")&&vl(t,function(){if(M){var Pe=ot(t,{doc:o,mirror:e,blockClass:r,blockSelector:n,needsMask:ge,maskTextClass:s,maskTextSelector:a,skipChild:!1,inlineStylesheet:f,maskInputOptions:v,maskTextFn:p,maskInputFn:g,slimDOMOptions:d,dataURLOptions:w,inlineImages:b,recordCanvas:x,preserveWhiteSpace:Ee,onSerialize:E,onIframeLoad:R,iframeLoadTimeout:B,onStylesheetLoad:M,stylesheetLoadTimeout:G,keepIframeSrcFn:j});Pe&&M(t,Pe)}},G),z}function bl(t,i){var o=i||{},e=o.mirror,r=e===void 0?new po:e,n=o.blockClass,s=n===void 0?"rr-block":n,a=o.blockSelector,u=a===void 0?null:a,l=o.maskTextClass,c=l===void 0?"rr-mask":l,f=o.maskTextSelector,h=f===void 0?null:f,v=o.inlineStylesheet,p=v===void 0?!0:v,g=o.inlineImages,d=g===void 0?!1:g,y=o.recordCanvas,w=y===void 0?!1:y,S=o.maskAllInputs,b=S===void 0?!1:S,C=o.maskTextFn,x=o.maskInputFn,E=o.slimDOM,R=E===void 0?!1:E,_=o.dataURLOptions,B=o.preserveWhiteSpace,M=o.onSerialize,P=o.onIframeLoad,G=o.iframeLoadTimeout,pe=o.onStylesheetLoad,j=o.stylesheetLoadTimeout,me=o.keepIframeSrcFn,he=me===void 0?function(){return!1}:me,Q=b===!0?{color:!0,date:!0,"datetime-local":!0,email:!0,month:!0,number:!0,range:!0,search:!0,tel:!0,text:!0,time:!0,url:!0,week:!0,textarea:!0,select:!0,password:!0}:b===!1?{password:!0}:b,se=R===!0||R==="all"?{script:!0,comment:!0,headFavicon:!0,headWhitespace:!0,headMetaDescKeywords:R==="all",headMetaSocial:!0,headMetaRobots:!0,headMetaHttpEquiv:!0,headMetaAuthorship:!0,headMetaVerification:!0}:R===!1?{}:R;return ot(t,{doc:t,mirror:r,blockClass:s,blockSelector:u,maskTextClass:c,maskTextSelector:h,skipChild:!1,inlineStylesheet:p,maskInputOptions:Q,maskTextFn:C,maskInputFn:x,slimDOMOptions:se,dataURLOptions:_,inlineImages:d,recordCanvas:w,preserveWhiteSpace:B,onSerialize:M,onIframeLoad:P,iframeLoadTimeout:G,onStylesheetLoad:pe,stylesheetLoadTimeout:j,keepIframeSrcFn:he,newlyAddedElement:!1})}function Cl(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}function Il(t){if(t.__esModule)return t;var i=t.default;if(typeof i=="function"){var o=function e(){return T(this,e)?Reflect.construct(i,arguments,this.constructor):i.apply(this,arguments)};o.prototype=i.prototype}else o={};return Object.defineProperty(o,"__esModule",{value:!0}),Object.keys(t).forEach(function(e){var r=Object.getOwnPropertyDescriptor(t,e);Object.defineProperty(o,e,r.get?r:{enumerable:!0,get:function(){return t[e]}})}),o}var En={exports:{}},J=String,Io=function(){return{isColorSupported:!1,reset:J,bold:J,dim:J,italic:J,underline:J,inverse:J,hidden:J,strikethrough:J,black:J,red:J,green:J,yellow:J,blue:J,magenta:J,cyan:J,white:J,gray:J,bgBlack:J,bgRed:J,bgGreen:J,bgYellow:J,bgBlue:J,bgMagenta:J,bgCyan:J,bgWhite:J}};En.exports=Io(),En.exports.createColors=Io;var Ol=En.exports,xl={},Rl=Object.freeze(Object.defineProperty({__proto__:null,default:xl},Symbol.toStringTag,{value:"Module"})),re=Il(Rl),Oo=Ol,xo=re,An=function(t){ae(i,t);function i(e,r,n,s,a,u){var l;return l=t.call(this,e)||this,l.name="CssSyntaxError",l.reason=e,a&&(l.file=a),s&&(l.source=s),u&&(l.plugin=u),typeof r!="undefined"&&typeof n!="undefined"&&(typeof r=="number"?(l.line=r,l.column=n):(l.line=r.line,l.column=r.column,l.endLine=n.line,l.endColumn=n.column)),l.setMessage(),Error.captureStackTrace&&Error.captureStackTrace(l,i),l}var o=i.prototype;return o.setMessage=function(){this.message=this.plugin?this.plugin+": ":"",this.message+=this.file?this.file:"<css input>",typeof this.line!="undefined"&&(this.message+=":"+this.line+":"+this.column),this.message+=": "+this.reason},o.showSourceCode=function(r){var n=this;if(!this.source)return"";var s=this.source;r==null&&(r=Oo.isColorSupported),xo&&r&&(s=xo(s));var a=s.split(/\r?\n/),u=Math.max(this.line-3,0),l=Math.min(this.line+2,a.length),c=String(l).length,f,h;if(r){var v=Oo.createColors(!0),p=v.bold,g=v.gray,d=v.red;f=function(y){return p(d(y))},h=function(y){return g(y)}}else f=h=function(y){return y};return a.slice(u,l).map(function(y,w){var S=u+1+w,b=" "+(" "+S).slice(-c)+" | ";if(S===n.line){var C=h(b.replace(/\d/g," "))+y.slice(0,n.column-1).replace(/[^\t]/g," ");return f(">")+h(b)+y+"\n "+C+f("^")}return" "+h(b)+y}).join("\n")},o.toString=function(){var r=this.showSourceCode();return r&&(r="\n\n"+r+"\n"),this.name+": "+this.message+r},i}(ar(Error)),Mn=An;An.default=An;var $e={};$e.isClean=Symbol("isClean"),$e.my=Symbol("my");var Ro={after:"\n",beforeClose:"\n",beforeComment:"\n",beforeDecl:"\n",beforeOpen:" ",beforeRule:"\n",colon:": ",commentLeft:" ",commentRight:" ",emptyBody:"",indent:" ",semicolon:!1};function El(t){return t[0].toUpperCase()+t.slice(1)}var kn=function(){function t(o){this.builder=o}var i=t.prototype;return i.atrule=function(e,r){var n="@"+e.name,s=e.params?this.rawValue(e,"params"):"";if(typeof e.raws.afterName!="undefined"?n+=e.raws.afterName:s&&(n+=" "),e.nodes)this.block(e,n+s);else{var a=(e.raws.between||"")+(r?";":"");this.builder(n+s+a,e)}},i.beforeAfter=function(e,r){var n;e.type==="decl"?n=this.raw(e,null,"beforeDecl"):e.type==="comment"?n=this.raw(e,null,"beforeComment"):r==="before"?n=this.raw(e,null,"beforeRule"):n=this.raw(e,null,"beforeClose");for(var s=e.parent,a=0;s&&s.type!=="root";)a+=1,s=s.parent;if(n.includes("\n")){var u=this.raw(e,null,"indent");if(u.length)for(var l=0;l<a;l++)n+=u}return n},i.block=function(e,r){var n=this.raw(e,"between","beforeOpen");this.builder(r+n+"{",e,"start");var s;e.nodes&&e.nodes.length?(this.body(e),s=this.raw(e,"after")):s=this.raw(e,"after","emptyBody"),s&&this.builder(s),this.builder("}",e,"end")},i.body=function(e){for(var r=e.nodes.length-1;r>0&&e.nodes[r].type==="comment";)r-=1;for(var n=this.raw(e,"semicolon"),s=0;s<e.nodes.length;s++){var a=e.nodes[s],u=this.raw(a,"before");u&&this.builder(u),this.stringify(a,r!==s||n)}},i.comment=function(e){var r=this.raw(e,"left","commentLeft"),n=this.raw(e,"right","commentRight");this.builder("/*"+r+e.text+n+"*/",e)},i.decl=function(e,r){var n=this.raw(e,"between","colon"),s=e.prop+n+this.rawValue(e,"value");e.important&&(s+=e.raws.important||" !important"),r&&(s+=";"),this.builder(s,e)},i.document=function(e){this.body(e)},i.raw=function(e,r,n){var s;if(n||(n=r),r&&(s=e.raws[r],typeof s!="undefined"))return s;var a=e.parent;if(n==="before"&&(!a||a.type==="root"&&a.first===e||a&&a.type==="document"))return"";if(!a)return Ro[n];var u=e.root();if(u.rawCache||(u.rawCache={}),typeof u.rawCache[n]!="undefined")return u.rawCache[n];if(n==="before"||n==="after")return this.beforeAfter(e,n);var l="raw"+El(n);return this[l]?s=this[l](u,e):u.walk(function(c){if(s=c.raws[r],typeof s!="undefined")return!1}),typeof s=="undefined"&&(s=Ro[n]),u.rawCache[n]=s,s},i.rawBeforeClose=function(e){var r;return e.walk(function(n){if(n.nodes&&n.nodes.length>0&&typeof n.raws.after!="undefined")return r=n.raws.after,r.includes("\n")&&(r=r.replace(/[^\n]+$/,"")),!1}),r&&(r=r.replace(/\S/g,"")),r},i.rawBeforeComment=function(e,r){var n;return e.walkComments(function(s){if(typeof s.raws.before!="undefined")return n=s.raws.before,n.includes("\n")&&(n=n.replace(/[^\n]+$/,"")),!1}),typeof n=="undefined"?n=this.raw(r,null,"beforeDecl"):n&&(n=n.replace(/\S/g,"")),n},i.rawBeforeDecl=function(e,r){var n;return e.walkDecls(function(s){if(typeof s.raws.before!="undefined")return n=s.raws.before,n.includes("\n")&&(n=n.replace(/[^\n]+$/,"")),!1}),typeof n=="undefined"?n=this.raw(r,null,"beforeRule"):n&&(n=n.replace(/\S/g,"")),n},i.rawBeforeOpen=function(e){var r;return e.walk(function(n){if(n.type!=="decl"&&(r=n.raws.between,typeof r!="undefined"))return!1}),r},i.rawBeforeRule=function(e){var r;return e.walk(function(n){if(n.nodes&&(n.parent!==e||e.first!==n)&&typeof n.raws.before!="undefined")return r=n.raws.before,r.includes("\n")&&(r=r.replace(/[^\n]+$/,"")),!1}),r&&(r=r.replace(/\S/g,"")),r},i.rawColon=function(e){var r;return e.walkDecls(function(n){if(typeof n.raws.between!="undefined")return r=n.raws.between.replace(/[^\s:]/g,""),!1}),r},i.rawEmptyBody=function(e){var r;return e.walk(function(n){if(n.nodes&&n.nodes.length===0&&(r=n.raws.after,typeof r!="undefined"))return!1}),r},i.rawIndent=function(e){if(e.raws.indent)return e.raws.indent;var r;return e.walk(function(n){var s=n.parent;if(s&&s!==e&&s.parent&&s.parent===e&&typeof n.raws.before!="undefined"){var a=n.raws.before.split("\n");return r=a[a.length-1],r=r.replace(/\S/g,""),!1}}),r},i.rawSemicolon=function(e){var r;return e.walk(function(n){if(n.nodes&&n.nodes.length&&n.last.type==="decl"&&(r=n.raws.semicolon,typeof r!="undefined"))return!1}),r},i.rawValue=function(e,r){var n=e[r],s=e.raws[r];return s&&s.value===n?s.raw:n},i.root=function(e){this.body(e),e.raws.after&&this.builder(e.raws.after)},i.rule=function(e){this.block(e,this.rawValue(e,"selector")),e.raws.ownSemicolon&&this.builder(e.raws.ownSemicolon,e,"end")},i.stringify=function(e,r){if(!this[e.type])throw new Error("Unknown AST node type "+e.type+". Maybe you need to change PostCSS stringifier.");this[e.type](e,r)},t}(),Eo=kn;kn.default=kn;var Al=Eo;function _n(t,i){var o=new Al(i);o.stringify(t)}var fr=_n;_n.default=_n;var hr=$e.isClean,Ml=$e.my,kl=Mn,_l=Eo,Tl=fr;function Tn(t,i){var o=new t.constructor;for(var e in t)if(Object.prototype.hasOwnProperty.call(t,e)&&e!=="proxyCache"){var r=t[e],n=typeof r=="undefined"?"undefined":N(r);e==="parent"&&n==="object"?i&&(o[e]=i):e==="source"?o[e]=r:Array.isArray(r)?o[e]=r.map(function(s){return Tn(s,o)}):(n==="object"&&r!==null&&(r=Tn(r)),o[e]=r)}return o}var Pn=function(){function t(o){o===void 0&&(o={}),this.raws={},this[hr]=!1,this[Ml]=!0;for(var e in o)if(e==="nodes"){this.nodes=[];for(var r=O(o[e]),n;!(n=r()).done;){var s=n.value;typeof s.clone=="function"?this.append(s.clone()):this.append(s)}}else this[e]=o[e]}var i=t.prototype;return i.addToError=function(e){if(e.postcssNode=this,e.stack&&this.source&&/\n\s{4}at /.test(e.stack)){var r=this.source;e.stack=e.stack.replace(/\n\s{4}at /,"$&"+r.input.from+":"+r.start.line+":"+r.start.column+"$&")}return e},i.after=function(e){return this.parent.insertAfter(this,e),this},i.assign=function(e){e===void 0&&(e={});for(var r in e)this[r]=e[r];return this},i.before=function(e){return this.parent.insertBefore(this,e),this},i.cleanRaws=function(e){delete this.raws.before,delete this.raws.after,e||delete this.raws.between},i.clone=function(e){e===void 0&&(e={});var r=Tn(this);for(var n in e)r[n]=e[n];return r},i.cloneAfter=function(e){e===void 0&&(e={});var r=this.clone(e);return this.parent.insertAfter(this,r),r},i.cloneBefore=function(e){e===void 0&&(e={});var r=this.clone(e);return this.parent.insertBefore(this,r),r},i.error=function(e,r){if(r===void 0&&(r={}),this.source){var n=this.rangeBy(r),s=n.end,a=n.start;return this.source.input.error(e,{column:a.column,line:a.line},{column:s.column,line:s.line},r)}return new kl(e)},i.getProxyProcessor=function(){return{get:function(r,n){return n==="proxyOf"?r:n==="root"?function(){return r.root().toProxy()}:r[n]},set:function(r,n,s){return r[n]===s||(r[n]=s,(n==="prop"||n==="value"||n==="name"||n==="params"||n==="important"||n==="text")&&r.markDirty()),!0}}},i.markDirty=function(){if(this[hr]){this[hr]=!1;for(var e=this;e=e.parent;)e[hr]=!1}},i.next=function(){if(this.parent){var e=this.parent.index(this);return this.parent.nodes[e+1]}},i.positionBy=function(e,r){var n=this.source.start;if(e.index)n=this.positionInside(e.index,r);else if(e.word){r=this.toString();var s=r.indexOf(e.word);s!==-1&&(n=this.positionInside(s,r))}return n},i.positionInside=function(e,r){for(var n=r||this.toString(),s=this.source.start.column,a=this.source.start.line,u=0;u<e;u++)n[u]==="\n"?(s=1,a+=1):s+=1;return{column:s,line:a}},i.prev=function(){if(this.parent){var e=this.parent.index(this);return this.parent.nodes[e-1]}},i.rangeBy=function(e){var r={column:this.source.start.column,line:this.source.start.line},n=this.source.end?{column:this.source.end.column+1,line:this.source.end.line}:{column:r.column+1,line:r.line};if(e.word){var s=this.toString(),a=s.indexOf(e.word);a!==-1&&(r=this.positionInside(a,s),n=this.positionInside(a+e.word.length,s))}else e.start?r={column:e.start.column,line:e.start.line}:e.index&&(r=this.positionInside(e.index)),e.end?n={column:e.end.column,line:e.end.line}:typeof e.endIndex=="number"?n=this.positionInside(e.endIndex):e.index&&(n=this.positionInside(e.index+1));return(n.line<r.line||n.line===r.line&&n.column<=r.column)&&(n={column:r.column+1,line:r.line}),{end:n,start:r}},i.raw=function(e,r){var n=new _l;return n.raw(this,e,r)},i.remove=function(){return this.parent&&this.parent.removeChild(this),this.parent=void 0,this},i.replaceWith=function(){for(var e=arguments.length,r=new Array(e),n=0;n<e;n++)r[n]=arguments[n];if(this.parent){for(var s=this,a=!1,u=O(r),l;!(l=u()).done;){var c=l.value;c===this?a=!0:a?(this.parent.insertAfter(s,c),s=c):this.parent.insertBefore(s,c)}a||this.remove()}return this},i.root=function(){for(var e=this;e.parent&&e.parent.type!=="document";)e=e.parent;return e},i.toJSON=function(e,r){var n={},s=r==null;r=r||new Map;var a=0;for(var u in this)if(Object.prototype.hasOwnProperty.call(this,u)&&!(u==="parent"||u==="proxyCache")){var l=this[u];if(Array.isArray(l))n[u]=l.map(function(f){return(typeof f=="undefined"?"undefined":N(f))==="object"&&f.toJSON?f.toJSON(null,r):f});else if((typeof l=="undefined"?"undefined":N(l))==="object"&&l.toJSON)n[u]=l.toJSON(null,r);else if(u==="source"){var c=r.get(l.input);c==null&&(c=a,r.set(l.input,a),a++),n[u]={end:l.end,inputId:c,start:l.start}}else n[u]=l}return s&&(n.inputs=[].concat(r.keys()).map(function(f){return f.toJSON()})),n},i.toProxy=function(){return this.proxyCache||(this.proxyCache=new Proxy(this,this.getProxyProcessor())),this.proxyCache},i.toString=function(e){e===void 0&&(e=Tl),e.stringify&&(e=e.stringify);var r="";return e(this,function(n){r+=n}),r},i.warn=function(e,r,n){var s={node:this};for(var a in n)s[a]=n[a];return e.warn(r,s)},oe(t,[{key:"proxyOf",get:function(){return this}}]),t}(),dr=Pn;Pn.default=Pn;var Pl=dr,Nn=function(t){ae(i,t);function i(o){var e;return o&&typeof o.value!="undefined"&&typeof o.value!="string"&&(o=F({},o,{value:String(o.value)})),e=t.call(this,o)||this,e.type="decl",e}return oe(i,[{key:"variable",get:function(){return this.prop.startsWith("--")||this.prop[0]==="$"}}]),i}(Pl),pr=Nn;Nn.default=Nn;var Nl="useandom-26T198340PX75pxJACKVERYMINDBUSHWOLF_GQZbfghjklqvwyzrict",$l=function(t){t===void 0&&(t=21);for(var i="",o=t;o--;)i+=Nl[Math.random()*64|0];return i},Dl={nanoid:$l},Ao=re.SourceMapConsumer,Mo=re.SourceMapGenerator,Ll=re.existsSync,Fl=re.readFileSync,$n=re.dirname,Bl=re.join;function Ul(t){return Buffer?Buffer.from(t,"base64").toString():window.atob(t)}var Dn=function(){function t(o,e){if(e.map!==!1){this.loadAnnotation(o),this.inline=this.startWith(this.annotation,"data:");var r=e.map?e.map.prev:void 0,n=this.loadMap(e.from,r);!this.mapFile&&e.from&&(this.mapFile=e.from),this.mapFile&&(this.root=$n(this.mapFile)),n&&(this.text=n)}}var i=t.prototype;return i.consumer=function(){return this.consumerCache||(this.consumerCache=new Ao(this.text)),this.consumerCache},i.decodeInline=function(e){var r=/^data:application\/json;charset=utf-?8;base64,/,n=/^data:application\/json;base64,/,s=/^data:application\/json;charset=utf-?8,/,a=/^data:application\/json,/;if(s.test(e)||a.test(e))return decodeURIComponent(e.substr(RegExp.lastMatch.length));if(r.test(e)||n.test(e))return Ul(e.substr(RegExp.lastMatch.length));var u=e.match(/data:application\/json;([^,]+),/)[1];throw new Error("Unsupported source map encoding "+u)},i.getAnnotationURL=function(e){return e.replace(/^\/\*\s*# sourceMappingURL=/,"").trim()},i.isMap=function(e){return(typeof e=="undefined"?"undefined":N(e))!=="object"?!1:typeof e.mappings=="string"||typeof e._mappings=="string"||Array.isArray(e.sections)},i.loadAnnotation=function(e){var r=e.match(/\/\*\s*# sourceMappingURL=/gm);if(r){var n=e.lastIndexOf(r.pop()),s=e.indexOf("*/",n);n>-1&&s>-1&&(this.annotation=this.getAnnotationURL(e.substring(n,s)))}},i.loadFile=function(e){if(this.root=$n(e),Ll(e))return this.mapFile=e,Fl(e,"utf-8").toString().trim()},i.loadMap=function(e,r){if(r===!1)return!1;if(r){if(typeof r=="string")return r;if(typeof r=="function"){var n=r(e);if(n){var s=this.loadFile(n);if(!s)throw new Error("Unable to load previous source map: "+n.toString());return s}}else{if(T(r,Ao))return Mo.fromSourceMap(r).toString();if(T(r,Mo))return r.toString();if(this.isMap(r))return JSON.stringify(r);throw new Error("Unsupported previous source map format: "+r.toString())}}else{if(this.inline)return this.decodeInline(this.annotation);if(this.annotation){var a=this.annotation;return e&&(a=Bl($n(e),a)),this.loadFile(a)}}},i.startWith=function(e,r){return e?e.substr(0,r.length)===r:!1},i.withContent=function(){return!!(this.consumer().sourcesContent&&this.consumer().sourcesContent.length>0)},t}(),ko=Dn;Dn.default=Dn;var zl=re.SourceMapConsumer,Wl=re.SourceMapGenerator,_o=re.fileURLToPath,vr=re.pathToFileURL,Ln=re.isAbsolute,Fn=re.resolve,Gl=Dl.nanoid,Bn=re,To=Mn,jl=ko,Un=Symbol("fromOffsetCache"),Vl=!!(zl&&Wl),Po=!!(Fn&&Ln),mr=function(){function t(o,e){if(e===void 0&&(e={}),o===null||typeof o=="undefined"||(typeof o=="undefined"?"undefined":N(o))==="object"&&!o.toString)throw new Error("PostCSS received "+o+" instead of CSS string");if(this.css=o.toString(),this.css[0]==="\uFEFF"||this.css[0]==="\uFFFE"?(this.hasBOM=!0,this.css=this.css.slice(1)):this.hasBOM=!1,e.from&&(!Po||/^\w+:\/\//.test(e.from)||Ln(e.from)?this.file=e.from:this.file=Fn(e.from)),Po&&Vl){var r=new jl(this.css,e);if(r.text){this.map=r;var n=r.consumer().file;!this.file&&n&&(this.file=this.mapResolve(n))}}this.file||(this.id="<input css "+Gl(6)+">"),this.map&&(this.map.file=this.from)}var i=t.prototype;return i.error=function(e,r,n,s){s===void 0&&(s={});var a,u,l;if(r&&(typeof r=="undefined"?"undefined":N(r))==="object"){var c=r,f=n;if(typeof c.offset=="number"){var h=this.fromOffset(c.offset);r=h.line,n=h.col}else r=c.line,n=c.column;if(typeof f.offset=="number"){var v=this.fromOffset(f.offset);u=v.line,l=v.col}else u=f.line,l=f.column}else if(!n){var p=this.fromOffset(r);r=p.line,n=p.col}var g=this.origin(r,n,u,l);return g?a=new To(e,g.endLine===void 0?g.line:{column:g.column,line:g.line},g.endLine===void 0?g.column:{column:g.endColumn,line:g.endLine},g.source,g.file,s.plugin):a=new To(e,u===void 0?r:{column:n,line:r},u===void 0?n:{column:l,line:u},this.css,this.file,s.plugin),a.input={column:n,endColumn:l,endLine:u,line:r,source:this.css},this.file&&(vr&&(a.input.url=vr(this.file).toString()),a.input.file=this.file),a},i.fromOffset=function(e){var r,n;if(this[Un])n=this[Un];else{var s=this.css.split("\n");n=new Array(s.length);for(var a=0,u=0,l=s.length;u<l;u++)n[u]=a,a+=s[u].length+1;this[Un]=n}r=n[n.length-1];var c=0;if(e>=r)c=n.length-1;else for(var f=n.length-2,h;c<f;)if(h=c+(f-c>>1),e<n[h])f=h-1;else if(e>=n[h+1])c=h+1;else{c=h;break}return{col:e-n[c]+1,line:c+1}},i.mapResolve=function(e){return/^\w+:\/\//.test(e)?e:Fn(this.map.consumer().sourceRoot||this.map.root||".",e)},i.origin=function(e,r,n,s){if(!this.map)return!1;var a=this.map.consumer(),u=a.originalPositionFor({column:r,line:e});if(!u.source)return!1;var l;typeof n=="number"&&(l=a.originalPositionFor({column:s,line:n}));var c;Ln(u.source)?c=vr(u.source):c=new URL(u.source,this.map.consumer().sourceRoot||vr(this.map.mapFile));var f={column:u.column,endColumn:l&&l.column,endLine:l&&l.line,line:u.line,url:c.toString()};if(c.protocol==="file:")if(_o)f.file=_o(c);else throw new Error("file: protocol is not available in this PostCSS build");var h=a.sourceContentFor(u.source);return h&&(f.source=h),f},i.toJSON=function(){for(var e={},r=0,n=["hasBOM","css","file","id"];r<n.length;r++){var s=n[r];this[s]!=null&&(e[s]=this[s])}return this.map&&(e.map=F({},this.map),e.map.consumerCache&&(e.map.consumerCache=void 0)),e},oe(t,[{key:"from",get:function(){return this.file||this.id}}]),t}(),gr=mr;mr.default=mr,Bn&&Bn.registerInput&&Bn.registerInput(mr);var No=re.SourceMapConsumer,yr=re.SourceMapGenerator,wr=re.dirname,$o=re.relative,Do=re.resolve,Lo=re.sep,Fo=re.pathToFileURL,Yl=gr,ql=!!(No&&yr),Hl=!!(wr&&Do&&$o&&Lo),Jl=function(){function t(o,e,r,n){this.stringify=o,this.mapOpts=r.map||{},this.root=e,this.opts=r,this.css=n,this.originalCSS=n,this.usesFileUrls=!this.mapOpts.from&&this.mapOpts.absolute,this.memoizedFileURLs=new Map,this.memoizedPaths=new Map,this.memoizedURLs=new Map}var i=t.prototype;return i.addAnnotation=function(){var e;this.isInline()?e="data:application/json;base64,"+this.toBase64(this.map.toString()):typeof this.mapOpts.annotation=="string"?e=this.mapOpts.annotation:typeof this.mapOpts.annotation=="function"?e=this.mapOpts.annotation(this.opts.to,this.root):e=this.outputFile()+".map";var r="\n";this.css.includes("\r\n")&&(r="\r\n"),this.css+=r+"/*# sourceMappingURL="+e+" */"},i.applyPrevMaps=function(){for(var e=O(this.previous()),r;!(r=e()).done;){var n=r.value,s=this.toUrl(this.path(n.file)),a=n.root||wr(n.file),u=void 0;this.mapOpts.sourcesContent===!1?(u=new No(n.text),u.sourcesContent&&(u.sourcesContent=null)):u=n.consumer(),this.map.applySourceMap(u,s,this.toUrl(this.path(a)))}},i.clearAnnotation=function(){if(this.mapOpts.annotation!==!1)if(this.root)for(var e,r=this.root.nodes.length-1;r>=0;r--)e=this.root.nodes[r],e.type==="comment"&&e.text.indexOf("# sourceMappingURL=")===0&&this.root.removeChild(r);else this.css&&(this.css=this.css.replace(/\n*?\/\*#[\S\s]*?\*\/$/gm,""))},i.generate=function(){if(this.clearAnnotation(),Hl&&ql&&this.isMap())return this.generateMap();var e="";return this.stringify(this.root,function(r){e+=r}),[e]},i.generateMap=function(){if(this.root)this.generateString();else if(this.previous().length===1){var e=this.previous()[0].consumer();e.file=this.outputFile(),this.map=yr.fromSourceMap(e,{ignoreInvalidMapping:!0})}else this.map=new yr({file:this.outputFile(),ignoreInvalidMapping:!0}),this.map.addMapping({generated:{column:0,line:1},original:{column:0,line:1},source:this.opts.from?this.toUrl(this.path(this.opts.from)):"<no source>"});return this.isSourcesContent()&&this.setSourcesContent(),this.root&&this.previous().length>0&&this.applyPrevMaps(),this.isAnnotation()&&this.addAnnotation(),this.isInline()?[this.css]:[this.css,this.map]},i.generateString=function(){var e=this;this.css="",this.map=new yr({file:this.outputFile(),ignoreInvalidMapping:!0});var r=1,n=1,s="<no source>",a={generated:{column:0,line:0},original:{column:0,line:0},source:""},u,l;this.stringify(this.root,function(c,f,h){if(e.css+=c,f&&h!=="end"&&(a.generated.line=r,a.generated.column=n-1,f.source&&f.source.start?(a.source=e.sourcePath(f),a.original.line=f.source.start.line,a.original.column=f.source.start.column-1,e.map.addMapping(a)):(a.source=s,a.original.line=1,a.original.column=0,e.map.addMapping(a))),u=c.match(/\n/g),u?(r+=u.length,l=c.lastIndexOf("\n"),n=c.length-l):n+=c.length,f&&h!=="start"){var v=f.parent||{raws:{}},p=f.type==="decl"||f.type==="atrule"&&!f.nodes;(!p||f!==v.last||v.raws.semicolon)&&(f.source&&f.source.end?(a.source=e.sourcePath(f),a.original.line=f.source.end.line,a.original.column=f.source.end.column-1,a.generated.line=r,a.generated.column=n-2,e.map.addMapping(a)):(a.source=s,a.original.line=1,a.original.column=0,a.generated.line=r,a.generated.column=n-1,e.map.addMapping(a)))}})},i.isAnnotation=function(){return this.isInline()?!0:typeof this.mapOpts.annotation!="undefined"?this.mapOpts.annotation:this.previous().length?this.previous().some(function(e){return e.annotation}):!0},i.isInline=function(){if(typeof this.mapOpts.inline!="undefined")return this.mapOpts.inline;var e=this.mapOpts.annotation;return typeof e!="undefined"&&e!==!0?!1:this.previous().length?this.previous().some(function(r){return r.inline}):!0},i.isMap=function(){return typeof this.opts.map!="undefined"?!!this.opts.map:this.previous().length>0},i.isSourcesContent=function(){return typeof this.mapOpts.sourcesContent!="undefined"?this.mapOpts.sourcesContent:this.previous().length?this.previous().some(function(e){return e.withContent()}):!0},i.outputFile=function(){return this.opts.to?this.path(this.opts.to):this.opts.from?this.path(this.opts.from):"to.css"},i.path=function(e){if(this.mapOpts.absolute||e.charCodeAt(0)===60||/^\w+:\/\//.test(e))return e;var r=this.memoizedPaths.get(e);if(r)return r;var n=this.opts.to?wr(this.opts.to):".";typeof this.mapOpts.annotation=="string"&&(n=wr(Do(n,this.mapOpts.annotation)));var s=$o(n,e);return this.memoizedPaths.set(e,s),s},i.previous=function(){var e=this;if(!this.previousMaps)if(this.previousMaps=[],this.root)this.root.walk(function(n){if(n.source&&n.source.input.map){var s=n.source.input.map;e.previousMaps.includes(s)||e.previousMaps.push(s)}});else{var r=new Yl(this.originalCSS,this.opts);r.map&&this.previousMaps.push(r.map)}return this.previousMaps},i.setSourcesContent=function(){var e=this,r={};if(this.root)this.root.walk(function(s){if(s.source){var a=s.source.input.from;if(a&&!r[a]){r[a]=!0;var u=e.usesFileUrls?e.toFileUrl(a):e.toUrl(e.path(a));e.map.setSourceContent(u,s.source.input.css)}}});else if(this.css){var n=this.opts.from?this.toUrl(this.path(this.opts.from)):"<no source>";this.map.setSourceContent(n,this.css)}},i.sourcePath=function(e){return this.mapOpts.from?this.toUrl(this.mapOpts.from):this.usesFileUrls?this.toFileUrl(e.source.input.from):this.toUrl(this.path(e.source.input.from))},i.toBase64=function(e){return Buffer?Buffer.from(e).toString("base64"):window.btoa(unescape(encodeURIComponent(e)))},i.toFileUrl=function(e){var r=this.memoizedFileURLs.get(e);if(r)return r;if(Fo){var n=Fo(e).toString();return this.memoizedFileURLs.set(e,n),n}else throw new Error("`map.absolute` option is not available in this PostCSS build")},i.toUrl=function(e){var r=this.memoizedURLs.get(e);if(r)return r;Lo==="\\"&&(e=e.replace(/\\/g,"/"));var n=encodeURI(e).replace(/[#?]/g,encodeURIComponent);return this.memoizedURLs.set(e,n),n},t}(),Bo=Jl,Zl=dr,zn=function(t){ae(i,t);function i(o){var e;return e=t.call(this,o)||this,e.type="comment",e}return i}(Zl),Sr=zn;zn.default=zn;var Uo=$e.isClean,zo=$e.my,Wo=pr,Go=Sr,Kl=dr,jo,Wn,Gn,Vo;function Yo(t){return t.map(function(i){return i.nodes&&(i.nodes=Yo(i.nodes)),delete i.source,i})}function qo(t){if(t[Uo]=!1,t.proxyOf.nodes)for(var i=O(t.proxyOf.nodes),o;!(o=i()).done;){var e=o.value;qo(e)}}var Ae=function(t){ae(i,t);function i(){return t.apply(this,arguments)||this}var o=i.prototype;return o.append=function(){for(var r=arguments.length,n=new Array(r),s=0;s<r;s++)n[s]=arguments[s];for(var a=O(n),u;!(u=a()).done;)for(var l=u.value,c=this.normalize(l,this.last),f=O(c),h;!(h=f()).done;){var v=h.value;this.proxyOf.nodes.push(v)}return this.markDirty(),this},o.cleanRaws=function(r){if(t.prototype.cleanRaws.call(this,r),this.nodes)for(var n=O(this.nodes),s;!(s=n()).done;){var a=s.value;a.cleanRaws(r)}},o.each=function(r){if(this.proxyOf.nodes){for(var n=this.getIterator(),s,a;this.indexes[n]<this.proxyOf.nodes.length&&(s=this.indexes[n],a=r(this.proxyOf.nodes[s],s),a!==!1);)this.indexes[n]+=1;return delete this.indexes[n],a}},o.every=function(r){return this.nodes.every(r)},o.getIterator=function(){this.lastEach||(this.lastEach=0),this.indexes||(this.indexes={}),this.lastEach+=1;var r=this.lastEach;return this.indexes[r]=0,r},o.getProxyProcessor=function(){return{get:function(n,s){return s==="proxyOf"?n:n[s]?s==="each"||typeof s=="string"&&s.startsWith("walk")?function(){for(var a=arguments.length,u=new Array(a),l=0;l<a;l++)u[l]=arguments[l];var c;return(c=n)[s].apply(c,[].concat(u.map(function(f){return typeof f=="function"?function(h,v){return f(h.toProxy(),v)}:f})))}:s==="every"||s==="some"?function(a){return n[s](function(u){for(var l=arguments.length,c=new Array(l>1?l-1:0),f=1;f<l;f++)c[f-1]=arguments[f];return a.apply(void 0,[].concat([u.toProxy()],c))})}:s==="root"?function(){return n.root().toProxy()}:s==="nodes"?n.nodes.map(function(a){return a.toProxy()}):s==="first"||s==="last"?n[s].toProxy():n[s]:n[s]},set:function(n,s,a){return n[s]===a||(n[s]=a,(s==="name"||s==="params"||s==="selector")&&n.markDirty()),!0}}},o.index=function(r){return typeof r=="number"?r:(r.proxyOf&&(r=r.proxyOf),this.proxyOf.nodes.indexOf(r))},o.insertAfter=function(r,n){var s=this.index(r),a=this.normalize(n,this.proxyOf.nodes[s]).reverse();s=this.index(r);for(var u=O(a),l;!(l=u()).done;){var c=l.value;this.proxyOf.nodes.splice(s+1,0,c)}var f;for(var h in this.indexes)f=this.indexes[h],s<f&&(this.indexes[h]=f+a.length);return this.markDirty(),this},o.insertBefore=function(r,n){var s=this.index(r),a=s===0?"prepend":!1,u=this.normalize(n,this.proxyOf.nodes[s],a).reverse();s=this.index(r);for(var l=O(u),c;!(c=l()).done;){var f=c.value;this.proxyOf.nodes.splice(s,0,f)}var h;for(var v in this.indexes)h=this.indexes[v],s<=h&&(this.indexes[v]=h+u.length);return this.markDirty(),this},o.normalize=function(r,n){var s=this;if(typeof r=="string")r=Yo(jo(r).nodes);else if(typeof r=="undefined")r=[];else if(Array.isArray(r)){r=r.slice(0);for(var a=O(r),u;!(u=a()).done;){var l=u.value;l.parent&&l.parent.removeChild(l,"ignore")}}else if(r.type==="root"&&this.type!=="document"){r=r.nodes.slice(0);for(var c=O(r),f;!(f=c()).done;){var h=f.value;h.parent&&h.parent.removeChild(h,"ignore")}}else if(r.type)r=[r];else if(r.prop){if(typeof r.value=="undefined")throw new Error("Value field is missed in node creation");typeof r.value!="string"&&(r.value=String(r.value)),r=[new Wo(r)]}else if(r.selector)r=[new Wn(r)];else if(r.name)r=[new Gn(r)];else if(r.text)r=[new Go(r)];else throw new Error("Unknown node type in node creation");var v=r.map(function(p){return p[zo]||i.rebuild(p),p=p.proxyOf,p.parent&&p.parent.removeChild(p),p[Uo]&&qo(p),typeof p.raws.before=="undefined"&&n&&typeof n.raws.before!="undefined"&&(p.raws.before=n.raws.before.replace(/\S/g,"")),p.parent=s.proxyOf,p});return v},o.prepend=function(){for(var r=arguments.length,n=new Array(r),s=0;s<r;s++)n[s]=arguments[s];n=n.reverse();for(var a=O(n),u;!(u=a()).done;){for(var l=u.value,c=this.normalize(l,this.first,"prepend").reverse(),f=O(c),h;!(h=f()).done;){var v=h.value;this.proxyOf.nodes.unshift(v)}for(var p in this.indexes)this.indexes[p]=this.indexes[p]+c.length}return this.markDirty(),this},o.push=function(r){return r.parent=this,this.proxyOf.nodes.push(r),this},o.removeAll=function(){for(var r=O(this.proxyOf.nodes),n;!(n=r()).done;){var s=n.value;s.parent=void 0}return this.proxyOf.nodes=[],this.markDirty(),this},o.removeChild=function(r){r=this.index(r),this.proxyOf.nodes[r].parent=void 0,this.proxyOf.nodes.splice(r,1);var n;for(var s in this.indexes)n=this.indexes[s],n>=r&&(this.indexes[s]=n-1);return this.markDirty(),this},o.replaceValues=function(r,n,s){return s||(s=n,n={}),this.walkDecls(function(a){n.props&&!n.props.includes(a.prop)||n.fast&&!a.value.includes(n.fast)||(a.value=a.value.replace(r,s))}),this.markDirty(),this},o.some=function(r){return this.nodes.some(r)},o.walk=function(r){return this.each(function(n,s){var a;try{a=r(n,s)}catch(u){throw n.addToError(u)}return a!==!1&&n.walk&&(a=n.walk(r)),a})},o.walkAtRules=function(r,n){return n?T(r,RegExp)?this.walk(function(s,a){if(s.type==="atrule"&&r.test(s.name))return n(s,a)}):this.walk(function(s,a){if(s.type==="atrule"&&s.name===r)return n(s,a)}):(n=r,this.walk(function(s,a){if(s.type==="atrule")return n(s,a)}))},o.walkComments=function(r){return this.walk(function(n,s){if(n.type==="comment")return r(n,s)})},o.walkDecls=function(r,n){return n?T(r,RegExp)?this.walk(function(s,a){if(s.type==="decl"&&r.test(s.prop))return n(s,a)}):this.walk(function(s,a){if(s.type==="decl"&&s.prop===r)return n(s,a)}):(n=r,this.walk(function(s,a){if(s.type==="decl")return n(s,a)}))},o.walkRules=function(r,n){return n?T(r,RegExp)?this.walk(function(s,a){if(s.type==="rule"&&r.test(s.selector))return n(s,a)}):this.walk(function(s,a){if(s.type==="rule"&&s.selector===r)return n(s,a)}):(n=r,this.walk(function(s,a){if(s.type==="rule")return n(s,a)}))},oe(i,[{key:"first",get:function(){if(this.proxyOf.nodes)return this.proxyOf.nodes[0]}},{key:"last",get:function(){if(this.proxyOf.nodes)return this.proxyOf.nodes[this.proxyOf.nodes.length-1]}}]),i}(Kl);Ae.registerParse=function(t){jo=t},Ae.registerRule=function(t){Wn=t},Ae.registerAtRule=function(t){Gn=t},Ae.registerRoot=function(t){Vo=t};var je=Ae;Ae.default=Ae,Ae.rebuild=function(t){t.type==="atrule"?Object.setPrototypeOf(t,Gn.prototype):t.type==="rule"?Object.setPrototypeOf(t,Wn.prototype):t.type==="decl"?Object.setPrototypeOf(t,Wo.prototype):t.type==="comment"?Object.setPrototypeOf(t,Go.prototype):t.type==="root"&&Object.setPrototypeOf(t,Vo.prototype),t[zo]=!0,t.nodes&&t.nodes.forEach(function(i){Ae.rebuild(i)})};var Xl=je,Ho,Jo,kt=function(t){ae(i,t);function i(e){var r;return r=t.call(this,F({type:"document"},e))||this,r.nodes||(r.nodes=[]),r}var o=i.prototype;return o.toResult=function(r){r===void 0&&(r={});var n=new Ho(new Jo,this,r);return n.stringify()},i}(Xl);kt.registerLazyResult=function(t){Ho=t},kt.registerProcessor=function(t){Jo=t};var jn=kt;kt.default=kt;var Zo={},Ko=function(i){Zo[i]||(Zo[i]=!0,typeof console!="undefined"&&console.warn&&console.warn(i))},Vn=function(){function t(o,e){if(e===void 0&&(e={}),this.type="warning",this.text=o,e.node&&e.node.source){var r=e.node.rangeBy(e);this.line=r.start.line,this.column=r.start.column,this.endLine=r.end.line,this.endColumn=r.end.column}for(var n in e)this[n]=e[n]}var i=t.prototype;return i.toString=function(){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},t}(),Xo=Vn;Vn.default=Vn;var Ql=Xo,Yn=function(){function t(o,e,r){this.processor=o,this.messages=[],this.root=e,this.opts=r,this.css=void 0,this.map=void 0}var i=t.prototype;return i.toString=function(){return this.css},i.warn=function(e,r){r===void 0&&(r={}),r.plugin||this.lastPlugin&&this.lastPlugin.postcssPlugin&&(r.plugin=this.lastPlugin.postcssPlugin);var n=new Ql(e,r);return this.messages.push(n),n},i.warnings=function(){return this.messages.filter(function(e){return e.type==="warning"})},oe(t,[{key:"content",get:function(){return this.css}}]),t}(),qn=Yn;Yn.default=Yn;var Hn=39,Qo=34,br=92,es=47,Cr=10,_t=32,Ir=12,Or=9,xr=13,ec=91,tc=93,rc=40,nc=41,ic=123,oc=125,sc=59,ac=42,uc=58,lc=64,Rr=/[\t\n\f\r "#'()/;[\\\]{}]/g,Er=/[\t\n\f\r !"#'():;@[\\\]{}]|\/(?=\*)/g,cc=/.[\r\n"'(/\\]/,ts=/[\da-f]/i,fc=function(i,o){o===void 0&&(o={});var e=i.css.valueOf(),r=o.ignoreErrors,n,s,a,u,l,c,f,h,v,p,g=e.length,d=0,y=[],w=[];function S(){return d}function b(R){throw i.error("Unclosed "+R,d)}function C(){return w.length===0&&d>=g}function x(R){if(w.length)return w.pop();if(!(d>=g)){var _=R?R.ignoreUnclosed:!1;switch(n=e.charCodeAt(d),n){case Cr:case _t:case Or:case xr:case Ir:{s=d;do s+=1,n=e.charCodeAt(s);while(n===_t||n===Cr||n===Or||n===xr||n===Ir);p=["space",e.slice(d,s)],d=s-1;break}case ec:case tc:case ic:case oc:case uc:case sc:case nc:{var B=String.fromCharCode(n);p=[B,B,d];break}case rc:{if(h=y.length?y.pop()[1]:"",v=e.charCodeAt(d+1),h==="url"&&v!==Hn&&v!==Qo&&v!==_t&&v!==Cr&&v!==Or&&v!==Ir&&v!==xr){s=d;do{if(c=!1,s=e.indexOf(")",s+1),s===-1)if(r||_){s=d;break}else b("bracket");for(f=s;e.charCodeAt(f-1)===br;)f-=1,c=!c}while(c);p=["brackets",e.slice(d,s+1),d,s],d=s}else s=e.indexOf(")",d+1),u=e.slice(d,s+1),s===-1||cc.test(u)?p=["(","(",d]:(p=["brackets",u,d,s],d=s);break}case Hn:case Qo:{a=n===Hn?"'":'"',s=d;do{if(c=!1,s=e.indexOf(a,s+1),s===-1)if(r||_){s=d+1;break}else b("string");for(f=s;e.charCodeAt(f-1)===br;)f-=1,c=!c}while(c);p=["string",e.slice(d,s+1),d,s],d=s;break}case lc:{Rr.lastIndex=d+1,Rr.test(e),Rr.lastIndex===0?s=e.length-1:s=Rr.lastIndex-2,p=["at-word",e.slice(d,s+1),d,s],d=s;break}case br:{for(s=d,l=!0;e.charCodeAt(s+1)===br;)s+=1,l=!l;if(n=e.charCodeAt(s+1),l&&n!==es&&n!==_t&&n!==Cr&&n!==Or&&n!==xr&&n!==Ir&&(s+=1,ts.test(e.charAt(s)))){for(;ts.test(e.charAt(s+1));)s+=1;e.charCodeAt(s+1)===_t&&(s+=1)}p=["word",e.slice(d,s+1),d,s],d=s;break}default:{n===es&&e.charCodeAt(d+1)===ac?(s=e.indexOf("*/",d+2)+1,s===0&&(r||_?s=e.length:b("comment")),p=["comment",e.slice(d,s+1),d,s],d=s):(Er.lastIndex=d+1,Er.test(e),Er.lastIndex===0?s=e.length-1:s=Er.lastIndex-2,p=["word",e.slice(d,s+1),d,s],y.push(p),d=s);break}}return d++,p}}function E(R){w.push(R)}return{back:E,endOfFile:C,nextToken:x,position:S}},rs=je,Ar=function(t){ae(i,t);function i(e){var r;return r=t.call(this,e)||this,r.type="atrule",r}var o=i.prototype;return o.append=function(){for(var r=arguments.length,n=new Array(r),s=0;s<r;s++)n[s]=arguments[s];var a;return this.proxyOf.nodes||(this.nodes=[]),(a=t.prototype.append).call.apply(a,[].concat([this],n))},o.prepend=function(){for(var r=arguments.length,n=new Array(r),s=0;s<r;s++)n[s]=arguments[s];var a;return this.proxyOf.nodes||(this.nodes=[]),(a=t.prototype.prepend).call.apply(a,[].concat([this],n))},i}(rs),Jn=Ar;Ar.default=Ar,rs.registerAtRule(Ar);var ns=je,is,os,st=function(t){ae(i,t);function i(e){var r;return r=t.call(this,e)||this,r.type="root",r.nodes||(r.nodes=[]),r}var o=i.prototype;return o.normalize=function(r,n,s){var a=t.prototype.normalize.call(this,r);if(n){if(s==="prepend")this.nodes.length>1?n.raws.before=this.nodes[1].raws.before:delete n.raws.before;else if(this.first!==n)for(var u=O(a),l;!(l=u()).done;){var c=l.value;c.raws.before=n.raws.before}}return a},o.removeChild=function(r,n){var s=this.index(r);return!n&&s===0&&this.nodes.length>1&&(this.nodes[1].raws.before=this.nodes[s].raws.before),t.prototype.removeChild.call(this,r)},o.toResult=function(r){r===void 0&&(r={});var n=new is(new os,this,r);return n.stringify()},i}(ns);st.registerLazyResult=function(t){is=t},st.registerProcessor=function(t){os=t};var Tt=st;st.default=st,ns.registerRoot(st);var Pt={comma:function(i){return Pt.split(i,[","],!0)},space:function(i){var o=[" ","\n"," "];return Pt.split(i,o)},split:function(i,o,e){for(var r=[],n="",s=!1,a=0,u=!1,l="",c=!1,f=O(i),h;!(h=f()).done;){var v=h.value;c?c=!1:v==="\\"?c=!0:u?v===l&&(u=!1):v==='"'||v==="'"?(u=!0,l=v):v==="("?a+=1:v===")"?a>0&&(a-=1):a===0&&o.includes(v)&&(s=!0),s?(n!==""&&r.push(n.trim()),n="",s=!1):n+=v}return(e||n!=="")&&r.push(n.trim()),r}},ss=Pt;Pt.default=Pt;var as=je,hc=ss,Mr=function(t){ae(i,t);function i(o){var e;return e=t.call(this,o)||this,e.type="rule",e.nodes||(e.nodes=[]),e}return oe(i,[{key:"selectors",get:function(){return hc.comma(this.selector)},set:function(e){var r=this.selector?this.selector.match(/,\s*/):null,n=r?r[0]:","+this.raw("between","beforeOpen");this.selector=e.join(n)}}]),i}(as),Zn=Mr;Mr.default=Mr,as.registerRule(Mr);var dc=pr,pc=fc,vc=Sr,mc=Jn,gc=Tt,us=Zn,ls={empty:!0,space:!0};function yc(t){for(var i=t.length-1;i>=0;i--){var o=t[i],e=o[3]||o[2];if(e)return e}}var wc=function(){function t(o){this.input=o,this.root=new gc,this.current=this.root,this.spaces="",this.semicolon=!1,this.createTokenizer(),this.root.source={input:o,start:{column:1,line:1,offset:0}}}var i=t.prototype;return i.atrule=function(e){var r=new mc;r.name=e[1].slice(1),r.name===""&&this.unnamedAtrule(r,e),this.init(r,e[2]);for(var n,s,a,u=!1,l=!1,c=[],f=[];!this.tokenizer.endOfFile();){if(e=this.tokenizer.nextToken(),n=e[0],n==="("||n==="["?f.push(n==="("?")":"]"):n==="{"&&f.length>0?f.push("}"):n===f[f.length-1]&&f.pop(),f.length===0)if(n===";"){r.source.end=this.getPosition(e[2]),r.source.end.offset++,this.semicolon=!0;break}else if(n==="{"){l=!0;break}else if(n==="}"){if(c.length>0){for(a=c.length-1,s=c[a];s&&s[0]==="space";)s=c[--a];s&&(r.source.end=this.getPosition(s[3]||s[2]),r.source.end.offset++)}this.end(e);break}else c.push(e);else c.push(e);if(this.tokenizer.endOfFile()){u=!0;break}}r.raws.between=this.spacesAndCommentsFromEnd(c),c.length?(r.raws.afterName=this.spacesAndCommentsFromStart(c),this.raw(r,"params",c),u&&(e=c[c.length-1],r.source.end=this.getPosition(e[3]||e[2]),r.source.end.offset++,this.spaces=r.raws.between,r.raws.between="")):(r.raws.afterName="",r.params=""),l&&(r.nodes=[],this.current=r)},i.checkMissedSemicolon=function(e){var r=this.colon(e);if(r!==!1){for(var n=0,s,a=r-1;a>=0&&(s=e[a],!(s[0]!=="space"&&(n+=1,n===2)));a--);throw this.input.error("Missed semicolon",s[0]==="word"?s[3]+1:s[2])}},i.colon=function(e){for(var r=0,n,s,a,u=O(e.entries()),l;!(l=u()).done;){var c=l.value,f=c[0],h=c[1];if(n=h,s=n[0],s==="("&&(r+=1),s===")"&&(r-=1),r===0&&s===":")if(!a)this.doubleColon(n);else{if(a[0]==="word"&&a[1]==="progid")continue;return f}a=n}return!1},i.comment=function(e){var r=new vc;this.init(r,e[2]),r.source.end=this.getPosition(e[3]||e[2]),r.source.end.offset++;var n=e[1].slice(2,-2);if(/^\s*$/.test(n))r.text="",r.raws.left=n,r.raws.right="";else{var s=n.match(/^(\s*)([^]*\S)(\s*)$/);r.text=s[2],r.raws.left=s[1],r.raws.right=s[3]}},i.createTokenizer=function(){this.tokenizer=pc(this.input)},i.decl=function(e,r){var n=new dc;this.init(n,e[0][2]);var s=e[e.length-1];for(s[0]===";"&&(this.semicolon=!0,e.pop()),n.source.end=this.getPosition(s[3]||s[2]||yc(e)),n.source.end.offset++;e[0][0]!=="word";)e.length===1&&this.unknownWord(e),n.raws.before+=e.shift()[1];for(n.source.start=this.getPosition(e[0][2]),n.prop="";e.length;){var a=e[0][0];if(a===":"||a==="space"||a==="comment")break;n.prop+=e.shift()[1]}n.raws.between="";for(var u;e.length;)if(u=e.shift(),u[0]===":"){n.raws.between+=u[1];break}else u[0]==="word"&&/\w/.test(u[1])&&this.unknownWord([u]),n.raws.between+=u[1];(n.prop[0]==="_"||n.prop[0]==="*")&&(n.raws.before+=n.prop[0],n.prop=n.prop.slice(1));for(var l=[],c;e.length&&(c=e[0][0],!(c!=="space"&&c!=="comment"));)l.push(e.shift());this.precheckMissedSemicolon(e);for(var f=e.length-1;f>=0;f--){if(u=e[f],u[1].toLowerCase()==="!important"){n.important=!0;var h=this.stringFrom(e,f);h=this.spacesFromEnd(e)+h,h!==" !important"&&(n.raws.important=h);break}else if(u[1].toLowerCase()==="important"){for(var v=e.slice(0),p="",g=f;g>0;g--){var d=v[g][0];if(p.trim().indexOf("!")===0&&d!=="space")break;p=v.pop()[1]+p}p.trim().indexOf("!")===0&&(n.important=!0,n.raws.important=p,e=v)}if(u[0]!=="space"&&u[0]!=="comment")break}var y=e.some(function(w){return w[0]!=="space"&&w[0]!=="comment"});y&&(n.raws.between+=l.map(function(w){return w[1]}).join(""),l=[]),this.raw(n,"value",l.concat(e),r),n.value.includes(":")&&!r&&this.checkMissedSemicolon(e)},i.doubleColon=function(e){throw this.input.error("Double colon",{offset:e[2]},{offset:e[2]+e[1].length})},i.emptyRule=function(e){var r=new us;this.init(r,e[2]),r.selector="",r.raws.between="",this.current=r},i.end=function(e){this.current.nodes&&this.current.nodes.length&&(this.current.raws.semicolon=this.semicolon),this.semicolon=!1,this.current.raws.after=(this.current.raws.after||"")+this.spaces,this.spaces="",this.current.parent?(this.current.source.end=this.getPosition(e[2]),this.current.source.end.offset++,this.current=this.current.parent):this.unexpectedClose(e)},i.endFile=function(){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())},i.freeSemicolon=function(e){if(this.spaces+=e[1],this.current.nodes){var r=this.current.nodes[this.current.nodes.length-1];r&&r.type==="rule"&&!r.raws.ownSemicolon&&(r.raws.ownSemicolon=this.spaces,this.spaces="")}},i.getPosition=function(e){var r=this.input.fromOffset(e);return{column:r.col,line:r.line,offset:e}},i.init=function(e,r){this.current.push(e),e.source={input:this.input,start:this.getPosition(r)},e.raws.before=this.spaces,this.spaces="",e.type!=="comment"&&(this.semicolon=!1)},i.other=function(e){for(var r=!1,n=null,s=!1,a=null,u=[],l=e[1].startsWith("--"),c=[],f=e;f;){if(n=f[0],c.push(f),n==="("||n==="[")a||(a=f),u.push(n==="("?")":"]");else if(l&&s&&n==="{")a||(a=f),u.push("}");else if(u.length===0)if(n===";")if(s){this.decl(c,l);return}else break;else if(n==="{"){this.rule(c);return}else if(n==="}"){this.tokenizer.back(c.pop()),r=!0;break}else n===":"&&(s=!0);else n===u[u.length-1]&&(u.pop(),u.length===0&&(a=null));f=this.tokenizer.nextToken()}if(this.tokenizer.endOfFile()&&(r=!0),u.length>0&&this.unclosedBracket(a),r&&s){if(!l)for(;c.length&&(f=c[c.length-1][0],!(f!=="space"&&f!=="comment"));)this.tokenizer.back(c.pop());this.decl(c,l)}else this.unknownWord(c)},i.parse=function(){for(var e;!this.tokenizer.endOfFile();)switch(e=this.tokenizer.nextToken(),e[0]){case"space":this.spaces+=e[1];break;case";":this.freeSemicolon(e);break;case"}":this.end(e);break;case"comment":this.comment(e);break;case"at-word":this.atrule(e);break;case"{":this.emptyRule(e);break;default:this.other(e);break}this.endFile()},i.precheckMissedSemicolon=function(){},i.raw=function(e,r,n,s){for(var a,u,l=n.length,c="",f=!0,h,v,p=0;p<l;p+=1)a=n[p],u=a[0],u==="space"&&p===l-1&&!s?f=!1:u==="comment"?(v=n[p-1]?n[p-1][0]:"empty",h=n[p+1]?n[p+1][0]:"empty",!ls[v]&&!ls[h]?c.slice(-1)===","?f=!1:c+=a[1]:f=!1):c+=a[1];if(!f){var g=n.reduce(function(d,y){return d+y[1]},"");e.raws[r]={raw:g,value:c}}e[r]=c},i.rule=function(e){e.pop();var r=new us;this.init(r,e[0][2]),r.raws.between=this.spacesAndCommentsFromEnd(e),this.raw(r,"selector",e),this.current=r},i.spacesAndCommentsFromEnd=function(e){for(var r,n="";e.length&&(r=e[e.length-1][0],!(r!=="space"&&r!=="comment"));)n=e.pop()[1]+n;return n},i.spacesAndCommentsFromStart=function(e){for(var r,n="";e.length&&(r=e[0][0],!(r!=="space"&&r!=="comment"));)n+=e.shift()[1];return n},i.spacesFromEnd=function(e){for(var r,n="";e.length&&(r=e[e.length-1][0],r==="space");)n=e.pop()[1]+n;return n},i.stringFrom=function(e,r){for(var n="",s=r;s<e.length;s++)n+=e[s][1];return e.splice(r,e.length-r),n},i.unclosedBlock=function(){var e=this.current.source.start;throw this.input.error("Unclosed block",e.line,e.column)},i.unclosedBracket=function(e){throw this.input.error("Unclosed bracket",{offset:e[2]},{offset:e[2]+1})},i.unexpectedClose=function(e){throw this.input.error("Unexpected }",{offset:e[2]},{offset:e[2]+1})},i.unknownWord=function(e){throw this.input.error("Unknown word",{offset:e[0][2]},{offset:e[0][2]+e[0][1].length})},i.unnamedAtrule=function(e,r){throw this.input.error("At-rule without name",{offset:r[2]},{offset:r[2]+r[1].length})},t}(),Sc=wc,bc=je,Cc=Sc,Ic=gr;function kr(t,i){var o=new Ic(t,i),e=new Cc(o);try{e.parse()}catch(r){throw process.env.NODE_ENV!=="production"&&r.name==="CssSyntaxError"&&i&&i.from&&(/\.scss$/i.test(i.from)?r.message+="\nYou tried to parse SCSS with the standard CSS parser; try again with the postcss-scss parser":/\.sass/i.test(i.from)?r.message+="\nYou tried to parse Sass with the standard CSS parser; try again with the postcss-sass parser":/\.less$/i.test(i.from)&&(r.message+="\nYou tried to parse Less with the standard CSS parser; try again with the postcss-less parser")),r}return e.root}var Kn=kr;kr.default=kr,bc.registerParse(kr);var Oe=$e.isClean,Oc=$e.my,xc=Bo,Rc=fr,Ec=je,Ac=jn,Mc=Ko,cs=qn,kc=Kn,_c=Tt,Tc={atrule:"AtRule",comment:"Comment",decl:"Declaration",document:"Document",root:"Root",rule:"Rule"},Pc={AtRule:!0,AtRuleExit:!0,Comment:!0,CommentExit:!0,Declaration:!0,DeclarationExit:!0,Document:!0,DocumentExit:!0,Once:!0,OnceExit:!0,postcssPlugin:!0,prepare:!0,Root:!0,RootExit:!0,Rule:!0,RuleExit:!0},Nc={Once:!0,postcssPlugin:!0,prepare:!0},at=0;function Nt(t){return(typeof t=="undefined"?"undefined":N(t))==="object"&&typeof t.then=="function"}function fs(t){var i=!1,o=Tc[t.type];return t.type==="decl"?i=t.prop.toLowerCase():t.type==="atrule"&&(i=t.name.toLowerCase()),i&&t.append?[o,o+"-"+i,at,o+"Exit",o+"Exit-"+i]:i?[o,o+"-"+i,o+"Exit",o+"Exit-"+i]:t.append?[o,at,o+"Exit"]:[o,o+"Exit"]}function hs(t){var i;return t.type==="document"?i=["Document",at,"DocumentExit"]:t.type==="root"?i=["Root",at,"RootExit"]:i=fs(t),{eventIndex:0,events:i,iterator:0,node:t,visitorIndex:0,visitors:[]}}function Xn(t){return t[Oe]=!1,t.nodes&&t.nodes.forEach(function(i){return Xn(i)}),t}var Qn={},ut=function(){function t(o,e,r){var n=this;this.stringified=!1,this.processed=!1;var s;if((typeof e=="undefined"?"undefined":N(e))==="object"&&e!==null&&(e.type==="root"||e.type==="document"))s=Xn(e);else if(T(e,t)||T(e,cs))s=Xn(e.root),e.map&&(typeof r.map=="undefined"&&(r.map={}),r.map.inline||(r.map.inline=!1),r.map.prev=e.map);else{var a=kc;r.syntax&&(a=r.syntax.parse),r.parser&&(a=r.parser),a.parse&&(a=a.parse);try{s=a(e,r)}catch(u){this.processed=!0,this.error=u}s&&!s[Oc]&&Ec.rebuild(s)}this.result=new cs(o,s,r),this.helpers=F({},Qn,{postcss:Qn,result:this.result}),this.plugins=this.processor.plugins.map(function(u){return(typeof u=="undefined"?"undefined":N(u))==="object"&&u.prepare?F({},u,u.prepare(n.result)):u})}var i=t.prototype;return i.async=function(){return this.error?Promise.reject(this.error):this.processed?Promise.resolve(this.result):(this.processing||(this.processing=this.runAsync()),this.processing)},i.catch=function(e){return this.async().catch(e)},i.finally=function(e){return this.async().then(e,e)},i.getAsyncError=function(){throw new Error("Use process(css).then(cb) to work with async plugins")},i.handleError=function(e,r){var n=this.result.lastPlugin;try{if(r&&r.addToError(e),this.error=e,e.name==="CssSyntaxError"&&!e.plugin)e.plugin=n.postcssPlugin,e.setMessage();else if(n.postcssVersion&&process.env.NODE_ENV!=="production"){var s=n.postcssPlugin,a=n.postcssVersion,u=this.result.processor.version,l=a.split("."),c=u.split(".");(l[0]!==c[0]||parseInt(l[1])>parseInt(c[1]))&&console.error("Unknown error from PostCSS plugin. Your current PostCSS version is "+u+", but "+s+" uses "+a+". Perhaps this is the source of the error below.")}}catch(f){console&&console.error&&console.error(f)}return e},i.prepareVisitors=function(){var e=this;this.listeners={};for(var r=function(c,f,h){e.listeners[f]||(e.listeners[f]=[]),e.listeners[f].push([c,h])},n=O(this.plugins),s;!(s=n()).done;){var a=s.value;if((typeof a=="undefined"?"undefined":N(a))==="object")for(var u in a){if(!Pc[u]&&/^[A-Z]/.test(u))throw new Error("Unknown event "+u+" in "+a.postcssPlugin+". Try to update PostCSS ("+this.processor.version+" now).");if(!Nc[u])if(N(a[u])==="object")for(var l in a[u])l==="*"?r(a,u,a[u][l]):r(a,u+"-"+l.toLowerCase(),a[u][l]);else typeof a[u]=="function"&&r(a,u,a[u])}}this.hasListener=Object.keys(this.listeners).length>0},i.runAsync=function(){var e=this;return gn(function(){var r,n,s,a,u,l,c,f,h,v,p,g;return Rt(this,function(d){switch(d.label){case 0:e.plugin=0,r=0,d.label=1;case 1:if(!(r<e.plugins.length))return[3,6];if(n=e.plugins[r],s=e.runOnRoot(n),!Nt(s))return[3,5];d.label=2;case 2:return d.trys.push([2,4,,5]),[4,s];case 3:return d.sent(),[3,5];case 4:throw a=d.sent(),e.handleError(a);case 5:return r++,[3,1];case 6:if(e.prepareVisitors(),!e.hasListener)return[3,18];u=e.result.root,d.label=7;case 7:if(u[Oe])return[3,14];u[Oe]=!0,l=[hs(u)],d.label=8;case 8:if(!(l.length>0))return[3,13];if(c=e.visitTick(l),!Nt(c))return[3,12];d.label=9;case 9:return d.trys.push([9,11,,12]),[4,c];case 10:return d.sent(),[3,12];case 11:throw f=d.sent(),h=l[l.length-1].node,e.handleError(f,h);case 12:return[3,8];case 13:return[3,7];case 14:if(!e.listeners.OnceExit)return[3,18];v=function(){var y,w,S,b,C;return Rt(this,function(x){switch(x.label){case 0:y=g.value,w=y[0],S=y[1],e.result.lastPlugin=w,x.label=1;case 1:return x.trys.push([1,6,,7]),u.type!=="document"?[3,3]:(b=u.nodes.map(function(E){return S(E,e.helpers)}),[4,Promise.all(b)]);case 2:return x.sent(),[3,5];case 3:return[4,S(u,e.helpers)];case 4:x.sent(),x.label=5;case 5:return[3,7];case 6:throw C=x.sent(),e.handleError(C);case 7:return[2]}})},p=O(e.listeners.OnceExit),d.label=15;case 15:return(g=p()).done?[3,18]:[5,oo(v())];case 16:d.sent(),d.label=17;case 17:return[3,15];case 18:return e.processed=!0,[2,e.stringify()]}})})()},i.runOnRoot=function(e){var r=this;this.result.lastPlugin=e;try{if((typeof e=="undefined"?"undefined":N(e))==="object"&&e.Once){if(this.result.root.type==="document"){var n=this.result.root.nodes.map(function(s){return e.Once(s,r.helpers)});return Nt(n[0])?Promise.all(n):n}return e.Once(this.result.root,this.helpers)}else if(typeof e=="function")return e(this.result.root,this.result)}catch(s){throw this.handleError(s)}},i.stringify=function(){if(this.error)throw this.error;if(this.stringified)return this.result;this.stringified=!0,this.sync();var e=this.result.opts,r=Rc;e.syntax&&(r=e.syntax.stringify),e.stringifier&&(r=e.stringifier),r.stringify&&(r=r.stringify);var n=new xc(r,this.result.root,this.result.opts),s=n.generate();return this.result.css=s[0],this.result.map=s[1],this.result},i.sync=function(){if(this.error)throw this.error;if(this.processed)return this.result;if(this.processed=!0,this.processing)throw this.getAsyncError();for(var e=O(this.plugins),r;!(r=e()).done;){var n=r.value,s=this.runOnRoot(n);if(Nt(s))throw this.getAsyncError()}if(this.prepareVisitors(),this.hasListener){for(var a=this.result.root;!a[Oe];)a[Oe]=!0,this.walkSync(a);if(this.listeners.OnceExit)if(a.type==="document")for(var u=O(a.nodes),l;!(l=u()).done;){var c=l.value;this.visitSync(this.listeners.OnceExit,c)}else this.visitSync(this.listeners.OnceExit,a)}return this.result},i.then=function(e,r){return process.env.NODE_ENV!=="production"&&("from"in this.opts||Mc("Without `from` option PostCSS could generate wrong source map and will not find Browserslist config. Set it to CSS file path or to `undefined` to prevent this warning.")),this.async().then(e,r)},i.toString=function(){return this.css},i.visitSync=function(e,r){for(var n=O(e),s;!(s=n()).done;){var a=s.value,u=a[0],l=a[1];this.result.lastPlugin=u;var c=void 0;try{c=l(r,this.helpers)}catch(f){throw this.handleError(f,r.proxyOf)}if(r.type!=="root"&&r.type!=="document"&&!r.parent)return!0;if(Nt(c))throw this.getAsyncError()}},i.visitTick=function(e){var r=e[e.length-1],n=r.node,s=r.visitors;if(n.type!=="root"&&n.type!=="document"&&!n.parent){e.pop();return}if(s.length>0&&r.visitorIndex<s.length){var a=s[r.visitorIndex],u=a[0],l=a[1];r.visitorIndex+=1,r.visitorIndex===s.length&&(r.visitors=[],r.visitorIndex=0),this.result.lastPlugin=u;try{return l(n.toProxy(),this.helpers)}catch(p){throw this.handleError(p,n)}}if(r.iterator!==0){for(var c=r.iterator,f;f=n.nodes[n.indexes[c]];)if(n.indexes[c]+=1,!f[Oe]){f[Oe]=!0,e.push(hs(f));return}r.iterator=0,delete n.indexes[c]}for(var h=r.events;r.eventIndex<h.length;){var v=h[r.eventIndex];if(r.eventIndex+=1,v===at){n.nodes&&n.nodes.length&&(n[Oe]=!0,r.iterator=n.getIterator());return}else if(this.listeners[v]){r.visitors=this.listeners[v];return}}e.pop()},i.walkSync=function(e){var r=this;e[Oe]=!0;for(var n=fs(e),s=O(n),a;!(a=s()).done;){var u=a.value;if(u===at)e.nodes&&e.each(function(c){c[Oe]||r.walkSync(c)});else{var l=this.listeners[u];if(l&&this.visitSync(l,e.toProxy()))return}}},i.warnings=function(){return this.sync().warnings()},oe(t,[{key:"content",get:function(){return this.stringify().content}},{key:"css",get:function(){return this.stringify().css}},{key:"map",get:function(){return this.stringify().map}},{key:"messages",get:function(){return this.sync().messages}},{key:"opts",get:function(){return this.result.opts}},{key:"processor",get:function(){return this.result.processor}},{key:"root",get:function(){return this.sync().root}},{key:Symbol.toStringTag,get:function(){return"LazyResult"}}]),t}();ut.registerPostcss=function(t){Qn=t};var ds=ut;ut.default=ut,_c.registerLazyResult(ut),Ac.registerLazyResult(ut);var $c=Bo,Dc=fr,Lc=Ko,Fc=Kn,Bc=qn,ei=function(){function t(o,e,r){e=e.toString(),this.stringified=!1,this._processor=o,this._css=e,this._opts=r,this._map=void 0;var n,s=Dc;this.result=new Bc(this._processor,n,this._opts),this.result.css=e;var a=this;Object.defineProperty(this.result,"root",{get:function(){return a.root}});var u=new $c(s,n,this._opts,e);if(u.isMap()){var l=u.generate(),c=l[0],f=l[1];c&&(this.result.css=c),f&&(this.result.map=f)}else u.clearAnnotation(),this.result.css=u.css}var i=t.prototype;return i.async=function(){return this.error?Promise.reject(this.error):Promise.resolve(this.result)},i.catch=function(e){return this.async().catch(e)},i.finally=function(e){return this.async().then(e,e)},i.sync=function(){if(this.error)throw this.error;return this.result},i.then=function(e,r){return process.env.NODE_ENV!=="production"&&("from"in this._opts||Lc("Without `from` option PostCSS could generate wrong source map and will not find Browserslist config. Set it to CSS file path or to `undefined` to prevent this warning.")),this.async().then(e,r)},i.toString=function(){return this._css},i.warnings=function(){return[]},oe(t,[{key:"content",get:function(){return this.result.css}},{key:"css",get:function(){return this.result.css}},{key:"map",get:function(){return this.result.map}},{key:"messages",get:function(){return[]}},{key:"opts",get:function(){return this.result.opts}},{key:"processor",get:function(){return this.result.processor}},{key:"root",get:function(){if(this._root)return this._root;var e,r=Fc;try{e=r(this._css,this._opts)}catch(n){this.error=n}if(this.error)throw this.error;return this._root=e,e}},{key:Symbol.toStringTag,get:function(){return"NoWorkResult"}}]),t}(),Uc=ei;ei.default=ei;var zc=Uc,Wc=ds,Gc=jn,jc=Tt,$t=function(){function t(o){o===void 0&&(o=[]),this.version="8.4.38",this.plugins=this.normalize(o)}var i=t.prototype;return i.normalize=function(e){for(var r=[],n=O(e),s;!(s=n()).done;){var a=s.value;if(a.postcss===!0?a=a():a.postcss&&(a=a.postcss),(typeof a=="undefined"?"undefined":N(a))==="object"&&Array.isArray(a.plugins))r=r.concat(a.plugins);else if((typeof a=="undefined"?"undefined":N(a))==="object"&&a.postcssPlugin)r.push(a);else if(typeof a=="function")r.push(a);else if((typeof a=="undefined"?"undefined":N(a))==="object"&&(a.parse||a.stringify)){if(process.env.NODE_ENV!=="production")throw new Error("PostCSS syntaxes cannot be used as plugins. Instead, please use one of the syntax/parser/stringifier options as outlined in your PostCSS runner documentation.")}else throw new Error(a+" is not a PostCSS plugin")}return r},i.process=function(e,r){return r===void 0&&(r={}),!this.plugins.length&&!r.parser&&!r.stringifier&&!r.syntax?new zc(this,e,r):new Wc(this,e,r)},i.use=function(e){return this.plugins=this.plugins.concat(this.normalize([e])),this},t}(),Vc=$t;$t.default=$t,jc.registerProcessor($t),Gc.registerProcessor($t);var Yc=pr,qc=ko,Hc=Sr,Jc=Jn,Zc=gr,Kc=Tt,Xc=Zn;function Dt(t,i){if(Array.isArray(t))return t.map(function(f){return Dt(f)});var o=t.inputs,e=Ot(t,["inputs"]);if(o){i=[];for(var r=O(o),n;!(n=r()).done;){var s=n.value,a=F({},s,{__proto__:Zc.prototype});a.map&&(a.map=F({},a.map,{__proto__:qc.prototype})),i.push(a)}}if(e.nodes&&(e.nodes=t.nodes.map(function(f){return Dt(f,i)})),e.source){var u=e.source,l=u.inputId,c=Ot(u,["inputId"]);e.source=c,l!=null&&(e.source.input=i[l])}if(e.type==="root")return new Kc(e);if(e.type==="decl")return new Yc(e);if(e.type==="rule")return new Xc(e);if(e.type==="comment")return new Hc(e);if(e.type==="atrule")return new Jc(e);throw new Error("Unknown node type: "+t.type)}var Qc=Dt;Dt.default=Dt;var ef=Mn,ps=pr,tf=ds,rf=je,ti=Vc,nf=fr,of=Qc,vs=jn,sf=Xo,ms=Sr,gs=Jn,af=qn,uf=gr,lf=Kn,cf=ss,ys=Zn,ws=Tt,ff=dr;function V(){for(var t=arguments.length,i=new Array(t),o=0;o<t;o++)i[o]=arguments[o];return i.length===1&&Array.isArray(i[0])&&(i=i[0]),new ti(i)}V.plugin=function(i,o){var e=!1;function r(){for(var s=arguments.length,a=new Array(s),u=0;u<s;u++)a[u]=arguments[u];console&&console.warn&&!e&&(e=!0,console.warn(i+": postcss.plugin was deprecated. Migration guide:\nhttps://evilmartians.com/chronicles/postcss-8-plugin-migration"),process.env.LANG&&process.env.LANG.startsWith("cn")&&console.warn(i+": \u91CC\u9762 postcss.plugin \u88AB\u5F03\u7528. \u8FC1\u79FB\u6307\u5357:\nhttps://www.w3ctech.com/topic/2226"));var l=o.apply(void 0,[].concat(a));return l.postcssPlugin=i,l.postcssVersion=new ti().version,l}var n;return Object.defineProperty(r,"postcss",{get:function(){return n||(n=r()),n}}),r.process=function(s,a,u){return V([r(u)]).process(s,a)},r},V.stringify=nf,V.parse=lf,V.fromJSON=of,V.list=cf,V.comment=function(t){return new ms(t)},V.atRule=function(t){return new gs(t)},V.decl=function(t){return new ps(t)},V.rule=function(t){return new ys(t)},V.root=function(t){return new ws(t)},V.document=function(t){return new vs(t)},V.CssSyntaxError=ef,V.Declaration=ps,V.Container=rf,V.Processor=ti,V.Document=vs,V.Comment=ms,V.Warning=sf,V.AtRule=gs,V.Result=af,V.Input=uf,V.Rule=ys,V.Root=ws,V.Node=ff,tf.registerPostcss(V);var hf=V;V.default=V;var K=Cl(hf);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 df=Object.defineProperty,pf=function(t,i,o){return i in t?df(t,i,{enumerable:!0,configurable:!0,writable:!0,value:o}):t[i]=o},we=function(t,i,o){return pf(t,(typeof i=="undefined"?"undefined":N(i))!=="symbol"?i+"":i,o)};function vf(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}function mf(t){if(t.__esModule)return t;var i=t.default;if(typeof i=="function"){var o=function e(){return T(this,e)?Reflect.construct(i,arguments,this.constructor):i.apply(this,arguments)};o.prototype=i.prototype}else o={};return Object.defineProperty(o,"__esModule",{value:!0}),Object.keys(t).forEach(function(e){var r=Object.getOwnPropertyDescriptor(t,e);Object.defineProperty(o,e,r.get?r:{enumerable:!0,get:function(){return t[e]}})}),o}var ri={exports:{}},Z=String,Ss=function(){return{isColorSupported:!1,reset:Z,bold:Z,dim:Z,italic:Z,underline:Z,inverse:Z,hidden:Z,strikethrough:Z,black:Z,red:Z,green:Z,yellow:Z,blue:Z,magenta:Z,cyan:Z,white:Z,gray:Z,bgBlack:Z,bgRed:Z,bgGreen:Z,bgYellow:Z,bgBlue:Z,bgMagenta:Z,bgCyan:Z,bgWhite:Z}};ri.exports=Ss(),ri.exports.createColors=Ss;var gf=ri.exports,yf={},wf=Object.freeze(Object.defineProperty({__proto__:null,default:yf},Symbol.toStringTag,{value:"Module"})),ne=mf(wf),bs=gf,Cs=ne,ni=function(t){ae(i,t);function i(e,r,n,s,a,u){var l;return l=t.call(this,e)||this,l.name="CssSyntaxError",l.reason=e,a&&(l.file=a),s&&(l.source=s),u&&(l.plugin=u),typeof r!="undefined"&&typeof n!="undefined"&&(typeof r=="number"?(l.line=r,l.column=n):(l.line=r.line,l.column=r.column,l.endLine=n.line,l.endColumn=n.column)),l.setMessage(),Error.captureStackTrace&&Error.captureStackTrace(l,i),l}var o=i.prototype;return o.setMessage=function(){this.message=this.plugin?this.plugin+": ":"",this.message+=this.file?this.file:"<css input>",typeof this.line!="undefined"&&(this.message+=":"+this.line+":"+this.column),this.message+=": "+this.reason},o.showSourceCode=function(r){var n=this;if(!this.source)return"";var s=this.source;r==null&&(r=bs.isColorSupported),Cs&&r&&(s=Cs(s));var a=s.split(/\r?\n/),u=Math.max(this.line-3,0),l=Math.min(this.line+2,a.length),c=String(l).length,f,h;if(r){var v=bs.createColors(!0),p=v.bold,g=v.gray,d=v.red;f=function(y){return p(d(y))},h=function(y){return g(y)}}else f=h=function(y){return y};return a.slice(u,l).map(function(y,w){var S=u+1+w,b=" "+(" "+S).slice(-c)+" | ";if(S===n.line){var C=h(b.replace(/\d/g," "))+y.slice(0,n.column-1).replace(/[^\t]/g," ");return f(">")+h(b)+y+"\n "+C+f("^")}return" "+h(b)+y}).join("\n")},o.toString=function(){var r=this.showSourceCode();return r&&(r="\n\n"+r+"\n"),this.name+": "+this.message+r},i}(ar(Error)),ii=ni;ni.default=ni;var De={};De.isClean=Symbol("isClean"),De.my=Symbol("my");var Is={after:"\n",beforeClose:"\n",beforeComment:"\n",beforeDecl:"\n",beforeOpen:" ",beforeRule:"\n",colon:": ",commentLeft:" ",commentRight:" ",emptyBody:"",indent:" ",semicolon:!1};function Sf(t){return t[0].toUpperCase()+t.slice(1)}var oi=function(){function t(o){this.builder=o}var i=t.prototype;return i.atrule=function(e,r){var n="@"+e.name,s=e.params?this.rawValue(e,"params"):"";if(typeof e.raws.afterName!="undefined"?n+=e.raws.afterName:s&&(n+=" "),e.nodes)this.block(e,n+s);else{var a=(e.raws.between||"")+(r?";":"");this.builder(n+s+a,e)}},i.beforeAfter=function(e,r){var n;e.type==="decl"?n=this.raw(e,null,"beforeDecl"):e.type==="comment"?n=this.raw(e,null,"beforeComment"):r==="before"?n=this.raw(e,null,"beforeRule"):n=this.raw(e,null,"beforeClose");for(var s=e.parent,a=0;s&&s.type!=="root";)a+=1,s=s.parent;if(n.includes("\n")){var u=this.raw(e,null,"indent");if(u.length)for(var l=0;l<a;l++)n+=u}return n},i.block=function(e,r){var n=this.raw(e,"between","beforeOpen");this.builder(r+n+"{",e,"start");var s;e.nodes&&e.nodes.length?(this.body(e),s=this.raw(e,"after")):s=this.raw(e,"after","emptyBody"),s&&this.builder(s),this.builder("}",e,"end")},i.body=function(e){for(var r=e.nodes.length-1;r>0&&e.nodes[r].type==="comment";)r-=1;for(var n=this.raw(e,"semicolon"),s=0;s<e.nodes.length;s++){var a=e.nodes[s],u=this.raw(a,"before");u&&this.builder(u),this.stringify(a,r!==s||n)}},i.comment=function(e){var r=this.raw(e,"left","commentLeft"),n=this.raw(e,"right","commentRight");this.builder("/*"+r+e.text+n+"*/",e)},i.decl=function(e,r){var n=this.raw(e,"between","colon"),s=e.prop+n+this.rawValue(e,"value");e.important&&(s+=e.raws.important||" !important"),r&&(s+=";"),this.builder(s,e)},i.document=function(e){this.body(e)},i.raw=function(e,r,n){var s;if(n||(n=r),r&&(s=e.raws[r],typeof s!="undefined"))return s;var a=e.parent;if(n==="before"&&(!a||a.type==="root"&&a.first===e||a&&a.type==="document"))return"";if(!a)return Is[n];var u=e.root();if(u.rawCache||(u.rawCache={}),typeof u.rawCache[n]!="undefined")return u.rawCache[n];if(n==="before"||n==="after")return this.beforeAfter(e,n);var l="raw"+Sf(n);return this[l]?s=this[l](u,e):u.walk(function(c){if(s=c.raws[r],typeof s!="undefined")return!1}),typeof s=="undefined"&&(s=Is[n]),u.rawCache[n]=s,s},i.rawBeforeClose=function(e){var r;return e.walk(function(n){if(n.nodes&&n.nodes.length>0&&typeof n.raws.after!="undefined")return r=n.raws.after,r.includes("\n")&&(r=r.replace(/[^\n]+$/,"")),!1}),r&&(r=r.replace(/\S/g,"")),r},i.rawBeforeComment=function(e,r){var n;return e.walkComments(function(s){if(typeof s.raws.before!="undefined")return n=s.raws.before,n.includes("\n")&&(n=n.replace(/[^\n]+$/,"")),!1}),typeof n=="undefined"?n=this.raw(r,null,"beforeDecl"):n&&(n=n.replace(/\S/g,"")),n},i.rawBeforeDecl=function(e,r){var n;return e.walkDecls(function(s){if(typeof s.raws.before!="undefined")return n=s.raws.before,n.includes("\n")&&(n=n.replace(/[^\n]+$/,"")),!1}),typeof n=="undefined"?n=this.raw(r,null,"beforeRule"):n&&(n=n.replace(/\S/g,"")),n},i.rawBeforeOpen=function(e){var r;return e.walk(function(n){if(n.type!=="decl"&&(r=n.raws.between,typeof r!="undefined"))return!1}),r},i.rawBeforeRule=function(e){var r;return e.walk(function(n){if(n.nodes&&(n.parent!==e||e.first!==n)&&typeof n.raws.before!="undefined")return r=n.raws.before,r.includes("\n")&&(r=r.replace(/[^\n]+$/,"")),!1}),r&&(r=r.replace(/\S/g,"")),r},i.rawColon=function(e){var r;return e.walkDecls(function(n){if(typeof n.raws.between!="undefined")return r=n.raws.between.replace(/[^\s:]/g,""),!1}),r},i.rawEmptyBody=function(e){var r;return e.walk(function(n){if(n.nodes&&n.nodes.length===0&&(r=n.raws.after,typeof r!="undefined"))return!1}),r},i.rawIndent=function(e){if(e.raws.indent)return e.raws.indent;var r;return e.walk(function(n){var s=n.parent;if(s&&s!==e&&s.parent&&s.parent===e&&typeof n.raws.before!="undefined"){var a=n.raws.before.split("\n");return r=a[a.length-1],r=r.replace(/\S/g,""),!1}}),r},i.rawSemicolon=function(e){var r;return e.walk(function(n){if(n.nodes&&n.nodes.length&&n.last.type==="decl"&&(r=n.raws.semicolon,typeof r!="undefined"))return!1}),r},i.rawValue=function(e,r){var n=e[r],s=e.raws[r];return s&&s.value===n?s.raw:n},i.root=function(e){this.body(e),e.raws.after&&this.builder(e.raws.after)},i.rule=function(e){this.block(e,this.rawValue(e,"selector")),e.raws.ownSemicolon&&this.builder(e.raws.ownSemicolon,e,"end")},i.stringify=function(e,r){if(!this[e.type])throw new Error("Unknown AST node type "+e.type+". Maybe you need to change PostCSS stringifier.");this[e.type](e,r)},t}(),Os=oi;oi.default=oi;var bf=Os;function si(t,i){var o=new bf(i);o.stringify(t)}var _r=si;si.default=si;var Tr=De.isClean,Cf=De.my,If=ii,Of=Os,xf=_r;function ai(t,i){var o=new t.constructor;for(var e in t)if(Object.prototype.hasOwnProperty.call(t,e)&&e!=="proxyCache"){var r=t[e],n=typeof r=="undefined"?"undefined":N(r);e==="parent"&&n==="object"?i&&(o[e]=i):e==="source"?o[e]=r:Array.isArray(r)?o[e]=r.map(function(s){return ai(s,o)}):(n==="object"&&r!==null&&(r=ai(r)),o[e]=r)}return o}var ui=function(){function t(o){o===void 0&&(o={}),this.raws={},this[Tr]=!1,this[Cf]=!0;for(var e in o)if(e==="nodes"){this.nodes=[];for(var r=O(o[e]),n;!(n=r()).done;){var s=n.value;typeof s.clone=="function"?this.append(s.clone()):this.append(s)}}else this[e]=o[e]}var i=t.prototype;return i.addToError=function(e){if(e.postcssNode=this,e.stack&&this.source&&/\n\s{4}at /.test(e.stack)){var r=this.source;e.stack=e.stack.replace(/\n\s{4}at /,"$&"+r.input.from+":"+r.start.line+":"+r.start.column+"$&")}return e},i.after=function(e){return this.parent.insertAfter(this,e),this},i.assign=function(e){e===void 0&&(e={});for(var r in e)this[r]=e[r];return this},i.before=function(e){return this.parent.insertBefore(this,e),this},i.cleanRaws=function(e){delete this.raws.before,delete this.raws.after,e||delete this.raws.between},i.clone=function(e){e===void 0&&(e={});var r=ai(this);for(var n in e)r[n]=e[n];return r},i.cloneAfter=function(e){e===void 0&&(e={});var r=this.clone(e);return this.parent.insertAfter(this,r),r},i.cloneBefore=function(e){e===void 0&&(e={});var r=this.clone(e);return this.parent.insertBefore(this,r),r},i.error=function(e,r){if(r===void 0&&(r={}),this.source){var n=this.rangeBy(r),s=n.end,a=n.start;return this.source.input.error(e,{column:a.column,line:a.line},{column:s.column,line:s.line},r)}return new If(e)},i.getProxyProcessor=function(){return{get:function(r,n){return n==="proxyOf"?r:n==="root"?function(){return r.root().toProxy()}:r[n]},set:function(r,n,s){return r[n]===s||(r[n]=s,(n==="prop"||n==="value"||n==="name"||n==="params"||n==="important"||n==="text")&&r.markDirty()),!0}}},i.markDirty=function(){if(this[Tr]){this[Tr]=!1;for(var e=this;e=e.parent;)e[Tr]=!1}},i.next=function(){if(this.parent){var e=this.parent.index(this);return this.parent.nodes[e+1]}},i.positionBy=function(e,r){var n=this.source.start;if(e.index)n=this.positionInside(e.index,r);else if(e.word){r=this.toString();var s=r.indexOf(e.word);s!==-1&&(n=this.positionInside(s,r))}return n},i.positionInside=function(e,r){for(var n=r||this.toString(),s=this.source.start.column,a=this.source.start.line,u=0;u<e;u++)n[u]==="\n"?(s=1,a+=1):s+=1;return{column:s,line:a}},i.prev=function(){if(this.parent){var e=this.parent.index(this);return this.parent.nodes[e-1]}},i.rangeBy=function(e){var r={column:this.source.start.column,line:this.source.start.line},n=this.source.end?{column:this.source.end.column+1,line:this.source.end.line}:{column:r.column+1,line:r.line};if(e.word){var s=this.toString(),a=s.indexOf(e.word);a!==-1&&(r=this.positionInside(a,s),n=this.positionInside(a+e.word.length,s))}else e.start?r={column:e.start.column,line:e.start.line}:e.index&&(r=this.positionInside(e.index)),e.end?n={column:e.end.column,line:e.end.line}:typeof e.endIndex=="number"?n=this.positionInside(e.endIndex):e.index&&(n=this.positionInside(e.index+1));return(n.line<r.line||n.line===r.line&&n.column<=r.column)&&(n={column:r.column+1,line:r.line}),{end:n,start:r}},i.raw=function(e,r){var n=new Of;return n.raw(this,e,r)},i.remove=function(){return this.parent&&this.parent.removeChild(this),this.parent=void 0,this},i.replaceWith=function(){for(var e=arguments.length,r=new Array(e),n=0;n<e;n++)r[n]=arguments[n];if(this.parent){for(var s=this,a=!1,u=O(r),l;!(l=u()).done;){var c=l.value;c===this?a=!0:a?(this.parent.insertAfter(s,c),s=c):this.parent.insertBefore(s,c)}a||this.remove()}return this},i.root=function(){for(var e=this;e.parent&&e.parent.type!=="document";)e=e.parent;return e},i.toJSON=function(e,r){var n={},s=r==null;r=r||new Map;var a=0;for(var u in this)if(Object.prototype.hasOwnProperty.call(this,u)&&!(u==="parent"||u==="proxyCache")){var l=this[u];if(Array.isArray(l))n[u]=l.map(function(f){return(typeof f=="undefined"?"undefined":N(f))==="object"&&f.toJSON?f.toJSON(null,r):f});else if((typeof l=="undefined"?"undefined":N(l))==="object"&&l.toJSON)n[u]=l.toJSON(null,r);else if(u==="source"){var c=r.get(l.input);c==null&&(c=a,r.set(l.input,a),a++),n[u]={end:l.end,inputId:c,start:l.start}}else n[u]=l}return s&&(n.inputs=[].concat(r.keys()).map(function(f){return f.toJSON()})),n},i.toProxy=function(){return this.proxyCache||(this.proxyCache=new Proxy(this,this.getProxyProcessor())),this.proxyCache},i.toString=function(e){e===void 0&&(e=xf),e.stringify&&(e=e.stringify);var r="";return e(this,function(n){r+=n}),r},i.warn=function(e,r,n){var s={node:this};for(var a in n)s[a]=n[a];return e.warn(r,s)},oe(t,[{key:"proxyOf",get:function(){return this}}]),t}(),Pr=ui;ui.default=ui;var Rf=Pr,li=function(t){ae(i,t);function i(o){var e;return o&&typeof o.value!="undefined"&&typeof o.value!="string"&&(o=F({},o,{value:String(o.value)})),e=t.call(this,o)||this,e.type="decl",e}return oe(i,[{key:"variable",get:function(){return this.prop.startsWith("--")||this.prop[0]==="$"}}]),i}(Rf),Nr=li;li.default=li;var Ef="useandom-26T198340PX75pxJACKVERYMINDBUSHWOLF_GQZbfghjklqvwyzrict",Af=function(t){t===void 0&&(t=21);for(var i="",o=t;o--;)i+=Ef[Math.random()*64|0];return i},Mf={nanoid:Af},xs=ne.SourceMapConsumer,Rs=ne.SourceMapGenerator,kf=ne.existsSync,_f=ne.readFileSync,ci=ne.dirname,Tf=ne.join;function Pf(t){return Buffer?Buffer.from(t,"base64").toString():window.atob(t)}var fi=function(){function t(o,e){if(e.map!==!1){this.loadAnnotation(o),this.inline=this.startWith(this.annotation,"data:");var r=e.map?e.map.prev:void 0,n=this.loadMap(e.from,r);!this.mapFile&&e.from&&(this.mapFile=e.from),this.mapFile&&(this.root=ci(this.mapFile)),n&&(this.text=n)}}var i=t.prototype;return i.consumer=function(){return this.consumerCache||(this.consumerCache=new xs(this.text)),this.consumerCache},i.decodeInline=function(e){var r=/^data:application\/json;charset=utf-?8;base64,/,n=/^data:application\/json;base64,/,s=/^data:application\/json;charset=utf-?8,/,a=/^data:application\/json,/;if(s.test(e)||a.test(e))return decodeURIComponent(e.substr(RegExp.lastMatch.length));if(r.test(e)||n.test(e))return Pf(e.substr(RegExp.lastMatch.length));var u=e.match(/data:application\/json;([^,]+),/)[1];throw new Error("Unsupported source map encoding "+u)},i.getAnnotationURL=function(e){return e.replace(/^\/\*\s*# sourceMappingURL=/,"").trim()},i.isMap=function(e){return(typeof e=="undefined"?"undefined":N(e))!=="object"?!1:typeof e.mappings=="string"||typeof e._mappings=="string"||Array.isArray(e.sections)},i.loadAnnotation=function(e){var r=e.match(/\/\*\s*# sourceMappingURL=/gm);if(r){var n=e.lastIndexOf(r.pop()),s=e.indexOf("*/",n);n>-1&&s>-1&&(this.annotation=this.getAnnotationURL(e.substring(n,s)))}},i.loadFile=function(e){if(this.root=ci(e),kf(e))return this.mapFile=e,_f(e,"utf-8").toString().trim()},i.loadMap=function(e,r){if(r===!1)return!1;if(r){if(typeof r=="string")return r;if(typeof r=="function"){var n=r(e);if(n){var s=this.loadFile(n);if(!s)throw new Error("Unable to load previous source map: "+n.toString());return s}}else{if(T(r,xs))return Rs.fromSourceMap(r).toString();if(T(r,Rs))return r.toString();if(this.isMap(r))return JSON.stringify(r);throw new Error("Unsupported previous source map format: "+r.toString())}}else{if(this.inline)return this.decodeInline(this.annotation);if(this.annotation){var a=this.annotation;return e&&(a=Tf(ci(e),a)),this.loadFile(a)}}},i.startWith=function(e,r){return e?e.substr(0,r.length)===r:!1},i.withContent=function(){return!!(this.consumer().sourcesContent&&this.consumer().sourcesContent.length>0)},t}(),Es=fi;fi.default=fi;var Nf=ne.SourceMapConsumer,$f=ne.SourceMapGenerator,As=ne.fileURLToPath,$r=ne.pathToFileURL,hi=ne.isAbsolute,di=ne.resolve,Df=Mf.nanoid,pi=ne,Ms=ii,Lf=Es,vi=Symbol("fromOffsetCache"),Ff=!!(Nf&&$f),ks=!!(di&&hi),Dr=function(){function t(o,e){if(e===void 0&&(e={}),o===null||typeof o=="undefined"||(typeof o=="undefined"?"undefined":N(o))==="object"&&!o.toString)throw new Error("PostCSS received "+o+" instead of CSS string");if(this.css=o.toString(),this.css[0]==="\uFEFF"||this.css[0]==="\uFFFE"?(this.hasBOM=!0,this.css=this.css.slice(1)):this.hasBOM=!1,e.from&&(!ks||/^\w+:\/\//.test(e.from)||hi(e.from)?this.file=e.from:this.file=di(e.from)),ks&&Ff){var r=new Lf(this.css,e);if(r.text){this.map=r;var n=r.consumer().file;!this.file&&n&&(this.file=this.mapResolve(n))}}this.file||(this.id="<input css "+Df(6)+">"),this.map&&(this.map.file=this.from)}var i=t.prototype;return i.error=function(e,r,n,s){s===void 0&&(s={});var a,u,l;if(r&&(typeof r=="undefined"?"undefined":N(r))==="object"){var c=r,f=n;if(typeof c.offset=="number"){var h=this.fromOffset(c.offset);r=h.line,n=h.col}else r=c.line,n=c.column;if(typeof f.offset=="number"){var v=this.fromOffset(f.offset);u=v.line,l=v.col}else u=f.line,l=f.column}else if(!n){var p=this.fromOffset(r);r=p.line,n=p.col}var g=this.origin(r,n,u,l);return g?a=new Ms(e,g.endLine===void 0?g.line:{column:g.column,line:g.line},g.endLine===void 0?g.column:{column:g.endColumn,line:g.endLine},g.source,g.file,s.plugin):a=new Ms(e,u===void 0?r:{column:n,line:r},u===void 0?n:{column:l,line:u},this.css,this.file,s.plugin),a.input={column:n,endColumn:l,endLine:u,line:r,source:this.css},this.file&&($r&&(a.input.url=$r(this.file).toString()),a.input.file=this.file),a},i.fromOffset=function(e){var r,n;if(this[vi])n=this[vi];else{var s=this.css.split("\n");n=new Array(s.length);for(var a=0,u=0,l=s.length;u<l;u++)n[u]=a,a+=s[u].length+1;this[vi]=n}r=n[n.length-1];var c=0;if(e>=r)c=n.length-1;else for(var f=n.length-2,h;c<f;)if(h=c+(f-c>>1),e<n[h])f=h-1;else if(e>=n[h+1])c=h+1;else{c=h;break}return{col:e-n[c]+1,line:c+1}},i.mapResolve=function(e){return/^\w+:\/\//.test(e)?e:di(this.map.consumer().sourceRoot||this.map.root||".",e)},i.origin=function(e,r,n,s){if(!this.map)return!1;var a=this.map.consumer(),u=a.originalPositionFor({column:r,line:e});if(!u.source)return!1;var l;typeof n=="number"&&(l=a.originalPositionFor({column:s,line:n}));var c;hi(u.source)?c=$r(u.source):c=new URL(u.source,this.map.consumer().sourceRoot||$r(this.map.mapFile));var f={column:u.column,endColumn:l&&l.column,endLine:l&&l.line,line:u.line,url:c.toString()};if(c.protocol==="file:")if(As)f.file=As(c);else throw new Error("file: protocol is not available in this PostCSS build");var h=a.sourceContentFor(u.source);return h&&(f.source=h),f},i.toJSON=function(){for(var e={},r=0,n=["hasBOM","css","file","id"];r<n.length;r++){var s=n[r];this[s]!=null&&(e[s]=this[s])}return this.map&&(e.map=F({},this.map),e.map.consumerCache&&(e.map.consumerCache=void 0)),e},oe(t,[{key:"from",get:function(){return this.file||this.id}}]),t}(),Lr=Dr;Dr.default=Dr,pi&&pi.registerInput&&pi.registerInput(Dr);var _s=ne.SourceMapConsumer,Fr=ne.SourceMapGenerator,Br=ne.dirname,Ts=ne.relative,Ps=ne.resolve,Ns=ne.sep,$s=ne.pathToFileURL,Bf=Lr,Uf=!!(_s&&Fr),zf=!!(Br&&Ps&&Ts&&Ns),Wf=function(){function t(o,e,r,n){this.stringify=o,this.mapOpts=r.map||{},this.root=e,this.opts=r,this.css=n,this.originalCSS=n,this.usesFileUrls=!this.mapOpts.from&&this.mapOpts.absolute,this.memoizedFileURLs=new Map,this.memoizedPaths=new Map,this.memoizedURLs=new Map}var i=t.prototype;return i.addAnnotation=function(){var e;this.isInline()?e="data:application/json;base64,"+this.toBase64(this.map.toString()):typeof this.mapOpts.annotation=="string"?e=this.mapOpts.annotation:typeof this.mapOpts.annotation=="function"?e=this.mapOpts.annotation(this.opts.to,this.root):e=this.outputFile()+".map";var r="\n";this.css.includes("\r\n")&&(r="\r\n"),this.css+=r+"/*# sourceMappingURL="+e+" */"},i.applyPrevMaps=function(){for(var e=O(this.previous()),r;!(r=e()).done;){var n=r.value,s=this.toUrl(this.path(n.file)),a=n.root||Br(n.file),u=void 0;this.mapOpts.sourcesContent===!1?(u=new _s(n.text),u.sourcesContent&&(u.sourcesContent=null)):u=n.consumer(),this.map.applySourceMap(u,s,this.toUrl(this.path(a)))}},i.clearAnnotation=function(){if(this.mapOpts.annotation!==!1)if(this.root)for(var e,r=this.root.nodes.length-1;r>=0;r--)e=this.root.nodes[r],e.type==="comment"&&e.text.indexOf("# sourceMappingURL=")===0&&this.root.removeChild(r);else this.css&&(this.css=this.css.replace(/\n*?\/\*#[\S\s]*?\*\/$/gm,""))},i.generate=function(){if(this.clearAnnotation(),zf&&Uf&&this.isMap())return this.generateMap();var e="";return this.stringify(this.root,function(r){e+=r}),[e]},i.generateMap=function(){if(this.root)this.generateString();else if(this.previous().length===1){var e=this.previous()[0].consumer();e.file=this.outputFile(),this.map=Fr.fromSourceMap(e,{ignoreInvalidMapping:!0})}else this.map=new Fr({file:this.outputFile(),ignoreInvalidMapping:!0}),this.map.addMapping({generated:{column:0,line:1},original:{column:0,line:1},source:this.opts.from?this.toUrl(this.path(this.opts.from)):"<no source>"});return this.isSourcesContent()&&this.setSourcesContent(),this.root&&this.previous().length>0&&this.applyPrevMaps(),this.isAnnotation()&&this.addAnnotation(),this.isInline()?[this.css]:[this.css,this.map]},i.generateString=function(){var e=this;this.css="",this.map=new Fr({file:this.outputFile(),ignoreInvalidMapping:!0});var r=1,n=1,s="<no source>",a={generated:{column:0,line:0},original:{column:0,line:0},source:""},u,l;this.stringify(this.root,function(c,f,h){if(e.css+=c,f&&h!=="end"&&(a.generated.line=r,a.generated.column=n-1,f.source&&f.source.start?(a.source=e.sourcePath(f),a.original.line=f.source.start.line,a.original.column=f.source.start.column-1,e.map.addMapping(a)):(a.source=s,a.original.line=1,a.original.column=0,e.map.addMapping(a))),u=c.match(/\n/g),u?(r+=u.length,l=c.lastIndexOf("\n"),n=c.length-l):n+=c.length,f&&h!=="start"){var v=f.parent||{raws:{}},p=f.type==="decl"||f.type==="atrule"&&!f.nodes;(!p||f!==v.last||v.raws.semicolon)&&(f.source&&f.source.end?(a.source=e.sourcePath(f),a.original.line=f.source.end.line,a.original.column=f.source.end.column-1,a.generated.line=r,a.generated.column=n-2,e.map.addMapping(a)):(a.source=s,a.original.line=1,a.original.column=0,a.generated.line=r,a.generated.column=n-1,e.map.addMapping(a)))}})},i.isAnnotation=function(){return this.isInline()?!0:typeof this.mapOpts.annotation!="undefined"?this.mapOpts.annotation:this.previous().length?this.previous().some(function(e){return e.annotation}):!0},i.isInline=function(){if(typeof this.mapOpts.inline!="undefined")return this.mapOpts.inline;var e=this.mapOpts.annotation;return typeof e!="undefined"&&e!==!0?!1:this.previous().length?this.previous().some(function(r){return r.inline}):!0},i.isMap=function(){return typeof this.opts.map!="undefined"?!!this.opts.map:this.previous().length>0},i.isSourcesContent=function(){return typeof this.mapOpts.sourcesContent!="undefined"?this.mapOpts.sourcesContent:this.previous().length?this.previous().some(function(e){return e.withContent()}):!0},i.outputFile=function(){return this.opts.to?this.path(this.opts.to):this.opts.from?this.path(this.opts.from):"to.css"},i.path=function(e){if(this.mapOpts.absolute||e.charCodeAt(0)===60||/^\w+:\/\//.test(e))return e;var r=this.memoizedPaths.get(e);if(r)return r;var n=this.opts.to?Br(this.opts.to):".";typeof this.mapOpts.annotation=="string"&&(n=Br(Ps(n,this.mapOpts.annotation)));var s=Ts(n,e);return this.memoizedPaths.set(e,s),s},i.previous=function(){var e=this;if(!this.previousMaps)if(this.previousMaps=[],this.root)this.root.walk(function(n){if(n.source&&n.source.input.map){var s=n.source.input.map;e.previousMaps.includes(s)||e.previousMaps.push(s)}});else{var r=new Bf(this.originalCSS,this.opts);r.map&&this.previousMaps.push(r.map)}return this.previousMaps},i.setSourcesContent=function(){var e=this,r={};if(this.root)this.root.walk(function(s){if(s.source){var a=s.source.input.from;if(a&&!r[a]){r[a]=!0;var u=e.usesFileUrls?e.toFileUrl(a):e.toUrl(e.path(a));e.map.setSourceContent(u,s.source.input.css)}}});else if(this.css){var n=this.opts.from?this.toUrl(this.path(this.opts.from)):"<no source>";this.map.setSourceContent(n,this.css)}},i.sourcePath=function(e){return this.mapOpts.from?this.toUrl(this.mapOpts.from):this.usesFileUrls?this.toFileUrl(e.source.input.from):this.toUrl(this.path(e.source.input.from))},i.toBase64=function(e){return Buffer?Buffer.from(e).toString("base64"):window.btoa(unescape(encodeURIComponent(e)))},i.toFileUrl=function(e){var r=this.memoizedFileURLs.get(e);if(r)return r;if($s){var n=$s(e).toString();return this.memoizedFileURLs.set(e,n),n}else throw new Error("`map.absolute` option is not available in this PostCSS build")},i.toUrl=function(e){var r=this.memoizedURLs.get(e);if(r)return r;Ns==="\\"&&(e=e.replace(/\\/g,"/"));var n=encodeURI(e).replace(/[#?]/g,encodeURIComponent);return this.memoizedURLs.set(e,n),n},t}(),Ds=Wf,Gf=Pr,mi=function(t){ae(i,t);function i(o){var e;return e=t.call(this,o)||this,e.type="comment",e}return i}(Gf),Ur=mi;mi.default=mi;var Ls=De.isClean,Fs=De.my,Bs=Nr,Us=Ur,jf=Pr,zs,gi,yi,Ws;function Gs(t){return t.map(function(i){return i.nodes&&(i.nodes=Gs(i.nodes)),delete i.source,i})}function js(t){if(t[Ls]=!1,t.proxyOf.nodes)for(var i=O(t.proxyOf.nodes),o;!(o=i()).done;){var e=o.value;js(e)}}var Me=function(t){ae(i,t);function i(){return t.apply(this,arguments)||this}var o=i.prototype;return o.append=function(){for(var r=arguments.length,n=new Array(r),s=0;s<r;s++)n[s]=arguments[s];for(var a=O(n),u;!(u=a()).done;)for(var l=u.value,c=this.normalize(l,this.last),f=O(c),h;!(h=f()).done;){var v=h.value;this.proxyOf.nodes.push(v)}return this.markDirty(),this},o.cleanRaws=function(r){if(t.prototype.cleanRaws.call(this,r),this.nodes)for(var n=O(this.nodes),s;!(s=n()).done;){var a=s.value;a.cleanRaws(r)}},o.each=function(r){if(this.proxyOf.nodes){for(var n=this.getIterator(),s,a;this.indexes[n]<this.proxyOf.nodes.length&&(s=this.indexes[n],a=r(this.proxyOf.nodes[s],s),a!==!1);)this.indexes[n]+=1;return delete this.indexes[n],a}},o.every=function(r){return this.nodes.every(r)},o.getIterator=function(){this.lastEach||(this.lastEach=0),this.indexes||(this.indexes={}),this.lastEach+=1;var r=this.lastEach;return this.indexes[r]=0,r},o.getProxyProcessor=function(){return{get:function(n,s){return s==="proxyOf"?n:n[s]?s==="each"||typeof s=="string"&&s.startsWith("walk")?function(){for(var a=arguments.length,u=new Array(a),l=0;l<a;l++)u[l]=arguments[l];var c;return(c=n)[s].apply(c,[].concat(u.map(function(f){return typeof f=="function"?function(h,v){return f(h.toProxy(),v)}:f})))}:s==="every"||s==="some"?function(a){return n[s](function(u){for(var l=arguments.length,c=new Array(l>1?l-1:0),f=1;f<l;f++)c[f-1]=arguments[f];return a.apply(void 0,[].concat([u.toProxy()],c))})}:s==="root"?function(){return n.root().toProxy()}:s==="nodes"?n.nodes.map(function(a){return a.toProxy()}):s==="first"||s==="last"?n[s].toProxy():n[s]:n[s]},set:function(n,s,a){return n[s]===a||(n[s]=a,(s==="name"||s==="params"||s==="selector")&&n.markDirty()),!0}}},o.index=function(r){return typeof r=="number"?r:(r.proxyOf&&(r=r.proxyOf),this.proxyOf.nodes.indexOf(r))},o.insertAfter=function(r,n){var s=this.index(r),a=this.normalize(n,this.proxyOf.nodes[s]).reverse();s=this.index(r);for(var u=O(a),l;!(l=u()).done;){var c=l.value;this.proxyOf.nodes.splice(s+1,0,c)}var f;for(var h in this.indexes)f=this.indexes[h],s<f&&(this.indexes[h]=f+a.length);return this.markDirty(),this},o.insertBefore=function(r,n){var s=this.index(r),a=s===0?"prepend":!1,u=this.normalize(n,this.proxyOf.nodes[s],a).reverse();s=this.index(r);for(var l=O(u),c;!(c=l()).done;){var f=c.value;this.proxyOf.nodes.splice(s,0,f)}var h;for(var v in this.indexes)h=this.indexes[v],s<=h&&(this.indexes[v]=h+u.length);return this.markDirty(),this},o.normalize=function(r,n){var s=this;if(typeof r=="string")r=Gs(zs(r).nodes);else if(typeof r=="undefined")r=[];else if(Array.isArray(r)){r=r.slice(0);for(var a=O(r),u;!(u=a()).done;){var l=u.value;l.parent&&l.parent.removeChild(l,"ignore")}}else if(r.type==="root"&&this.type!=="document"){r=r.nodes.slice(0);for(var c=O(r),f;!(f=c()).done;){var h=f.value;h.parent&&h.parent.removeChild(h,"ignore")}}else if(r.type)r=[r];else if(r.prop){if(typeof r.value=="undefined")throw new Error("Value field is missed in node creation");typeof r.value!="string"&&(r.value=String(r.value)),r=[new Bs(r)]}else if(r.selector)r=[new gi(r)];else if(r.name)r=[new yi(r)];else if(r.text)r=[new Us(r)];else throw new Error("Unknown node type in node creation");var v=r.map(function(p){return p[Fs]||i.rebuild(p),p=p.proxyOf,p.parent&&p.parent.removeChild(p),p[Ls]&&js(p),typeof p.raws.before=="undefined"&&n&&typeof n.raws.before!="undefined"&&(p.raws.before=n.raws.before.replace(/\S/g,"")),p.parent=s.proxyOf,p});return v},o.prepend=function(){for(var r=arguments.length,n=new Array(r),s=0;s<r;s++)n[s]=arguments[s];n=n.reverse();for(var a=O(n),u;!(u=a()).done;){for(var l=u.value,c=this.normalize(l,this.first,"prepend").reverse(),f=O(c),h;!(h=f()).done;){var v=h.value;this.proxyOf.nodes.unshift(v)}for(var p in this.indexes)this.indexes[p]=this.indexes[p]+c.length}return this.markDirty(),this},o.push=function(r){return r.parent=this,this.proxyOf.nodes.push(r),this},o.removeAll=function(){for(var r=O(this.proxyOf.nodes),n;!(n=r()).done;){var s=n.value;s.parent=void 0}return this.proxyOf.nodes=[],this.markDirty(),this},o.removeChild=function(r){r=this.index(r),this.proxyOf.nodes[r].parent=void 0,this.proxyOf.nodes.splice(r,1);var n;for(var s in this.indexes)n=this.indexes[s],n>=r&&(this.indexes[s]=n-1);return this.markDirty(),this},o.replaceValues=function(r,n,s){return s||(s=n,n={}),this.walkDecls(function(a){n.props&&!n.props.includes(a.prop)||n.fast&&!a.value.includes(n.fast)||(a.value=a.value.replace(r,s))}),this.markDirty(),this},o.some=function(r){return this.nodes.some(r)},o.walk=function(r){return this.each(function(n,s){var a;try{a=r(n,s)}catch(u){throw n.addToError(u)}return a!==!1&&n.walk&&(a=n.walk(r)),a})},o.walkAtRules=function(r,n){return n?T(r,RegExp)?this.walk(function(s,a){if(s.type==="atrule"&&r.test(s.name))return n(s,a)}):this.walk(function(s,a){if(s.type==="atrule"&&s.name===r)return n(s,a)}):(n=r,this.walk(function(s,a){if(s.type==="atrule")return n(s,a)}))},o.walkComments=function(r){return this.walk(function(n,s){if(n.type==="comment")return r(n,s)})},o.walkDecls=function(r,n){return n?T(r,RegExp)?this.walk(function(s,a){if(s.type==="decl"&&r.test(s.prop))return n(s,a)}):this.walk(function(s,a){if(s.type==="decl"&&s.prop===r)return n(s,a)}):(n=r,this.walk(function(s,a){if(s.type==="decl")return n(s,a)}))},o.walkRules=function(r,n){return n?T(r,RegExp)?this.walk(function(s,a){if(s.type==="rule"&&r.test(s.selector))return n(s,a)}):this.walk(function(s,a){if(s.type==="rule"&&s.selector===r)return n(s,a)}):(n=r,this.walk(function(s,a){if(s.type==="rule")return n(s,a)}))},oe(i,[{key:"first",get:function(){if(this.proxyOf.nodes)return this.proxyOf.nodes[0]}},{key:"last",get:function(){if(this.proxyOf.nodes)return this.proxyOf.nodes[this.proxyOf.nodes.length-1]}}]),i}(jf);Me.registerParse=function(t){zs=t},Me.registerRule=function(t){gi=t},Me.registerAtRule=function(t){yi=t},Me.registerRoot=function(t){Ws=t};var Ve=Me;Me.default=Me,Me.rebuild=function(t){t.type==="atrule"?Object.setPrototypeOf(t,yi.prototype):t.type==="rule"?Object.setPrototypeOf(t,gi.prototype):t.type==="decl"?Object.setPrototypeOf(t,Bs.prototype):t.type==="comment"?Object.setPrototypeOf(t,Us.prototype):t.type==="root"&&Object.setPrototypeOf(t,Ws.prototype),t[Fs]=!0,t.nodes&&t.nodes.forEach(function(i){Me.rebuild(i)})};var Vf=Ve,Vs,Ys,Lt=function(t){ae(i,t);function i(e){var r;return r=t.call(this,F({type:"document"},e))||this,r.nodes||(r.nodes=[]),r}var o=i.prototype;return o.toResult=function(r){r===void 0&&(r={});var n=new Vs(new Ys,this,r);return n.stringify()},i}(Vf);Lt.registerLazyResult=function(t){Vs=t},Lt.registerProcessor=function(t){Ys=t};var wi=Lt;Lt.default=Lt;var qs={},Hs=function(i){qs[i]||(qs[i]=!0,typeof console!="undefined"&&console.warn&&console.warn(i))},Si=function(){function t(o,e){if(e===void 0&&(e={}),this.type="warning",this.text=o,e.node&&e.node.source){var r=e.node.rangeBy(e);this.line=r.start.line,this.column=r.start.column,this.endLine=r.end.line,this.endColumn=r.end.column}for(var n in e)this[n]=e[n]}var i=t.prototype;return i.toString=function(){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},t}(),Js=Si;Si.default=Si;var Yf=Js,bi=function(){function t(o,e,r){this.processor=o,this.messages=[],this.root=e,this.opts=r,this.css=void 0,this.map=void 0}var i=t.prototype;return i.toString=function(){return this.css},i.warn=function(e,r){r===void 0&&(r={}),r.plugin||this.lastPlugin&&this.lastPlugin.postcssPlugin&&(r.plugin=this.lastPlugin.postcssPlugin);var n=new Yf(e,r);return this.messages.push(n),n},i.warnings=function(){return this.messages.filter(function(e){return e.type==="warning"})},oe(t,[{key:"content",get:function(){return this.css}}]),t}(),Ci=bi;bi.default=bi;var Ii=39,Zs=34,zr=92,Ks=47,Wr=10,Ft=32,Gr=12,jr=9,Vr=13,qf=91,Hf=93,Jf=40,Zf=41,Kf=123,Xf=125,Qf=59,eh=42,th=58,rh=64,Yr=/[\t\n\f\r "#'()/;[\\\]{}]/g,qr=/[\t\n\f\r !"#'():;@[\\\]{}]|\/(?=\*)/g,nh=/.[\r\n"'(/\\]/,Xs=/[\da-f]/i,ih=function(i,o){o===void 0&&(o={});var e=i.css.valueOf(),r=o.ignoreErrors,n,s,a,u,l,c,f,h,v,p,g=e.length,d=0,y=[],w=[];function S(){return d}function b(R){throw i.error("Unclosed "+R,d)}function C(){return w.length===0&&d>=g}function x(R){if(w.length)return w.pop();if(!(d>=g)){var _=R?R.ignoreUnclosed:!1;switch(n=e.charCodeAt(d),n){case Wr:case Ft:case jr:case Vr:case Gr:{s=d;do s+=1,n=e.charCodeAt(s);while(n===Ft||n===Wr||n===jr||n===Vr||n===Gr);p=["space",e.slice(d,s)],d=s-1;break}case qf:case Hf:case Kf:case Xf:case th:case Qf:case Zf:{var B=String.fromCharCode(n);p=[B,B,d];break}case Jf:{if(h=y.length?y.pop()[1]:"",v=e.charCodeAt(d+1),h==="url"&&v!==Ii&&v!==Zs&&v!==Ft&&v!==Wr&&v!==jr&&v!==Gr&&v!==Vr){s=d;do{if(c=!1,s=e.indexOf(")",s+1),s===-1)if(r||_){s=d;break}else b("bracket");for(f=s;e.charCodeAt(f-1)===zr;)f-=1,c=!c}while(c);p=["brackets",e.slice(d,s+1),d,s],d=s}else s=e.indexOf(")",d+1),u=e.slice(d,s+1),s===-1||nh.test(u)?p=["(","(",d]:(p=["brackets",u,d,s],d=s);break}case Ii:case Zs:{a=n===Ii?"'":'"',s=d;do{if(c=!1,s=e.indexOf(a,s+1),s===-1)if(r||_){s=d+1;break}else b("string");for(f=s;e.charCodeAt(f-1)===zr;)f-=1,c=!c}while(c);p=["string",e.slice(d,s+1),d,s],d=s;break}case rh:{Yr.lastIndex=d+1,Yr.test(e),Yr.lastIndex===0?s=e.length-1:s=Yr.lastIndex-2,p=["at-word",e.slice(d,s+1),d,s],d=s;break}case zr:{for(s=d,l=!0;e.charCodeAt(s+1)===zr;)s+=1,l=!l;if(n=e.charCodeAt(s+1),l&&n!==Ks&&n!==Ft&&n!==Wr&&n!==jr&&n!==Vr&&n!==Gr&&(s+=1,Xs.test(e.charAt(s)))){for(;Xs.test(e.charAt(s+1));)s+=1;e.charCodeAt(s+1)===Ft&&(s+=1)}p=["word",e.slice(d,s+1),d,s],d=s;break}default:{n===Ks&&e.charCodeAt(d+1)===eh?(s=e.indexOf("*/",d+2)+1,s===0&&(r||_?s=e.length:b("comment")),p=["comment",e.slice(d,s+1),d,s],d=s):(qr.lastIndex=d+1,qr.test(e),qr.lastIndex===0?s=e.length-1:s=qr.lastIndex-2,p=["word",e.slice(d,s+1),d,s],y.push(p),d=s);break}}return d++,p}}function E(R){w.push(R)}return{back:E,endOfFile:C,nextToken:x,position:S}},Qs=Ve,Hr=function(t){ae(i,t);function i(e){var r;return r=t.call(this,e)||this,r.type="atrule",r}var o=i.prototype;return o.append=function(){for(var r=arguments.length,n=new Array(r),s=0;s<r;s++)n[s]=arguments[s];var a;return this.proxyOf.nodes||(this.nodes=[]),(a=t.prototype.append).call.apply(a,[].concat([this],n))},o.prepend=function(){for(var r=arguments.length,n=new Array(r),s=0;s<r;s++)n[s]=arguments[s];var a;return this.proxyOf.nodes||(this.nodes=[]),(a=t.prototype.prepend).call.apply(a,[].concat([this],n))},i}(Qs),Oi=Hr;Hr.default=Hr,Qs.registerAtRule(Hr);var ea=Ve,ta,ra,lt=function(t){ae(i,t);function i(e){var r;return r=t.call(this,e)||this,r.type="root",r.nodes||(r.nodes=[]),r}var o=i.prototype;return o.normalize=function(r,n,s){var a=t.prototype.normalize.call(this,r);if(n){if(s==="prepend")this.nodes.length>1?n.raws.before=this.nodes[1].raws.before:delete n.raws.before;else if(this.first!==n)for(var u=O(a),l;!(l=u()).done;){var c=l.value;c.raws.before=n.raws.before}}return a},o.removeChild=function(r,n){var s=this.index(r);return!n&&s===0&&this.nodes.length>1&&(this.nodes[1].raws.before=this.nodes[s].raws.before),t.prototype.removeChild.call(this,r)},o.toResult=function(r){r===void 0&&(r={});var n=new ta(new ra,this,r);return n.stringify()},i}(ea);lt.registerLazyResult=function(t){ta=t},lt.registerProcessor=function(t){ra=t};var Bt=lt;lt.default=lt,ea.registerRoot(lt);var Ut={comma:function(i){return Ut.split(i,[","],!0)},space:function(i){var o=[" ","\n"," "];return Ut.split(i,o)},split:function(i,o,e){for(var r=[],n="",s=!1,a=0,u=!1,l="",c=!1,f=O(i),h;!(h=f()).done;){var v=h.value;c?c=!1:v==="\\"?c=!0:u?v===l&&(u=!1):v==='"'||v==="'"?(u=!0,l=v):v==="("?a+=1:v===")"?a>0&&(a-=1):a===0&&o.includes(v)&&(s=!0),s?(n!==""&&r.push(n.trim()),n="",s=!1):n+=v}return(e||n!=="")&&r.push(n.trim()),r}},na=Ut;Ut.default=Ut;var ia=Ve,oh=na,Jr=function(t){ae(i,t);function i(o){var e;return e=t.call(this,o)||this,e.type="rule",e.nodes||(e.nodes=[]),e}return oe(i,[{key:"selectors",get:function(){return oh.comma(this.selector)},set:function(e){var r=this.selector?this.selector.match(/,\s*/):null,n=r?r[0]:","+this.raw("between","beforeOpen");this.selector=e.join(n)}}]),i}(ia),xi=Jr;Jr.default=Jr,ia.registerRule(Jr);var sh=Nr,ah=ih,uh=Ur,lh=Oi,ch=Bt,oa=xi,sa={empty:!0,space:!0};function fh(t){for(var i=t.length-1;i>=0;i--){var o=t[i],e=o[3]||o[2];if(e)return e}}var hh=function(){function t(o){this.input=o,this.root=new ch,this.current=this.root,this.spaces="",this.semicolon=!1,this.createTokenizer(),this.root.source={input:o,start:{column:1,line:1,offset:0}}}var i=t.prototype;return i.atrule=function(e){var r=new lh;r.name=e[1].slice(1),r.name===""&&this.unnamedAtrule(r,e),this.init(r,e[2]);for(var n,s,a,u=!1,l=!1,c=[],f=[];!this.tokenizer.endOfFile();){if(e=this.tokenizer.nextToken(),n=e[0],n==="("||n==="["?f.push(n==="("?")":"]"):n==="{"&&f.length>0?f.push("}"):n===f[f.length-1]&&f.pop(),f.length===0)if(n===";"){r.source.end=this.getPosition(e[2]),r.source.end.offset++,this.semicolon=!0;break}else if(n==="{"){l=!0;break}else if(n==="}"){if(c.length>0){for(a=c.length-1,s=c[a];s&&s[0]==="space";)s=c[--a];s&&(r.source.end=this.getPosition(s[3]||s[2]),r.source.end.offset++)}this.end(e);break}else c.push(e);else c.push(e);if(this.tokenizer.endOfFile()){u=!0;break}}r.raws.between=this.spacesAndCommentsFromEnd(c),c.length?(r.raws.afterName=this.spacesAndCommentsFromStart(c),this.raw(r,"params",c),u&&(e=c[c.length-1],r.source.end=this.getPosition(e[3]||e[2]),r.source.end.offset++,this.spaces=r.raws.between,r.raws.between="")):(r.raws.afterName="",r.params=""),l&&(r.nodes=[],this.current=r)},i.checkMissedSemicolon=function(e){var r=this.colon(e);if(r!==!1){for(var n=0,s,a=r-1;a>=0&&(s=e[a],!(s[0]!=="space"&&(n+=1,n===2)));a--);throw this.input.error("Missed semicolon",s[0]==="word"?s[3]+1:s[2])}},i.colon=function(e){for(var r=0,n,s,a,u=O(e.entries()),l;!(l=u()).done;){var c=l.value,f=c[0],h=c[1];if(n=h,s=n[0],s==="("&&(r+=1),s===")"&&(r-=1),r===0&&s===":")if(!a)this.doubleColon(n);else{if(a[0]==="word"&&a[1]==="progid")continue;return f}a=n}return!1},i.comment=function(e){var r=new uh;this.init(r,e[2]),r.source.end=this.getPosition(e[3]||e[2]),r.source.end.offset++;var n=e[1].slice(2,-2);if(/^\s*$/.test(n))r.text="",r.raws.left=n,r.raws.right="";else{var s=n.match(/^(\s*)([^]*\S)(\s*)$/);r.text=s[2],r.raws.left=s[1],r.raws.right=s[3]}},i.createTokenizer=function(){this.tokenizer=ah(this.input)},i.decl=function(e,r){var n=new sh;this.init(n,e[0][2]);var s=e[e.length-1];for(s[0]===";"&&(this.semicolon=!0,e.pop()),n.source.end=this.getPosition(s[3]||s[2]||fh(e)),n.source.end.offset++;e[0][0]!=="word";)e.length===1&&this.unknownWord(e),n.raws.before+=e.shift()[1];for(n.source.start=this.getPosition(e[0][2]),n.prop="";e.length;){var a=e[0][0];if(a===":"||a==="space"||a==="comment")break;n.prop+=e.shift()[1]}n.raws.between="";for(var u;e.length;)if(u=e.shift(),u[0]===":"){n.raws.between+=u[1];break}else u[0]==="word"&&/\w/.test(u[1])&&this.unknownWord([u]),n.raws.between+=u[1];(n.prop[0]==="_"||n.prop[0]==="*")&&(n.raws.before+=n.prop[0],n.prop=n.prop.slice(1));for(var l=[],c;e.length&&(c=e[0][0],!(c!=="space"&&c!=="comment"));)l.push(e.shift());this.precheckMissedSemicolon(e);for(var f=e.length-1;f>=0;f--){if(u=e[f],u[1].toLowerCase()==="!important"){n.important=!0;var h=this.stringFrom(e,f);h=this.spacesFromEnd(e)+h,h!==" !important"&&(n.raws.important=h);break}else if(u[1].toLowerCase()==="important"){for(var v=e.slice(0),p="",g=f;g>0;g--){var d=v[g][0];if(p.trim().indexOf("!")===0&&d!=="space")break;p=v.pop()[1]+p}p.trim().indexOf("!")===0&&(n.important=!0,n.raws.important=p,e=v)}if(u[0]!=="space"&&u[0]!=="comment")break}var y=e.some(function(w){return w[0]!=="space"&&w[0]!=="comment"});y&&(n.raws.between+=l.map(function(w){return w[1]}).join(""),l=[]),this.raw(n,"value",l.concat(e),r),n.value.includes(":")&&!r&&this.checkMissedSemicolon(e)},i.doubleColon=function(e){throw this.input.error("Double colon",{offset:e[2]},{offset:e[2]+e[1].length})},i.emptyRule=function(e){var r=new oa;this.init(r,e[2]),r.selector="",r.raws.between="",this.current=r},i.end=function(e){this.current.nodes&&this.current.nodes.length&&(this.current.raws.semicolon=this.semicolon),this.semicolon=!1,this.current.raws.after=(this.current.raws.after||"")+this.spaces,this.spaces="",this.current.parent?(this.current.source.end=this.getPosition(e[2]),this.current.source.end.offset++,this.current=this.current.parent):this.unexpectedClose(e)},i.endFile=function(){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())},i.freeSemicolon=function(e){if(this.spaces+=e[1],this.current.nodes){var r=this.current.nodes[this.current.nodes.length-1];r&&r.type==="rule"&&!r.raws.ownSemicolon&&(r.raws.ownSemicolon=this.spaces,this.spaces="")}},i.getPosition=function(e){var r=this.input.fromOffset(e);return{column:r.col,line:r.line,offset:e}},i.init=function(e,r){this.current.push(e),e.source={input:this.input,start:this.getPosition(r)},e.raws.before=this.spaces,this.spaces="",e.type!=="comment"&&(this.semicolon=!1)},i.other=function(e){for(var r=!1,n=null,s=!1,a=null,u=[],l=e[1].startsWith("--"),c=[],f=e;f;){if(n=f[0],c.push(f),n==="("||n==="[")a||(a=f),u.push(n==="("?")":"]");else if(l&&s&&n==="{")a||(a=f),u.push("}");else if(u.length===0)if(n===";")if(s){this.decl(c,l);return}else break;else if(n==="{"){this.rule(c);return}else if(n==="}"){this.tokenizer.back(c.pop()),r=!0;break}else n===":"&&(s=!0);else n===u[u.length-1]&&(u.pop(),u.length===0&&(a=null));f=this.tokenizer.nextToken()}if(this.tokenizer.endOfFile()&&(r=!0),u.length>0&&this.unclosedBracket(a),r&&s){if(!l)for(;c.length&&(f=c[c.length-1][0],!(f!=="space"&&f!=="comment"));)this.tokenizer.back(c.pop());this.decl(c,l)}else this.unknownWord(c)},i.parse=function(){for(var e;!this.tokenizer.endOfFile();)switch(e=this.tokenizer.nextToken(),e[0]){case"space":this.spaces+=e[1];break;case";":this.freeSemicolon(e);break;case"}":this.end(e);break;case"comment":this.comment(e);break;case"at-word":this.atrule(e);break;case"{":this.emptyRule(e);break;default:this.other(e);break}this.endFile()},i.precheckMissedSemicolon=function(){},i.raw=function(e,r,n,s){for(var a,u,l=n.length,c="",f=!0,h,v,p=0;p<l;p+=1)a=n[p],u=a[0],u==="space"&&p===l-1&&!s?f=!1:u==="comment"?(v=n[p-1]?n[p-1][0]:"empty",h=n[p+1]?n[p+1][0]:"empty",!sa[v]&&!sa[h]?c.slice(-1)===","?f=!1:c+=a[1]:f=!1):c+=a[1];if(!f){var g=n.reduce(function(d,y){return d+y[1]},"");e.raws[r]={raw:g,value:c}}e[r]=c},i.rule=function(e){e.pop();var r=new oa;this.init(r,e[0][2]),r.raws.between=this.spacesAndCommentsFromEnd(e),this.raw(r,"selector",e),this.current=r},i.spacesAndCommentsFromEnd=function(e){for(var r,n="";e.length&&(r=e[e.length-1][0],!(r!=="space"&&r!=="comment"));)n=e.pop()[1]+n;return n},i.spacesAndCommentsFromStart=function(e){for(var r,n="";e.length&&(r=e[0][0],!(r!=="space"&&r!=="comment"));)n+=e.shift()[1];return n},i.spacesFromEnd=function(e){for(var r,n="";e.length&&(r=e[e.length-1][0],r==="space");)n=e.pop()[1]+n;return n},i.stringFrom=function(e,r){for(var n="",s=r;s<e.length;s++)n+=e[s][1];return e.splice(r,e.length-r),n},i.unclosedBlock=function(){var e=this.current.source.start;throw this.input.error("Unclosed block",e.line,e.column)},i.unclosedBracket=function(e){throw this.input.error("Unclosed bracket",{offset:e[2]},{offset:e[2]+1})},i.unexpectedClose=function(e){throw this.input.error("Unexpected }",{offset:e[2]},{offset:e[2]+1})},i.unknownWord=function(e){throw this.input.error("Unknown word",{offset:e[0][2]},{offset:e[0][2]+e[0][1].length})},i.unnamedAtrule=function(e,r){throw this.input.error("At-rule without name",{offset:r[2]},{offset:r[2]+r[1].length})},t}(),dh=hh,ph=Ve,vh=dh,mh=Lr;function Zr(t,i){var o=new mh(t,i),e=new vh(o);try{e.parse()}catch(r){throw process.env.NODE_ENV!=="production"&&r.name==="CssSyntaxError"&&i&&i.from&&(/\.scss$/i.test(i.from)?r.message+="\nYou tried to parse SCSS with the standard CSS parser; try again with the postcss-scss parser":/\.sass/i.test(i.from)?r.message+="\nYou tried to parse Sass with the standard CSS parser; try again with the postcss-sass parser":/\.less$/i.test(i.from)&&(r.message+="\nYou tried to parse Less with the standard CSS parser; try again with the postcss-less parser")),r}return e.root}var Ri=Zr;Zr.default=Zr,ph.registerParse(Zr);var xe=De.isClean,gh=De.my,yh=Ds,wh=_r,Sh=Ve,bh=wi,Ch=Hs,aa=Ci,Ih=Ri,Oh=Bt,xh={atrule:"AtRule",comment:"Comment",decl:"Declaration",document:"Document",root:"Root",rule:"Rule"},Rh={AtRule:!0,AtRuleExit:!0,Comment:!0,CommentExit:!0,Declaration:!0,DeclarationExit:!0,Document:!0,DocumentExit:!0,Once:!0,OnceExit:!0,postcssPlugin:!0,prepare:!0,Root:!0,RootExit:!0,Rule:!0,RuleExit:!0},Eh={Once:!0,postcssPlugin:!0,prepare:!0},ct=0;function zt(t){return(typeof t=="undefined"?"undefined":N(t))==="object"&&typeof t.then=="function"}function ua(t){var i=!1,o=xh[t.type];return t.type==="decl"?i=t.prop.toLowerCase():t.type==="atrule"&&(i=t.name.toLowerCase()),i&&t.append?[o,o+"-"+i,ct,o+"Exit",o+"Exit-"+i]:i?[o,o+"-"+i,o+"Exit",o+"Exit-"+i]:t.append?[o,ct,o+"Exit"]:[o,o+"Exit"]}function la(t){var i;return t.type==="document"?i=["Document",ct,"DocumentExit"]:t.type==="root"?i=["Root",ct,"RootExit"]:i=ua(t),{eventIndex:0,events:i,iterator:0,node:t,visitorIndex:0,visitors:[]}}function Ei(t){return t[xe]=!1,t.nodes&&t.nodes.forEach(function(i){return Ei(i)}),t}var Ai={},ft=function(){function t(o,e,r){var n=this;this.stringified=!1,this.processed=!1;var s;if((typeof e=="undefined"?"undefined":N(e))==="object"&&e!==null&&(e.type==="root"||e.type==="document"))s=Ei(e);else if(T(e,t)||T(e,aa))s=Ei(e.root),e.map&&(typeof r.map=="undefined"&&(r.map={}),r.map.inline||(r.map.inline=!1),r.map.prev=e.map);else{var a=Ih;r.syntax&&(a=r.syntax.parse),r.parser&&(a=r.parser),a.parse&&(a=a.parse);try{s=a(e,r)}catch(u){this.processed=!0,this.error=u}s&&!s[gh]&&Sh.rebuild(s)}this.result=new aa(o,s,r),this.helpers=F({},Ai,{postcss:Ai,result:this.result}),this.plugins=this.processor.plugins.map(function(u){return(typeof u=="undefined"?"undefined":N(u))==="object"&&u.prepare?F({},u,u.prepare(n.result)):u})}var i=t.prototype;return i.async=function(){return this.error?Promise.reject(this.error):this.processed?Promise.resolve(this.result):(this.processing||(this.processing=this.runAsync()),this.processing)},i.catch=function(e){return this.async().catch(e)},i.finally=function(e){return this.async().then(e,e)},i.getAsyncError=function(){throw new Error("Use process(css).then(cb) to work with async plugins")},i.handleError=function(e,r){var n=this.result.lastPlugin;try{if(r&&r.addToError(e),this.error=e,e.name==="CssSyntaxError"&&!e.plugin)e.plugin=n.postcssPlugin,e.setMessage();else if(n.postcssVersion&&process.env.NODE_ENV!=="production"){var s=n.postcssPlugin,a=n.postcssVersion,u=this.result.processor.version,l=a.split("."),c=u.split(".");(l[0]!==c[0]||parseInt(l[1])>parseInt(c[1]))&&console.error("Unknown error from PostCSS plugin. Your current PostCSS version is "+u+", but "+s+" uses "+a+". Perhaps this is the source of the error below.")}}catch(f){console&&console.error&&console.error(f)}return e},i.prepareVisitors=function(){var e=this;this.listeners={};for(var r=function(c,f,h){e.listeners[f]||(e.listeners[f]=[]),e.listeners[f].push([c,h])},n=O(this.plugins),s;!(s=n()).done;){var a=s.value;if((typeof a=="undefined"?"undefined":N(a))==="object")for(var u in a){if(!Rh[u]&&/^[A-Z]/.test(u))throw new Error("Unknown event "+u+" in "+a.postcssPlugin+". Try to update PostCSS ("+this.processor.version+" now).");if(!Eh[u])if(N(a[u])==="object")for(var l in a[u])l==="*"?r(a,u,a[u][l]):r(a,u+"-"+l.toLowerCase(),a[u][l]);else typeof a[u]=="function"&&r(a,u,a[u])}}this.hasListener=Object.keys(this.listeners).length>0},i.runAsync=function(){var e=this;return gn(function(){var r,n,s,a,u,l,c,f,h,v,p,g;return Rt(this,function(d){switch(d.label){case 0:e.plugin=0,r=0,d.label=1;case 1:if(!(r<e.plugins.length))return[3,6];if(n=e.plugins[r],s=e.runOnRoot(n),!zt(s))return[3,5];d.label=2;case 2:return d.trys.push([2,4,,5]),[4,s];case 3:return d.sent(),[3,5];case 4:throw a=d.sent(),e.handleError(a);case 5:return r++,[3,1];case 6:if(e.prepareVisitors(),!e.hasListener)return[3,18];u=e.result.root,d.label=7;case 7:if(u[xe])return[3,14];u[xe]=!0,l=[la(u)],d.label=8;case 8:if(!(l.length>0))return[3,13];if(c=e.visitTick(l),!zt(c))return[3,12];d.label=9;case 9:return d.trys.push([9,11,,12]),[4,c];case 10:return d.sent(),[3,12];case 11:throw f=d.sent(),h=l[l.length-1].node,e.handleError(f,h);case 12:return[3,8];case 13:return[3,7];case 14:if(!e.listeners.OnceExit)return[3,18];v=function(){var y,w,S,b,C;return Rt(this,function(x){switch(x.label){case 0:y=g.value,w=y[0],S=y[1],e.result.lastPlugin=w,x.label=1;case 1:return x.trys.push([1,6,,7]),u.type!=="document"?[3,3]:(b=u.nodes.map(function(E){return S(E,e.helpers)}),[4,Promise.all(b)]);case 2:return x.sent(),[3,5];case 3:return[4,S(u,e.helpers)];case 4:x.sent(),x.label=5;case 5:return[3,7];case 6:throw C=x.sent(),e.handleError(C);case 7:return[2]}})},p=O(e.listeners.OnceExit),d.label=15;case 15:return(g=p()).done?[3,18]:[5,oo(v())];case 16:d.sent(),d.label=17;case 17:return[3,15];case 18:return e.processed=!0,[2,e.stringify()]}})})()},i.runOnRoot=function(e){var r=this;this.result.lastPlugin=e;try{if((typeof e=="undefined"?"undefined":N(e))==="object"&&e.Once){if(this.result.root.type==="document"){var n=this.result.root.nodes.map(function(s){return e.Once(s,r.helpers)});return zt(n[0])?Promise.all(n):n}return e.Once(this.result.root,this.helpers)}else if(typeof e=="function")return e(this.result.root,this.result)}catch(s){throw this.handleError(s)}},i.stringify=function(){if(this.error)throw this.error;if(this.stringified)return this.result;this.stringified=!0,this.sync();var e=this.result.opts,r=wh;e.syntax&&(r=e.syntax.stringify),e.stringifier&&(r=e.stringifier),r.stringify&&(r=r.stringify);var n=new yh(r,this.result.root,this.result.opts),s=n.generate();return this.result.css=s[0],this.result.map=s[1],this.result},i.sync=function(){if(this.error)throw this.error;if(this.processed)return this.result;if(this.processed=!0,this.processing)throw this.getAsyncError();for(var e=O(this.plugins),r;!(r=e()).done;){var n=r.value,s=this.runOnRoot(n);if(zt(s))throw this.getAsyncError()}if(this.prepareVisitors(),this.hasListener){for(var a=this.result.root;!a[xe];)a[xe]=!0,this.walkSync(a);if(this.listeners.OnceExit)if(a.type==="document")for(var u=O(a.nodes),l;!(l=u()).done;){var c=l.value;this.visitSync(this.listeners.OnceExit,c)}else this.visitSync(this.listeners.OnceExit,a)}return this.result},i.then=function(e,r){return process.env.NODE_ENV!=="production"&&("from"in this.opts||Ch("Without `from` option PostCSS could generate wrong source map and will not find Browserslist config. Set it to CSS file path or to `undefined` to prevent this warning.")),this.async().then(e,r)},i.toString=function(){return this.css},i.visitSync=function(e,r){for(var n=O(e),s;!(s=n()).done;){var a=s.value,u=a[0],l=a[1];this.result.lastPlugin=u;var c=void 0;try{c=l(r,this.helpers)}catch(f){throw this.handleError(f,r.proxyOf)}if(r.type!=="root"&&r.type!=="document"&&!r.parent)return!0;if(zt(c))throw this.getAsyncError()}},i.visitTick=function(e){var r=e[e.length-1],n=r.node,s=r.visitors;if(n.type!=="root"&&n.type!=="document"&&!n.parent){e.pop();return}if(s.length>0&&r.visitorIndex<s.length){var a=s[r.visitorIndex],u=a[0],l=a[1];r.visitorIndex+=1,r.visitorIndex===s.length&&(r.visitors=[],r.visitorIndex=0),this.result.lastPlugin=u;try{return l(n.toProxy(),this.helpers)}catch(p){throw this.handleError(p,n)}}if(r.iterator!==0){for(var c=r.iterator,f;f=n.nodes[n.indexes[c]];)if(n.indexes[c]+=1,!f[xe]){f[xe]=!0,e.push(la(f));return}r.iterator=0,delete n.indexes[c]}for(var h=r.events;r.eventIndex<h.length;){var v=h[r.eventIndex];if(r.eventIndex+=1,v===ct){n.nodes&&n.nodes.length&&(n[xe]=!0,r.iterator=n.getIterator());return}else if(this.listeners[v]){r.visitors=this.listeners[v];return}}e.pop()},i.walkSync=function(e){var r=this;e[xe]=!0;for(var n=ua(e),s=O(n),a;!(a=s()).done;){var u=a.value;if(u===ct)e.nodes&&e.each(function(c){c[xe]||r.walkSync(c)});else{var l=this.listeners[u];if(l&&this.visitSync(l,e.toProxy()))return}}},i.warnings=function(){return this.sync().warnings()},oe(t,[{key:"content",get:function(){return this.stringify().content}},{key:"css",get:function(){return this.stringify().css}},{key:"map",get:function(){return this.stringify().map}},{key:"messages",get:function(){return this.sync().messages}},{key:"opts",get:function(){return this.result.opts}},{key:"processor",get:function(){return this.result.processor}},{key:"root",get:function(){return this.sync().root}},{key:Symbol.toStringTag,get:function(){return"LazyResult"}}]),t}();ft.registerPostcss=function(t){Ai=t};var ca=ft;ft.default=ft,Oh.registerLazyResult(ft),bh.registerLazyResult(ft);var Ah=Ds,Mh=_r,kh=Hs,_h=Ri,Th=Ci,Mi=function(){function t(o,e,r){e=e.toString(),this.stringified=!1,this._processor=o,this._css=e,this._opts=r,this._map=void 0;var n,s=Mh;this.result=new Th(this._processor,n,this._opts),this.result.css=e;var a=this;Object.defineProperty(this.result,"root",{get:function(){return a.root}});var u=new Ah(s,n,this._opts,e);if(u.isMap()){var l=u.generate(),c=l[0],f=l[1];c&&(this.result.css=c),f&&(this.result.map=f)}else u.clearAnnotation(),this.result.css=u.css}var i=t.prototype;return i.async=function(){return this.error?Promise.reject(this.error):Promise.resolve(this.result)},i.catch=function(e){return this.async().catch(e)},i.finally=function(e){return this.async().then(e,e)},i.sync=function(){if(this.error)throw this.error;return this.result},i.then=function(e,r){return process.env.NODE_ENV!=="production"&&("from"in this._opts||kh("Without `from` option PostCSS could generate wrong source map and will not find Browserslist config. Set it to CSS file path or to `undefined` to prevent this warning.")),this.async().then(e,r)},i.toString=function(){return this._css},i.warnings=function(){return[]},oe(t,[{key:"content",get:function(){return this.result.css}},{key:"css",get:function(){return this.result.css}},{key:"map",get:function(){return this.result.map}},{key:"messages",get:function(){return[]}},{key:"opts",get:function(){return this.result.opts}},{key:"processor",get:function(){return this.result.processor}},{key:"root",get:function(){if(this._root)return this._root;var e,r=_h;try{e=r(this._css,this._opts)}catch(n){this.error=n}if(this.error)throw this.error;return this._root=e,e}},{key:Symbol.toStringTag,get:function(){return"NoWorkResult"}}]),t}(),Ph=Mi;Mi.default=Mi;var Nh=Ph,$h=ca,Dh=wi,Lh=Bt,Wt=function(){function t(o){o===void 0&&(o=[]),this.version="8.4.38",this.plugins=this.normalize(o)}var i=t.prototype;return i.normalize=function(e){for(var r=[],n=O(e),s;!(s=n()).done;){var a=s.value;if(a.postcss===!0?a=a():a.postcss&&(a=a.postcss),(typeof a=="undefined"?"undefined":N(a))==="object"&&Array.isArray(a.plugins))r=r.concat(a.plugins);else if((typeof a=="undefined"?"undefined":N(a))==="object"&&a.postcssPlugin)r.push(a);else if(typeof a=="function")r.push(a);else if((typeof a=="undefined"?"undefined":N(a))==="object"&&(a.parse||a.stringify)){if(process.env.NODE_ENV!=="production")throw new Error("PostCSS syntaxes cannot be used as plugins. Instead, please use one of the syntax/parser/stringifier options as outlined in your PostCSS runner documentation.")}else throw new Error(a+" is not a PostCSS plugin")}return r},i.process=function(e,r){return r===void 0&&(r={}),!this.plugins.length&&!r.parser&&!r.stringifier&&!r.syntax?new Nh(this,e,r):new $h(this,e,r)},i.use=function(e){return this.plugins=this.plugins.concat(this.normalize([e])),this},t}(),Fh=Wt;Wt.default=Wt,Lh.registerProcessor(Wt),Dh.registerProcessor(Wt);var Bh=Nr,Uh=Es,zh=Ur,Wh=Oi,Gh=Lr,jh=Bt,Vh=xi;function Gt(t,i){if(Array.isArray(t))return t.map(function(f){return Gt(f)});var o=t.inputs,e=Ot(t,["inputs"]);if(o){i=[];for(var r=O(o),n;!(n=r()).done;){var s=n.value,a=F({},s,{__proto__:Gh.prototype});a.map&&(a.map=F({},a.map,{__proto__:Uh.prototype})),i.push(a)}}if(e.nodes&&(e.nodes=t.nodes.map(function(f){return Gt(f,i)})),e.source){var u=e.source,l=u.inputId,c=Ot(u,["inputId"]);e.source=c,l!=null&&(e.source.input=i[l])}if(e.type==="root")return new jh(e);if(e.type==="decl")return new Bh(e);if(e.type==="rule")return new Vh(e);if(e.type==="comment")return new zh(e);if(e.type==="atrule")return new Wh(e);throw new Error("Unknown node type: "+t.type)}var Yh=Gt;Gt.default=Gt;var qh=ii,fa=Nr,Hh=ca,Jh=Ve,ki=Fh,Zh=_r,Kh=Yh,ha=wi,Xh=Js,da=Ur,pa=Oi,Qh=Ci,ed=Lr,td=Ri,rd=na,va=xi,ma=Bt,nd=Pr;function Y(){for(var t=arguments.length,i=new Array(t),o=0;o<t;o++)i[o]=arguments[o];return i.length===1&&Array.isArray(i[0])&&(i=i[0]),new ki(i)}Y.plugin=function(i,o){var e=!1;function r(){for(var s=arguments.length,a=new Array(s),u=0;u<s;u++)a[u]=arguments[u];console&&console.warn&&!e&&(e=!0,console.warn(i+": postcss.plugin was deprecated. Migration guide:\nhttps://evilmartians.com/chronicles/postcss-8-plugin-migration"),process.env.LANG&&process.env.LANG.startsWith("cn")&&console.warn(i+": \u91CC\u9762 postcss.plugin \u88AB\u5F03\u7528. \u8FC1\u79FB\u6307\u5357:\nhttps://www.w3ctech.com/topic/2226"));var l=o.apply(void 0,[].concat(a));return l.postcssPlugin=i,l.postcssVersion=new ki().version,l}var n;return Object.defineProperty(r,"postcss",{get:function(){return n||(n=r()),n}}),r.process=function(s,a,u){return Y([r(u)]).process(s,a)},r},Y.stringify=Zh,Y.parse=td,Y.fromJSON=Kh,Y.list=rd,Y.comment=function(t){return new da(t)},Y.atRule=function(t){return new pa(t)},Y.decl=function(t){return new fa(t)},Y.rule=function(t){return new va(t)},Y.root=function(t){return new ma(t)},Y.document=function(t){return new ha(t)},Y.CssSyntaxError=qh,Y.Declaration=fa,Y.Container=Jh,Y.Processor=ki,Y.Document=ha,Y.Comment=da,Y.Warning=Xh,Y.AtRule=pa,Y.Result=Qh,Y.Input=ed,Y.Rule=va,Y.Root=ma,Y.Node=nd,Hh.registerPostcss(Y);var id=Y;Y.default=Y;var X=vf(id);X.stringify,X.fromJSON,X.plugin,X.parse,X.list,X.document,X.comment,X.atRule,X.rule,X.decl,X.root,X.CssSyntaxError,X.Declaration,X.Container,X.Processor,X.Document,X.Comment,X.Warning,X.AtRule,X.Result,X.Input,X.Rule,X.Root,X.Node;var od=function(){function t(){for(var o=arguments.length,e=new Array(o),r=0;r<o;r++)e[r]=arguments[r];we(this,"parentElement",null),we(this,"parentNode",null),we(this,"ownerDocument"),we(this,"firstChild",null),we(this,"lastChild",null),we(this,"previousSibling",null),we(this,"nextSibling",null),we(this,"ELEMENT_NODE",1),we(this,"TEXT_NODE",3),we(this,"nodeType"),we(this,"nodeName"),we(this,"RRNodeType")}var i=t.prototype;return i.contains=function(e){if(T(e,t)){if(e.ownerDocument!==this.ownerDocument)return!1;if(e===this)return!0}else return!1;for(;e.parentNode;){if(e.parentNode===this)return!0;e=e.parentNode}return!1},i.appendChild=function(e){throw new Error("RRDomException: Failed to execute 'appendChild' on 'RRNode': This RRNode type does not support this method.")},i.insertBefore=function(e,r){throw new Error("RRDomException: Failed to execute 'insertBefore' on 'RRNode': This RRNode type does not support this method.")},i.removeChild=function(e){throw new Error("RRDomException: Failed to execute 'removeChild' on 'RRNode': This RRNode type does not support this method.")},i.toString=function(){return"RRNode"},oe(t,[{key:"childNodes",get:function(){for(var e=[],r=this.firstChild;r;)e.push(r),r=r.nextSibling;return e}}]),t}(),ga={Node:["childNodes","parentNode","parentElement","textContent"],ShadowRoot:["host","styleSheets"],Element:["shadowRoot","querySelector","querySelectorAll"],MutationObserver:[]},ya={Node:["contains","getRootNode"],ShadowRoot:["getSelection"],Element:[],MutationObserver:["constructor"]},Kr={},sd=function(){return!!globalThis.Zone};function _i(t){if(Kr[t])return Kr[t];var i=globalThis[t],o=i.prototype,e=t in ga?ga[t]:void 0,r=!!(e&&e.every(function(c){var f,h;return!!((h=(f=Object.getOwnPropertyDescriptor(o,c))==null?void 0:f.get)!=null&&h.toString().includes("[native code]"))})),n=t in ya?ya[t]:void 0,s=!!(n&&n.every(function(c){var f;return typeof o[c]=="function"&&((f=o[c])==null?void 0:f.toString().includes("[native code]"))}));if(r&&s&&!sd())return Kr[t]=i.prototype,i.prototype;try{var a=document.createElement("iframe");document.body.appendChild(a);var u=a.contentWindow;if(!u)return i.prototype;var l=u[t].prototype;return document.body.removeChild(a),l?Kr[t]=l:o}catch(c){return o}}var Ti={};function Le(t,i,o){var e,r=t+"."+String(o);if(Ti[r])return Ti[r].call(i);var n=_i(t),s=(e=Object.getOwnPropertyDescriptor(n,o))==null?void 0:e.get;return s?(Ti[r]=s,s.call(i)):i[o]}var Pi={};function wa(t,i,o){var e=t+"."+String(o);if(Pi[e])return Pi[e].bind(i);var r=_i(t),n=r[o];return typeof n!="function"?i[o]:(Pi[e]=n,n.bind(i))}function ad(t){return Le("Node",t,"childNodes")}function ud(t){return Le("Node",t,"parentNode")}function ld(t){return Le("Node",t,"parentElement")}function cd(t){return Le("Node",t,"textContent")}function fd(t,i){return wa("Node",t,"contains")(i)}function hd(t){return wa("Node",t,"getRootNode")()}function dd(t){return!t||!("host"in t)?null:Le("ShadowRoot",t,"host")}function pd(t){return t.styleSheets}function vd(t){return!t||!("shadowRoot"in t)?null:Le("Element",t,"shadowRoot")}function md(t,i){return Le("Element",t,"querySelector")(i)}function gd(t,i){return Le("Element",t,"querySelectorAll")(i)}function Sa(){return _i("MutationObserver").constructor}var $={childNodes:ad,parentNode:ud,parentElement:ld,textContent:cd,contains:fd,getRootNode:hd,host:dd,styleSheets:pd,shadowRoot:vd,querySelector:md,querySelectorAll:gd,mutationObserver:Sa};function ce(t,i,o){o===void 0&&(o=document);var e={capture:!0,passive:!0};return o.addEventListener(t,i,e),function(){return o.removeEventListener(t,i,e)}}var ht="Please stop import mirror directly. Instead of that,\r\nnow you can use replayer.getMirror() to access the mirror instance of a replayer,\r\nor you can use record.mirror to access the mirror instance during recording.",ba={map:{},getId:function(){return console.error(ht),-1},getNode:function(){return console.error(ht),null},removeNodeFromMap:function(){console.error(ht)},has:function(){return console.error(ht),!1},reset:function(){console.error(ht)}};typeof window!="undefined"&&window.Proxy&&window.Reflect&&(ba=new Proxy(ba,{get:function(i,o,e){return o==="map"&&console.error(ht),Reflect.get(i,o,e)}}));function jt(t,i,o){o===void 0&&(o={});var e=null,r=0;return function(){for(var n=arguments.length,s=new Array(n),a=0;a<n;a++)s[a]=arguments[a];var u=Date.now();!r&&o.leading===!1&&(r=u);var l=i-(u-r),c=this;l<=0||l>i?(e&&(clearTimeout(e),e=null),r=u,t.apply(c,s)):!e&&o.trailing!==!1&&(e=setTimeout(function(){r=o.leading===!1?0:Date.now(),e=null,t.apply(c,s)},l))}}function Xr(t,i,o,e,r){r===void 0&&(r=window);var n=r.Object.getOwnPropertyDescriptor(t,i);return r.Object.defineProperty(t,i,e?o:{set:function(a){var u=this;setTimeout(function(){o.set.call(u,a)},0),n&&n.set&&n.set.call(this,a)}}),function(){return Xr(t,i,n||{},!0)}}function dt(t,i,o){try{if(!(i in t))return function(){};var e=t[i],r=o(e);return typeof r=="function"&&(r.prototype=r.prototype||{},Object.defineProperties(r,{__rrweb_original__:{enumerable:!1,value:e}})),t[i]=r,function(){t[i]=e}}catch(n){return function(){}}}var Qr=Date.now;/[1-9][0-9]{12}/.test(Date.now().toString())||(Qr=function(){return new Date().getTime()});function Ca(t){var i,o,e,r,n=t.document;return{left:n.scrollingElement?n.scrollingElement.scrollLeft:t.pageXOffset!==void 0?t.pageXOffset:n.documentElement.scrollLeft||(n==null?void 0:n.body)&&((i=$.parentElement(n.body))==null?void 0:i.scrollLeft)||((o=n==null?void 0:n.body)==null?void 0:o.scrollLeft)||0,top:n.scrollingElement?n.scrollingElement.scrollTop:t.pageYOffset!==void 0?t.pageYOffset:(n==null?void 0:n.documentElement.scrollTop)||(n==null?void 0:n.body)&&((e=$.parentElement(n.body))==null?void 0:e.scrollTop)||((r=n==null?void 0:n.body)==null?void 0:r.scrollTop)||0}}function Ia(){return window.innerHeight||document.documentElement&&document.documentElement.clientHeight||document.body&&document.body.clientHeight}function Oa(){return window.innerWidth||document.documentElement&&document.documentElement.clientWidth||document.body&&document.body.clientWidth}function xa(t){if(!t)return null;var i=t.nodeType===t.ELEMENT_NODE?t:$.parentElement(t);return i}function fe(t,i,o,e){if(!t)return!1;var r=xa(t);if(!r)return!1;try{if(typeof i=="string"){if(r.classList.contains(i)||e&&r.closest("."+i)!==null)return!0}else if(cr(r,i,e))return!0}catch(n){}return!!(o&&(r.matches(o)||e&&r.closest(o)!==null))}function yd(t,i){return i.getId(t)!==-1}function Ni(t,i,o){return t.tagName==="TITLE"&&o.headTitleMutations?!0:i.getId(t)===Mt}function Ra(t,i){if(Et(t))return!1;var o=i.getId(t);if(!i.has(o))return!0;var e=$.parentNode(t);return e&&e.nodeType===t.DOCUMENT_NODE?!1:e?Ra(e,i):!0}function $i(t){return!!t.changedTouches}function wd(t){t===void 0&&(t=window),"NodeList"in t&&!t.NodeList.prototype.forEach&&(t.NodeList.prototype.forEach=Array.prototype.forEach),"DOMTokenList"in t&&!t.DOMTokenList.prototype.forEach&&(t.DOMTokenList.prototype.forEach=Array.prototype.forEach)}function Ea(t,i){return!!(t.nodeName==="IFRAME"&&i.getMeta(t))}function Aa(t,i){return!!(t.nodeName==="LINK"&&t.nodeType===t.ELEMENT_NODE&&t.getAttribute&&t.getAttribute("rel")==="stylesheet"&&i.getMeta(t))}function Di(t){return t?T(t,od)&&"shadowRoot"in t?!!t.shadowRoot:!!$.shadowRoot(t):!1}var Sd=function(){function t(){I(this,"id",1),I(this,"styleIDMap",new WeakMap),I(this,"idStyleMap",new Map)}var i=t.prototype;return i.getId=function(e){var r;return(r=this.styleIDMap.get(e))!=null?r:-1},i.has=function(e){return this.styleIDMap.has(e)},i.add=function(e,r){if(this.has(e))return this.getId(e);var n;return r===void 0?n=this.id++:n=r,this.styleIDMap.set(e,n),this.idStyleMap.set(n,e),n},i.getStyle=function(e){return this.idStyleMap.get(e)||null},i.reset=function(){this.styleIDMap=new WeakMap,this.idStyleMap=new Map,this.id=1},i.generateId=function(){return this.id++},t}();function Ma(t){var i,o=null;return"getRootNode"in t&&((i=$.getRootNode(t))==null?void 0:i.nodeType)===Node.DOCUMENT_FRAGMENT_NODE&&$.host($.getRootNode(t))&&(o=$.host($.getRootNode(t))),o}function bd(t){for(var i=t,o;o=Ma(i);)i=o;return i}function Cd(t){var i=t.ownerDocument;if(!i)return!1;var o=bd(t);return $.contains(i,o)}function ka(t){var i=t.ownerDocument;return i?$.contains(i,t)||Cd(t):!1}var D=function(t){return t[t.DomContentLoaded=0]="DomContentLoaded",t[t.Load=1]="Load",t[t.FullSnapshot=2]="FullSnapshot",t[t.IncrementalSnapshot=3]="IncrementalSnapshot",t[t.Meta=4]="Meta",t[t.Custom=5]="Custom",t[t.Plugin=6]="Plugin",t}(D||{}),k=function(t){return t[t.Mutation=0]="Mutation",t[t.MouseMove=1]="MouseMove",t[t.MouseInteraction=2]="MouseInteraction",t[t.Scroll=3]="Scroll",t[t.ViewportResize=4]="ViewportResize",t[t.Input=5]="Input",t[t.TouchMove=6]="TouchMove",t[t.MediaInteraction=7]="MediaInteraction",t[t.StyleSheetRule=8]="StyleSheetRule",t[t.CanvasMutation=9]="CanvasMutation",t[t.Font=10]="Font",t[t.Log=11]="Log",t[t.Drag=12]="Drag",t[t.StyleDeclaration=13]="StyleDeclaration",t[t.Selection=14]="Selection",t[t.AdoptedStyleSheet=15]="AdoptedStyleSheet",t[t.CustomElement=16]="CustomElement",t}(k||{}),de=function(t){return t[t.MouseUp=0]="MouseUp",t[t.MouseDown=1]="MouseDown",t[t.Click=2]="Click",t[t.ContextMenu=3]="ContextMenu",t[t.DblClick=4]="DblClick",t[t.Focus=5]="Focus",t[t.Blur=6]="Blur",t[t.TouchStart=7]="TouchStart",t[t.TouchMove_Departed=8]="TouchMove_Departed",t[t.TouchEnd=9]="TouchEnd",t[t.TouchCancel=10]="TouchCancel",t}(de||{}),ke=function(t){return t[t.Mouse=0]="Mouse",t[t.Pen=1]="Pen",t[t.Touch=2]="Touch",t}(ke||{}),pt=function(t){return t[t["2D"]=0]="2D",t[t.WebGL=1]="WebGL",t[t.WebGL2=2]="WebGL2",t}(pt||{}),vt=function(t){return t[t.Play=0]="Play",t[t.Pause=1]="Pause",t[t.Seeked=2]="Seeked",t[t.VolumeChange=3]="VolumeChange",t[t.RateChange=4]="RateChange",t}(vt||{}),_a=function(t){return t[t.Document=0]="Document",t[t.DocumentType=1]="DocumentType",t[t.Element=2]="Element",t[t.Text=3]="Text",t[t.CDATA=4]="CDATA",t[t.Comment=5]="Comment",t}(_a||{});function Ta(t){return"__ln"in t}var Id=function(){function t(){I(this,"length",0),I(this,"head",null),I(this,"tail",null)}var i=t.prototype;return i.get=function(e){if(e>=this.length)throw new Error("Position outside of list range");for(var r=this.head,n=0;n<e;n++)r=(r==null?void 0:r.next)||null;return r},i.addNode=function(e){var r={value:e,previous:null,next:null};if(e.__ln=r,e.previousSibling&&Ta(e.previousSibling)){var n=e.previousSibling.__ln.next;r.next=n,r.previous=e.previousSibling.__ln,e.previousSibling.__ln.next=r,n&&(n.previous=r)}else if(e.nextSibling&&Ta(e.nextSibling)&&e.nextSibling.__ln.previous){var s=e.nextSibling.__ln.previous;r.previous=s,r.next=e.nextSibling.__ln,e.nextSibling.__ln.previous=r,s&&(s.next=r)}else this.head&&(this.head.previous=r),r.next=this.head,this.head=r;r.next===null&&(this.tail=r),this.length++},i.removeNode=function(e){var r=e.__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),e.__ln&&delete e.__ln,this.length--)},t}(),Pa=function(t,i){return t+"@"+i},Od=function(){function t(){var o=this;I(this,"frozen",!1),I(this,"locked",!1),I(this,"texts",[]),I(this,"attributes",[]),I(this,"attributeMap",new WeakMap),I(this,"removes",[]),I(this,"mapRemoves",[]),I(this,"movedMap",{}),I(this,"addedSet",new Set),I(this,"movedSet",new Set),I(this,"droppedSet",new Set),I(this,"removesSubTreeCache",new Set),I(this,"mutationCb"),I(this,"blockClass"),I(this,"blockSelector"),I(this,"maskTextClass"),I(this,"maskTextSelector"),I(this,"inlineStylesheet"),I(this,"maskInputOptions"),I(this,"maskTextFn"),I(this,"maskInputFn"),I(this,"keepIframeSrcFn"),I(this,"recordCanvas"),I(this,"inlineImages"),I(this,"slimDOMOptions"),I(this,"dataURLOptions"),I(this,"doc"),I(this,"mirror"),I(this,"iframeManager"),I(this,"stylesheetManager"),I(this,"shadowDomManager"),I(this,"canvasManager"),I(this,"processedNodeManager"),I(this,"unattachedDoc"),I(this,"processMutations",function(e){e.forEach(o.processMutation),o.emit()}),I(this,"emit",function(){if(!(o.frozen||o.locked)){for(var e=[],r=new Set,n=new Id,s=function(M){for(var P=M,G=Mt;G===Mt;)P=P&&P.nextSibling,G=P&&o.mirror.getId(P);return G},a=function(M){var P=$.parentNode(M);if(!(!P||!ka(M))){var G=!1;if(M.nodeType===Node.TEXT_NODE){var pe=P.tagName;if(pe==="TEXTAREA")return;pe==="STYLE"&&o.addedSet.has(P)&&(G=!0)}var j=Et(P)?o.mirror.getId(Ma(M)):o.mirror.getId(P),me=s(M);if(j===-1||me===-1)return n.addNode(M);var he=ot(M,{doc:o.doc,mirror:o.mirror,blockClass:o.blockClass,blockSelector:o.blockSelector,maskTextClass:o.maskTextClass,maskTextSelector:o.maskTextSelector,skipChild:!0,newlyAddedElement:!0,inlineStylesheet:o.inlineStylesheet,maskInputOptions:o.maskInputOptions,maskTextFn:o.maskTextFn,maskInputFn:o.maskInputFn,slimDOMOptions:o.slimDOMOptions,dataURLOptions:o.dataURLOptions,recordCanvas:o.recordCanvas,inlineImages:o.inlineImages,onSerialize:function(Q){Ea(Q,o.mirror)&&o.iframeManager.addIframe(Q),Aa(Q,o.mirror)&&o.stylesheetManager.trackLinkElement(Q),Di(M)&&o.shadowDomManager.addShadowRoot($.shadowRoot(M),o.doc)},onIframeLoad:function(Q,se){o.iframeManager.attachIframe(Q,se),o.shadowDomManager.observeAttachShadow(Q)},onStylesheetLoad:function(Q,se){o.stylesheetManager.attachLinkElement(Q,se)},cssCaptured:G});he&&(e.push({parentId:j,nextId:me,node:he}),r.add(he.id))}};o.mapRemoves.length;)o.mirror.removeNodeFromMap(o.mapRemoves.shift());for(var u=O(o.movedSet),l;!(l=u()).done;){var c=l.value;Na(o.removesSubTreeCache,c,o.mirror)&&!o.movedSet.has($.parentNode(c))||a(c)}for(var f=O(o.addedSet),h;!(h=f()).done;){var v=h.value;!$a(o.droppedSet,v)&&!Na(o.removesSubTreeCache,v,o.mirror)||$a(o.movedSet,v)?a(v):o.droppedSet.add(v)}for(var p=null;n.length;){var g=null;if(p){var d=o.mirror.getId($.parentNode(p.value)),y=s(p.value);d!==-1&&y!==-1&&(g=p)}if(!g)for(var w=n.tail;w;){var S=w;if(w=w.previous,S){var b=o.mirror.getId($.parentNode(S.value)),C=s(S.value);if(C===-1)continue;if(b!==-1){g=S;break}else{var x=S.value,E=$.parentNode(x);if(E&&E.nodeType===Node.DOCUMENT_FRAGMENT_NODE){var R=$.host(E),_=o.mirror.getId(R);if(_!==-1){g=S;break}}}}}if(!g){for(;n.head;)n.removeNode(n.head.value);break}p=g.previous,n.removeNode(g.value),a(g.value)}var B={texts:o.texts.map(function(M){var P=M.node,G=$.parentNode(P);return G&&G.tagName==="TEXTAREA"&&o.genTextAreaValueMutation(G),{id:o.mirror.getId(P),value:M.value}}).filter(function(M){return!r.has(M.id)}).filter(function(M){return o.mirror.has(M.id)}),attributes:o.attributes.map(function(M){var P=M.attributes;if(typeof P.style=="string"){var G=JSON.stringify(M.styleDiff),pe=JSON.stringify(M._unchangedStyles);G.length<P.style.length&&(G+pe).split("var(").length===P.style.split("var(").length&&(P.style=M.styleDiff)}return{id:o.mirror.getId(M.node),attributes:P}}).filter(function(M){return!r.has(M.id)}).filter(function(M){return o.mirror.has(M.id)}),removes:o.removes,adds:e};!B.texts.length&&!B.attributes.length&&!B.removes.length&&!B.adds.length||(o.texts=[],o.attributes=[],o.attributeMap=new WeakMap,o.removes=[],o.addedSet=new Set,o.movedSet=new Set,o.droppedSet=new Set,o.removesSubTreeCache=new Set,o.movedMap={},o.mutationCb(B))}}),I(this,"genTextAreaValueMutation",function(e){var r=o.attributeMap.get(e);r||(r={node:e,attributes:{},styleDiff:{},_unchangedStyles:{}},o.attributes.push(r),o.attributeMap.set(e,r)),r.attributes.value=Array.from($.childNodes(e),function(n){return $.textContent(n)||""}).join("")}),I(this,"processMutation",function(e){if(!Ni(e.target,o.mirror,o.slimDOMOptions))switch(e.type){case"characterData":{var r=$.textContent(e.target);!fe(e.target,o.blockClass,o.blockSelector,!1)&&r!==e.oldValue&&o.texts.push({value:Co(e.target,o.maskTextClass,o.maskTextSelector,!0)&&r?o.maskTextFn?o.maskTextFn(r,xa(e.target)):r.replace(/[\S]/g,"*"):r,node:e.target});break}case"attributes":{var n=e.target,s=e.attributeName,a=e.target.getAttribute(s);if(s==="value"){var u=On(n);a=In({element:n,maskInputOptions:o.maskInputOptions,tagName:n.tagName,type:u,value:a,maskInputFn:o.maskInputFn})}if(fe(e.target,o.blockClass,o.blockSelector,!1)||a===e.oldValue)return;var l=o.attributeMap.get(e.target);if(n.tagName==="IFRAME"&&s==="src"&&!o.keepIframeSrcFn(a))if(!n.contentDocument)s="rr_src";else return;if(l||(l={node:e.target,attributes:{},styleDiff:{},_unchangedStyles:{}},o.attributes.push(l),o.attributeMap.set(e.target,l)),s==="type"&&n.tagName==="INPUT"&&(e.oldValue||"").toLowerCase()==="password"&&n.setAttribute("data-rr-is-password","true"),!bo(n.tagName,s))if(l.attributes[s]=So(o.doc,Ge(n.tagName),Ge(s),a),s==="style"){if(!o.unattachedDoc)try{o.unattachedDoc=document.implementation.createHTMLDocument()}catch(S){o.unattachedDoc=o.doc}var c=o.unattachedDoc.createElement("span");e.oldValue&&c.setAttribute("style",e.oldValue);for(var f=O(Array.from(n.style)),h;!(h=f()).done;){var v=h.value,p=n.style.getPropertyValue(v),g=n.style.getPropertyPriority(v);p!==c.style.getPropertyValue(v)||g!==c.style.getPropertyPriority(v)?g===""?l.styleDiff[v]=p:l.styleDiff[v]=[p,g]:l._unchangedStyles[v]=[p,g]}for(var d=O(Array.from(c.style)),y;!(y=d()).done;){var w=y.value;n.style.getPropertyValue(w)===""&&(l.styleDiff[w]=!1)}}else s==="open"&&n.tagName==="DIALOG"&&(n.matches("dialog:modal")?l.attributes.rr_open_mode="modal":l.attributes.rr_open_mode="non-modal");break}case"childList":{if(fe(e.target,o.blockClass,o.blockSelector,!0))return;if(e.target.tagName==="TEXTAREA"){o.genTextAreaValueMutation(e.target);return}e.addedNodes.forEach(function(S){return o.genAdds(S,e.target)}),e.removedNodes.forEach(function(S){var b=o.mirror.getId(S),C=Et(e.target)?o.mirror.getId($.host(e.target)):o.mirror.getId(e.target);fe(e.target,o.blockClass,o.blockSelector,!1)||Ni(S,o.mirror,o.slimDOMOptions)||!yd(S,o.mirror)||(o.addedSet.has(S)?(Li(o.addedSet,S),o.droppedSet.add(S)):o.addedSet.has(e.target)&&b===-1||Ra(e.target,o.mirror)||(o.movedSet.has(S)&&o.movedMap[Pa(b,C)]?Li(o.movedSet,S):(o.removes.push({parentId:C,id:b,isShadow:Et(e.target)&&At(e.target)?!0:void 0}),xd(S,o.removesSubTreeCache))),o.mapRemoves.push(S))});break}}}),I(this,"genAdds",function(e,r){if(!o.processedNodeManager.inOtherBuffer(e,o)&&!(o.addedSet.has(e)||o.movedSet.has(e))){if(o.mirror.hasNode(e)){if(Ni(e,o.mirror,o.slimDOMOptions))return;o.movedSet.add(e);var n=null;r&&o.mirror.hasNode(r)&&(n=o.mirror.getId(r)),n&&n!==-1&&(o.movedMap[Pa(o.mirror.getId(e),n)]=!0)}else o.addedSet.add(e),o.droppedSet.delete(e);fe(e,o.blockClass,o.blockSelector,!1)||($.childNodes(e).forEach(function(s){return o.genAdds(s)}),Di(e)&&$.childNodes($.shadowRoot(e)).forEach(function(s){o.processedNodeManager.add(s,o),o.genAdds(s,e)}))}})}var i=t.prototype;return i.init=function(e){var r=this;["mutationCb","blockClass","blockSelector","maskTextClass","maskTextSelector","inlineStylesheet","maskInputOptions","maskTextFn","maskInputFn","keepIframeSrcFn","recordCanvas","inlineImages","slimDOMOptions","dataURLOptions","doc","mirror","iframeManager","stylesheetManager","shadowDomManager","canvasManager","processedNodeManager"].forEach(function(n){r[n]=e[n]})},i.freeze=function(){this.frozen=!0,this.canvasManager.freeze()},i.unfreeze=function(){this.frozen=!1,this.canvasManager.unfreeze(),this.emit()},i.isFrozen=function(){return this.frozen},i.lock=function(){this.locked=!0,this.canvasManager.lock()},i.unlock=function(){this.locked=!1,this.canvasManager.unlock(),this.emit()},i.reset=function(){this.shadowDomManager.reset(),this.canvasManager.reset()},t}();function Li(t,i){t.delete(i),$.childNodes(i).forEach(function(o){return Li(t,o)})}function xd(t,i){for(var o=[t];o.length;){var e=o.pop();i.has(e)||(i.add(e),$.childNodes(e).forEach(function(r){return o.push(r)}))}}function Na(t,i,o){return t.size===0?!1:Rd(t,i)}function Rd(t,i,o){var e=$.parentNode(i);return e?t.has(e):!1}function $a(t,i){return t.size===0?!1:Da(t,i)}function Da(t,i){var o=$.parentNode(i);return o?t.has(o)?!0:Da(t,o):!1}var Vt;function Ed(t){Vt=t}function Ad(){Vt=void 0}var L=function(t){if(!Vt)return t;var i=function(){for(var o=arguments.length,e=new Array(o),r=0;r<o;r++)e[r]=arguments[r];try{return t.apply(void 0,[].concat(e))}catch(n){if(Vt&&Vt(n)===!0)return;throw n}};return i},Ye=[];function Yt(t){try{if("composedPath"in t){var i=t.composedPath();if(i.length)return i[0]}else if("path"in t&&t.path.length)return t.path[0]}catch(o){}return t&&t.target}function La(t,i){var o=new Od;Ye.push(o),o.init(t);var e=new(Sa())(L(o.processMutations.bind(o)));return e.observe(i,{attributes:!0,attributeOldValue:!0,characterData:!0,characterDataOldValue:!0,childList:!0,subtree:!0}),e}function Md(t){var i=t.mousemoveCb,o=t.sampling,e=t.doc,r=t.mirror;if(o.mousemove===!1)return function(){};var n=typeof o.mousemove=="number"?o.mousemove:50,s=typeof o.mousemoveCallback=="number"?o.mousemoveCallback:500,a=[],u,l=jt(L(function(h){var v=Date.now()-u;i(a.map(function(p){return p.timeOffset-=v,p}),h),a=[],u=null}),s),c=L(jt(L(function(h){var v=Yt(h),p=$i(h)?h.changedTouches[0]:h,g=p.clientX,d=p.clientY;u||(u=Qr()),a.push({x:g,y:d,id:r.getId(v),timeOffset:Qr()-u}),l(typeof DragEvent!="undefined"&&T(h,DragEvent)?k.Drag:T(h,MouseEvent)?k.MouseMove:k.TouchMove)}),n,{trailing:!1})),f=[ce("mousemove",c,e),ce("touchmove",c,e),ce("drag",c,e)];return L(function(){f.forEach(function(h){return h()})})}function kd(t){var i=t.mouseInteractionCb,o=t.doc,e=t.mirror,r=t.blockClass,n=t.blockSelector,s=t.sampling;if(s.mouseInteraction===!1)return function(){};var a=s.mouseInteraction===!0||s.mouseInteraction===void 0?{}:s.mouseInteraction,u=[],l=null,c=function(f){return function(h){var v=Yt(h);if(!fe(v,r,n,!0)){var p=null,g=f;if("pointerType"in h){switch(h.pointerType){case"mouse":p=ke.Mouse;break;case"touch":p=ke.Touch;break;case"pen":p=ke.Pen;break}p===ke.Touch?de[f]===de.MouseDown?g="TouchStart":de[f]===de.MouseUp&&(g="TouchEnd"):ke.Pen}else $i(h)&&(p=ke.Touch);p!==null?(l=p,(g.startsWith("Touch")&&p===ke.Touch||g.startsWith("Mouse")&&p===ke.Mouse)&&(p=null)):de[f]===de.Click&&(p=l,l=null);var d=$i(h)?h.changedTouches[0]:h;if(d){var y=e.getId(v),w=d.clientX,S=d.clientY;L(i)(F({type:de[g],id:y,x:w,y:S},p!==null&&{pointerType:p}))}}}};return Object.keys(de).filter(function(f){return Number.isNaN(Number(f))&&!f.endsWith("_Departed")&&a[f]!==!1}).forEach(function(f){var h=Ge(f),v=c(f);if(window.PointerEvent)switch(de[f]){case de.MouseDown:case de.MouseUp:h=h.replace("mouse","pointer");break;case de.TouchStart:case de.TouchEnd:return}u.push(ce(h,v,o))}),L(function(){u.forEach(function(f){return f()})})}function Fa(t){var i=t.scrollCb,o=t.doc,e=t.mirror,r=t.blockClass,n=t.blockSelector,s=t.sampling,a=L(jt(L(function(u){var l=Yt(u);if(!(!l||fe(l,r,n,!0))){var c=e.getId(l);if(l===o&&o.defaultView){var f=Ca(o.defaultView);i({id:c,x:f.left,y:f.top})}else i({id:c,x:l.scrollLeft,y:l.scrollTop})}}),s.scroll||100));return ce("scroll",a,o)}function _d(t,i){var o=t.viewportResizeCb,e=i.win,r=-1,n=-1,s=L(jt(L(function(){var a=Ia(),u=Oa();(r!==a||n!==u)&&(o({width:Number(u),height:Number(a)}),r=a,n=u)}),200));return ce("resize",s,e)}var Td=["INPUT","TEXTAREA","SELECT"],Ba=new WeakMap;function Pd(t){var i=t.inputCb,o=t.doc,e=t.mirror,r=t.blockClass,n=t.blockSelector,s=t.ignoreClass,a=t.ignoreSelector,u=t.maskInputOptions,l=t.maskInputFn,c=t.sampling,f=t.userTriggeredOnInput;function h(b){var C=Yt(b),x=b.isTrusted,E=C&&C.tagName;if(C&&E==="OPTION"&&(C=$.parentElement(C)),!(!C||!E||Td.indexOf(E)<0||fe(C,r,n,!0))&&!(C.classList.contains(s)||a&&C.matches(a))){var R=C.value,_=!1,B=On(C)||"";B==="radio"||B==="checkbox"?_=C.checked:(u[E.toLowerCase()]||u[B])&&(R=In({element:C,maskInputOptions:u,tagName:E,type:B,value:R,maskInputFn:l})),v(C,f?{text:R,isChecked:_,userTriggered:x}:{text:R,isChecked:_});var M=C.name;B==="radio"&&M&&_&&o.querySelectorAll('input[type="radio"][name="'+M+'"]').forEach(function(P){if(P!==C){var G=P.value;v(P,f?{text:G,isChecked:!_,userTriggered:!1}:{text:G,isChecked:!_})}})}}function v(b,C){var x=Ba.get(b);if(!x||x.text!==C.text||x.isChecked!==C.isChecked){Ba.set(b,C);var E=e.getId(b);L(i)(F({},C,{id:E}))}}var p=c.input==="last"?["change"]:["input","change"],g=p.map(function(b){return ce(b,L(h),o)}),d=o.defaultView;if(!d)return function(){g.forEach(function(b){return b()})};var y=d.Object.getOwnPropertyDescriptor(d.HTMLInputElement.prototype,"value"),w=[[d.HTMLInputElement.prototype,"value"],[d.HTMLInputElement.prototype,"checked"],[d.HTMLSelectElement.prototype,"value"],[d.HTMLTextAreaElement.prototype,"value"],[d.HTMLSelectElement.prototype,"selectedIndex"],[d.HTMLOptionElement.prototype,"selected"]];if(y&&y.set){var S;(S=g).push.apply(S,[].concat(w.map(function(b){return Xr(b[0],b[1],{set:function(){L(h)({target:this,isTrusted:!1})}},!1,d)})))}return L(function(){g.forEach(function(b){return b()})})}function en(t){var i=[];function o(e,r){if(tn("CSSGroupingRule")&&T(e.parentRule,CSSGroupingRule)||tn("CSSMediaRule")&&T(e.parentRule,CSSMediaRule)||tn("CSSSupportsRule")&&T(e.parentRule,CSSSupportsRule)||tn("CSSConditionRule")&&T(e.parentRule,CSSConditionRule)){var n=Array.from(e.parentRule.cssRules),s=n.indexOf(e);r.unshift(s)}else if(e.parentStyleSheet){var a=Array.from(e.parentStyleSheet.cssRules),u=a.indexOf(e);r.unshift(u)}return r}return o(t,i)}function Fe(t,i,o){var e,r;return t?(t.ownerNode?e=i.getId(t.ownerNode):r=o.getId(t),{styleId:r,id:e}):{}}function Nd(t,i){var o=t.styleSheetRuleCb,e=t.mirror,r=t.stylesheetManager,n=i.win;if(!n.CSSStyleSheet||!n.CSSStyleSheet.prototype)return function(){};var s=n.CSSStyleSheet.prototype.insertRule;n.CSSStyleSheet.prototype.insertRule=new Proxy(s,{apply:L(function(h,v,p){var g=p[0],d=p[1],y=Fe(v,e,r.styleMirror),w=y.id,S=y.styleId;return(w&&w!==-1||S&&S!==-1)&&o({id:w,styleId:S,adds:[{rule:g,index:d}]}),h.apply(v,p)})}),n.CSSStyleSheet.prototype.addRule=function(h,v,p){p===void 0&&(p=this.cssRules.length);var g=h+" { "+v+" }";return n.CSSStyleSheet.prototype.insertRule.apply(this,[g,p])};var a=n.CSSStyleSheet.prototype.deleteRule;n.CSSStyleSheet.prototype.deleteRule=new Proxy(a,{apply:L(function(h,v,p){var g=p[0],d=Fe(v,e,r.styleMirror),y=d.id,w=d.styleId;return(y&&y!==-1||w&&w!==-1)&&o({id:y,styleId:w,removes:[{index:g}]}),h.apply(v,p)})}),n.CSSStyleSheet.prototype.removeRule=function(h){return n.CSSStyleSheet.prototype.deleteRule.apply(this,[h])};var u;n.CSSStyleSheet.prototype.replace&&(u=n.CSSStyleSheet.prototype.replace,n.CSSStyleSheet.prototype.replace=new Proxy(u,{apply:L(function(h,v,p){var g=p[0],d=Fe(v,e,r.styleMirror),y=d.id,w=d.styleId;return(y&&y!==-1||w&&w!==-1)&&o({id:y,styleId:w,replace:g}),h.apply(v,p)})}));var l;n.CSSStyleSheet.prototype.replaceSync&&(l=n.CSSStyleSheet.prototype.replaceSync,n.CSSStyleSheet.prototype.replaceSync=new Proxy(l,{apply:L(function(h,v,p){var g=p[0],d=Fe(v,e,r.styleMirror),y=d.id,w=d.styleId;return(y&&y!==-1||w&&w!==-1)&&o({id:y,styleId:w,replaceSync:g}),h.apply(v,p)})}));var c={};rn("CSSGroupingRule")?c.CSSGroupingRule=n.CSSGroupingRule:(rn("CSSMediaRule")&&(c.CSSMediaRule=n.CSSMediaRule),rn("CSSConditionRule")&&(c.CSSConditionRule=n.CSSConditionRule),rn("CSSSupportsRule")&&(c.CSSSupportsRule=n.CSSSupportsRule));var f={};return Object.entries(c).forEach(function(h){var v=h[0],p=h[1];f[v]={insertRule:p.prototype.insertRule,deleteRule:p.prototype.deleteRule},p.prototype.insertRule=new Proxy(f[v].insertRule,{apply:L(function(g,d,y){var w=y[0],S=y[1],b=Fe(d.parentStyleSheet,e,r.styleMirror),C=b.id,x=b.styleId;return(C&&C!==-1||x&&x!==-1)&&o({id:C,styleId:x,adds:[{rule:w,index:[].concat(en(d),[S||0])}]}),g.apply(d,y)})}),p.prototype.deleteRule=new Proxy(f[v].deleteRule,{apply:L(function(g,d,y){var w=y[0],S=Fe(d.parentStyleSheet,e,r.styleMirror),b=S.id,C=S.styleId;return(b&&b!==-1||C&&C!==-1)&&o({id:b,styleId:C,removes:[{index:[].concat(en(d),[w])}]}),g.apply(d,y)})})}),L(function(){n.CSSStyleSheet.prototype.insertRule=s,n.CSSStyleSheet.prototype.deleteRule=a,u&&(n.CSSStyleSheet.prototype.replace=u),l&&(n.CSSStyleSheet.prototype.replaceSync=l),Object.entries(c).forEach(function(h){var v=h[0],p=h[1];p.prototype.insertRule=f[v].insertRule,p.prototype.deleteRule=f[v].deleteRule})})}function Ua(t,i){var o=t.mirror,e=t.stylesheetManager,r,n,s,a=null;i.nodeName==="#document"?a=o.getId(i):a=o.getId($.host(i));var u=i.nodeName==="#document"?(r=i.defaultView)==null?void 0:r.Document:(s=(n=i.ownerDocument)==null?void 0:n.defaultView)==null?void 0:s.ShadowRoot,l=u!=null&&u.prototype?Object.getOwnPropertyDescriptor(u==null?void 0:u.prototype,"adoptedStyleSheets"):void 0;return a===null||a===-1||!u||!l?function(){}:(Object.defineProperty(i,"adoptedStyleSheets",{configurable:l.configurable,enumerable:l.enumerable,get:function(){var f;return(f=l.get)==null?void 0:f.call(this)},set:function(f){var h,v=(h=l.set)==null?void 0:h.call(this,f);if(a!==null&&a!==-1)try{e.adoptStyleSheets(f,a)}catch(p){}return v}}),L(function(){Object.defineProperty(i,"adoptedStyleSheets",{configurable:l.configurable,enumerable:l.enumerable,get:l.get,set:l.set})}))}function $d(t,i){var o=t.styleDeclarationCb,e=t.mirror,r=t.ignoreCSSAttributes,n=t.stylesheetManager,s=i.win,a=s.CSSStyleDeclaration.prototype.setProperty;s.CSSStyleDeclaration.prototype.setProperty=new Proxy(a,{apply:L(function(l,c,f){var h,v=f[0],p=f[1],g=f[2];if(r.has(v))return a.apply(c,[v,p,g]);var d=Fe((h=c.parentRule)==null?void 0:h.parentStyleSheet,e,n.styleMirror),y=d.id,w=d.styleId;return(y&&y!==-1||w&&w!==-1)&&o({id:y,styleId:w,set:{property:v,value:p,priority:g},index:en(c.parentRule)}),l.apply(c,f)})});var u=s.CSSStyleDeclaration.prototype.removeProperty;return s.CSSStyleDeclaration.prototype.removeProperty=new Proxy(u,{apply:L(function(l,c,f){var h,v=f[0];if(r.has(v))return u.apply(c,[v]);var p=Fe((h=c.parentRule)==null?void 0:h.parentStyleSheet,e,n.styleMirror),g=p.id,d=p.styleId;return(g&&g!==-1||d&&d!==-1)&&o({id:g,styleId:d,remove:{property:v},index:en(c.parentRule)}),l.apply(c,f)})}),L(function(){s.CSSStyleDeclaration.prototype.setProperty=a,s.CSSStyleDeclaration.prototype.removeProperty=u})}function Dd(t){var i=t.mediaInteractionCb,o=t.blockClass,e=t.blockSelector,r=t.mirror,n=t.sampling,s=t.doc,a=L(function(l){return jt(L(function(c){var f=Yt(c);if(!(!f||fe(f,o,e,!0))){var h=f.currentTime,v=f.volume,p=f.muted,g=f.playbackRate,d=f.loop;i({type:l,id:r.getId(f),currentTime:h,volume:v,muted:p,playbackRate:g,loop:d})}}),n.media||500)}),u=[ce("play",a(vt.Play),s),ce("pause",a(vt.Pause),s),ce("seeked",a(vt.Seeked),s),ce("volumechange",a(vt.VolumeChange),s),ce("ratechange",a(vt.RateChange),s)];return L(function(){u.forEach(function(l){return l()})})}function Ld(t){var i=t.fontCb,o=t.doc,e=o.defaultView;if(!e)return function(){};var r=[],n=new WeakMap,s=e.FontFace;e.FontFace=function(l,c,f){var h=new s(l,c,f);return n.set(h,{family:l,buffer:typeof c!="string",descriptors:f,fontSource:typeof c=="string"?c:JSON.stringify(Array.from(new Uint8Array(c)))}),h};var a=dt(o.fonts,"add",function(u){return function(l){return setTimeout(L(function(){var c=n.get(l);c&&(i(c),n.delete(l))}),0),u.apply(this,[l])}});return r.push(function(){e.FontFace=s}),r.push(a),L(function(){r.forEach(function(u){return u()})})}function Fd(t){var i=t.doc,o=t.mirror,e=t.blockClass,r=t.blockSelector,n=t.selectionCb,s=!0,a=L(function(){var u=i.getSelection();if(!(!u||s&&(u!=null&&u.isCollapsed))){s=u.isCollapsed||!1;for(var l=[],c=u.rangeCount||0,f=0;f<c;f++){var h=u.getRangeAt(f),v=h.startContainer,p=h.startOffset,g=h.endContainer,d=h.endOffset,y=fe(v,e,r,!0)||fe(g,e,r,!0);y||l.push({start:o.getId(v),startOffset:p,end:o.getId(g),endOffset:d})}n({ranges:l})}});return a(),ce("selectionchange",a)}function Bd(t){var i=t.doc,o=t.customElementCb,e=i.defaultView;if(!e||!e.customElements)return function(){};var r=dt(e.customElements,"define",function(n){return function(s,a,u){try{o({define:{name:s}})}catch(l){console.warn("Custom element callback failed for "+s)}return n.apply(this,[s,a,u])}});return r}function Ud(t,i){var o=t.mutationCb,e=t.mousemoveCb,r=t.mouseInteractionCb,n=t.scrollCb,s=t.viewportResizeCb,a=t.inputCb,u=t.mediaInteractionCb,l=t.styleSheetRuleCb,c=t.styleDeclarationCb,f=t.canvasMutationCb,h=t.fontCb,v=t.selectionCb,p=t.customElementCb;t.mutationCb=function(){for(var g=arguments.length,d=new Array(g),y=0;y<g;y++)d[y]=arguments[y];if(i.mutation){var w;(w=i).mutation.apply(w,[].concat(d))}o.apply(void 0,[].concat(d))},t.mousemoveCb=function(){for(var g=arguments.length,d=new Array(g),y=0;y<g;y++)d[y]=arguments[y];if(i.mousemove){var w;(w=i).mousemove.apply(w,[].concat(d))}e.apply(void 0,[].concat(d))},t.mouseInteractionCb=function(){for(var g=arguments.length,d=new Array(g),y=0;y<g;y++)d[y]=arguments[y];if(i.mouseInteraction){var w;(w=i).mouseInteraction.apply(w,[].concat(d))}r.apply(void 0,[].concat(d))},t.scrollCb=function(){for(var g=arguments.length,d=new Array(g),y=0;y<g;y++)d[y]=arguments[y];if(i.scroll){var w;(w=i).scroll.apply(w,[].concat(d))}n.apply(void 0,[].concat(d))},t.viewportResizeCb=function(){for(var g=arguments.length,d=new Array(g),y=0;y<g;y++)d[y]=arguments[y];if(i.viewportResize){var w;(w=i).viewportResize.apply(w,[].concat(d))}s.apply(void 0,[].concat(d))},t.inputCb=function(){for(var g=arguments.length,d=new Array(g),y=0;y<g;y++)d[y]=arguments[y];if(i.input){var w;(w=i).input.apply(w,[].concat(d))}a.apply(void 0,[].concat(d))},t.mediaInteractionCb=function(){for(var g=arguments.length,d=new Array(g),y=0;y<g;y++)d[y]=arguments[y];if(i.mediaInteaction){var w;(w=i).mediaInteaction.apply(w,[].concat(d))}u.apply(void 0,[].concat(d))},t.styleSheetRuleCb=function(){for(var g=arguments.length,d=new Array(g),y=0;y<g;y++)d[y]=arguments[y];if(i.styleSheetRule){var w;(w=i).styleSheetRule.apply(w,[].concat(d))}l.apply(void 0,[].concat(d))},t.styleDeclarationCb=function(){for(var g=arguments.length,d=new Array(g),y=0;y<g;y++)d[y]=arguments[y];if(i.styleDeclaration){var w;(w=i).styleDeclaration.apply(w,[].concat(d))}c.apply(void 0,[].concat(d))},t.canvasMutationCb=function(){for(var g=arguments.length,d=new Array(g),y=0;y<g;y++)d[y]=arguments[y];if(i.canvasMutation){var w;(w=i).canvasMutation.apply(w,[].concat(d))}f.apply(void 0,[].concat(d))},t.fontCb=function(){for(var g=arguments.length,d=new Array(g),y=0;y<g;y++)d[y]=arguments[y];if(i.font){var w;(w=i).font.apply(w,[].concat(d))}h.apply(void 0,[].concat(d))},t.selectionCb=function(){for(var g=arguments.length,d=new Array(g),y=0;y<g;y++)d[y]=arguments[y];if(i.selection){var w;(w=i).selection.apply(w,[].concat(d))}v.apply(void 0,[].concat(d))},t.customElementCb=function(){for(var g=arguments.length,d=new Array(g),y=0;y<g;y++)d[y]=arguments[y];if(i.customElement){var w;(w=i).customElement.apply(w,[].concat(d))}p.apply(void 0,[].concat(d))}}function zd(t,i){i===void 0&&(i={});var o=t.doc.defaultView;if(!o)return function(){};Ud(t,i);var e;t.recordDOM&&(e=La(t,t.doc));var r=Md(t),n=kd(t),s=Fa(t),a=_d(t,{win:o}),u=Pd(t),l=Dd(t),c=function(){},f=function(){},h=function(){},v=function(){};t.recordDOM&&(c=Nd(t,{win:o}),f=Ua(t,t.doc),h=$d(t,{win:o}),t.collectFonts&&(v=Ld(t)));for(var p=Fd(t),g=Bd(t),d=[],y=O(t.plugins),w;!(w=y()).done;){var S=w.value;d.push(S.observer(S.callback,o,S.options))}return L(function(){Ye.forEach(function(b){return b.reset()}),e==null||e.disconnect(),r(),n(),s(),a(),u(),l(),c(),f(),h(),v(),p(),g(),d.forEach(function(b){return b()})})}function tn(t){return typeof window[t]!="undefined"}function rn(t){return!!(typeof window[t]!="undefined"&&window[t].prototype&&"insertRule"in window[t].prototype&&"deleteRule"in window[t].prototype)}for(var za=function(){function t(o){I(this,"iframeIdToRemoteIdMap",new WeakMap),I(this,"iframeRemoteIdToIdMap",new WeakMap),this.generateIdFn=o}var i=t.prototype;return i.getId=function(e,r,n,s){var a=n||this.getIdToRemoteIdMap(e),u=s||this.getRemoteIdToIdMap(e),l=a.get(r);return l||(l=this.generateIdFn(),a.set(r,l),u.set(l,r)),l},i.getIds=function(e,r){var n=this,s=this.getIdToRemoteIdMap(e),a=this.getRemoteIdToIdMap(e);return r.map(function(u){return n.getId(e,u,s,a)})},i.getRemoteId=function(e,r,n){var s=n||this.getRemoteIdToIdMap(e);if(typeof r!="number")return r;var a=s.get(r);return a||-1},i.getRemoteIds=function(e,r){var n=this,s=this.getRemoteIdToIdMap(e);return r.map(function(a){return n.getRemoteId(e,a,s)})},i.reset=function(e){if(!e){this.iframeIdToRemoteIdMap=new WeakMap,this.iframeRemoteIdToIdMap=new WeakMap;return}this.iframeIdToRemoteIdMap.delete(e),this.iframeRemoteIdToIdMap.delete(e)},i.getIdToRemoteIdMap=function(e){var r=this.iframeIdToRemoteIdMap.get(e);return r||(r=new Map,this.iframeIdToRemoteIdMap.set(e,r)),r},i.getRemoteIdToIdMap=function(e){var r=this.iframeRemoteIdToIdMap.get(e);return r||(r=new Map,this.iframeRemoteIdToIdMap.set(e,r)),r},t}(),Wd=function(){function t(o){I(this,"iframes",new WeakMap),I(this,"crossOriginIframeMap",new WeakMap),I(this,"crossOriginIframeMirror",new za(go)),I(this,"crossOriginIframeStyleMirror"),I(this,"crossOriginIframeRootIdMap",new WeakMap),I(this,"mirror"),I(this,"mutationCb"),I(this,"wrappedEmit"),I(this,"loadListener"),I(this,"stylesheetManager"),I(this,"recordCrossOriginIframes"),this.mutationCb=o.mutationCb,this.wrappedEmit=o.wrappedEmit,this.stylesheetManager=o.stylesheetManager,this.recordCrossOriginIframes=o.recordCrossOriginIframes,this.crossOriginIframeStyleMirror=new za(this.stylesheetManager.styleMirror.generateId.bind(this.stylesheetManager.styleMirror)),this.mirror=o.mirror,this.recordCrossOriginIframes&&window.addEventListener("message",this.handleMessage.bind(this))}var i=t.prototype;return i.addIframe=function(e){this.iframes.set(e,!0),e.contentWindow&&this.crossOriginIframeMap.set(e.contentWindow,e)},i.addLoadListener=function(e){this.loadListener=e},i.attachIframe=function(e,r){var n,s;this.mutationCb({adds:[{parentId:this.mirror.getId(e),nextId:null,node:r}],removes:[],texts:[],attributes:[],isAttachIframe:!0}),this.recordCrossOriginIframes&&((n=e.contentWindow)==null||n.addEventListener("message",this.handleMessage.bind(this))),(s=this.loadListener)==null||s.call(this,e),e.contentDocument&&e.contentDocument.adoptedStyleSheets&&e.contentDocument.adoptedStyleSheets.length>0&&this.stylesheetManager.adoptStyleSheets(e.contentDocument.adoptedStyleSheets,this.mirror.getId(e.contentDocument))},i.handleMessage=function(e){var r=e;if(!(r.data.type!=="rrweb"||r.origin!==r.data.origin)){var n=e.source;if(n){var s=this.crossOriginIframeMap.get(e.source);if(s){var a=this.transformCrossOriginEvent(s,r.data.event);a&&this.wrappedEmit(a,r.data.isCheckout)}}}},i.transformCrossOriginEvent=function(e,r){var n=this,s;switch(r.type){case D.FullSnapshot:{this.crossOriginIframeMirror.reset(e),this.crossOriginIframeStyleMirror.reset(e),this.replaceIdOnNode(r.data.node,e);var a=r.data.node.id;return this.crossOriginIframeRootIdMap.set(e,a),this.patchRootIdOnNode(r.data.node,a),{timestamp:r.timestamp,type:D.IncrementalSnapshot,data:{source:k.Mutation,adds:[{parentId:this.mirror.getId(e),nextId:null,node:r.data.node}],removes:[],texts:[],attributes:[],isAttachIframe:!0}}}case D.Meta:case D.Load:case D.DomContentLoaded:return!1;case D.Plugin:return r;case D.Custom:return this.replaceIds(r.data.payload,e,["id","parentId","previousId","nextId"]),r;case D.IncrementalSnapshot:switch(r.data.source){case k.Mutation:return r.data.adds.forEach(function(u){n.replaceIds(u,e,["parentId","nextId","previousId"]),n.replaceIdOnNode(u.node,e);var l=n.crossOriginIframeRootIdMap.get(e);l&&n.patchRootIdOnNode(u.node,l)}),r.data.removes.forEach(function(u){n.replaceIds(u,e,["parentId","id"])}),r.data.attributes.forEach(function(u){n.replaceIds(u,e,["id"])}),r.data.texts.forEach(function(u){n.replaceIds(u,e,["id"])}),r;case k.Drag:case k.TouchMove:case k.MouseMove:return r.data.positions.forEach(function(u){n.replaceIds(u,e,["id"])}),r;case k.ViewportResize:return!1;case k.MediaInteraction:case k.MouseInteraction:case k.Scroll:case k.CanvasMutation:case k.Input:return this.replaceIds(r.data,e,["id"]),r;case k.StyleSheetRule:case k.StyleDeclaration:return this.replaceIds(r.data,e,["id"]),this.replaceStyleIds(r.data,e,["styleId"]),r;case k.Font:return r;case k.Selection:return r.data.ranges.forEach(function(u){n.replaceIds(u,e,["start","end"])}),r;case k.AdoptedStyleSheet:return this.replaceIds(r.data,e,["id"]),this.replaceStyleIds(r.data,e,["styleIds"]),(s=r.data.styles)==null||s.forEach(function(u){n.replaceStyleIds(u,e,["styleId"])}),r}}return!1},i.replace=function(e,r,n,s){for(var a=O(s),u;!(u=a()).done;){var l=u.value;!Array.isArray(r[l])&&typeof r[l]!="number"||(Array.isArray(r[l])?r[l]=e.getIds(n,r[l]):r[l]=e.getId(n,r[l]))}return r},i.replaceIds=function(e,r,n){return this.replace(this.crossOriginIframeMirror,e,r,n)},i.replaceStyleIds=function(e,r,n){return this.replace(this.crossOriginIframeStyleMirror,e,r,n)},i.replaceIdOnNode=function(e,r){var n=this;this.replaceIds(e,r,["id","rootId"]),"childNodes"in e&&e.childNodes.forEach(function(s){n.replaceIdOnNode(s,r)})},i.patchRootIdOnNode=function(e,r){var n=this;e.type!==_a.Document&&!e.rootId&&(e.rootId=r),"childNodes"in e&&e.childNodes.forEach(function(s){n.patchRootIdOnNode(s,r)})},t}(),Gd=function(){function t(o){I(this,"shadowDoms",new WeakSet),I(this,"mutationCb"),I(this,"scrollCb"),I(this,"bypassOptions"),I(this,"mirror"),I(this,"restoreHandlers",[]),this.mutationCb=o.mutationCb,this.scrollCb=o.scrollCb,this.bypassOptions=o.bypassOptions,this.mirror=o.mirror,this.init()}var i=t.prototype;return i.init=function(){this.reset(),this.patchAttachShadow(Element,document)},i.addShadowRoot=function(e,r){var n=this;if(At(e)&&!this.shadowDoms.has(e)){this.shadowDoms.add(e);var s=La(F({},this.bypassOptions,{doc:r,mutationCb:this.mutationCb,mirror:this.mirror,shadowDomManager:this}),e);this.restoreHandlers.push(function(){return s.disconnect()}),this.restoreHandlers.push(Fa(F({},this.bypassOptions,{scrollCb:this.scrollCb,doc:e,mirror:this.mirror}))),setTimeout(function(){e.adoptedStyleSheets&&e.adoptedStyleSheets.length>0&&n.bypassOptions.stylesheetManager.adoptStyleSheets(e.adoptedStyleSheets,n.mirror.getId($.host(e))),n.restoreHandlers.push(Ua({mirror:n.mirror,stylesheetManager:n.bypassOptions.stylesheetManager},e))},0)}},i.observeAttachShadow=function(e){!e.contentWindow||!e.contentDocument||this.patchAttachShadow(e.contentWindow.Element,e.contentDocument)},i.patchAttachShadow=function(e,r){var n=this;this.restoreHandlers.push(dt(e.prototype,"attachShadow",function(s){return function(a){var u=s.call(this,a),l=$.shadowRoot(this);return l&&ka(this)&&n.addShadowRoot(l,r),u}}))},i.reset=function(){this.restoreHandlers.forEach(function(e){try{e()}catch(r){}}),this.restoreHandlers=[],this.shadowDoms=new WeakSet},t}(),mt="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",jd=typeof Uint8Array=="undefined"?[]:new Uint8Array(256),nn=0;nn<mt.length;nn++)jd[mt.charCodeAt(nn)]=nn;var Vd=function(i){var o=new Uint8Array(i),e,r=o.length,n="";for(e=0;e<r;e+=3)n+=mt[o[e]>>2],n+=mt[(o[e]&3)<<4|o[e+1]>>4],n+=mt[(o[e+1]&15)<<2|o[e+2]>>6],n+=mt[o[e+2]&63];return r%3===2?n=n.substring(0,n.length-1)+"=":r%3===1&&(n=n.substring(0,n.length-2)+"=="),n},Wa=new Map;function Yd(t,i){var o=Wa.get(t);return o||(o=new Map,Wa.set(t,o)),o.has(i)||o.set(i,[]),o.get(i)}var Ga=function(t,i,o){if(!(!t||!(Va(t,i)||(typeof t=="undefined"?"undefined":N(t))==="object"))){var e=t.constructor.name,r=Yd(o,e),n=r.indexOf(t);return n===-1&&(n=r.length,r.push(t)),n}};function on(t,i,o){if(T(t,Array))return t.map(function(p){return on(p,i,o)});if(t===null)return t;if(T(t,Float32Array)||T(t,Float64Array)||T(t,Int32Array)||T(t,Uint32Array)||T(t,Uint8Array)||T(t,Uint16Array)||T(t,Int16Array)||T(t,Int8Array)||T(t,Uint8ClampedArray)){var e=t.constructor.name;return{rr_type:e,args:[Object.values(t)]}}else if(T(t,ArrayBuffer)){var r=t.constructor.name,n=Vd(t);return{rr_type:r,base64:n}}else if(T(t,DataView)){var s=t.constructor.name;return{rr_type:s,args:[on(t.buffer,i,o),t.byteOffset,t.byteLength]}}else if(T(t,HTMLImageElement)){var a=t.constructor.name,u=t.src;return{rr_type:a,src:u}}else if(T(t,HTMLCanvasElement)){var l="HTMLImageElement",c=t.toDataURL();return{rr_type:l,src:c}}else if(T(t,ImageData)){var f=t.constructor.name;return{rr_type:f,args:[on(t.data,i,o),t.width,t.height]}}else if(Va(t,i)||(typeof t=="undefined"?"undefined":N(t))==="object"){var h=t.constructor.name,v=Ga(t,i,o);return{rr_type:h,index:v}}return t}var ja=function(t,i,o){return t.map(function(e){return on(e,i,o)})},Va=function(t,i){var o=["WebGLActiveInfo","WebGLBuffer","WebGLFramebuffer","WebGLProgram","WebGLRenderbuffer","WebGLShader","WebGLShaderPrecisionFormat","WebGLTexture","WebGLUniformLocation","WebGLVertexArrayObject","WebGLVertexArrayObjectOES"],e=o.filter(function(r){return typeof i[r]=="function"});return!!e.find(function(r){return T(t,i[r])})};function qd(t,i,o,e){for(var r=function(){var l=u.value;try{if(typeof i.CanvasRenderingContext2D.prototype[l]!="function")return"continue";var c=dt(i.CanvasRenderingContext2D.prototype,l,function(h){return function(){for(var v=this,p=arguments.length,g=new Array(p),d=0;d<p;d++)g[d]=arguments[d];return fe(this.canvas,o,e,!0)||setTimeout(function(){var y=ja(g,i,v);t(v.canvas,{type:pt["2D"],property:l,args:y})},0),h.apply(this,g)}});n.push(c)}catch(h){var f=Xr(i.CanvasRenderingContext2D.prototype,l,{set:function(p){t(this.canvas,{type:pt["2D"],property:l,args:[p],setter:!0})}});n.push(f)}},n=[],s=Object.getOwnPropertyNames(i.CanvasRenderingContext2D.prototype),a=O(s),u;!(u=a()).done;)r();return function(){n.forEach(function(l){return l()})}}function Hd(t){return t==="experimental-webgl"?"webgl":t}function Ya(t,i,o,e){var r=[];try{var n=dt(t.HTMLCanvasElement.prototype,"getContext",function(s){return function(a){for(var u=arguments.length,l=new Array(u>1?u-1:0),c=1;c<u;c++)l[c-1]=arguments[c];if(!fe(this,i,o,!0)){var f=Hd(a);if("__context"in this||(this.__context=f),e&&["webgl","webgl2"].includes(f))if(l[0]&&N(l[0])==="object"){var h=l[0];h.preserveDrawingBuffer||(h.preserveDrawingBuffer=!0)}else l.splice(0,1,{preserveDrawingBuffer:!0})}return s.apply(this,[].concat([a],l))}});r.push(n)}catch(s){console.error("failed to patch HTMLCanvasElement.prototype.getContext")}return function(){r.forEach(function(s){return s()})}}function qa(t,i,o,e,r,n){for(var s=function(){var f=c.value;if(["isContextLost","canvas","drawingBufferWidth","drawingBufferHeight"].includes(f))return"continue";try{if(typeof t[f]!="function")return"continue";var h=dt(t,f,function(p){return function(){for(var g=arguments.length,d=new Array(g),y=0;y<g;y++)d[y]=arguments[y];var w=p.apply(this,d);if(Ga(w,n,this),"tagName"in this.canvas&&!fe(this.canvas,e,r,!0)){var S=ja(d,n,this),b={type:i,property:f,args:S};o(this.canvas,b)}return w}});a.push(h)}catch(p){var v=Xr(t,f,{set:function(d){o(this.canvas,{type:i,property:f,args:[d],setter:!0})}});a.push(v)}},a=[],u=Object.getOwnPropertyNames(t),l=O(u),c;!(c=l()).done;)s();return a}function Jd(t,i,o,e){var r,n=[];if((r=n).push.apply(r,[].concat(qa(i.WebGLRenderingContext.prototype,pt.WebGL,t,o,e,i))),typeof i.WebGL2RenderingContext!="undefined"){var s;(s=n).push.apply(s,[].concat(qa(i.WebGL2RenderingContext.prototype,pt.WebGL2,t,o,e,i)))}return function(){n.forEach(function(a){return a()})}}var Ha="KGZ1bmN0aW9uKCkgewogICJ1c2Ugc3RyaWN0IjsKICB2YXIgY2hhcnMgPSAiQUJDREVGR0hJSktMTU5PUFFSU1RVVldYWVphYmNkZWZnaGlqa2xtbm9wcXJzdHV2d3h5ejAxMjM0NTY3ODkrLyI7CiAgdmFyIGxvb2t1cCA9IHR5cGVvZiBVaW50OEFycmF5ID09PSAidW5kZWZpbmVkIiA/IFtdIDogbmV3IFVpbnQ4QXJyYXkoMjU2KTsKICBmb3IgKHZhciBpID0gMDsgaSA8IGNoYXJzLmxlbmd0aDsgaSsrKSB7CiAgICBsb29rdXBbY2hhcnMuY2hhckNvZGVBdChpKV0gPSBpOwogIH0KICB2YXIgZW5jb2RlID0gZnVuY3Rpb24oYXJyYXlidWZmZXIpIHsKICAgIHZhciBieXRlcyA9IG5ldyBVaW50OEFycmF5KGFycmF5YnVmZmVyKSwgaTIsIGxlbiA9IGJ5dGVzLmxlbmd0aCwgYmFzZTY0ID0gIiI7CiAgICBmb3IgKGkyID0gMDsgaTIgPCBsZW47IGkyICs9IDMpIHsKICAgICAgYmFzZTY0ICs9IGNoYXJzW2J5dGVzW2kyXSA+PiAyXTsKICAgICAgYmFzZTY0ICs9IGNoYXJzWyhieXRlc1tpMl0gJiAzKSA8PCA0IHwgYnl0ZXNbaTIgKyAxXSA+PiA0XTsKICAgICAgYmFzZTY0ICs9IGNoYXJzWyhieXRlc1tpMiArIDFdICYgMTUpIDw8IDIgfCBieXRlc1tpMiArIDJdID4+IDZdOwogICAgICBiYXNlNjQgKz0gY2hhcnNbYnl0ZXNbaTIgKyAyXSAmIDYzXTsKICAgIH0KICAgIGlmIChsZW4gJSAzID09PSAyKSB7CiAgICAgIGJhc2U2NCA9IGJhc2U2NC5zdWJzdHJpbmcoMCwgYmFzZTY0Lmxlbmd0aCAtIDEpICsgIj0iOwogICAgfSBlbHNlIGlmIChsZW4gJSAzID09PSAxKSB7CiAgICAgIGJhc2U2NCA9IGJhc2U2NC5zdWJzdHJpbmcoMCwgYmFzZTY0Lmxlbmd0aCAtIDIpICsgIj09IjsKICAgIH0KICAgIHJldHVybiBiYXNlNjQ7CiAgfTsKICBjb25zdCBsYXN0QmxvYk1hcCA9IC8qIEBfX1BVUkVfXyAqLyBuZXcgTWFwKCk7CiAgY29uc3QgdHJhbnNwYXJlbnRCbG9iTWFwID0gLyogQF9fUFVSRV9fICovIG5ldyBNYXAoKTsKICBhc3luYyBmdW5jdGlvbiBnZXRUcmFuc3BhcmVudEJsb2JGb3Iod2lkdGgsIGhlaWdodCwgZGF0YVVSTE9wdGlvbnMpIHsKICAgIGNvbnN0IGlkID0gYCR7d2lkdGh9LSR7aGVpZ2h0fWA7CiAgICBpZiAoIk9mZnNjcmVlbkNhbnZhcyIgaW4gZ2xvYmFsVGhpcykgewogICAgICBpZiAodHJhbnNwYXJlbnRCbG9iTWFwLmhhcyhpZCkpIHJldHVybiB0cmFuc3BhcmVudEJsb2JNYXAuZ2V0KGlkKTsKICAgICAgY29uc3Qgb2Zmc2NyZWVuID0gbmV3IE9mZnNjcmVlbkNhbnZhcyh3aWR0aCwgaGVpZ2h0KTsKICAgICAgb2Zmc2NyZWVuLmdldENvbnRleHQoIjJkIik7CiAgICAgIGNvbnN0IGJsb2IgPSBhd2FpdCBvZmZzY3JlZW4uY29udmVydFRvQmxvYihkYXRhVVJMT3B0aW9ucyk7CiAgICAgIGNvbnN0IGFycmF5QnVmZmVyID0gYXdhaXQgYmxvYi5hcnJheUJ1ZmZlcigpOwogICAgICBjb25zdCBiYXNlNjQgPSBlbmNvZGUoYXJyYXlCdWZmZXIpOwogICAgICB0cmFuc3BhcmVudEJsb2JNYXAuc2V0KGlkLCBiYXNlNjQpOwogICAgICByZXR1cm4gYmFzZTY0OwogICAgfSBlbHNlIHsKICAgICAgcmV0dXJuICIiOwogICAgfQogIH0KICBjb25zdCB3b3JrZXIgPSBzZWxmOwogIHdvcmtlci5vbm1lc3NhZ2UgPSBhc3luYyBmdW5jdGlvbihlKSB7CiAgICBpZiAoIk9mZnNjcmVlbkNhbnZhcyIgaW4gZ2xvYmFsVGhpcykgewogICAgICBjb25zdCB7IGlkLCBiaXRtYXAsIHdpZHRoLCBoZWlnaHQsIGRhdGFVUkxPcHRpb25zIH0gPSBlLmRhdGE7CiAgICAgIGNvbnN0IHRyYW5zcGFyZW50QmFzZTY0ID0gZ2V0VHJhbnNwYXJlbnRCbG9iRm9yKAogICAgICAgIHdpZHRoLAogICAgICAgIGhlaWdodCwKICAgICAgICBkYXRhVVJMT3B0aW9ucwogICAgICApOwogICAgICBjb25zdCBvZmZzY3JlZW4gPSBuZXcgT2Zmc2NyZWVuQ2FudmFzKHdpZHRoLCBoZWlnaHQpOwogICAgICBjb25zdCBjdHggPSBvZmZzY3JlZW4uZ2V0Q29udGV4dCgiMmQiKTsKICAgICAgY3R4LmRyYXdJbWFnZShiaXRtYXAsIDAsIDApOwogICAgICBiaXRtYXAuY2xvc2UoKTsKICAgICAgY29uc3QgYmxvYiA9IGF3YWl0IG9mZnNjcmVlbi5jb252ZXJ0VG9CbG9iKGRhdGFVUkxPcHRpb25zKTsKICAgICAgY29uc3QgdHlwZSA9IGJsb2IudHlwZTsKICAgICAgY29uc3QgYXJyYXlCdWZmZXIgPSBhd2FpdCBibG9iLmFycmF5QnVmZmVyKCk7CiAgICAgIGNvbnN0IGJhc2U2NCA9IGVuY29kZShhcnJheUJ1ZmZlcik7CiAgICAgIGlmICghbGFzdEJsb2JNYXAuaGFzKGlkKSAmJiBhd2FpdCB0cmFuc3BhcmVudEJhc2U2NCA9PT0gYmFzZTY0KSB7CiAgICAgICAgbGFzdEJsb2JNYXAuc2V0KGlkLCBiYXNlNjQpOwogICAgICAgIHJldHVybiB3b3JrZXIucG9zdE1lc3NhZ2UoeyBpZCB9KTsKICAgICAgfQogICAgICBpZiAobGFzdEJsb2JNYXAuZ2V0KGlkKSA9PT0gYmFzZTY0KSByZXR1cm4gd29ya2VyLnBvc3RNZXNzYWdlKHsgaWQgfSk7CiAgICAgIHdvcmtlci5wb3N0TWVzc2FnZSh7CiAgICAgICAgaWQsCiAgICAgICAgdHlwZSwKICAgICAgICBiYXNlNjQsCiAgICAgICAgd2lkdGgsCiAgICAgICAgaGVpZ2h0CiAgICAgIH0pOwogICAgICBsYXN0QmxvYk1hcC5zZXQoaWQsIGJhc2U2NCk7CiAgICB9IGVsc2UgewogICAgICByZXR1cm4gd29ya2VyLnBvc3RNZXNzYWdlKHsgaWQ6IGUuZGF0YS5pZCB9KTsKICAgIH0KICB9Owp9KSgpOwovLyMgc291cmNlTWFwcGluZ1VSTD1pbWFnZS1iaXRtYXAtZGF0YS11cmwtd29ya2VyLUlKcEM3Z19iLmpzLm1hcAo=",Zd=function(t){return Uint8Array.from(atob(t),function(i){return i.charCodeAt(0)})},Ja=typeof window!="undefined"&&window.Blob&&new Blob([Zd(Ha)],{type:"text/javascript;charset=utf-8"});function Kd(t){var i;try{if(i=Ja&&(window.URL||window.webkitURL).createObjectURL(Ja),!i)throw"";var o=new Worker(i,{name:t==null?void 0:t.name});return o.addEventListener("error",function(){(window.URL||window.webkitURL).revokeObjectURL(i)}),o}catch(e){return new Worker("data:text/javascript;base64,"+Ha,{name:t==null?void 0:t.name})}finally{i&&(window.URL||window.webkitURL).revokeObjectURL(i)}}var Xd=function(){function t(o){var e=this;I(this,"pendingCanvasMutations",new Map),I(this,"rafStamps",{latestId:0,invokeId:null}),I(this,"mirror"),I(this,"mutationCb"),I(this,"resetObservers"),I(this,"frozen",!1),I(this,"locked",!1),I(this,"processMutation",function(f,h){var v=e.rafStamps.invokeId&&e.rafStamps.latestId!==e.rafStamps.invokeId;(v||!e.rafStamps.invokeId)&&(e.rafStamps.invokeId=e.rafStamps.latestId),e.pendingCanvasMutations.has(f)||e.pendingCanvasMutations.set(f,[]),e.pendingCanvasMutations.get(f).push(h)});var r=o.sampling,n=r===void 0?"all":r,s=o.win,a=o.blockClass,u=o.blockSelector,l=o.recordCanvas,c=o.dataURLOptions;this.mutationCb=o.mutationCb,this.mirror=o.mirror,l&&n==="all"&&this.initCanvasMutationObserver(s,a,u),l&&typeof n=="number"&&this.initCanvasFPSObserver(n,s,a,u,{dataURLOptions:c})}var i=t.prototype;return i.reset=function(){this.pendingCanvasMutations.clear(),this.resetObservers&&this.resetObservers()},i.freeze=function(){this.frozen=!0},i.unfreeze=function(){this.frozen=!1},i.lock=function(){this.locked=!0},i.unlock=function(){this.locked=!1},i.initCanvasFPSObserver=function(e,r,n,s,a){var u=this,l=Ya(r,n,s,!0),c=new Map,f=new Kd;f.onmessage=function(y){var w=y.data.id;if(c.set(w,!1),"base64"in y.data){var S=y.data,b=S.base64,C=S.type,x=S.width,E=S.height;u.mutationCb({id:w,type:pt["2D"],commands:[{property:"clearRect",args:[0,0,x,E]},{property:"drawImage",args:[{rr_type:"ImageBitmap",args:[{rr_type:"Blob",data:[{rr_type:"ArrayBuffer",base64:b}],type:C}]},0,0]}]})}};var h=1e3/e,v=0,p,g=function(){var y=[];return r.document.querySelectorAll("canvas").forEach(function(w){fe(w,n,s,!0)||y.push(w)}),y},d=function(y){if(v&&y-v<h){p=requestAnimationFrame(d);return}v=y;var w=u;g().forEach(gn(function(S){var b,C,x,E;return Rt(this,function(R){switch(R.label){case 0:return C=w.mirror.getId(S),c.get(C)?[2]:S.width===0||S.height===0?[2]:(c.set(C,!0),["webgl","webgl2"].includes(S.__context)&&(x=S.getContext(S.__context),((b=x==null?void 0:x.getContextAttributes())==null?void 0:b.preserveDrawingBuffer)===!1&&x.clear(x.COLOR_BUFFER_BIT)),[4,createImageBitmap(S)]);case 1:return E=R.sent(),f.postMessage({id:C,bitmap:E,width:S.width,height:S.height,dataURLOptions:a.dataURLOptions},[E]),[2]}})})),p=requestAnimationFrame(d)};p=requestAnimationFrame(d),this.resetObservers=function(){l(),cancelAnimationFrame(p)}},i.initCanvasMutationObserver=function(e,r,n){this.startRAFTimestamping(),this.startPendingCanvasMutationFlusher();var s=Ya(e,r,n,!1),a=qd(this.processMutation.bind(this),e,r,n),u=Jd(this.processMutation.bind(this),e,r,n);this.resetObservers=function(){s(),a(),u()}},i.startPendingCanvasMutationFlusher=function(){var e=this;requestAnimationFrame(function(){return e.flushPendingCanvasMutations()})},i.startRAFTimestamping=function(){var e=this,r=function(n){e.rafStamps.latestId=n,requestAnimationFrame(r)};requestAnimationFrame(r)},i.flushPendingCanvasMutations=function(){var e=this;this.pendingCanvasMutations.forEach(function(r,n){var s=e.mirror.getId(n);e.flushPendingCanvasMutationFor(n,s)}),requestAnimationFrame(function(){return e.flushPendingCanvasMutations()})},i.flushPendingCanvasMutationFor=function(e,r){if(!(this.frozen||this.locked)){var n=this.pendingCanvasMutations.get(e);if(!(!n||r===-1)){var s=n.map(function(u){u.type;var l=Ot(u,["type"]);return l}),a=n[0].type;this.mutationCb({id:r,type:a,commands:s}),this.pendingCanvasMutations.delete(e)}}},t}(),Qd=function(){function t(o){I(this,"trackedLinkElements",new WeakSet),I(this,"mutationCb"),I(this,"adoptedStyleSheetCb"),I(this,"styleMirror",new Sd),this.mutationCb=o.mutationCb,this.adoptedStyleSheetCb=o.adoptedStyleSheetCb}var i=t.prototype;return i.attachLinkElement=function(e,r){"_cssText"in r.attributes&&this.mutationCb({adds:[],removes:[],texts:[],attributes:[{id:r.id,attributes:r.attributes}]}),this.trackLinkElement(e)},i.trackLinkElement=function(e){this.trackedLinkElements.has(e)||(this.trackedLinkElements.add(e),this.trackStylesheetInLinkElement(e))},i.adoptStyleSheets=function(e,r){var n,s=function(){var f=c.value,h=void 0;n.styleMirror.has(f)?h=n.styleMirror.getId(f):(h=n.styleMirror.add(f),u.push({styleId:h,rules:Array.from(f.rules||CSSRule,function(v,p){return{rule:ho(v,f.href),index:p}})})),a.styleIds.push(h)};if(e.length!==0){for(var a={id:r,styleIds:[]},u=[],l=O(e),c;!(c=l()).done;)n=this,s();u.length>0&&(a.styles=u),this.adoptedStyleSheetCb(a)}},i.reset=function(){this.styleMirror.reset(),this.trackedLinkElements=new WeakSet},i.trackStylesheetInLinkElement=function(e){},t}(),ep=function(){function t(){I(this,"nodeMap",new WeakMap),I(this,"active",!1)}var i=t.prototype;return i.inOtherBuffer=function(e,r){var n=this.nodeMap.get(e);return n&&Array.from(n).some(function(s){return s!==r})},i.add=function(e,r){var n=this;this.active||(this.active=!0,requestAnimationFrame(function(){n.nodeMap=new WeakMap,n.active=!1})),this.nodeMap.set(e,(this.nodeMap.get(e)||new Set).add(r))},i.destroy=function(){},t}(),te,sn,Fi,an=!1;try{if(Array.from([1],function(t){return t*2})[0]!==2){var Bi=document.createElement("iframe");document.body.appendChild(Bi),Array.from=((so=Bi.contentWindow)==null?void 0:so.Array.from)||Array.from,document.body.removeChild(Bi)}}catch(t){console.debug("Unable to override Array.from",t)}var be=Ku();function Be(t){t===void 0&&(t={});var i=t.emit,o=t.checkoutEveryNms,e=t.checkoutEveryNth,r=t.blockClass,n=r===void 0?"rr-block":r,s=t.blockSelector,a=s===void 0?null:s,u=t.ignoreClass,l=u===void 0?"rr-ignore":u,c=t.ignoreSelector,f=c===void 0?null:c,h=t.maskTextClass,v=h===void 0?"rr-mask":h,p=t.maskTextSelector,g=p===void 0?null:p,d=t.inlineStylesheet,y=d===void 0?!0:d,w=t.maskAllInputs,S=t.maskInputOptions,b=t.slimDOMOptions,C=t.maskInputFn,x=t.maskTextFn,E=t.hooks,R=t.packFn,_=t.sampling,B=_===void 0?{}:_,M=t.dataURLOptions,P=M===void 0?{}:M,G=t.mousemoveWait,pe=t.recordDOM,j=pe===void 0?!0:pe,me=t.recordCanvas,he=me===void 0?!1:me,Q=t.recordCrossOriginIframes,se=Q===void 0?!1:Q,ge=t.recordAfter,He=ge===void 0?t.recordAfter==="DOMContentLoaded"?t.recordAfter:"load":ge,Ee=t.userTriggeredOnInput,St=Ee===void 0?!1:Ee,ye=t.collectFonts,Je=ye===void 0?!1:ye,z=t.inlineImages,Ze=z===void 0?!1:z,Ke=t.plugins,bt=t.keepIframeSrcFn,rr=bt===void 0?function(){return!1}:bt,nr=t.ignoreCSSAttributes,Xi=nr===void 0?new Set([]):nr,vn=t.errorHandler;Ed(vn);var We=se?window.parent===window:!0,Xe=!1;if(!We)try{window.parent.document&&(Xe=!1)}catch(q){Xe=!0}if(We&&!i)throw new Error("emit function is required");if(!We&&!Xe)return function(){};G!==void 0&&B.mousemove===void 0&&(B.mousemove=G),be.reset();var Ct=w===!0?{color:!0,date:!0,"datetime-local":!0,email:!0,month:!0,number:!0,range:!0,search:!0,tel:!0,text:!0,time:!0,url:!0,week:!0,textarea:!0,select:!0,password:!0}:S!==void 0?S:{password:!0},ir=b===!0||b==="all"?{script:!0,comment:!0,headFavicon:!0,headWhitespace:!0,headMetaSocial:!0,headMetaRobots:!0,headMetaHttpEquiv:!0,headMetaVerification:!0,headMetaAuthorship:b==="all",headMetaDescKeywords:b==="all",headTitleMutations:b==="all"}:b||{};wd();var It,Qe=0,Pe=function(q){for(var Se=O(Ke||[]),A;!(A=Se()).done;){var ee=A.value;ee.eventProcessor&&(q=ee.eventProcessor(q))}return R&&!Xe&&(q=R(q)),q};te=function(q,Se){var A,ee=q;if(ee.timestamp=Qr(),(A=Ye[0])!=null&&A.isFrozen()&&ee.type!==D.FullSnapshot&&!(ee.type===D.IncrementalSnapshot&&ee.data.source===k.Mutation)&&Ye.forEach(function(Dp){return Dp.unfreeze()}),We)i==null||i(Pe(ee),Se);else if(Xe){var Pp={type:"rrweb",event:Pe(ee),origin:window.location.origin,isCheckout:Se};window.parent.postMessage(Pp,"*")}if(ee.type===D.FullSnapshot)It=ee,Qe=0;else if(ee.type===D.IncrementalSnapshot){if(ee.data.source===k.Mutation&&ee.data.isAttachIframe)return;Qe++;var Np=e&&Qe>=e,$p=o&&ee.timestamp-It.timestamp>o;(Np||$p)&&sn(!0)}};for(var et=function(q){te({type:D.IncrementalSnapshot,data:F({source:k.Mutation},q)})},bu=function(q){return te({type:D.IncrementalSnapshot,data:F({source:k.Scroll},q)})},Cu=function(q){return te({type:D.IncrementalSnapshot,data:F({source:k.CanvasMutation},q)})},_p=function(q){return te({type:D.IncrementalSnapshot,data:F({source:k.AdoptedStyleSheet},q)})},tt=new Qd({mutationCb:et,adoptedStyleSheetCb:_p}),rt=new Wd({mirror:be,mutationCb:et,stylesheetManager:tt,recordCrossOriginIframes:se,wrappedEmit:te}),Tp=O(Ke||[]),Iu;!(Iu=Tp()).done;){var Ou=Iu.value;Ou.getMirror&&Ou.getMirror({nodeMirror:be,crossOriginIframeMirror:rt.crossOriginIframeMirror,crossOriginIframeStyleMirror:rt.crossOriginIframeStyleMirror})}var Qi=new ep;Fi=new Xd({recordCanvas:he,mutationCb:Cu,win:window,blockClass:n,blockSelector:a,mirror:be,sampling:B.canvas,dataURLOptions:P});var mn=new Gd({mutationCb:et,scrollCb:bu,bypassOptions:{blockClass:n,blockSelector:a,maskTextClass:v,maskTextSelector:g,inlineStylesheet:y,maskInputOptions:Ct,dataURLOptions:P,maskTextFn:x,maskInputFn:C,recordCanvas:he,inlineImages:Ze,sampling:B,slimDOMOptions:ir,iframeManager:rt,stylesheetManager:tt,canvasManager:Fi,keepIframeSrcFn:rr,processedNodeManager:Qi},mirror:be});sn=function(q){if(q===void 0&&(q=!1),!!j){te({type:D.Meta,data:{href:window.location.href,width:Oa(),height:Ia()}},q),tt.reset(),mn.init(),Ye.forEach(function(A){return A.lock()});var Se=bl(document,{mirror:be,blockClass:n,blockSelector:a,maskTextClass:v,maskTextSelector:g,inlineStylesheet:y,maskAllInputs:Ct,maskTextFn:x,maskInputFn:C,slimDOM:ir,dataURLOptions:P,recordCanvas:he,inlineImages:Ze,onSerialize:function(A){Ea(A,be)&&rt.addIframe(A),Aa(A,be)&&tt.trackLinkElement(A),Di(A)&&mn.addShadowRoot($.shadowRoot(A),document)},onIframeLoad:function(A,ee){rt.attachIframe(A,ee),mn.observeAttachShadow(A)},onStylesheetLoad:function(A,ee){tt.attachLinkElement(A,ee)},keepIframeSrcFn:rr});if(!Se)return console.warn("Failed to snapshot the document");te({type:D.FullSnapshot,data:{node:Se,initialOffset:Ca(window)}},q),Ye.forEach(function(A){return A.unlock()}),document.adoptedStyleSheets&&document.adoptedStyleSheets.length>0&&tt.adoptStyleSheets(document.adoptedStyleSheets,be.getId(document))}};try{var or=[],xu=function(q){var Se;return L(zd)({mutationCb:et,mousemoveCb:function(A,ee){return te({type:D.IncrementalSnapshot,data:{source:ee,positions:A}})},mouseInteractionCb:function(A){return te({type:D.IncrementalSnapshot,data:F({source:k.MouseInteraction},A)})},scrollCb:bu,viewportResizeCb:function(A){return te({type:D.IncrementalSnapshot,data:F({source:k.ViewportResize},A)})},inputCb:function(A){return te({type:D.IncrementalSnapshot,data:F({source:k.Input},A)})},mediaInteractionCb:function(A){return te({type:D.IncrementalSnapshot,data:F({source:k.MediaInteraction},A)})},styleSheetRuleCb:function(A){return te({type:D.IncrementalSnapshot,data:F({source:k.StyleSheetRule},A)})},styleDeclarationCb:function(A){return te({type:D.IncrementalSnapshot,data:F({source:k.StyleDeclaration},A)})},canvasMutationCb:Cu,fontCb:function(A){return te({type:D.IncrementalSnapshot,data:F({source:k.Font},A)})},selectionCb:function(A){te({type:D.IncrementalSnapshot,data:F({source:k.Selection},A)})},customElementCb:function(A){te({type:D.IncrementalSnapshot,data:F({source:k.CustomElement},A)})},blockClass:n,ignoreClass:l,ignoreSelector:f,maskTextClass:v,maskTextSelector:g,maskInputOptions:Ct,inlineStylesheet:y,sampling:B,recordDOM:j,recordCanvas:he,inlineImages:Ze,userTriggeredOnInput:St,collectFonts:Je,doc:q,maskInputFn:C,maskTextFn:x,keepIframeSrcFn:rr,blockSelector:a,slimDOMOptions:ir,dataURLOptions:P,mirror:be,iframeManager:rt,stylesheetManager:tt,shadowDomManager:mn,processedNodeManager:Qi,canvasManager:Fi,ignoreCSSAttributes:Xi,plugins:((Se=Ke==null?void 0:Ke.filter(function(A){return A.observer}))==null?void 0:Se.map(function(A){return{observer:A.observer,options:A.options,callback:function(ee){return te({type:D.Plugin,data:{plugin:A.name,payload:ee}})}}}))||[]},E)};rt.addLoadListener(function(q){try{or.push(xu(q.contentDocument))}catch(Se){console.warn(Se)}});var eo=function(){sn(),or.push(xu(document)),an=!0};return document.readyState==="interactive"||document.readyState==="complete"?eo():(or.push(ce("DOMContentLoaded",function(){te({type:D.DomContentLoaded,data:{}}),He==="DOMContentLoaded"&&eo()})),or.push(ce("load",function(){te({type:D.Load,data:{}}),He==="load"&&eo()},window))),function(){or.forEach(function(q){return q()}),Qi.destroy(),an=!1,Ad()}}catch(q){console.warn(q)}}Be.addCustomEvent=function(t,i){if(!an)throw new Error("please add custom event after start recording");te({type:D.Custom,data:{tag:t,payload:i}})},Be.freezePage=function(){Ye.forEach(function(t){return t.freeze()})},Be.takeFullSnapshot=function(t){if(!an)throw new Error("please take full snapshot after start recording");sn(t)},Be.mirror=be;var Za;(function(t){t[t.NotStarted=0]="NotStarted",t[t.Running=1]="Running",t[t.Stopped=2]="Stopped"})(Za||(Za={})),Be.addCustomEvent,Be.freezePage,Be.takeFullSnapshot;var Ka=W.setImmediate,Ue,Ui,zi,Xa=Object.prototype.toString,tp=typeof Ka!="undefined"?function(i){return Ka(i)}:setTimeout;try{Object.defineProperty({},"x",{}),Ue=function(i,o,e,r){return Object.defineProperty(i,o,{value:e,writable:!0,configurable:r!==!1})}}catch(t){Ue=function(o,e,r){return o[e]=r,o}}zi=function(){var i,o,e;function r(n,s){this.fn=n,this.self=s,this.next=void 0}return{add:function(s,a){e=new r(s,a),o?o.next=e:i=e,o=e,e=void 0},drain:function(){var s=i;for(i=o=Ui=void 0;s;)s.fn.call(s.self),s=s.next}}}();function un(t,i){zi.add(t,i),Ui||(Ui=tp(zi.drain))}function Qa(t){var i,o=typeof t;return t!==null&&(o==="object"||o==="function")&&(i=t.then),typeof i=="function"?i:!1}function Wi(){for(var t=0;t<this.chain.length;t++)rp(this,this.state===1?this.chain[t].success:this.chain[t].failure,this.chain[t]);this.chain.length=0}function rp(t,i,o){var e,r;try{i===!1?o.reject(t.msg):(i===!0?e=t.msg:e=i.call(void 0,t.msg),e===o.promise?o.reject(TypeError("Promise-chain cycle")):(r=Qa(e))?r.call(e,o.resolve,o.reject):o.resolve(e))}catch(n){o.reject(n)}}function eu(t){var i,o=this;if(!o.triggered){o.triggered=!0,o.def&&(o=o.def);try{(i=Qa(t))?un(function(){var e=new ru(o);try{i.call(t,function(){eu.apply(e,arguments)},function(){qt.apply(e,arguments)})}catch(r){qt.call(e,r)}}):(o.msg=t,o.state=1,o.chain.length>0&&un(Wi,o))}catch(e){qt.call(new ru(o),e)}}}function qt(t){var i=this;i.triggered||(i.triggered=!0,i.def&&(i=i.def),i.msg=t,i.state=2,i.chain.length>0&&un(Wi,i))}function tu(t,i,o,e){for(var r=0;r<i.length;r++)(function(s){t.resolve(i[s]).then(function(u){o(s,u)},e)})(r)}function ru(t){this.def=t,this.triggered=!1}function np(t){this.promise=t,this.state=0,this.triggered=!1,this.chain=[],this.msg=void 0}function ze(t){if(typeof t!="function")throw TypeError("Not a function");if(this.__NPO__!==0)throw TypeError("Not a promise");this.__NPO__=1;var i=new np(this);this.then=function(e,r){var n={success:typeof e=="function"?e:!0,failure:typeof r=="function"?r:!1};return n.promise=new this.constructor(function(a,u){if(typeof a!="function"||typeof u!="function")throw TypeError("Not a function");n.resolve=a,n.reject=u}),i.chain.push(n),i.state!==0&&un(Wi,i),n.promise},this.catch=function(e){return this.then(void 0,e)};try{t.call(void 0,function(e){eu.call(i,e)},function(e){qt.call(i,e)})}catch(o){qt.call(i,o)}}var nu=Ue({},"constructor",ze,!1);ze.prototype=nu,Ue(nu,"__NPO__",0,!1),Ue(ze,"resolve",function(i){var o=this;return i&&typeof i=="object"&&i.__NPO__===1?i:new o(function(r,n){if(typeof r!="function"||typeof n!="function")throw TypeError("Not a function");r(i)})}),Ue(ze,"reject",function(i){return new this(function(e,r){if(typeof e!="function"||typeof r!="function")throw TypeError("Not a function");r(i)})}),Ue(ze,"all",function(i){var o=this;return Xa.call(i)!=="[object Array]"?o.reject(TypeError("Not an array")):i.length===0?o.resolve([]):new o(function(r,n){if(typeof r!="function"||typeof n!="function")throw TypeError("Not a function");var s=i.length,a=Array(s),u=0;tu(o,i,function(c,f){a[c]=f,++u===s&&r(a)},n)})}),Ue(ze,"race",function(i){var o=this;return Xa.call(i)!=="[object Array]"?o.reject(TypeError("Not an array")):new o(function(r,n){if(typeof r!="function"||typeof n!="function")throw TypeError("Not a function");tu(o,i,function(a,u){r(u)},n)})});var U;typeof Promise!="undefined"&&Promise.toString().indexOf("[native code]")!==-1?U=Promise:U=ze;var Gi={LIB_VERSION:"2.63.0"},ln=24*60*60*1e3,ji=8*1e3,cn=Array.prototype,ip=Function.prototype,iu=Object.prototype,qe=cn.slice,Ht=iu.toString,fn=iu.hasOwnProperty,Jt=W.console,Zt=W.navigator,ve=W.document,hn=W.opera,ou=W.screen,gt=Zt.userAgent,Vi=ip.bind,su=cn.forEach,au=cn.indexOf,uu=cn.map,op=Array.isArray,Yi={},m={trim:function(t){return t.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"")}},Ce={log:function(){},warn:function(){},error:function(){},critical:function(){if(!m.isUndefined(Jt)&&Jt){var t=["Mixpanel error:"].concat(m.toArray(arguments));try{Jt.error.apply(Jt,t)}catch(i){m.each(t,function(o){Jt.error(o)})}}}},qi=function(t,i){return function(){return arguments[0]="["+i+"] "+arguments[0],t.apply(Ce,arguments)}},Kt=function(t){return{log:qi(Ce.log,t),error:qi(Ce.error,t),critical:qi(Ce.critical,t)}};m.bind=function(t,i){var o,e;if(Vi&&t.bind===Vi)return Vi.apply(t,qe.call(arguments,1));if(!m.isFunction(t))throw new TypeError;return o=qe.call(arguments,2),e=function(){if(!(this instanceof e))return t.apply(i,o.concat(qe.call(arguments)));var r={};r.prototype=t.prototype;var n=new r;r.prototype=null;var s=t.apply(n,o.concat(qe.call(arguments)));return Object(s)===s?s:n},e},m.each=function(t,i,o){if(t!=null){if(su&&t.forEach===su)t.forEach(i,o);else if(t.length===+t.length){for(var e=0,r=t.length;e<r;e++)if(e in t&&i.call(o,t[e],e,t)===Yi)return}else for(var n in t)if(fn.call(t,n)&&i.call(o,t[n],n,t)===Yi)return}},m.extend=function(t){return m.each(qe.call(arguments,1),function(i){for(var o in i)i[o]!==void 0&&(t[o]=i[o])}),t},m.isArray=op||function(t){return Ht.call(t)==="[object Array]"},m.isFunction=function(t){try{return/^\s*\bfunction\b/.test(t)}catch(i){return!1}},m.isArguments=function(t){return!!(t&&fn.call(t,"callee"))},m.toArray=function(t){return t?t.toArray?t.toArray():m.isArray(t)||m.isArguments(t)?qe.call(t):m.values(t):[]},m.map=function(t,i,o){if(uu&&t.map===uu)return t.map(i,o);var e=[];return m.each(t,function(r){e.push(i.call(o,r))}),e},m.keys=function(t){var i=[];return t===null||m.each(t,function(o,e){i[i.length]=e}),i},m.values=function(t){var i=[];return t===null||m.each(t,function(o){i[i.length]=o}),i},m.include=function(t,i){var o=!1;return t===null?o:au&&t.indexOf===au?t.indexOf(i)!=-1:(m.each(t,function(e){if(o||(o=e===i))return Yi}),o)},m.includes=function(t,i){return t.indexOf(i)!==-1},m.inherit=function(t,i){return t.prototype=new i,t.prototype.constructor=t,t.superclass=i.prototype,t},m.isObject=function(t){return t===Object(t)&&!m.isArray(t)},m.isEmptyObject=function(t){if(m.isObject(t)){for(var i in t)if(fn.call(t,i))return!1;return!0}return!1},m.isUndefined=function(t){return t===void 0},m.isString=function(t){return Ht.call(t)=="[object String]"},m.isDate=function(t){return Ht.call(t)=="[object Date]"},m.isNumber=function(t){return Ht.call(t)=="[object Number]"},m.isElement=function(t){return!!(t&&t.nodeType===1)},m.encodeDates=function(t){return m.each(t,function(i,o){m.isDate(i)?t[o]=m.formatDate(i):m.isObject(i)&&(t[o]=m.encodeDates(i))}),t},m.timestamp=function(){return Date.now=Date.now||function(){return+new Date},Date.now()},m.formatDate=function(t){function i(o){return o<10?"0"+o:o}return t.getUTCFullYear()+"-"+i(t.getUTCMonth()+1)+"-"+i(t.getUTCDate())+"T"+i(t.getUTCHours())+":"+i(t.getUTCMinutes())+":"+i(t.getUTCSeconds())},m.strip_empty_properties=function(t){var i={};return m.each(t,function(o,e){m.isString(o)&&o.length>0&&(i[e]=o)}),i},m.truncate=function(t,i){var o;return typeof t=="string"?o=t.slice(0,i):m.isArray(t)?(o=[],m.each(t,function(e){o.push(m.truncate(e,i))})):m.isObject(t)?(o={},m.each(t,function(e,r){o[r]=m.truncate(e,i)})):o=t,o},m.JSONEncode=function(){return function(t){var i=t,o=function(r){var n=/[\\"\x00-\x1f\x7f-\x9f\u00ad\u0600-\u0604\u070f\u17b4\u17b5\u200c-\u200f\u2028-\u202f\u2060-\u206f\ufeff\ufff0-\uffff]/g,s={"\b":"\\b"," ":"\\t","\n":"\\n","\f":"\\f","\r":"\\r",'"':'\\"',"\\":"\\\\"};return n.lastIndex=0,n.test(r)?'"'+r.replace(n,function(a){var u=s[a];return typeof u=="string"?u:"\\u"+("0000"+a.charCodeAt(0).toString(16)).slice(-4)})+'"':'"'+r+'"'},e=function(r,n){var s="",a=" ",u=0,l="",c="",f=0,h=s,v=[],p=n[r];switch(p&&typeof p=="object"&&typeof p.toJSON=="function"&&(p=p.toJSON(r)),typeof p){case"string":return o(p);case"number":return isFinite(p)?String(p):"null";case"boolean":case"null":return String(p);case"object":if(!p)return"null";if(s+=a,v=[],Ht.apply(p)==="[object Array]"){for(f=p.length,u=0;u<f;u+=1)v[u]=e(u,p)||"null";return c=v.length===0?"[]":s?"[\n"+s+v.join(",\n"+s)+"\n"+h+"]":"["+v.join(",")+"]",s=h,c}for(l in p)fn.call(p,l)&&(c=e(l,p),c&&v.push(o(l)+(s?": ":":")+c));return c=v.length===0?"{}":s?"{"+v.join(",")+h+"}":"{"+v.join(",")+"}",s=h,c}};return e("",{"":i})}}(),m.JSONDecode=function(){var t,i,o={'"':'"',"\\":"\\","/":"/",b:"\b",f:"\f",n:"\n",r:"\r",t:" "},e,r=function(v){var p=new SyntaxError(v);throw p.at=t,p.text=e,p},n=function(v){return v&&v!==i&&r("Expected '"+v+"' instead of '"+i+"'"),i=e.charAt(t),t+=1,i},s=function(){var v,p="";for(i==="-"&&(p="-",n("-"));i>="0"&&i<="9";)p+=i,n();if(i===".")for(p+=".";n()&&i>="0"&&i<="9";)p+=i;if(i==="e"||i==="E")for(p+=i,n(),(i==="-"||i==="+")&&(p+=i,n());i>="0"&&i<="9";)p+=i,n();if(v=+p,!isFinite(v))r("Bad number");else return v},a=function(){var v,p,g="",d;if(i==='"')for(;n();){if(i==='"')return n(),g;if(i==="\\")if(n(),i==="u"){for(d=0,p=0;p<4&&(v=parseInt(n(),16),!!isFinite(v));p+=1)d=d*16+v;g+=String.fromCharCode(d)}else if(typeof o[i]=="string")g+=o[i];else break;else g+=i}r("Bad string")},u=function(){for(;i&&i<=" ";)n()},l=function(){switch(i){case"t":return n("t"),n("r"),n("u"),n("e"),!0;case"f":return n("f"),n("a"),n("l"),n("s"),n("e"),!1;case"n":return n("n"),n("u"),n("l"),n("l"),null}r('Unexpected "'+i+'"')},c,f=function(){var v=[];if(i==="["){if(n("["),u(),i==="]")return n("]"),v;for(;i;){if(v.push(c()),u(),i==="]")return n("]"),v;n(","),u()}}r("Bad array")},h=function(){var v,p={};if(i==="{"){if(n("{"),u(),i==="}")return n("}"),p;for(;i;){if(v=a(),u(),n(":"),Object.hasOwnProperty.call(p,v)&&r('Duplicate key "'+v+'"'),p[v]=c(),u(),i==="}")return n("}"),p;n(","),u()}}r("Bad object")};return c=function(){switch(u(),i){case"{":return h();case"[":return f();case'"':return a();case"-":return s();default:return i>="0"&&i<="9"?s():l()}},function(v){var p;return e=v,t=0,i=" ",p=c(),u(),i&&r("Syntax error"),p}}(),m.base64Encode=function(t){var i="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=",o,e,r,n,s,a,u,l,c=0,f=0,h="",v=[];if(!t)return t;t=m.utf8Encode(t);do o=t.charCodeAt(c++),e=t.charCodeAt(c++),r=t.charCodeAt(c++),l=o<<16|e<<8|r,n=l>>18&63,s=l>>12&63,a=l>>6&63,u=l&63,v[f++]=i.charAt(n)+i.charAt(s)+i.charAt(a)+i.charAt(u);while(c<t.length);switch(h=v.join(""),t.length%3){case 1:h=h.slice(0,-2)+"==";break;case 2:h=h.slice(0,-1)+"=";break}return h},m.utf8Encode=function(t){t=(t+"").replace(/\r\n/g,"\n").replace(/\r/g,"\n");var i="",o,e,r=0,n;for(o=e=0,r=t.length,n=0;n<r;n++){var s=t.charCodeAt(n),a=null;s<128?e++:s>127&&s<2048?a=String.fromCharCode(s>>6|192,s&63|128):a=String.fromCharCode(s>>12|224,s>>6&63|128,s&63|128),a!==null&&(e>o&&(i+=t.substring(o,e)),i+=a,o=e=n+1)}return e>o&&(i+=t.substring(o,t.length)),i},m.UUID=function(){try{return W.crypto.randomUUID()}catch(o){for(var t=new Array(36),i=0;i<36;i++)t[i]=Math.floor(Math.random()*16);return t[14]=4,t[19]=t[19]&=-5,t[19]=t[19]|=8,t[8]=t[13]=t[18]=t[23]="-",m.map(t,function(e){return e.toString(16)}).join("")}};var lu=["ahrefsbot","ahrefssiteaudit","amazonbot","baiduspider","bingbot","bingpreview","chrome-lighthouse","facebookexternal","petalbot","pinterest","screaming frog","yahoo! slurp","yandex","adsbot-google","apis-google","duplexweb-google","feedfetcher-google","google favicon","google web preview","google-read-aloud","googlebot","googleweblight","mediapartners-google","storebot-google"];m.isBlockedUA=function(t){var i;for(t=t.toLowerCase(),i=0;i<lu.length;i++)if(t.indexOf(lu[i])!==-1)return!0;return!1},m.HTTPBuildQuery=function(t,i){var o,e,r=[];return m.isUndefined(i)&&(i="&"),m.each(t,function(n,s){o=encodeURIComponent(n.toString()),e=encodeURIComponent(s),r[r.length]=e+"="+o}),r.join(i)},m.getQueryParam=function(t,i){i=i.replace(/[[]/g,"\\[").replace(/[\]]/g,"\\]");var o="[\\?&]"+i+"=([^&#]*)",e=new RegExp(o),r=e.exec(t);if(r===null||r&&typeof r[1]!="string"&&r[1].length)return"";var n=r[1];try{n=decodeURIComponent(n)}catch(s){Ce.error("Skipping decoding for malformed query param: "+n)}return n.replace(/\+/g," ")},m.cookie={get:function(t){for(var i=t+"=",o=ve.cookie.split(";"),e=0;e<o.length;e++){for(var r=o[e];r.charAt(0)==" ";)r=r.substring(1,r.length);if(r.indexOf(i)===0)return decodeURIComponent(r.substring(i.length,r.length))}return null},parse:function(t){var i;try{i=m.JSONDecode(m.cookie.get(t))||{}}catch(o){}return i},set_seconds:function(t,i,o,e,r,n,s){var a="",u="",l="";if(s)a="; domain="+s;else if(e){var c=hu(ve.location.hostname);a=c?"; domain=."+c:""}if(o){var f=new Date;f.setTime(f.getTime()+o*1e3),u="; expires="+f.toGMTString()}n&&(r=!0,l="; SameSite=None"),r&&(l+="; secure"),ve.cookie=t+"="+encodeURIComponent(i)+u+"; path=/"+a+l},set:function(t,i,o,e,r,n,s){var a="",u="",l="";if(s)a="; domain="+s;else if(e){var c=hu(ve.location.hostname);a=c?"; domain=."+c:""}if(o){var f=new Date;f.setTime(f.getTime()+o*24*60*60*1e3),u="; expires="+f.toGMTString()}n&&(r=!0,l="; SameSite=None"),r&&(l+="; secure");var h=t+"="+encodeURIComponent(i)+u+"; path=/"+a+l;return ve.cookie=h,h},remove:function(t,i,o){m.cookie.set(t,"",-1,i,!1,!1,o)}};var cu=function(t){var i=!0;try{var o="__mplss_"+Zi(8),e="xyz";t.setItem(o,e),t.getItem(o)!==e&&(i=!1),t.removeItem(o)}catch(r){i=!1}return i},Hi=null,Xt=function(t,i){return Hi!==null&&!i?Hi:Hi=cu(t||W.localStorage)},Ji=null,sp=function(t,i){return Ji!==null&&!i?Ji:Ji=cu(t||W.sessionStorage)};function fu(t,i,o){var e=function(r){Ce.error(i+" error: "+r)};return{is_supported:function(r){var n=o(t,r);return n||Ce.error(i+" unsupported"),n},error:e,get:function(r){try{return t.getItem(r)}catch(n){e(n)}return null},parse:function(r){try{return m.JSONDecode(t.getItem(r))||{}}catch(n){}return null},set:function(r,n){try{t.setItem(r,n)}catch(s){e(s)}},remove:function(r){try{t.removeItem(r)}catch(n){e(n)}}}}m.localStorage=fu(W.localStorage,"localStorage",Xt),m.sessionStorage=fu(W.sessionStorage,"sessionStorage",sp),m.register_event=function(){var t=function(e,r,n,s,a){if(!e){Ce.error("No valid element provided to register_event");return}if(e.addEventListener&&!s)e.addEventListener(r,n,!!a);else{var u="on"+r,l=e[u];e[u]=i(e,n,l)}};function i(e,r,n){var s=function(a){if(a=a||o(W.event),!!a){var u=!0,l,c;return m.isFunction(n)&&(l=n(a)),c=r.call(e,a),(l===!1||c===!1)&&(u=!1),u}};return s}function o(e){return e&&(e.preventDefault=o.preventDefault,e.stopPropagation=o.stopPropagation),e}return o.preventDefault=function(){this.returnValue=!1},o.stopPropagation=function(){this.cancelBubble=!0},t}();var ap=new RegExp('^(\\w*)\\[(\\w+)([=~\\|\\^\\$\\*]?)=?"?([^\\]"]*)"?\\]$');m.dom_query=function(){function t(r){return r.all?r.all:r.getElementsByTagName("*")}var i=/[\t\r\n]/g;function o(r,n){var s=" "+n+" ";return(" "+r.className+" ").replace(i," ").indexOf(s)>=0}function e(r){if(!ve.getElementsByTagName)return[];var n=r.split(" "),s,a,u,l,c,f,h,v,p,g,d=[ve];for(f=0;f<n.length;f++){if(s=n[f].replace(/^\s+/,"").replace(/\s+$/,""),s.indexOf("#")>-1){a=s.split("#"),u=a[0];var y=a[1],w=ve.getElementById(y);if(!w||u&&w.nodeName.toLowerCase()!=u)return[];d=[w];continue}if(s.indexOf(".")>-1){a=s.split("."),u=a[0];var S=a[1];for(u||(u="*"),l=[],c=0,h=0;h<d.length;h++)for(u=="*"?p=t(d[h]):p=d[h].getElementsByTagName(u),v=0;v<p.length;v++)l[c++]=p[v];for(d=[],g=0,h=0;h<l.length;h++)l[h].className&&m.isString(l[h].className)&&o(l[h],S)&&(d[g++]=l[h]);continue}var b=s.match(ap);if(b){u=b[1];var C=b[2],x=b[3],E=b[4];for(u||(u="*"),l=[],c=0,h=0;h<d.length;h++)for(u=="*"?p=t(d[h]):p=d[h].getElementsByTagName(u),v=0;v<p.length;v++)l[c++]=p[v];d=[],g=0;var R;switch(x){case"=":R=function(_){return _.getAttribute(C)==E};break;case"~":R=function(_){return _.getAttribute(C).match(new RegExp("\\b"+E+"\\b"))};break;case"|":R=function(_){return _.getAttribute(C).match(new RegExp("^"+E+"-?"))};break;case"^":R=function(_){return _.getAttribute(C).indexOf(E)===0};break;case"$":R=function(_){return _.getAttribute(C).lastIndexOf(E)==_.getAttribute(C).length-E.length};break;case"*":R=function(_){return _.getAttribute(C).indexOf(E)>-1};break;default:R=function(_){return _.getAttribute(C)}}for(d=[],g=0,h=0;h<l.length;h++)R(l[h])&&(d[g++]=l[h]);continue}for(u=s,l=[],c=0,h=0;h<d.length;h++)for(p=d[h].getElementsByTagName(u),v=0;v<p.length;v++)l[c++]=p[v];d=l}return d}return function(r){return m.isElement(r)?[r]:m.isObject(r)&&!m.isUndefined(r.length)?r:e.call(this,r)}}();var up=["utm_source","utm_medium","utm_campaign","utm_content","utm_term","utm_id","utm_source_platform","utm_campaign_id","utm_creative_format","utm_marketing_tactic"],lp=["dclid","fbclid","gclid","ko_click_id","li_fat_id","msclkid","sccid","ttclid","twclid","wbraid"];m.info={campaignParams:function(t){var i="",o={};return m.each(up,function(e){i=m.getQueryParam(ve.URL,e),i.length?o[e]=i:t!==void 0&&(o[e]=t)}),o},clickParams:function(){var t="",i={};return m.each(lp,function(o){t=m.getQueryParam(ve.URL,o),t.length&&(i[o]=t)}),i},marketingParams:function(){return m.extend(m.info.campaignParams(),m.info.clickParams())},searchEngine:function(t){return t.search("https?://(.*)google.([^/?]*)")===0?"google":t.search("https?://(.*)bing.com")===0?"bing":t.search("https?://(.*)yahoo.com")===0?"yahoo":t.search("https?://(.*)duckduckgo.com")===0?"duckduckgo":null},searchInfo:function(t){var i=m.info.searchEngine(t),o=i!="yahoo"?"q":"p",e={};if(i!==null){e.$search_engine=i;var r=m.getQueryParam(t,o);r.length&&(e.mp_keyword=r)}return e},browser:function(t,i,o){return i=i||"",o||m.includes(t," OPR/")?m.includes(t,"Mini")?"Opera Mini":"Opera":/(BlackBerry|PlayBook|BB10)/i.test(t)?"BlackBerry":m.includes(t,"IEMobile")||m.includes(t,"WPDesktop")?"Internet Explorer Mobile":m.includes(t,"SamsungBrowser/")?"Samsung Internet":m.includes(t,"Edge")||m.includes(t,"Edg/")?"Microsoft Edge":m.includes(t,"FBIOS")?"Facebook Mobile":m.includes(t,"Chrome")?"Chrome":m.includes(t,"CriOS")?"Chrome iOS":m.includes(t,"UCWEB")||m.includes(t,"UCBrowser")?"UC Browser":m.includes(t,"FxiOS")?"Firefox iOS":m.includes(i,"Apple")?m.includes(t,"Mobile")?"Mobile Safari":"Safari":m.includes(t,"Android")?"Android Mobile":m.includes(t,"Konqueror")?"Konqueror":m.includes(t,"Firefox")?"Firefox":m.includes(t,"MSIE")||m.includes(t,"Trident/")?"Internet Explorer":m.includes(t,"Gecko")?"Mozilla":""},browserVersion:function(t,i,o){var e=m.info.browser(t,i,o),r={"Internet Explorer Mobile":/rv:(\d+(\.\d+)?)/,"Microsoft Edge":/Edge?\/(\d+(\.\d+)?)/,Chrome:/Chrome\/(\d+(\.\d+)?)/,"Chrome iOS":/CriOS\/(\d+(\.\d+)?)/,"UC Browser":/(UCBrowser|UCWEB)\/(\d+(\.\d+)?)/,Safari:/Version\/(\d+(\.\d+)?)/,"Mobile Safari":/Version\/(\d+(\.\d+)?)/,Opera:/(Opera|OPR)\/(\d+(\.\d+)?)/,Firefox:/Firefox\/(\d+(\.\d+)?)/,"Firefox iOS":/FxiOS\/(\d+(\.\d+)?)/,Konqueror:/Konqueror:(\d+(\.\d+)?)/,BlackBerry:/BlackBerry (\d+(\.\d+)?)/,"Android Mobile":/android\s(\d+(\.\d+)?)/,"Samsung Internet":/SamsungBrowser\/(\d+(\.\d+)?)/,"Internet Explorer":/(rv:|MSIE )(\d+(\.\d+)?)/,Mozilla:/rv:(\d+(\.\d+)?)/},n=r[e];if(n===void 0)return null;var s=t.match(n);return s?parseFloat(s[s.length-2]):null},os:function(){var t=gt;return/Windows/i.test(t)?/Phone/.test(t)||/WPDesktop/.test(t)?"Windows Phone":"Windows":/(iPhone|iPad|iPod)/.test(t)?"iOS":/Android/.test(t)?"Android":/(BlackBerry|PlayBook|BB10)/i.test(t)?"BlackBerry":/Mac/i.test(t)?"Mac OS X":/Linux/.test(t)?"Linux":/CrOS/.test(t)?"Chrome OS":""},device:function(t){return/Windows Phone/i.test(t)||/WPDesktop/.test(t)?"Windows Phone":/iPad/.test(t)?"iPad":/iPod/.test(t)?"iPod Touch":/iPhone/.test(t)?"iPhone":/(BlackBerry|PlayBook|BB10)/i.test(t)?"BlackBerry":/Android/.test(t)?"Android":""},referringDomain:function(t){var i=t.split("/");return i.length>=3?i[2]:""},currentUrl:function(){return W.location.href},properties:function(t){return typeof t!="object"&&(t={}),m.extend(m.strip_empty_properties({$os:m.info.os(),$browser:m.info.browser(gt,Zt.vendor,hn),$referrer:ve.referrer,$referring_domain:m.info.referringDomain(ve.referrer),$device:m.info.device(gt)}),{$current_url:m.info.currentUrl(),$browser_version:m.info.browserVersion(gt,Zt.vendor,hn),$screen_height:ou.height,$screen_width:ou.width,mp_lib:"web",$lib_version:Gi.LIB_VERSION,$insert_id:Zi(),time:m.timestamp()/1e3},m.strip_empty_properties(t))},people_properties:function(){return m.extend(m.strip_empty_properties({$os:m.info.os(),$browser:m.info.browser(gt,Zt.vendor,hn)}),{$browser_version:m.info.browserVersion(gt,Zt.vendor,hn)})},mpPageViewProperties:function(){return m.strip_empty_properties({current_page_title:ve.title,current_domain:W.location.hostname,current_url_path:W.location.pathname,current_url_protocol:W.location.protocol,current_url_search:W.location.search})}};var cp=function(t,i){var o=null,e=[];return function(r){var n=this;return e.push(r),o||(o=new U(function(s){setTimeout(function(){var a=t.apply(n,[e]);o=null,e=[],s(a)},i)})),o}},Zi=function(t){var i=Math.random().toString(36).substring(2,10)+Math.random().toString(36).substring(2,10);return t?i.substring(0,t):i},fp=/[a-z0-9][a-z0-9-]*\.[a-z]+$/i,hp=/[a-z0-9][a-z0-9-]+\.[a-z.]{2,6}$/i,hu=function(t){var i=hp,o=t.split("."),e=o[o.length-1];(e.length>4||e==="com"||e==="org")&&(i=fp);var r=t.match(i);return r?r[0]:""},dp=function(){var t=W.navigator.onLine;return m.isUndefined(t)||t},Ki=function(){},dn=null,pn=null;typeof JSON!="undefined"&&(dn=JSON.stringify,pn=JSON.parse),dn=dn||m.JSONEncode,pn=pn||m.JSONDecode,m.info=m.info,m.info.browser=m.info.browser,m.info.browserVersion=m.info.browserVersion,m.info.device=m.info.device,m.info.properties=m.info.properties,m.isBlockedUA=m.isBlockedUA,m.isEmptyObject=m.isEmptyObject,m.isObject=m.isObject,m.JSONDecode=m.JSONDecode,m.JSONEncode=m.JSONEncode,m.toArray=m.toArray,m.NPO=ze;var pp="mixpanelBrowserDb",du="mixpanelRecordingEvents",pu="mixpanelRecordingRegistry",vp=1,mp=[du,pu],_e=function(t){this.dbPromise=null,this.storeName=t};_e.prototype._openDb=function(){return new U(function(t,i){var o=W.indexedDB.open(pp,vp);o.onerror=function(){i(o.error)},o.onsuccess=function(){t(o.result)},o.onupgradeneeded=function(e){var r=e.target.result;mp.forEach(function(n){r.createObjectStore(n)})}})},_e.prototype.init=function(){return W.indexedDB?(this.dbPromise||(this.dbPromise=this._openDb()),this.dbPromise.then(function(t){return t instanceof W.IDBDatabase?U.resolve():U.reject(t)})):U.reject("indexedDB is not supported in this browser")},_e.prototype.makeTransaction=function(t,i){var o=this.storeName,e=function(r){return new U(function(n,s){var a=r.transaction(o,t);a.oncomplete=function(){n(a)},a.onabort=a.onerror=function(){s(a.error)},i(a.objectStore(o))})};return this.dbPromise.then(e).catch(function(r){return r&&r.name==="InvalidStateError"?(this.dbPromise=this._openDb(),this.dbPromise.then(e)):U.reject(r)}.bind(this))},_e.prototype.setItem=function(t,i){return this.makeTransaction("readwrite",function(o){o.put(i,t)})},_e.prototype.getItem=function(t){var i;return this.makeTransaction("readonly",function(o){i=o.get(t)}).then(function(){return i.result})},_e.prototype.removeItem=function(t){return this.makeTransaction("readwrite",function(i){i.delete(t)})},_e.prototype.getAll=function(){var t;return this.makeTransaction("readonly",function(i){t=i.getAll()}).then(function(){return t.result})};var gp="__mp_opt_in_out_";function yp(t,i){if(Ip(i))return Ce.warn('This browser has "Do Not Track" enabled. This will prevent the Mixpanel SDK from sending any data. To ignore the "Do Not Track" browser setting, initialize the Mixpanel instance with the config "ignore_dnt: true"'),!0;var o=Cp(t,i)==="0";return o&&Ce.warn("You are opted out of Mixpanel tracking. This will prevent the Mixpanel SDK from sending any data."),o}function wp(t){return Op(t,function(i){return this.get_config(i)})}function Sp(t){return t=t||{},t.persistenceType==="localStorage"?m.localStorage:m.cookie}function bp(t,i){return i=i||{},(i.persistencePrefix||gp)+t}function Cp(t,i){return Sp(i).get(bp(t,i))}function Ip(t){if(t&&t.ignoreDnt)return!1;var i=t&&t.window||W,o=i.navigator||{},e=!1;return m.each([o.doNotTrack,o.msDoNotTrack,i.doNotTrack],function(r){m.includes([!0,1,"1","yes"],r)&&(e=!0)}),e}function Op(t,i){return function(){var o=!1;try{var e=i.call(this,"token"),r=i.call(this,"ignore_dnt"),n=i.call(this,"opt_out_tracking_persistence_type"),s=i.call(this,"opt_out_tracking_cookie_prefix"),a=i.call(this,"window");e&&(o=yp(e,{ignoreDnt:r,persistenceType:n,persistencePrefix:s,window:a}))}catch(l){Ce.error("Unexpected error when checking tracking opt-out status: "+l)}if(!o)return t.apply(this,arguments);var u=arguments[arguments.length-1];typeof u=="function"&&u(0)}}var xp=Kt("lock"),vu=function(t,i){i=i||{},this.storageKey=t,this.storage=i.storage||W.localStorage,this.pollIntervalMS=i.pollIntervalMS||100,this.timeoutMS=i.timeoutMS||2e3,this.promiseImpl=i.promiseImpl||U};vu.prototype.withLock=function(t,i){var o=this.promiseImpl;return new o(m.bind(function(e,r){var n=i||new Date().getTime()+"|"+Math.random(),s=new Date().getTime(),a=this.storageKey,u=this.pollIntervalMS,l=this.timeoutMS,c=this.storage,f=a+":X",h=a+":Y",v=a+":Z",p=function(S){if(new Date().getTime()-s>l){xp.error("Timeout waiting for mutex on "+a+"; clearing lock. ["+n+"]"),c.removeItem(v),c.removeItem(h),y();return}setTimeout(function(){try{S()}catch(b){r(b)}},u*(Math.random()+.1))},g=function(S,b){S()?b():p(function(){g(S,b)})},d=function(){var S=c.getItem(h);return S&&S!==n?!1:(c.setItem(h,n),c.getItem(h)===n?!0:(Xt(c,!0)||r(new Error("localStorage support dropped while acquiring lock")),!1))},y=function(){c.setItem(f,n),g(d,function(){if(c.getItem(f)===n){w();return}p(function(){if(c.getItem(h)!==n){y();return}g(function(){return!c.getItem(v)},w)})})},w=function(){c.setItem(v,"1");var S=function(){c.removeItem(v),c.getItem(h)===n&&c.removeItem(h),c.getItem(f)===n&&c.removeItem(f)};t().then(function(b){S(),e(b)}).catch(function(b){S(),r(b)})};try{if(Xt(c,!0))y();else throw new Error("localStorage support check failed")}catch(S){r(S)}},this))};var Qt=function(t){this.storage=t||W.localStorage};Qt.prototype.init=function(){return U.resolve()},Qt.prototype.setItem=function(t,i){return new U(m.bind(function(o,e){try{this.storage.setItem(t,dn(i))}catch(r){e(r)}o()},this))},Qt.prototype.getItem=function(t){return new U(m.bind(function(i,o){var e;try{e=pn(this.storage.getItem(t))}catch(r){o(r)}i(e)},this))},Qt.prototype.removeItem=function(t){return new U(m.bind(function(i,o){try{this.storage.removeItem(t)}catch(e){o(e)}i()},this))};var mu=Kt("batch"),Re=function(t,i){i=i||{},this.storageKey=t,this.usePersistence=i.usePersistence,this.usePersistence&&(this.queueStorage=i.queueStorage||new Qt,this.lock=new vu(t,{storage:i.sharedLockStorage||W.localStorage,timeoutMS:i.sharedLockTimeoutMS})),this.reportError=i.errorReporter||m.bind(mu.error,mu),this.pid=i.pid||null,this.memQueue=[],this.initialized=!1,i.enqueueThrottleMs?this.enqueuePersisted=cp(m.bind(this._enqueuePersisted,this),i.enqueueThrottleMs):this.enqueuePersisted=m.bind(function(o){return this._enqueuePersisted([o])},this)};Re.prototype.ensureInit=function(){return this.initialized?U.resolve():this.queueStorage.init().then(m.bind(function(){this.initialized=!0},this)).catch(m.bind(function(t){this.reportError("Error initializing queue persistence. Disabling persistence",t),this.initialized=!0,this.usePersistence=!1},this))},Re.prototype.enqueue=function(t,i){var o={id:Zi(),flushAfter:new Date().getTime()+i*2,payload:t};return this.usePersistence?this.enqueuePersisted(o):(this.memQueue.push(o),U.resolve(!0))},Re.prototype._enqueuePersisted=function(t){var i=m.bind(function(){return this.ensureInit().then(m.bind(function(){return this.readFromStorage()},this)).then(m.bind(function(o){return this.saveToStorage(o.concat(t))},this)).then(m.bind(function(o){return o&&(this.memQueue=this.memQueue.concat(t)),o},this)).catch(m.bind(function(o){return this.reportError("Error enqueueing items",o,t),!1},this))},this);return this.lock.withLock(i,this.pid).catch(m.bind(function(o){return this.reportError("Error acquiring storage lock",o),!1},this))},Re.prototype.fillBatch=function(t){var i=this.memQueue.slice(0,t);return this.usePersistence&&i.length<t?this.ensureInit().then(m.bind(function(){return this.readFromStorage()},this)).then(m.bind(function(o){if(o.length){var e={};m.each(i,function(s){e[s.id]=!0});for(var r=0;r<o.length;r++){var n=o[r];if(new Date().getTime()>n.flushAfter&&!e[n.id]&&(n.orphaned=!0,i.push(n),i.length>=t))break}}return i},this)):U.resolve(i)};var gu=function(t,i){var o=[];return m.each(t,function(e){e.id&&!i[e.id]&&o.push(e)}),o};Re.prototype.removeItemsByID=function(t){var i={};if(m.each(t,function(e){i[e]=!0}),this.memQueue=gu(this.memQueue,i),this.usePersistence){var o=m.bind(function(){return this.ensureInit().then(m.bind(function(){return this.readFromStorage()},this)).then(m.bind(function(e){return e=gu(e,i),this.saveToStorage(e)},this)).then(m.bind(function(){return this.readFromStorage()},this)).then(m.bind(function(e){for(var r=0;r<e.length;r++){var n=e[r];if(n.id&&i[n.id])throw new Error("Item not removed from storage")}return!0},this)).catch(m.bind(function(e){return this.reportError("Error removing items",e,t),!1},this))},this);return this.lock.withLock(o,this.pid).catch(m.bind(function(e){return this.reportError("Error acquiring storage lock",e),Xt(this.lock.storage,!0)?!1:o().then(m.bind(function(r){return r||this.queueStorage.removeItem(this.storageKey).then(function(){return r})},this)).catch(m.bind(function(r){return this.reportError("Error clearing queue",r),!1},this))},this))}else return U.resolve(!0)};var yu=function(t,i){var o=[];return m.each(t,function(e){var r=e.id;if(r in i){var n=i[r];n!==null&&(e.payload=n,o.push(e))}else o.push(e)}),o};Re.prototype.updatePayloads=function(t){return this.memQueue=yu(this.memQueue,t),this.usePersistence?this.lock.withLock(m.bind(function(){return this.ensureInit().then(m.bind(function(){return this.readFromStorage()},this)).then(m.bind(function(o){return o=yu(o,t),this.saveToStorage(o)},this)).catch(m.bind(function(o){return this.reportError("Error updating items",t,o),!1},this))},this),this.pid).catch(m.bind(function(i){return this.reportError("Error acquiring storage lock",i),!1},this)):U.resolve(!0)},Re.prototype.readFromStorage=function(){return this.ensureInit().then(m.bind(function(){return this.queueStorage.getItem(this.storageKey)},this)).then(m.bind(function(t){return t&&(m.isArray(t)||(this.reportError("Invalid storage entry:",t),t=null)),t||[]},this)).catch(m.bind(function(t){return this.reportError("Error retrieving queue",t),[]},this))},Re.prototype.saveToStorage=function(t){return this.ensureInit().then(m.bind(function(){return this.queueStorage.setItem(this.storageKey,t)},this)).then(function(){return!0}).catch(m.bind(function(i){return this.reportError("Error saving queue",i),!1},this))},Re.prototype.clear=function(){return this.memQueue=[],this.usePersistence?this.ensureInit().then(m.bind(function(){return this.queueStorage.removeItem(this.storageKey)},this)):U.resolve()};var Rp=10*60*1e3,er=Kt("batch"),Ie=function(t,i){this.errorReporter=i.errorReporter,this.queue=new Re(t,{errorReporter:m.bind(this.reportError,this),queueStorage:i.queueStorage,sharedLockStorage:i.sharedLockStorage,sharedLockTimeoutMS:i.sharedLockTimeoutMS,usePersistence:i.usePersistence,enqueueThrottleMs:i.enqueueThrottleMs}),this.libConfig=i.libConfig,this.sendRequest=i.sendRequestFunc,this.beforeSendHook=i.beforeSendHook,this.stopAllBatching=i.stopAllBatchingFunc,this.batchSize=this.libConfig.batch_size,this.flushInterval=this.libConfig.batch_flush_interval_ms,this.stopped=!this.libConfig.batch_autostart,this.consecutiveRemovalFailures=0,this.itemIdsSentSuccessfully={},this.flushOnlyOnInterval=i.flushOnlyOnInterval||!1,this._flushPromise=null};Ie.prototype.enqueue=function(t){return this.queue.enqueue(t,this.flushInterval)},Ie.prototype.start=function(){return this.stopped=!1,this.consecutiveRemovalFailures=0,this.flush()},Ie.prototype.stop=function(){this.stopped=!0,this.timeoutID&&(clearTimeout(this.timeoutID),this.timeoutID=null)},Ie.prototype.clear=function(){return this.queue.clear()},Ie.prototype.resetBatchSize=function(){this.batchSize=this.libConfig.batch_size},Ie.prototype.resetFlush=function(){this.scheduleFlush(this.libConfig.batch_flush_interval_ms)},Ie.prototype.scheduleFlush=function(t){this.flushInterval=t,this.stopped||(this.timeoutID=setTimeout(m.bind(function(){this.stopped||(this._flushPromise=this.flush())},this),this.flushInterval))},Ie.prototype.sendRequestPromise=function(t,i){return new U(m.bind(function(o){this.sendRequest(t,i,o)},this))},Ie.prototype.flush=function(t){if(this.requestInProgress)return er.log("Flush: Request already in progress"),U.resolve();this.requestInProgress=!0,t=t||{};var i=this.libConfig.batch_request_timeout_ms,o=new Date().getTime(),e=this.batchSize;return this.queue.fillBatch(e).then(m.bind(function(r){var n=r.length===e,s=[],a={};if(m.each(r,function(f){var h=f.payload;if(this.beforeSendHook&&!f.orphaned&&(h=this.beforeSendHook(h)),h){h.event&&h.properties&&(h.properties=m.extend({},h.properties,{mp_sent_by_lib_version:Gi.LIB_VERSION}));var v=!0,p=f.id;p?(this.itemIdsSentSuccessfully[p]||0)>5&&(this.reportError("[dupe] item ID sent too many times, not sending",{item:f,batchSize:r.length,timesSent:this.itemIdsSentSuccessfully[p]}),v=!1):this.reportError("[dupe] found item with no ID",{item:f}),v&&s.push(h)}a[f.id]=h},this),s.length<1)return this.requestInProgress=!1,this.resetFlush(),U.resolve();var u=m.bind(function(){return this.queue.removeItemsByID(m.map(r,function(f){return f.id})).then(m.bind(function(f){return m.each(r,m.bind(function(h){var v=h.id;v?(this.itemIdsSentSuccessfully[v]=this.itemIdsSentSuccessfully[v]||0,this.itemIdsSentSuccessfully[v]++,this.itemIdsSentSuccessfully[v]>5&&this.reportError("[dupe] item ID sent too many times",{item:h,batchSize:r.length,timesSent:this.itemIdsSentSuccessfully[v]})):this.reportError("[dupe] found item with no ID while removing",{item:h})},this)),f?(this.consecutiveRemovalFailures=0,this.flushOnlyOnInterval&&!n?(this.resetFlush(),U.resolve()):this.flush()):(++this.consecutiveRemovalFailures>5?(this.reportError("Too many queue failures; disabling batching system."),this.stopAllBatching()):this.resetFlush(),U.resolve())},this))},this),l=m.bind(function(f){this.requestInProgress=!1;try{if(t.unloading)return this.queue.updatePayloads(a);if(m.isObject(f)&&f.error==="timeout"&&new Date().getTime()-o>=i)return this.reportError("Network timeout; retrying"),this.flush();if(m.isObject(f)&&(f.httpStatusCode>=500||f.httpStatusCode===429||f.httpStatusCode<=0&&!dp()||f.error==="timeout")){var h=this.flushInterval*2;return f.retryAfter&&(h=parseInt(f.retryAfter,10)*1e3||h),h=Math.min(Rp,h),this.reportError("Error; retry in "+h+" ms"),this.scheduleFlush(h),U.resolve()}else if(m.isObject(f)&&f.httpStatusCode===413)if(r.length>1){var v=Math.max(1,Math.floor(e/2));return this.batchSize=Math.min(this.batchSize,v,r.length-1),this.reportError("413 response; reducing batch size to "+this.batchSize),this.resetFlush(),U.resolve()}else return this.reportError("Single-event request too large; dropping",r),this.resetBatchSize(),u();else return u()}catch(p){this.reportError("Error handling API response",p),this.resetFlush()}},this),c={method:"POST",verbose:!0,ignore_json_errors:!0,timeout_ms:i};return t.unloading&&(c.transport="sendBeacon"),er.log("MIXPANEL REQUEST:",s),this.sendRequestPromise(s,c).then(l)},this)).catch(m.bind(function(r){this.reportError("Error flushing request queue",r),this.resetFlush()},this))},Ie.prototype.reportError=function(t,i){if(er.error.apply(er.error,arguments),this.errorReporter)try{i instanceof Error||(i=new Error(t)),this.errorReporter(t,i)}catch(o){er.error(o)}};var wu=function(t){var i=Date.now();return!t||i>t.maxExpires||i>t.idleExpires},Ep=250,yt=Kt("recorder"),Su=W.CompressionStream,Ap={batch_size:1e3,batch_flush_interval_ms:10*1e3,batch_request_timeout_ms:90*1e3,batch_autostart:!0},Mp=new Set([k.MouseMove,k.MouseInteraction,k.Scroll,k.ViewportResize,k.Input,k.TouchMove,k.MediaInteraction,k.Drag,k.Selection]);function kp(t){return t.type===D.IncrementalSnapshot&&Mp.has(t.data.source)}var le=function(t){this._mixpanel=t.mixpanelInstance,this._onIdleTimeout=t.onIdleTimeout||Ki,this._onMaxLengthReached=t.onMaxLengthReached||Ki,this._onBatchSent=t.onBatchSent||Ki,this._rrwebRecord=t.rrwebRecord||null,this._stopRecording=null,this.replayId=t.replayId,this.batchStartUrl=t.batchStartUrl||null,this.replayStartUrl=t.replayStartUrl||null,this.idleExpires=t.idleExpires||null,this.maxExpires=t.maxExpires||null,this.replayStartTime=t.replayStartTime||null,this.seqNo=t.seqNo||0,this.idleTimeoutId=null,this.maxTimeoutId=null,this.recordMaxMs=ln,this.recordMinMs=0;var i=Xt(t.sharedLockStorage,!0);this.batcherKey="__mprec_"+this.getConfig("name")+"_"+this.getConfig("token")+"_"+this.replayId,this.queueStorage=new _e(du),this.batcher=new Ie(this.batcherKey,{errorReporter:this.reportError.bind(this),flushOnlyOnInterval:!0,libConfig:Ap,sendRequestFunc:this.flushEventsWithOptOut.bind(this),queueStorage:this.queueStorage,sharedLockStorage:t.sharedLockStorage,usePersistence:i,stopAllBatchingFunc:this.stopRecording.bind(this),enqueueThrottleMs:Ep,sharedLockTimeoutMS:10*1e3})};le.prototype.unloadPersistedData=function(){return this.batcher.stop(),this.batcher.flush().then(function(){return this.queueStorage.removeItem(this.batcherKey)}.bind(this))},le.prototype.getConfig=function(t){return this._mixpanel.get_config(t)},le.prototype.get_config=function(t){return this.getConfig(t)},le.prototype.startRecording=function(t){if(this._rrwebRecord===null){this.reportError("rrweb record function not provided. ");return}if(this._stopRecording!==null){yt.log("Recording already in progress, skipping startRecording.");return}this.recordMaxMs=this.getConfig("record_max_ms"),this.recordMaxMs>ln&&(this.recordMaxMs=ln,yt.critical("record_max_ms cannot be greater than "+ln+"ms. Capping value.")),this.maxExpires||(this.maxExpires=new Date().getTime()+this.recordMaxMs),this.recordMinMs=this.getConfig("record_min_ms"),this.recordMinMs>ji&&(this.recordMinMs=ji,yt.critical("record_min_ms cannot be greater than "+ji+"ms. Capping value.")),this.replayStartTime||(this.replayStartTime=new Date().getTime(),this.batchStartUrl=m.info.currentUrl(),this.replayStartUrl=m.info.currentUrl()),t||this.recordMinMs>0?this.batcher.stop():this.batcher.start();var i=function(){clearTimeout(this.idleTimeoutId);var r=this.getConfig("record_idle_timeout_ms");this.idleTimeoutId=setTimeout(this._onIdleTimeout,r),this.idleExpires=new Date().getTime()+r}.bind(this);i();var o=this.getConfig("record_block_selector");(o===""||o===null)&&(o=void 0);try{this._stopRecording=this._rrwebRecord({emit:function(r){if(this.idleExpires&&this.idleExpires<r.timestamp){this._onIdleTimeout();return}kp(r)&&(this.batcher.stopped&&new Date().getTime()-this.replayStartTime>=this.recordMinMs&&this.batcher.start(),i()),this.__enqueuePromise=this.batcher.enqueue(r)}.bind(this),blockClass:this.getConfig("record_block_class"),blockSelector:o,collectFonts:this.getConfig("record_collect_fonts"),dataURLOptions:{type:"image/webp",quality:.6},maskAllInputs:!0,maskTextClass:this.getConfig("record_mask_text_class"),maskTextSelector:this.getConfig("record_mask_text_selector"),recordCanvas:this.getConfig("record_canvas"),sampling:{canvas:15}})}catch(r){this.reportError("Unexpected error when starting rrweb recording.",r)}if(typeof this._stopRecording!="function"){this.reportError("rrweb failed to start, skipping this recording."),this._stopRecording=null,this.stopRecording();return}var e=this.maxExpires-new Date().getTime();this.maxTimeoutId=setTimeout(this._onMaxLengthReached.bind(this),e)},le.prototype.stopRecording=function(t){if(!this.isRrwebStopped()){try{this._stopRecording()}catch(o){this.reportError("Error with rrweb stopRecording",o)}this._stopRecording=null}var i;return this.batcher.stopped?i=this.batcher.clear():t||(i=this.batcher.flush()),this.batcher.stop(),clearTimeout(this.idleTimeoutId),clearTimeout(this.maxTimeoutId),i},le.prototype.isRrwebStopped=function(){return this._stopRecording===null},le.prototype.flushEventsWithOptOut=function(t,i,o){var e=function(r){r===0&&(this.stopRecording(),o({error:"Tracking has been opted out, stopping recording."}))}.bind(this);this._flushEvents(t,i,o,e)},le.prototype.serialize=function(){var t;try{t=this._mixpanel.get_tab_id()}catch(i){this.reportError("Error getting tab ID for serialization ",i),t=null}return{replayId:this.replayId,seqNo:this.seqNo,replayStartTime:this.replayStartTime,batchStartUrl:this.batchStartUrl,replayStartUrl:this.replayStartUrl,idleExpires:this.idleExpires,maxExpires:this.maxExpires,tabId:t}},le.deserialize=function(t,i){var o=new le(m.extend({},i,{replayId:t.replayId,batchStartUrl:t.batchStartUrl,replayStartUrl:t.replayStartUrl,idleExpires:t.idleExpires,maxExpires:t.maxExpires,replayStartTime:t.replayStartTime,seqNo:t.seqNo,sharedLockStorage:i.sharedLockStorage}));return o},le.prototype._sendRequest=function(t,i,o,e){var r=function(n,s){n.status===200&&this.replayId===t&&(this.seqNo++,this.batchStartUrl=m.info.currentUrl()),this._onBatchSent(),e({status:0,httpStatusCode:n.status,responseBody:s,retryAfter:n.headers.get("Retry-After")})}.bind(this);W.fetch(this.getConfig("api_host")+"/"+this.getConfig("api_routes").record+"?"+new URLSearchParams(i),{method:"POST",headers:{Authorization:"Basic "+btoa(this.getConfig("token")+":"),"Content-Type":"application/octet-stream"},body:o}).then(function(n){n.json().then(function(s){r(n,s)}).catch(function(s){e({error:s})})}).catch(function(n){e({error:n,httpStatusCode:0})})},le.prototype._flushEvents=wp(function(t,i,o){var e=t.length;if(e>0){for(var r=this.replayId,n=1/0,s=-1/0,a=!1,u=0;u<e;u++)n=Math.min(n,t[u].timestamp),s=Math.max(s,t[u].timestamp),t[u].type===D.FullSnapshot&&(a=!0);if(this.seqNo===0){if(!a){o({error:"First batch does not contain a full snapshot. Aborting recording."}),this.stopRecording(!0);return}this.replayStartTime=n}else this.replayStartTime||(this.reportError("Replay start time not set but seqNo is not 0. Using current batch start time as a fallback."),this.replayStartTime=n);var l=s-this.replayStartTime,c={$current_url:this.batchStartUrl,$lib_version:Gi.LIB_VERSION,batch_start_time:n/1e3,distinct_id:String(this._mixpanel.get_distinct_id()),mp_lib:"web",replay_id:r,replay_length_ms:l,replay_start_time:this.replayStartTime/1e3,replay_start_url:this.replayStartUrl,seq:this.seqNo},f=JSON.stringify(t),h=this._mixpanel.get_property("$device_id");h&&(c.$device_id=h);var v=this._mixpanel.get_property("$user_id");if(v&&(c.$user_id=v),Su){var p=new Blob([f],{type:"application/json"}).stream(),g=p.pipeThrough(new Su("gzip"));new Response(g).blob().then(function(d){c.format="gzip",this._sendRequest(r,c,d,o)}.bind(this))}else c.format="body",this._sendRequest(r,c,f,o)}}),le.prototype.reportError=function(t,i){yt.error.apply(yt.error,arguments);try{!i&&!(t instanceof Error)&&(t=new Error(t)),this.getConfig("error_reporter")(t,i)}catch(o){yt.error(o)}};var wt=function(t){this.idb=new _e(pu),this.errorReporter=t.errorReporter,this.mixpanelInstance=t.mixpanelInstance,this.sharedLockStorage=t.sharedLockStorage};wt.prototype.handleError=function(t){this.errorReporter("IndexedDB error: ",t)},wt.prototype.setActiveRecording=function(t){var i=t.tabId;return i?this.idb.init().then(function(){return this.idb.setItem(i,t)}.bind(this)).catch(this.handleError.bind(this)):(console.warn("No tab ID is set, cannot persist recording metadata."),U.resolve())},wt.prototype.getActiveRecording=function(){return this.idb.init().then(function(){return this.idb.getItem(this.mixpanelInstance.get_tab_id())}.bind(this)).then(function(t){return wu(t)?null:t}.bind(this)).catch(this.handleError.bind(this))},wt.prototype.clearActiveRecording=function(){return this.getActiveRecording().then(function(t){if(t)return t.maxExpires=0,this.setActiveRecording(t)}.bind(this)).catch(this.handleError.bind(this))},wt.prototype.flushInactiveRecordings=function(){return this.idb.init().then(function(){return this.idb.getAll()}.bind(this)).then(function(t){var i=t.filter(function(o){return wu(o)}).map(function(o){var e=le.deserialize(o,{mixpanelInstance:this.mixpanelInstance,sharedLockStorage:this.sharedLockStorage});return e.unloadPersistedData().then(function(){return this.idb.removeItem(o.tabId)}.bind(this)).catch(this.handleError.bind(this))}.bind(this));return U.all(i)}.bind(this)).catch(this.handleError.bind(this))};var tr=Kt("recorder"),Te=function(t,i,o){this.mixpanelInstance=t,this.rrwebRecord=i||Be,this.sharedLockStorage=o,this.recordingRegistry=new wt({mixpanelInstance:this.mixpanelInstance,errorReporter:tr.error,sharedLockStorage:o}),this._flushInactivePromise=this.recordingRegistry.flushInactiveRecordings(),this.activeRecording=null};Te.prototype.startRecording=function(t){if(t=t||{},this.activeRecording&&!this.activeRecording.isRrwebStopped()){tr.log("Recording already in progress, skipping startRecording.");return}var i=function(){tr.log("Idle timeout reached, restarting recording."),this.resetRecording()}.bind(this),o=function(){tr.log("Max recording length reached, stopping recording."),this.resetRecording()}.bind(this),e=function(){this.recordingRegistry.setActiveRecording(this.activeRecording.serialize()),this.__flushPromise=this.activeRecording.batcher._flushPromise}.bind(this),r={mixpanelInstance:this.mixpanelInstance,onBatchSent:e,onIdleTimeout:i,onMaxLengthReached:o,replayId:m.UUID(),rrwebRecord:this.rrwebRecord,sharedLockStorage:this.sharedLockStorage};return t.activeSerializedRecording?this.activeRecording=le.deserialize(t.activeSerializedRecording,r):this.activeRecording=new le(r),this.activeRecording.startRecording(t.shouldStopBatcher),this.recordingRegistry.setActiveRecording(this.activeRecording.serialize())},Te.prototype.stopRecording=function(){var t=this._stopCurrentRecording(!1);return this.recordingRegistry.clearActiveRecording(),this.activeRecording=null,t},Te.prototype.pauseRecording=function(){return this._stopCurrentRecording(!1)},Te.prototype._stopCurrentRecording=function(t){return this.activeRecording?this.activeRecording.stopRecording(t):U.resolve()},Te.prototype.resumeRecording=function(t){return this.activeRecording&&this.activeRecording.isRrwebStopped()?(this.activeRecording.startRecording(!1),U.resolve(null)):this.recordingRegistry.getActiveRecording().then(function(i){return i?this.startRecording({activeSerializedRecording:i}):t?this.startRecording({shouldStopBatcher:!1}):(tr.log("No resumable recording found."),null)}.bind(this))},Te.prototype.resetRecording=function(){this.stopRecording(),this.startRecording({shouldStopBatcher:!0})},Te.prototype.getActiveReplayId=function(){return this.activeRecording&&!this.activeRecording.isRrwebStopped()?this.activeRecording.replayId:null},Object.defineProperty(Te.prototype,"replayId",{get:function(){return this.getActiveReplayId()}}),W.__mp_recorder=Te})();
39
2
  //# sourceMappingURL=mixpanel-recorder.min.js.map