@zharp/browser 0.0.0-stage → 0.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +21 -0
- package/README.md +133 -3
- package/dist/chunk-H5MED5NB.js +2 -0
- package/dist/chunk-H5MED5NB.js.map +1 -0
- package/dist/chunk-X34YPHYT.mjs +2 -0
- package/dist/chunk-X34YPHYT.mjs.map +1 -0
- package/dist/index.d.mts +159 -0
- package/dist/index.d.ts +159 -0
- package/dist/index.js +7 -0
- package/dist/index.js.map +1 -0
- package/dist/index.mjs +7 -0
- package/dist/index.mjs.map +1 -0
- package/dist/recorder-2KVKGSYN.js +2 -0
- package/dist/recorder-2KVKGSYN.js.map +1 -0
- package/dist/recorder-HNDTSUTD.mjs +2 -0
- package/dist/recorder-HNDTSUTD.mjs.map +1 -0
- package/dist/zharp-replay.min.js +147 -0
- package/dist/zharp-replay.min.js.map +1 -0
- package/dist/zharp.min.js +7 -0
- package/dist/zharp.min.js.map +1 -0
- package/package.json +66 -3
|
@@ -0,0 +1,147 @@
|
|
|
1
|
+
(function(){'use strict';var Tn=Object.defineProperty,Dn=(e,t,r)=>t in e?Tn(e,t,{enumerable:true,configurable:true,writable:true,value:r}):e[t]=r,I=(e,t,r)=>Dn(e,typeof t!="symbol"?t+"":t,r),us,_n=Object.defineProperty,kn=(e,t,r)=>t in e?_n(e,t,{enumerable:true,configurable:true,writable:true,value:r}):e[t]=r,cs=(e,t,r)=>kn(e,typeof t!="symbol"?t+"":t,r),J=(e=>(e[e.Document=0]="Document",e[e.DocumentType=1]="DocumentType",e[e.Element=2]="Element",e[e.Text=3]="Text",e[e.CDATA=4]="CDATA",e[e.Comment=5]="Comment",e))(J||{}),hs={Node:["childNodes","parentNode","parentElement","textContent","ownerDocument"],ShadowRoot:["host","styleSheets"],Element:["shadowRoot","querySelector","querySelectorAll"],MutationObserver:[]},fs={Node:["contains","getRootNode"],ShadowRoot:["getSelection"],Element:[],MutationObserver:["constructor"]},Ve={},_i={},Pn=()=>!!globalThis.Zone;function Wr(e){if(Ve[e])return Ve[e];let t=globalThis[e],r=t.prototype,a=e in hs?hs[e]:void 0,s=!!(a&&a.every(m=>{var o,d;return !!((d=(o=Object.getOwnPropertyDescriptor(r,m))==null?void 0:o.get)!=null&&d.toString().includes("[native code]"))})),u=e in fs?fs[e]:void 0,f=!!(u&&u.every(m=>{var o;return typeof r[m]=="function"&&((o=r[m])==null?void 0:o.toString().includes("[native code]"))}));if(s&&f&&!Pn())return Ve[e]=t.prototype,t.prototype;try{let m=document.createElement("iframe");m.style.display="none",document.body.appendChild(m);let o=m.contentWindow;if(!o)return t.prototype;let d=o[e].prototype;if(!d)return m.remove(),r;let i=navigator.userAgent;return i.includes("Safari")&&!i.includes("Chrome")?(m.classList.add("rr-block"),m.setAttribute("__rrwebUntaintedMutationObserver",""),_i[e]=()=>m.remove()):m.remove(),Ve[e]=d}catch(m){return r}}var Ct={};function pe(e,t,r){var a;let s=`${e}.${String(r)}`;if(Ct[s])return Ct[s].call(t);let u=Wr(e),f=(a=Object.getOwnPropertyDescriptor(u,r))==null?void 0:a.get;return f?(Ct[s]=f,f.call(t)):t[r]}var Et={};function ki(e,t,r){let a=`${e}.${String(r)}`;if(Et[a])return Et[a].bind(t);let u=Wr(e)[r];return typeof u!="function"?t[r]:(Et[a]=u,u.bind(t))}function Ln(e){return pe("Node",e,"ownerDocument")}function Fn(e){return pe("Node",e,"childNodes")}function Un(e){return pe("Node",e,"parentNode")}function Bn(e){return pe("Node",e,"parentElement")}function $n(e){return pe("Node",e,"textContent")}function Wn(e,t){return ki("Node",e,"contains")(t)}function zn(e){return ki("Node",e,"getRootNode")()}function qn(e){return !e||!("host"in e)?null:pe("ShadowRoot",e,"host")}function Vn(e){return e.styleSheets}function jn(e){return !e||!("shadowRoot"in e)?null:pe("Element",e,"shadowRoot")}function Gn(e,t){return pe("Element",e,"querySelector")(t)}function Hn(e,t){return pe("Element",e,"querySelectorAll")(t)}function Yn(){var e;return [Wr("MutationObserver").constructor,(e=_i.MutationObserver)!=null?e:(()=>{})]}var Pi=Date.now;/[1-9][0-9]{12}/.test(Date.now().toString())||(Pi=()=>new Date().getTime());function Xn(e,t,r){try{if(!(t in e))return ()=>{};let a=e[t],s=r(a);return typeof s=="function"&&(s.prototype=s.prototype||{},Object.defineProperties(s,{__rrweb_original__:{enumerable:!1,value:a}})),e[t]=s,()=>{e[t]=a;}}catch(a){return ()=>{}}}var Z={ownerDocument:Ln,childNodes:Fn,parentNode:Un,parentElement:Bn,textContent:$n,contains:Wn,getRootNode:zn,host:qn,styleSheets:Vn,shadowRoot:jn,querySelector:Gn,querySelectorAll:Hn,nowTimestamp:Pi,mutationObserverCtor:Yn,patch:Xn};function Li(e){return e.nodeType===e.ELEMENT_NODE}function Pe(e){let t=e&&"host"in e&&"mode"in e&&Z.host(e)||null;return !!(t&&"shadowRoot"in t&&Z.shadowRoot(t)===e)}function Le(e){return Object.prototype.toString.call(e)==="[object ShadowRoot]"}function Jn(e){return e.includes(" background-clip: text;")&&!e.includes(" -webkit-background-clip: text;")&&(e=e.replace(/\sbackground-clip:\s*text;/g," -webkit-background-clip: text; background-clip: text;")),e}function Qn(e){let{cssText:t}=e;if(t.split('"').length<3)return t;let r=["@import",`url(${JSON.stringify(e.href)})`];return e.layerName===""?r.push("layer"):e.layerName&&r.push(`layer(${e.layerName})`),e.supportsText&&r.push(`supports(${e.supportsText})`),e.media.length&&r.push(e.media.mediaText),r.join(" ")+";"}function Or(e){try{let t=e.rules||e.cssRules;if(!t)return null;let r=e.href;!r&&e.ownerNode&&(r=e.ownerNode.baseURI);let a=Array.from(t,s=>Fi(s,r)).join("");return Jn(a)}catch(t){return null}}function Fi(e,t){if(Kn(e)){let r;try{r=Or(e.styleSheet)||Qn(e);}catch(a){r=e.cssText;}return e.styleSheet.href?it(r,e.styleSheet.href):r}else {let r=e.cssText;return eo(e)&&e.selectorText.includes(":")&&(r=Zn(r)),t?it(r,t):r}}function Zn(e){let t=/(\[(?:[\w-]+)[^\\])(:(?:[\w-]+)\])/gm;return e.replace(t,"$1\\$2")}function Kn(e){return "styleSheet"in e}function eo(e){return "selectorText"in e}var tt=class{constructor(){cs(this,"idNodeMap",new Map),cs(this,"nodeMetaMap",new WeakMap);}getId(t){var r;if(!t)return -1;let a=(r=this.getMeta(t))==null?void 0:r.id;return a!=null?a:-1}getNode(t){return this.idNodeMap.get(t)||null}getIds(){return Array.from(this.idNodeMap.keys())}getMeta(t){return this.nodeMetaMap.get(t)||null}removeNodeFromMap(t){let r=this.getId(t);this.idNodeMap.delete(r),t.childNodes&&t.childNodes.forEach(a=>this.removeNodeFromMap(a));}has(t){return this.idNodeMap.has(t)}hasNode(t){return this.nodeMetaMap.has(t)}add(t,r){let a=r.id;this.idNodeMap.set(a,t),this.nodeMetaMap.set(t,r);}replace(t,r){let a=this.getNode(t);if(a){let s=this.nodeMetaMap.get(a);s&&this.nodeMetaMap.set(r,s);}this.idNodeMap.set(t,r);}reset(){this.idNodeMap=new Map,this.nodeMetaMap=new WeakMap;}};function to(){return new tt}function rt({element:e,maskInputOptions:t,tagName:r,type:a,value:s,maskInputFn:u}){let f=s||"",m=a&&Ce(a);return (t[r.toLowerCase()]||m&&t[m])&&(u?f=u(f,e):f="*".repeat(f.length)),f}function Ce(e){return e.toLowerCase()}var ds="__rrweb_original__";function ro(e){let t=e.getContext("2d");if(!t)return true;let r=50;for(let a=0;a<e.width;a+=r)for(let s=0;s<e.height;s+=r){let u=t.getImageData,f=ds in u?u[ds]:u;if(new Uint32Array(f.call(t,a,s,Math.min(r,e.width-a),Math.min(r,e.height-s)).data.buffer).some(o=>o!==0))return false}return true}function st(e){let t=e.type;return e.hasAttribute("data-rr-is-password")?"password":t?Ce(t):null}function Ui(e,t){var u;let r;try{r=new URL(e,t!=null?t:window.location.href);}catch(f){return null}let a=/\.([0-9a-z]+)(?:$)/i,s=r.pathname.match(a);return (u=s==null?void 0:s[1])!=null?u:null}function so(e){let t="";return e.indexOf("//")>-1?t=e.split("/").slice(0,3).join("/"):t=e.split("/")[0],t=t.split("?")[0],t}var io=/url\((?:(')([^']*)'|(")(.*?)"|([^)]*))\)/gm,no=/^(?:[a-z+]+:)?\/\//i,oo=/^www\..*/i,ao=/^(data:)([^,]*),(.*)/i;function it(e,t){return (e||"").replace(io,(r,a,s,u,f,m)=>{let o=s||f||m,d=a||u||"";if(!o)return r;if(no.test(o)||oo.test(o))return `url(${d}${o}${d})`;if(ao.test(o))return `url(${d}${o}${d})`;if(o[0]==="/")return `url(${d}${so(t)+o}${d})`;let i=o.split("#")[0],h=o.substring(i.length),l=t.split("#")[0].split("/"),n=i.split("/");l.pop();for(let p of n)p!=="."&&(p===".."?l.pop():l.push(p));return `url(${d}${l.join("/")}${h}${d})`})}function je(e,t=false){return t?e.replace(/(\/\*[^*]*\*\/)|[\s;]/g,""):e.replace(/(\/\*[^*]*\*\/)|[\s;]/g,"").replace(/0px/g,"0")}function lo(e,t,r=false){let a=Array.from(t.childNodes),s=[],u=0;if(a.length>1&&e&&typeof e=="string"){let f=je(e,r),m=f.length/e.length;for(let o=1;o<a.length;o++)if(a[o].textContent&&typeof a[o].textContent=="string"){let d=je(a[o].textContent,r),i=100,h=3;for(;h<d.length&&(d[h].match(/[a-zA-Z0-9]/)||d.indexOf(d.substring(0,h),1)!==-1);h++);for(;h<d.length;h++){let l=d.substring(0,h),n=f.split(l),p=-1;if(n.length===2)p=n[0].length;else if(n.length>2&&n[0]===""&&a[o-1].textContent!=="")p=f.indexOf(l,1);else if(n.length===1){if(l=l.substring(0,l.length-1),n=f.split(l),n.length<=1)return s.push(e),s;h=i+1;}else h===d.length-1&&(p=f.indexOf(l));if(n.length>=2&&h>i){let c=a[o-1].textContent;if(c&&typeof c=="string"){let g=je(c).length;p=f.indexOf(l,g);}p===-1&&(p=n[0].length);}if(p!==-1){let c=Math.floor(p/m);for(;c>0&&c<e.length;){if(u+=1,u>50*a.length)return s.push(e),s;let g=je(e.substring(0,c),r);if(g.length===p){s.push(e.substring(0,c)),e=e.substring(c),f=f.substring(p);break}else g.length<p?c+=Math.max(1,Math.floor((p-g.length)/m)):c-=Math.max(1,Math.floor((g.length-p)*m));}break}}}}return s.push(e),s}function uo(e,t){return lo(e,t).join("/* rr_split */")}var co=1,ho=new RegExp("[^a-z0-9-_:]"),Ue=-2;function Bi(){return co++}function fo(e){if(e instanceof HTMLFormElement)return "form";let t=Ce(e.tagName);return ho.test(t)?"div":t}var Re,ps,po=/^[^ \t\n\r\u000c]+/,mo=/^[, \t\n\r\u000c]+/;function go(e,t){if(t.trim()==="")return t;let r=0;function a(u){let f,m=u.exec(t.substring(r));return m?(f=m[0],r+=f.length,f):""}let s=[];for(;a(mo),!(r>=t.length);){let u=a(po);if(u.slice(-1)===",")u=Ie(e,u.substring(0,u.length-1)),s.push(u);else {let f="";u=Ie(e,u);let m=false;for(;;){let o=t.charAt(r);if(o===""){s.push((u+f).trim());break}else if(m)o===")"&&(m=false);else if(o===","){r+=1,s.push((u+f).trim());break}else o==="("&&(m=true);f+=o,r+=1;}}}return s.join(", ")}var ms=new WeakMap;function Ie(e,t){return !t||t.trim()===""?t:zr(e,t)}function yo(e){return !!(e.tagName==="svg"||e.ownerSVGElement)}function zr(e,t){let r=ms.get(e);if(r||(r=e.createElement("a"),ms.set(e,r)),!t)t="";else if(t.startsWith("blob:")||t.startsWith("data:"))return t;return r.setAttribute("href",t),r.href}function $i(e,t,r,a){return a&&(r==="src"||r==="href"&&!(t==="use"&&a[0]==="#")||r==="xlink:href"&&a[0]!=="#"||r==="background"&&["table","td","th"].includes(t)?Ie(e,a):r==="srcset"?go(e,a):r==="style"?it(a,zr(e)):t==="object"&&r==="data"?Ie(e,a):a)}function Wi(e,t,r){return ["video","audio"].includes(e)&&t==="autoplay"}function wo(e,t,r){try{if(typeof t=="string"){if(e.classList.contains(t))return !0}else for(let a=e.classList.length;a--;){let s=e.classList[a];if(t.test(s))return !0}if(r)return e.matches(r)}catch(a){}return false}function nt(e,t,r){if(!e)return false;if(e.nodeType!==e.ELEMENT_NODE)return r?nt(Z.parentNode(e),t,r):false;for(let a=e.classList.length;a--;){let s=e.classList[a];if(t.test(s))return true}return r?nt(Z.parentNode(e),t,r):false}function zi(e,t,r,a){let s;if(Li(e)){if(s=e,!Z.childNodes(s).length)return false}else {if(Z.parentElement(e)===null)return false;s=Z.parentElement(e);}try{if(typeof t=="string"){if(a){if(s.closest(`.${t}`))return !0}else if(s.classList.contains(t))return !0}else if(nt(s,t,a))return !0;if(r){if(a){if(s.closest(r))return !0}else if(s.matches(r))return !0}}catch(u){}return false}function bo(e,t,r){let a=e.contentWindow;if(!a)return;let s=false,u;try{u=a.document.readyState;}catch(m){return}if(u!=="complete"){let m=setTimeout(()=>{s||(t(),s=true);},r);e.addEventListener("load",()=>{clearTimeout(m),s=true,t();});return}let f="about:blank";if(a.location.href!==f||e.src===f||e.src==="")return setTimeout(t,0),e.addEventListener("load",t);e.addEventListener("load",t);}function vo(e,t,r){let a=false,s;try{s=e.sheet;}catch(f){return}if(s)return;let u=setTimeout(()=>{a||(t(),a=true);},r);e.addEventListener("load",()=>{clearTimeout(u),a=true,t();});}function So(e,t){let{doc:r,mirror:a,blockClass:s,blockSelector:u,needsMask:f,inlineStylesheet:m,maskInputOptions:o={},maskTextFn:d,maskInputFn:i,dataURLOptions:h={},inlineImages:l,recordCanvas:n,keepIframeSrcFn:p,newlyAddedElement:c=false,cssCaptured:g=false}=t,S=Co(r,a);switch(e.nodeType){case e.DOCUMENT_NODE:return e.compatMode!=="CSS1Compat"?{type:J.Document,childNodes:[],compatMode:e.compatMode}:{type:J.Document,childNodes:[]};case e.DOCUMENT_TYPE_NODE:return {type:J.DocumentType,name:e.name,publicId:e.publicId,systemId:e.systemId,rootId:S};case e.ELEMENT_NODE:return xo(e,{doc:r,blockClass:s,blockSelector:u,inlineStylesheet:m,maskInputOptions:o,maskInputFn:i,dataURLOptions:h,inlineImages:l,recordCanvas:n,keepIframeSrcFn:p,newlyAddedElement:c,rootId:S});case e.TEXT_NODE:return Eo(e,{doc:r,needsMask:f,maskTextFn:d,rootId:S,cssCaptured:g});case e.CDATA_SECTION_NODE:return {type:J.CDATA,textContent:"",rootId:S};case e.COMMENT_NODE:return {type:J.Comment,textContent:Z.textContent(e)||"",rootId:S};default:return false}}function Co(e,t){if(!t.hasNode(e))return;let r=t.getId(e);return r===1?void 0:r}function Eo(e,t){let{needsMask:r,maskTextFn:a,rootId:s,cssCaptured:u}=t,f=Z.parentNode(e),m=f&&f.tagName,o="",d=m==="STYLE"?true:void 0,i=m==="SCRIPT"?true:void 0;return i?o="SCRIPT_PLACEHOLDER":u||(o=Z.textContent(e),d&&o&&(o=it(o,zr(t.doc)))),!d&&!i&&o&&r&&(o=a?a(o,Z.parentElement(e)):o.replace(/[\S]/g,"*")),{type:J.Text,textContent:o||"",rootId:s}}function xo(e,t){let{doc:r,blockClass:a,blockSelector:s,inlineStylesheet:u,maskInputOptions:f={},maskInputFn:m,dataURLOptions:o={},inlineImages:d,recordCanvas:i,keepIframeSrcFn:h,newlyAddedElement:l=false,rootId:n}=t,p=wo(e,a,s),c=fo(e),g={},S=e.attributes.length;for(let v=0;v<S;v++){let E=e.attributes[v];Wi(c,E.name,E.value)||(g[E.name]=$i(r,c,Ce(E.name),E.value));}if(c==="link"&&u){let v=Array.from(r.styleSheets).find(w=>w.href===e.href),E=null;v&&(E=Or(v)),E&&(delete g.rel,delete g.href,g._cssText=E);}if(c==="style"&&e.sheet){let v=Or(e.sheet);v&&(e.childNodes.length>1&&(v=uo(v,e)),g._cssText=v);}if(["input","textarea","select"].includes(c)){let v=e.value,E=e.checked;g.type!=="radio"&&g.type!=="checkbox"&&g.type!=="submit"&&g.type!=="button"&&v?g.value=rt({element:e,type:st(e),tagName:c,value:v,maskInputOptions:f,maskInputFn:m}):E&&(g.checked=E);}if(c==="option"&&(e.selected&&!f.select?g.selected=true:delete g.selected),c==="dialog"&&e.open&&(g.rr_open_mode=e.matches("dialog:modal")?"modal":"non-modal"),c==="canvas"&&i){if(e.__context==="2d")ro(e)||(g.rr_dataURL=e.toDataURL(o.type,o.quality));else if(!("__context"in e)){let v=e.toDataURL(o.type,o.quality),E=r.createElement("canvas");E.width=e.width,E.height=e.height;let w=E.toDataURL(o.type,o.quality);v!==w&&(g.rr_dataURL=v);}}if(c==="img"&&d){Re||(Re=r.createElement("canvas"),ps=Re.getContext("2d"));let v=e,E=v.currentSrc||v.getAttribute("src")||"<unknown-src>",w=v.crossOrigin,y=()=>{v.removeEventListener("load",y);try{Re.width=v.naturalWidth,Re.height=v.naturalHeight,ps.drawImage(v,0,0),g.rr_dataURL=Re.toDataURL(o.type,o.quality);}catch(C){if(v.crossOrigin!=="anonymous"){v.crossOrigin="anonymous",v.complete&&v.naturalWidth!==0?y():v.addEventListener("load",y);return}else console.warn(`Cannot inline img src=${E}! Error: ${C}`);}v.crossOrigin==="anonymous"&&(w?g.crossOrigin=w:v.removeAttribute("crossorigin"));};v.complete&&v.naturalWidth!==0?y():v.addEventListener("load",y);}if(["audio","video"].includes(c)){let v=g;v.rr_mediaState=e.paused?"paused":"played",v.rr_mediaCurrentTime=e.currentTime,v.rr_mediaPlaybackRate=e.playbackRate,v.rr_mediaMuted=e.muted,v.rr_mediaLoop=e.loop,v.rr_mediaVolume=e.volume;}if(l||(e.scrollLeft&&(g.rr_scrollLeft=e.scrollLeft),e.scrollTop&&(g.rr_scrollTop=e.scrollTop)),p){let{width:v,height:E}=e.getBoundingClientRect();g={class:g.class,rr_width:`${v}px`,rr_height:`${E}px`};}c==="iframe"&&!h(g.src)&&(e.contentDocument||(g.rr_src=g.src),delete g.src);let b;try{customElements.get(c)&&(b=!0);}catch(v){}return {type:J.Element,tagName:c,attributes:g,childNodes:[],isSVG:yo(e)||void 0,needBlock:p,rootId:n,isCustom:b}}function z(e){return e==null?"":e.toLowerCase()}function qi(e){return e===true||e==="all"?{script:true,comment:true,headFavicon:true,headWhitespace:true,headMetaSocial:true,headMetaRobots:true,headMetaHttpEquiv:true,headMetaVerification:true,headMetaAuthorship:e==="all",headMetaDescKeywords:e==="all",headTitleMutations:e==="all"}:e||{}}function Mo(e,t){if(t.comment&&e.type===J.Comment)return true;if(e.type===J.Element){if(t.script&&(e.tagName==="script"||e.tagName==="link"&&(e.attributes.rel==="preload"&&e.attributes.as==="script"||e.attributes.rel==="modulepreload")||e.tagName==="link"&&e.attributes.rel==="prefetch"&&typeof e.attributes.href=="string"&&Ui(e.attributes.href)==="js"))return true;if(t.headFavicon&&(e.tagName==="link"&&e.attributes.rel==="shortcut icon"||e.tagName==="meta"&&(z(e.attributes.name).match(/^msapplication-tile(image|color)$/)||z(e.attributes.name)==="application-name"||z(e.attributes.rel)==="icon"||z(e.attributes.rel)==="apple-touch-icon"||z(e.attributes.rel)==="shortcut icon")))return true;if(e.tagName==="meta"){if(t.headMetaDescKeywords&&z(e.attributes.name).match(/^description|keywords$/))return true;if(t.headMetaSocial&&(z(e.attributes.property).match(/^(og|twitter|fb):/)||z(e.attributes.name).match(/^(og|twitter):/)||z(e.attributes.name)==="pinterest"))return true;if(t.headMetaRobots&&(z(e.attributes.name)==="robots"||z(e.attributes.name)==="googlebot"||z(e.attributes.name)==="bingbot"))return true;if(t.headMetaHttpEquiv&&e.attributes["http-equiv"]!==void 0)return true;if(t.headMetaAuthorship&&(z(e.attributes.name)==="author"||z(e.attributes.name)==="generator"||z(e.attributes.name)==="framework"||z(e.attributes.name)==="publisher"||z(e.attributes.name)==="progid"||z(e.attributes.property).match(/^article:/)||z(e.attributes.property).match(/^product:/)))return true;if(t.headMetaVerification&&(z(e.attributes.name)==="google-site-verification"||z(e.attributes.name)==="yandex-verification"||z(e.attributes.name)==="csrf-token"||z(e.attributes.name)==="p:domain_verify"||z(e.attributes.name)==="verify-v1"||z(e.attributes.name)==="verification"||z(e.attributes.name)==="shopify-checkout-api-token"))return true}}return false}function Ae(e,t){let{doc:r,mirror:a,blockClass:s,blockSelector:u,maskTextClass:f,maskTextSelector:m,skipChild:o=false,inlineStylesheet:d=true,maskInputOptions:i={},maskTextFn:h,maskInputFn:l,slimDOMOptions:n,dataURLOptions:p={},inlineImages:c=false,recordCanvas:g=false,onSerialize:S,onIframeLoad:b,iframeLoadTimeout:v=5e3,onStylesheetLoad:E,stylesheetLoadTimeout:w=5e3,keepIframeSrcFn:y=()=>false,newlyAddedElement:C=false,cssCaptured:M=false}=t,{needsMask:O}=t,{preserveWhiteSpace:R=true}=t;O||(O=zi(e,f,m,O===void 0));let D=So(e,{doc:r,mirror:a,blockClass:s,blockSelector:u,needsMask:O,inlineStylesheet:d,maskInputOptions:i,maskTextFn:h,maskInputFn:l,dataURLOptions:p,inlineImages:c,recordCanvas:g,keepIframeSrcFn:y,newlyAddedElement:C,cssCaptured:M});if(!D)return console.warn(e,"not serialized"),null;let A;a.hasNode(e)?A=a.getId(e):Mo(D,n)||!R&&D.type===J.Text&&!D.textContent.replace(/^\s+|\s+$/gm,"").length?A=Ue:A=Bi();let x=Object.assign(D,{id:A});if(a.add(e,x),A===Ue)return null;S&&S(e);let ae=!o;if(x.type===J.Element){ae=ae&&!x.needBlock,delete x.needBlock;let U=Z.shadowRoot(e);U&&Le(U)&&(x.isShadowHost=true);}if((x.type===J.Document||x.type===J.Element)&&ae){n.headWhitespace&&x.type===J.Element&&x.tagName==="head"&&(R=false);let U={doc:r,mirror:a,blockClass:s,blockSelector:u,needsMask:O,maskTextClass:f,maskTextSelector:m,skipChild:o,inlineStylesheet:d,maskInputOptions:i,maskTextFn:h,maskInputFn:l,slimDOMOptions:n,dataURLOptions:p,inlineImages:c,recordCanvas:g,preserveWhiteSpace:R,onSerialize:S,onIframeLoad:b,iframeLoadTimeout:v,onStylesheetLoad:E,stylesheetLoadTimeout:w,keepIframeSrcFn:y,cssCaptured:false};if(!(x.type===J.Element&&x.tagName==="textarea"&&x.attributes.value!==void 0)){x.type===J.Element&&x.attributes._cssText!==void 0&&typeof x.attributes._cssText=="string"&&(U.cssCaptured=true);for(let H of Array.from(Z.childNodes(e))){let Q=Ae(H,U);Q&&x.childNodes.push(Q);}}let F=null;if(Li(e)&&(F=Z.shadowRoot(e)))for(let H of Array.from(Z.childNodes(F))){let Q=Ae(H,U);Q&&(Le(F)&&(Q.isShadow=true),x.childNodes.push(Q));}}let se=Z.parentNode(e);return se&&Pe(se)&&Le(se)&&(x.isShadow=true),x.type===J.Element&&x.tagName==="iframe"&&bo(e,()=>{let U=e.contentDocument;if(U&&b){let F=Ae(U,{doc:U,mirror:a,blockClass:s,blockSelector:u,needsMask:O,maskTextClass:f,maskTextSelector:m,skipChild:false,inlineStylesheet:d,maskInputOptions:i,maskTextFn:h,maskInputFn:l,slimDOMOptions:n,dataURLOptions:p,inlineImages:c,recordCanvas:g,preserveWhiteSpace:R,onSerialize:S,onIframeLoad:b,iframeLoadTimeout:v,onStylesheetLoad:E,stylesheetLoadTimeout:w,keepIframeSrcFn:y});F&&b(e,F);}},v),x.type===J.Element&&x.tagName==="link"&&typeof x.attributes.rel=="string"&&(x.attributes.rel==="stylesheet"||x.attributes.rel==="preload"&&typeof x.attributes.href=="string"&&Ui(x.attributes.href)==="css")&&vo(e,()=>{if(E){let U=Ae(e,{doc:r,mirror:a,blockClass:s,blockSelector:u,needsMask:O,maskTextClass:f,maskTextSelector:m,skipChild:false,inlineStylesheet:d,maskInputOptions:i,maskTextFn:h,maskInputFn:l,slimDOMOptions:n,dataURLOptions:p,inlineImages:c,recordCanvas:g,preserveWhiteSpace:R,onSerialize:S,onIframeLoad:b,iframeLoadTimeout:v,onStylesheetLoad:E,stylesheetLoadTimeout:w,keepIframeSrcFn:y});U&&E(e,U);}},w),x}function Ro(e,t){let{mirror:r=new tt,blockClass:a="rr-block",blockSelector:s=null,maskTextClass:u="rr-mask",maskTextSelector:f=null,inlineStylesheet:m=true,inlineImages:o=false,recordCanvas:d=false,maskAllInputs:i=false,maskTextFn:h,maskInputFn:l,slimDOM:n=false,dataURLOptions:p,preserveWhiteSpace:c,onSerialize:g,onIframeLoad:S,iframeLoadTimeout:b,onStylesheetLoad:v,stylesheetLoadTimeout:E,keepIframeSrcFn:w=()=>false}=t,y=i===true?{color:true,date:true,"datetime-local":true,email:true,month:true,number:true,range:true,search:true,tel:true,text:true,time:true,url:true,week:true,textarea:true,select:true,password:true}:i===false?{password:true}:i,C=qi(n);return Ae(e,{doc:e,mirror:r,blockClass:a,blockSelector:s,maskTextClass:u,maskTextSelector:f,skipChild:false,inlineStylesheet:m,maskInputOptions:y,maskTextFn:h,maskInputFn:l,slimDOMOptions:C,dataURLOptions:p,inlineImages:o,recordCanvas:d,preserveWhiteSpace:c,onSerialize:g,onIframeLoad:S,iframeLoadTimeout:b,onStylesheetLoad:v,stylesheetLoadTimeout:E,keepIframeSrcFn:w,newlyAddedElement:false})}function Oo(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}function Io(e){if(e.__esModule)return e;var t=e.default;if(typeof t=="function"){var r=function a(){return this instanceof a?Reflect.construct(t,arguments,this.constructor):t.apply(this,arguments)};r.prototype=t.prototype;}else r={};return Object.defineProperty(r,"__esModule",{value:true}),Object.keys(e).forEach(function(a){var s=Object.getOwnPropertyDescriptor(e,a);Object.defineProperty(r,a,s.get?s:{enumerable:true,get:function(){return e[a]}});}),r}var Ge={exports:{}},gs;function Ao(){if(gs)return Ge.exports;gs=1;var e=String,t=function(){return {isColorSupported:false,reset:e,bold:e,dim:e,italic:e,underline:e,inverse:e,hidden:e,strikethrough:e,black:e,red:e,green:e,yellow:e,blue:e,magenta:e,cyan:e,white:e,gray:e,bgBlack:e,bgRed:e,bgGreen:e,bgYellow:e,bgBlue:e,bgMagenta:e,bgCyan:e,bgWhite:e}};return Ge.exports=t(),Ge.exports.createColors=t,Ge.exports}var To={},Do=Object.freeze(Object.defineProperty({__proto__:null,default:To},Symbol.toStringTag,{value:"Module"})),ce=Io(Do),xt,ys;function qr(){if(ys)return xt;ys=1;let e=Ao(),t=ce;class r extends Error{constructor(s,u,f,m,o,d){super(s),this.name="CssSyntaxError",this.reason=s,o&&(this.file=o),m&&(this.source=m),d&&(this.plugin=d),typeof u!="undefined"&&typeof f!="undefined"&&(typeof u=="number"?(this.line=u,this.column=f):(this.line=u.line,this.column=u.column,this.endLine=f.line,this.endColumn=f.column)),this.setMessage(),Error.captureStackTrace&&Error.captureStackTrace(this,r);}setMessage(){this.message=this.plugin?this.plugin+": ":"",this.message+=this.file?this.file:"<css input>",typeof this.line!="undefined"&&(this.message+=":"+this.line+":"+this.column),this.message+=": "+this.reason;}showSourceCode(s){if(!this.source)return "";let u=this.source;s==null&&(s=e.isColorSupported),t&&s&&(u=t(u));let f=u.split(/\r?\n/),m=Math.max(this.line-3,0),o=Math.min(this.line+2,f.length),d=String(o).length,i,h;if(s){let{bold:l,gray:n,red:p}=e.createColors(true);i=c=>l(p(c)),h=c=>n(c);}else i=h=l=>l;return f.slice(m,o).map((l,n)=>{let p=m+1+n,c=" "+(" "+p).slice(-d)+" | ";if(p===this.line){let g=h(c.replace(/\d/g," "))+l.slice(0,this.column-1).replace(/[^\t]/g," ");return i(">")+h(c)+l+`
|
|
2
|
+
`+g+i("^")}return " "+h(c)+l}).join(`
|
|
3
|
+
`)}toString(){let s=this.showSourceCode();return s&&(s=`
|
|
4
|
+
|
|
5
|
+
`+s+`
|
|
6
|
+
`),this.name+": "+this.message+s}}return xt=r,r.default=r,xt}var He={},ws;function Vr(){return ws||(ws=1,He.isClean=Symbol("isClean"),He.my=Symbol("my")),He}var Mt,bs;function Vi(){if(bs)return Mt;bs=1;let e={after:`
|
|
7
|
+
`,beforeClose:`
|
|
8
|
+
`,beforeComment:`
|
|
9
|
+
`,beforeDecl:`
|
|
10
|
+
`,beforeOpen:" ",beforeRule:`
|
|
11
|
+
`,colon:": ",commentLeft:" ",commentRight:" ",emptyBody:"",indent:" ",semicolon:false};function t(a){return a[0].toUpperCase()+a.slice(1)}class r{constructor(s){this.builder=s;}atrule(s,u){let f="@"+s.name,m=s.params?this.rawValue(s,"params"):"";if(typeof s.raws.afterName!="undefined"?f+=s.raws.afterName:m&&(f+=" "),s.nodes)this.block(s,f+m);else {let o=(s.raws.between||"")+(u?";":"");this.builder(f+m+o,s);}}beforeAfter(s,u){let f;s.type==="decl"?f=this.raw(s,null,"beforeDecl"):s.type==="comment"?f=this.raw(s,null,"beforeComment"):u==="before"?f=this.raw(s,null,"beforeRule"):f=this.raw(s,null,"beforeClose");let m=s.parent,o=0;for(;m&&m.type!=="root";)o+=1,m=m.parent;if(f.includes(`
|
|
12
|
+
`)){let d=this.raw(s,null,"indent");if(d.length)for(let i=0;i<o;i++)f+=d;}return f}block(s,u){let f=this.raw(s,"between","beforeOpen");this.builder(u+f+"{",s,"start");let m;s.nodes&&s.nodes.length?(this.body(s),m=this.raw(s,"after")):m=this.raw(s,"after","emptyBody"),m&&this.builder(m),this.builder("}",s,"end");}body(s){let u=s.nodes.length-1;for(;u>0&&s.nodes[u].type==="comment";)u-=1;let f=this.raw(s,"semicolon");for(let m=0;m<s.nodes.length;m++){let o=s.nodes[m],d=this.raw(o,"before");d&&this.builder(d),this.stringify(o,u!==m||f);}}comment(s){let u=this.raw(s,"left","commentLeft"),f=this.raw(s,"right","commentRight");this.builder("/*"+u+s.text+f+"*/",s);}decl(s,u){let f=this.raw(s,"between","colon"),m=s.prop+f+this.rawValue(s,"value");s.important&&(m+=s.raws.important||" !important"),u&&(m+=";"),this.builder(m,s);}document(s){this.body(s);}raw(s,u,f){let m;if(f||(f=u),u&&(m=s.raws[u],typeof m!="undefined"))return m;let o=s.parent;if(f==="before"&&(!o||o.type==="root"&&o.first===s||o&&o.type==="document"))return "";if(!o)return e[f];let d=s.root();if(d.rawCache||(d.rawCache={}),typeof d.rawCache[f]!="undefined")return d.rawCache[f];if(f==="before"||f==="after")return this.beforeAfter(s,f);{let i="raw"+t(f);this[i]?m=this[i](d,s):d.walk(h=>{if(m=h.raws[u],typeof m!="undefined")return false});}return typeof m=="undefined"&&(m=e[f]),d.rawCache[f]=m,m}rawBeforeClose(s){let u;return s.walk(f=>{if(f.nodes&&f.nodes.length>0&&typeof f.raws.after!="undefined")return u=f.raws.after,u.includes(`
|
|
13
|
+
`)&&(u=u.replace(/[^\n]+$/,"")),false}),u&&(u=u.replace(/\S/g,"")),u}rawBeforeComment(s,u){let f;return s.walkComments(m=>{if(typeof m.raws.before!="undefined")return f=m.raws.before,f.includes(`
|
|
14
|
+
`)&&(f=f.replace(/[^\n]+$/,"")),false}),typeof f=="undefined"?f=this.raw(u,null,"beforeDecl"):f&&(f=f.replace(/\S/g,"")),f}rawBeforeDecl(s,u){let f;return s.walkDecls(m=>{if(typeof m.raws.before!="undefined")return f=m.raws.before,f.includes(`
|
|
15
|
+
`)&&(f=f.replace(/[^\n]+$/,"")),false}),typeof f=="undefined"?f=this.raw(u,null,"beforeRule"):f&&(f=f.replace(/\S/g,"")),f}rawBeforeOpen(s){let u;return s.walk(f=>{if(f.type!=="decl"&&(u=f.raws.between,typeof u!="undefined"))return false}),u}rawBeforeRule(s){let u;return s.walk(f=>{if(f.nodes&&(f.parent!==s||s.first!==f)&&typeof f.raws.before!="undefined")return u=f.raws.before,u.includes(`
|
|
16
|
+
`)&&(u=u.replace(/[^\n]+$/,"")),false}),u&&(u=u.replace(/\S/g,"")),u}rawColon(s){let u;return s.walkDecls(f=>{if(typeof f.raws.between!="undefined")return u=f.raws.between.replace(/[^\s:]/g,""),false}),u}rawEmptyBody(s){let u;return s.walk(f=>{if(f.nodes&&f.nodes.length===0&&(u=f.raws.after,typeof u!="undefined"))return false}),u}rawIndent(s){if(s.raws.indent)return s.raws.indent;let u;return s.walk(f=>{let m=f.parent;if(m&&m!==s&&m.parent&&m.parent===s&&typeof f.raws.before!="undefined"){let o=f.raws.before.split(`
|
|
17
|
+
`);return u=o[o.length-1],u=u.replace(/\S/g,""),false}}),u}rawSemicolon(s){let u;return s.walk(f=>{if(f.nodes&&f.nodes.length&&f.last.type==="decl"&&(u=f.raws.semicolon,typeof u!="undefined"))return false}),u}rawValue(s,u){let f=s[u],m=s.raws[u];return m&&m.value===f?m.raw:f}root(s){this.body(s),s.raws.after&&this.builder(s.raws.after);}rule(s){this.block(s,this.rawValue(s,"selector")),s.raws.ownSemicolon&&this.builder(s.raws.ownSemicolon,s,"end");}stringify(s,u){if(!this[s.type])throw new Error("Unknown AST node type "+s.type+". Maybe you need to change PostCSS stringifier.");this[s.type](s,u);}}return Mt=r,r.default=r,Mt}var Rt,vs;function ut(){if(vs)return Rt;vs=1;let e=Vi();function t(r,a){new e(a).stringify(r);}return Rt=t,t.default=t,Rt}var Nt,Ss;function ct(){if(Ss)return Nt;Ss=1;let{isClean:e,my:t}=Vr(),r=qr(),a=Vi(),s=ut();function u(m,o){let d=new m.constructor;for(let i in m){if(!Object.prototype.hasOwnProperty.call(m,i)||i==="proxyCache")continue;let h=m[i],l=typeof h;i==="parent"&&l==="object"?o&&(d[i]=o):i==="source"?d[i]=h:Array.isArray(h)?d[i]=h.map(n=>u(n,d)):(l==="object"&&h!==null&&(h=u(h)),d[i]=h);}return d}class f{constructor(o={}){this.raws={},this[e]=false,this[t]=true;for(let d in o)if(d==="nodes"){this.nodes=[];for(let i of o[d])typeof i.clone=="function"?this.append(i.clone()):this.append(i);}else this[d]=o[d];}addToError(o){if(o.postcssNode=this,o.stack&&this.source&&/\n\s{4}at /.test(o.stack)){let d=this.source;o.stack=o.stack.replace(/\n\s{4}at /,`$&${d.input.from}:${d.start.line}:${d.start.column}$&`);}return o}after(o){return this.parent.insertAfter(this,o),this}assign(o={}){for(let d in o)this[d]=o[d];return this}before(o){return this.parent.insertBefore(this,o),this}cleanRaws(o){delete this.raws.before,delete this.raws.after,o||delete this.raws.between;}clone(o={}){let d=u(this);for(let i in o)d[i]=o[i];return d}cloneAfter(o={}){let d=this.clone(o);return this.parent.insertAfter(this,d),d}cloneBefore(o={}){let d=this.clone(o);return this.parent.insertBefore(this,d),d}error(o,d={}){if(this.source){let{end:i,start:h}=this.rangeBy(d);return this.source.input.error(o,{column:h.column,line:h.line},{column:i.column,line:i.line},d)}return new r(o)}getProxyProcessor(){return {get(o,d){return d==="proxyOf"?o:d==="root"?()=>o.root().toProxy():o[d]},set(o,d,i){return o[d]===i||(o[d]=i,(d==="prop"||d==="value"||d==="name"||d==="params"||d==="important"||d==="text")&&o.markDirty()),true}}}markDirty(){if(this[e]){this[e]=false;let o=this;for(;o=o.parent;)o[e]=false;}}next(){if(!this.parent)return;let o=this.parent.index(this);return this.parent.nodes[o+1]}positionBy(o,d){let i=this.source.start;if(o.index)i=this.positionInside(o.index,d);else if(o.word){d=this.toString();let h=d.indexOf(o.word);h!==-1&&(i=this.positionInside(h,d));}return i}positionInside(o,d){let i=d||this.toString(),h=this.source.start.column,l=this.source.start.line;for(let n=0;n<o;n++)i[n]===`
|
|
18
|
+
`?(h=1,l+=1):h+=1;return {column:h,line:l}}prev(){if(!this.parent)return;let o=this.parent.index(this);return this.parent.nodes[o-1]}rangeBy(o){let d={column:this.source.start.column,line:this.source.start.line},i=this.source.end?{column:this.source.end.column+1,line:this.source.end.line}:{column:d.column+1,line:d.line};if(o.word){let h=this.toString(),l=h.indexOf(o.word);l!==-1&&(d=this.positionInside(l,h),i=this.positionInside(l+o.word.length,h));}else o.start?d={column:o.start.column,line:o.start.line}:o.index&&(d=this.positionInside(o.index)),o.end?i={column:o.end.column,line:o.end.line}:typeof o.endIndex=="number"?i=this.positionInside(o.endIndex):o.index&&(i=this.positionInside(o.index+1));return (i.line<d.line||i.line===d.line&&i.column<=d.column)&&(i={column:d.column+1,line:d.line}),{end:i,start:d}}raw(o,d){return new a().raw(this,o,d)}remove(){return this.parent&&this.parent.removeChild(this),this.parent=void 0,this}replaceWith(...o){if(this.parent){let d=this,i=false;for(let h of o)h===this?i=true:i?(this.parent.insertAfter(d,h),d=h):this.parent.insertBefore(d,h);i||this.remove();}return this}root(){let o=this;for(;o.parent&&o.parent.type!=="document";)o=o.parent;return o}toJSON(o,d){let i={},h=d==null;d=d||new Map;let l=0;for(let n in this){if(!Object.prototype.hasOwnProperty.call(this,n)||n==="parent"||n==="proxyCache")continue;let p=this[n];if(Array.isArray(p))i[n]=p.map(c=>typeof c=="object"&&c.toJSON?c.toJSON(null,d):c);else if(typeof p=="object"&&p.toJSON)i[n]=p.toJSON(null,d);else if(n==="source"){let c=d.get(p.input);c==null&&(c=l,d.set(p.input,l),l++),i[n]={end:p.end,inputId:c,start:p.start};}else i[n]=p;}return h&&(i.inputs=[...d.keys()].map(n=>n.toJSON())),i}toProxy(){return this.proxyCache||(this.proxyCache=new Proxy(this,this.getProxyProcessor())),this.proxyCache}toString(o=s){o.stringify&&(o=o.stringify);let d="";return o(this,i=>{d+=i;}),d}warn(o,d,i){let h={node:this};for(let l in i)h[l]=i[l];return o.warn(d,h)}get proxyOf(){return this}}return Nt=f,f.default=f,Nt}var Ot,Cs;function ht(){if(Cs)return Ot;Cs=1;let e=ct();class t extends e{constructor(a){a&&typeof a.value!="undefined"&&typeof a.value!="string"&&(a={...a,value:String(a.value)}),super(a),this.type="decl";}get variable(){return this.prop.startsWith("--")||this.prop[0]==="$"}}return Ot=t,t.default=t,Ot}var It,Es;function _o(){if(Es)return It;Es=1;let e="useandom-26T198340PX75pxJACKVERYMINDBUSHWOLF_GQZbfghjklqvwyzrict";return It={nanoid:(a=21)=>{let s="",u=a;for(;u--;)s+=e[Math.random()*64|0];return s},customAlphabet:(a,s=21)=>(u=s)=>{let f="",m=u;for(;m--;)f+=a[Math.random()*a.length|0];return f}},It}var At,xs;function ji(){if(xs)return At;xs=1;let{SourceMapConsumer:e,SourceMapGenerator:t}=ce,{existsSync:r,readFileSync:a}=ce,{dirname:s,join:u}=ce;function f(o){return Buffer?Buffer.from(o,"base64").toString():window.atob(o)}class m{constructor(d,i){if(i.map===false)return;this.loadAnnotation(d),this.inline=this.startWith(this.annotation,"data:");let h=i.map?i.map.prev:void 0,l=this.loadMap(i.from,h);!this.mapFile&&i.from&&(this.mapFile=i.from),this.mapFile&&(this.root=s(this.mapFile)),l&&(this.text=l);}consumer(){return this.consumerCache||(this.consumerCache=new e(this.text)),this.consumerCache}decodeInline(d){let i=/^data:application\/json;charset=utf-?8;base64,/,h=/^data:application\/json;base64,/,l=/^data:application\/json;charset=utf-?8,/,n=/^data:application\/json,/;if(l.test(d)||n.test(d))return decodeURIComponent(d.substr(RegExp.lastMatch.length));if(i.test(d)||h.test(d))return f(d.substr(RegExp.lastMatch.length));let p=d.match(/data:application\/json;([^,]+),/)[1];throw new Error("Unsupported source map encoding "+p)}getAnnotationURL(d){return d.replace(/^\/\*\s*# sourceMappingURL=/,"").trim()}isMap(d){return typeof d!="object"?false:typeof d.mappings=="string"||typeof d._mappings=="string"||Array.isArray(d.sections)}loadAnnotation(d){let i=d.match(/\/\*\s*# sourceMappingURL=/gm);if(!i)return;let h=d.lastIndexOf(i.pop()),l=d.indexOf("*/",h);h>-1&&l>-1&&(this.annotation=this.getAnnotationURL(d.substring(h,l)));}loadFile(d){if(this.root=s(d),r(d))return this.mapFile=d,a(d,"utf-8").toString().trim()}loadMap(d,i){if(i===false)return false;if(i){if(typeof i=="string")return i;if(typeof i=="function"){let h=i(d);if(h){let l=this.loadFile(h);if(!l)throw new Error("Unable to load previous source map: "+h.toString());return l}}else {if(i instanceof e)return t.fromSourceMap(i).toString();if(i instanceof t)return i.toString();if(this.isMap(i))return JSON.stringify(i);throw new Error("Unsupported previous source map format: "+i.toString())}}else {if(this.inline)return this.decodeInline(this.annotation);if(this.annotation){let h=this.annotation;return d&&(h=u(s(d),h)),this.loadFile(h)}}}startWith(d,i){return d?d.substr(0,i.length)===i:false}withContent(){return !!(this.consumer().sourcesContent&&this.consumer().sourcesContent.length>0)}}return At=m,m.default=m,At}var Tt,Ms;function ft(){if(Ms)return Tt;Ms=1;let{SourceMapConsumer:e,SourceMapGenerator:t}=ce,{fileURLToPath:r,pathToFileURL:a}=ce,{isAbsolute:s,resolve:u}=ce,{nanoid:f}=_o(),m=ce,o=qr(),d=ji(),i=Symbol("fromOffsetCache"),h=!!(e&&t),l=!!(u&&s);class n{constructor(c,g={}){if(c===null||typeof c=="undefined"||typeof c=="object"&&!c.toString)throw new Error(`PostCSS received ${c} instead of CSS string`);if(this.css=c.toString(),this.css[0]==="\uFEFF"||this.css[0]==="\uFFFE"?(this.hasBOM=true,this.css=this.css.slice(1)):this.hasBOM=false,g.from&&(!l||/^\w+:\/\//.test(g.from)||s(g.from)?this.file=g.from:this.file=u(g.from)),l&&h){let S=new d(this.css,g);if(S.text){this.map=S;let b=S.consumer().file;!this.file&&b&&(this.file=this.mapResolve(b));}}this.file||(this.id="<input css "+f(6)+">"),this.map&&(this.map.file=this.from);}error(c,g,S,b={}){let v,E,w;if(g&&typeof g=="object"){let C=g,M=S;if(typeof C.offset=="number"){let O=this.fromOffset(C.offset);g=O.line,S=O.col;}else g=C.line,S=C.column;if(typeof M.offset=="number"){let O=this.fromOffset(M.offset);E=O.line,w=O.col;}else E=M.line,w=M.column;}else if(!S){let C=this.fromOffset(g);g=C.line,S=C.col;}let y=this.origin(g,S,E,w);return y?v=new o(c,y.endLine===void 0?y.line:{column:y.column,line:y.line},y.endLine===void 0?y.column:{column:y.endColumn,line:y.endLine},y.source,y.file,b.plugin):v=new o(c,E===void 0?g:{column:S,line:g},E===void 0?S:{column:w,line:E},this.css,this.file,b.plugin),v.input={column:S,endColumn:w,endLine:E,line:g,source:this.css},this.file&&(a&&(v.input.url=a(this.file).toString()),v.input.file=this.file),v}fromOffset(c){let g,S;if(this[i])S=this[i];else {let v=this.css.split(`
|
|
19
|
+
`);S=new Array(v.length);let E=0;for(let w=0,y=v.length;w<y;w++)S[w]=E,E+=v[w].length+1;this[i]=S;}g=S[S.length-1];let b=0;if(c>=g)b=S.length-1;else {let v=S.length-2,E;for(;b<v;)if(E=b+(v-b>>1),c<S[E])v=E-1;else if(c>=S[E+1])b=E+1;else {b=E;break}}return {col:c-S[b]+1,line:b+1}}mapResolve(c){return /^\w+:\/\//.test(c)?c:u(this.map.consumer().sourceRoot||this.map.root||".",c)}origin(c,g,S,b){if(!this.map)return false;let v=this.map.consumer(),E=v.originalPositionFor({column:g,line:c});if(!E.source)return false;let w;typeof S=="number"&&(w=v.originalPositionFor({column:b,line:S}));let y;s(E.source)?y=a(E.source):y=new URL(E.source,this.map.consumer().sourceRoot||a(this.map.mapFile));let C={column:E.column,endColumn:w&&w.column,endLine:w&&w.line,line:E.line,url:y.toString()};if(y.protocol==="file:")if(r)C.file=r(y);else throw new Error("file: protocol is not available in this PostCSS build");let M=v.sourceContentFor(E.source);return M&&(C.source=M),C}toJSON(){let c={};for(let g of ["hasBOM","css","file","id"])this[g]!=null&&(c[g]=this[g]);return this.map&&(c.map={...this.map},c.map.consumerCache&&(c.map.consumerCache=void 0)),c}get from(){return this.file||this.id}}return Tt=n,n.default=n,m&&m.registerInput&&m.registerInput(n),Tt}var Dt,Rs;function Gi(){if(Rs)return Dt;Rs=1;let{SourceMapConsumer:e,SourceMapGenerator:t}=ce,{dirname:r,relative:a,resolve:s,sep:u}=ce,{pathToFileURL:f}=ce,m=ft(),o=!!(e&&t),d=!!(r&&s&&a&&u);class i{constructor(l,n,p,c){this.stringify=l,this.mapOpts=p.map||{},this.root=n,this.opts=p,this.css=c,this.originalCSS=c,this.usesFileUrls=!this.mapOpts.from&&this.mapOpts.absolute,this.memoizedFileURLs=new Map,this.memoizedPaths=new Map,this.memoizedURLs=new Map;}addAnnotation(){let l;this.isInline()?l="data:application/json;base64,"+this.toBase64(this.map.toString()):typeof this.mapOpts.annotation=="string"?l=this.mapOpts.annotation:typeof this.mapOpts.annotation=="function"?l=this.mapOpts.annotation(this.opts.to,this.root):l=this.outputFile()+".map";let n=`
|
|
20
|
+
`;this.css.includes(`\r
|
|
21
|
+
`)&&(n=`\r
|
|
22
|
+
`),this.css+=n+"/*# sourceMappingURL="+l+" */";}applyPrevMaps(){for(let l of this.previous()){let n=this.toUrl(this.path(l.file)),p=l.root||r(l.file),c;this.mapOpts.sourcesContent===false?(c=new e(l.text),c.sourcesContent&&(c.sourcesContent=null)):c=l.consumer(),this.map.applySourceMap(c,n,this.toUrl(this.path(p)));}}clearAnnotation(){if(this.mapOpts.annotation!==false)if(this.root){let l;for(let n=this.root.nodes.length-1;n>=0;n--)l=this.root.nodes[n],l.type==="comment"&&l.text.indexOf("# sourceMappingURL=")===0&&this.root.removeChild(n);}else this.css&&(this.css=this.css.replace(/\n*?\/\*#[\S\s]*?\*\/$/gm,""));}generate(){if(this.clearAnnotation(),d&&o&&this.isMap())return this.generateMap();{let l="";return this.stringify(this.root,n=>{l+=n;}),[l]}}generateMap(){if(this.root)this.generateString();else if(this.previous().length===1){let l=this.previous()[0].consumer();l.file=this.outputFile(),this.map=t.fromSourceMap(l,{ignoreInvalidMapping:true});}else this.map=new t({file:this.outputFile(),ignoreInvalidMapping:true}),this.map.addMapping({generated:{column:0,line:1},original:{column:0,line:1},source:this.opts.from?this.toUrl(this.path(this.opts.from)):"<no source>"});return this.isSourcesContent()&&this.setSourcesContent(),this.root&&this.previous().length>0&&this.applyPrevMaps(),this.isAnnotation()&&this.addAnnotation(),this.isInline()?[this.css]:[this.css,this.map]}generateString(){this.css="",this.map=new t({file:this.outputFile(),ignoreInvalidMapping:true});let l=1,n=1,p="<no source>",c={generated:{column:0,line:0},original:{column:0,line:0},source:""},g,S;this.stringify(this.root,(b,v,E)=>{if(this.css+=b,v&&E!=="end"&&(c.generated.line=l,c.generated.column=n-1,v.source&&v.source.start?(c.source=this.sourcePath(v),c.original.line=v.source.start.line,c.original.column=v.source.start.column-1,this.map.addMapping(c)):(c.source=p,c.original.line=1,c.original.column=0,this.map.addMapping(c))),g=b.match(/\n/g),g?(l+=g.length,S=b.lastIndexOf(`
|
|
23
|
+
`),n=b.length-S):n+=b.length,v&&E!=="start"){let w=v.parent||{raws:{}};(!(v.type==="decl"||v.type==="atrule"&&!v.nodes)||v!==w.last||w.raws.semicolon)&&(v.source&&v.source.end?(c.source=this.sourcePath(v),c.original.line=v.source.end.line,c.original.column=v.source.end.column-1,c.generated.line=l,c.generated.column=n-2,this.map.addMapping(c)):(c.source=p,c.original.line=1,c.original.column=0,c.generated.line=l,c.generated.column=n-1,this.map.addMapping(c)));}});}isAnnotation(){return this.isInline()?true:typeof this.mapOpts.annotation!="undefined"?this.mapOpts.annotation:this.previous().length?this.previous().some(l=>l.annotation):true}isInline(){if(typeof this.mapOpts.inline!="undefined")return this.mapOpts.inline;let l=this.mapOpts.annotation;return typeof l!="undefined"&&l!==true?false:this.previous().length?this.previous().some(n=>n.inline):true}isMap(){return typeof this.opts.map!="undefined"?!!this.opts.map:this.previous().length>0}isSourcesContent(){return typeof this.mapOpts.sourcesContent!="undefined"?this.mapOpts.sourcesContent:this.previous().length?this.previous().some(l=>l.withContent()):true}outputFile(){return this.opts.to?this.path(this.opts.to):this.opts.from?this.path(this.opts.from):"to.css"}path(l){if(this.mapOpts.absolute||l.charCodeAt(0)===60||/^\w+:\/\//.test(l))return l;let n=this.memoizedPaths.get(l);if(n)return n;let p=this.opts.to?r(this.opts.to):".";typeof this.mapOpts.annotation=="string"&&(p=r(s(p,this.mapOpts.annotation)));let c=a(p,l);return this.memoizedPaths.set(l,c),c}previous(){if(!this.previousMaps)if(this.previousMaps=[],this.root)this.root.walk(l=>{if(l.source&&l.source.input.map){let n=l.source.input.map;this.previousMaps.includes(n)||this.previousMaps.push(n);}});else {let l=new m(this.originalCSS,this.opts);l.map&&this.previousMaps.push(l.map);}return this.previousMaps}setSourcesContent(){let l={};if(this.root)this.root.walk(n=>{if(n.source){let p=n.source.input.from;if(p&&!l[p]){l[p]=true;let c=this.usesFileUrls?this.toFileUrl(p):this.toUrl(this.path(p));this.map.setSourceContent(c,n.source.input.css);}}});else if(this.css){let n=this.opts.from?this.toUrl(this.path(this.opts.from)):"<no source>";this.map.setSourceContent(n,this.css);}}sourcePath(l){return this.mapOpts.from?this.toUrl(this.mapOpts.from):this.usesFileUrls?this.toFileUrl(l.source.input.from):this.toUrl(this.path(l.source.input.from))}toBase64(l){return Buffer?Buffer.from(l).toString("base64"):window.btoa(unescape(encodeURIComponent(l)))}toFileUrl(l){let n=this.memoizedFileURLs.get(l);if(n)return n;if(f){let p=f(l).toString();return this.memoizedFileURLs.set(l,p),p}else throw new Error("`map.absolute` option is not available in this PostCSS build")}toUrl(l){let n=this.memoizedURLs.get(l);if(n)return n;u==="\\"&&(l=l.replace(/\\/g,"/"));let p=encodeURI(l).replace(/[#?]/g,encodeURIComponent);return this.memoizedURLs.set(l,p),p}}return Dt=i,Dt}var _t,Ns;function dt(){if(Ns)return _t;Ns=1;let e=ct();class t extends e{constructor(a){super(a),this.type="comment";}}return _t=t,t.default=t,_t}var kt,Os;function Ee(){if(Os)return kt;Os=1;let{isClean:e,my:t}=Vr(),r=ht(),a=dt(),s=ct(),u,f,m,o;function d(l){return l.map(n=>(n.nodes&&(n.nodes=d(n.nodes)),delete n.source,n))}function i(l){if(l[e]=false,l.proxyOf.nodes)for(let n of l.proxyOf.nodes)i(n);}class h extends s{append(...n){for(let p of n){let c=this.normalize(p,this.last);for(let g of c)this.proxyOf.nodes.push(g);}return this.markDirty(),this}cleanRaws(n){if(super.cleanRaws(n),this.nodes)for(let p of this.nodes)p.cleanRaws(n);}each(n){if(!this.proxyOf.nodes)return;let p=this.getIterator(),c,g;for(;this.indexes[p]<this.proxyOf.nodes.length&&(c=this.indexes[p],g=n(this.proxyOf.nodes[c],c),g!==false);)this.indexes[p]+=1;return delete this.indexes[p],g}every(n){return this.nodes.every(n)}getIterator(){this.lastEach||(this.lastEach=0),this.indexes||(this.indexes={}),this.lastEach+=1;let n=this.lastEach;return this.indexes[n]=0,n}getProxyProcessor(){return {get(n,p){return p==="proxyOf"?n:n[p]?p==="each"||typeof p=="string"&&p.startsWith("walk")?(...c)=>n[p](...c.map(g=>typeof g=="function"?(S,b)=>g(S.toProxy(),b):g)):p==="every"||p==="some"?c=>n[p]((g,...S)=>c(g.toProxy(),...S)):p==="root"?()=>n.root().toProxy():p==="nodes"?n.nodes.map(c=>c.toProxy()):p==="first"||p==="last"?n[p].toProxy():n[p]:n[p]},set(n,p,c){return n[p]===c||(n[p]=c,(p==="name"||p==="params"||p==="selector")&&n.markDirty()),true}}}index(n){return typeof n=="number"?n:(n.proxyOf&&(n=n.proxyOf),this.proxyOf.nodes.indexOf(n))}insertAfter(n,p){let c=this.index(n),g=this.normalize(p,this.proxyOf.nodes[c]).reverse();c=this.index(n);for(let b of g)this.proxyOf.nodes.splice(c+1,0,b);let S;for(let b in this.indexes)S=this.indexes[b],c<S&&(this.indexes[b]=S+g.length);return this.markDirty(),this}insertBefore(n,p){let c=this.index(n),g=c===0?"prepend":false,S=this.normalize(p,this.proxyOf.nodes[c],g).reverse();c=this.index(n);for(let v of S)this.proxyOf.nodes.splice(c,0,v);let b;for(let v in this.indexes)b=this.indexes[v],c<=b&&(this.indexes[v]=b+S.length);return this.markDirty(),this}normalize(n,p){if(typeof n=="string")n=d(u(n).nodes);else if(typeof n=="undefined")n=[];else if(Array.isArray(n)){n=n.slice(0);for(let g of n)g.parent&&g.parent.removeChild(g,"ignore");}else if(n.type==="root"&&this.type!=="document"){n=n.nodes.slice(0);for(let g of n)g.parent&&g.parent.removeChild(g,"ignore");}else if(n.type)n=[n];else if(n.prop){if(typeof n.value=="undefined")throw new Error("Value field is missed in node creation");typeof n.value!="string"&&(n.value=String(n.value)),n=[new r(n)];}else if(n.selector)n=[new f(n)];else if(n.name)n=[new m(n)];else if(n.text)n=[new a(n)];else throw new Error("Unknown node type in node creation");return n.map(g=>(g[t]||h.rebuild(g),g=g.proxyOf,g.parent&&g.parent.removeChild(g),g[e]&&i(g),typeof g.raws.before=="undefined"&&p&&typeof p.raws.before!="undefined"&&(g.raws.before=p.raws.before.replace(/\S/g,"")),g.parent=this.proxyOf,g))}prepend(...n){n=n.reverse();for(let p of n){let c=this.normalize(p,this.first,"prepend").reverse();for(let g of c)this.proxyOf.nodes.unshift(g);for(let g in this.indexes)this.indexes[g]=this.indexes[g]+c.length;}return this.markDirty(),this}push(n){return n.parent=this,this.proxyOf.nodes.push(n),this}removeAll(){for(let n of this.proxyOf.nodes)n.parent=void 0;return this.proxyOf.nodes=[],this.markDirty(),this}removeChild(n){n=this.index(n),this.proxyOf.nodes[n].parent=void 0,this.proxyOf.nodes.splice(n,1);let p;for(let c in this.indexes)p=this.indexes[c],p>=n&&(this.indexes[c]=p-1);return this.markDirty(),this}replaceValues(n,p,c){return c||(c=p,p={}),this.walkDecls(g=>{p.props&&!p.props.includes(g.prop)||p.fast&&!g.value.includes(p.fast)||(g.value=g.value.replace(n,c));}),this.markDirty(),this}some(n){return this.nodes.some(n)}walk(n){return this.each((p,c)=>{let g;try{g=n(p,c);}catch(S){throw p.addToError(S)}return g!==false&&p.walk&&(g=p.walk(n)),g})}walkAtRules(n,p){return p?n instanceof RegExp?this.walk((c,g)=>{if(c.type==="atrule"&&n.test(c.name))return p(c,g)}):this.walk((c,g)=>{if(c.type==="atrule"&&c.name===n)return p(c,g)}):(p=n,this.walk((c,g)=>{if(c.type==="atrule")return p(c,g)}))}walkComments(n){return this.walk((p,c)=>{if(p.type==="comment")return n(p,c)})}walkDecls(n,p){return p?n instanceof RegExp?this.walk((c,g)=>{if(c.type==="decl"&&n.test(c.prop))return p(c,g)}):this.walk((c,g)=>{if(c.type==="decl"&&c.prop===n)return p(c,g)}):(p=n,this.walk((c,g)=>{if(c.type==="decl")return p(c,g)}))}walkRules(n,p){return p?n instanceof RegExp?this.walk((c,g)=>{if(c.type==="rule"&&n.test(c.selector))return p(c,g)}):this.walk((c,g)=>{if(c.type==="rule"&&c.selector===n)return p(c,g)}):(p=n,this.walk((c,g)=>{if(c.type==="rule")return p(c,g)}))}get first(){if(this.proxyOf.nodes)return this.proxyOf.nodes[0]}get last(){if(this.proxyOf.nodes)return this.proxyOf.nodes[this.proxyOf.nodes.length-1]}}return h.registerParse=l=>{u=l;},h.registerRule=l=>{f=l;},h.registerAtRule=l=>{m=l;},h.registerRoot=l=>{o=l;},kt=h,h.default=h,h.rebuild=l=>{l.type==="atrule"?Object.setPrototypeOf(l,m.prototype):l.type==="rule"?Object.setPrototypeOf(l,f.prototype):l.type==="decl"?Object.setPrototypeOf(l,r.prototype):l.type==="comment"?Object.setPrototypeOf(l,a.prototype):l.type==="root"&&Object.setPrototypeOf(l,o.prototype),l[t]=true,l.nodes&&l.nodes.forEach(n=>{h.rebuild(n);});},kt}var Pt,Is;function jr(){if(Is)return Pt;Is=1;let e=Ee(),t,r;class a extends e{constructor(u){super({type:"document",...u}),this.nodes||(this.nodes=[]);}toResult(u={}){return new t(new r,this,u).stringify()}}return a.registerLazyResult=s=>{t=s;},a.registerProcessor=s=>{r=s;},Pt=a,a.default=a,Pt}var Ft,Ts;function Yi(){if(Ts)return Ft;Ts=1;class e{constructor(r,a={}){if(this.type="warning",this.text=r,a.node&&a.node.source){let s=a.node.rangeBy(a);this.line=s.start.line,this.column=s.start.column,this.endLine=s.end.line,this.endColumn=s.end.column;}for(let s in a)this[s]=a[s];}toString(){return this.node?this.node.error(this.text,{index:this.index,plugin:this.plugin,word:this.word}).message:this.plugin?this.plugin+": "+this.text:this.text}}return Ft=e,e.default=e,Ft}var Ut,Ds;function Gr(){if(Ds)return Ut;Ds=1;let e=Yi();class t{constructor(a,s,u){this.processor=a,this.messages=[],this.root=s,this.opts=u,this.css=void 0,this.map=void 0;}toString(){return this.css}warn(a,s={}){s.plugin||this.lastPlugin&&this.lastPlugin.postcssPlugin&&(s.plugin=this.lastPlugin.postcssPlugin);let u=new e(a,s);return this.messages.push(u),u}warnings(){return this.messages.filter(a=>a.type==="warning")}get content(){return this.css}}return Ut=t,t.default=t,Ut}var Bt,_s;function ko(){if(_s)return Bt;_s=1;let e=39,t=34,r=92,a=47,s=10,u=32,f=12,m=9,o=13,d=91,i=93,h=40,l=41,n=123,p=125,c=59,g=42,S=58,b=64,v=/[\t\n\f\r "#'()/;[\\\]{}]/g,E=/[\t\n\f\r !"#'():;@[\\\]{}]|\/(?=\*)/g,w=/.[\r\n"'(/\\]/,y=/[\da-f]/i;return Bt=function(M,O={}){let R=M.css.valueOf(),D=O.ignoreErrors,A,x,ae,se,U,F,H,Q,Y,B,ye=R.length,N=0,fe=[],ne=[];function _e(){return N}function K(T){throw M.error("Unclosed "+T,N)}function le(){return ne.length===0&&N>=ye}function ve(T){if(ne.length)return ne.pop();if(N>=ye)return;let X=T?T.ignoreUnclosed:false;switch(A=R.charCodeAt(N),A){case s:case u:case m:case o:case f:{x=N;do x+=1,A=R.charCodeAt(x);while(A===u||A===s||A===m||A===o||A===f);B=["space",R.slice(N,x)],N=x-1;break}case d:case i:case n:case p:case S:case c:case l:{let $=String.fromCharCode(A);B=[$,$,N];break}case h:{if(Q=fe.length?fe.pop()[1]:"",Y=R.charCodeAt(N+1),Q==="url"&&Y!==e&&Y!==t&&Y!==u&&Y!==s&&Y!==m&&Y!==f&&Y!==o){x=N;do{if(F=false,x=R.indexOf(")",x+1),x===-1)if(D||X){x=N;break}else K("bracket");for(H=x;R.charCodeAt(H-1)===r;)H-=1,F=!F;}while(F);B=["brackets",R.slice(N,x+1),N,x],N=x;}else x=R.indexOf(")",N+1),se=R.slice(N,x+1),x===-1||w.test(se)?B=["(","(",N]:(B=["brackets",se,N,x],N=x);break}case e:case t:{ae=A===e?"'":'"',x=N;do{if(F=false,x=R.indexOf(ae,x+1),x===-1)if(D||X){x=N+1;break}else K("string");for(H=x;R.charCodeAt(H-1)===r;)H-=1,F=!F;}while(F);B=["string",R.slice(N,x+1),N,x],N=x;break}case b:{v.lastIndex=N+1,v.test(R),v.lastIndex===0?x=R.length-1:x=v.lastIndex-2,B=["at-word",R.slice(N,x+1),N,x],N=x;break}case r:{for(x=N,U=true;R.charCodeAt(x+1)===r;)x+=1,U=!U;if(A=R.charCodeAt(x+1),U&&A!==a&&A!==u&&A!==s&&A!==m&&A!==o&&A!==f&&(x+=1,y.test(R.charAt(x)))){for(;y.test(R.charAt(x+1));)x+=1;R.charCodeAt(x+1)===u&&(x+=1);}B=["word",R.slice(N,x+1),N,x],N=x;break}default:{A===a&&R.charCodeAt(N+1)===g?(x=R.indexOf("*/",N+2)+1,x===0&&(D||X?x=R.length:K("comment")),B=["comment",R.slice(N,x+1),N,x],N=x):(E.lastIndex=N+1,E.test(R),E.lastIndex===0?x=R.length-1:x=E.lastIndex-2,B=["word",R.slice(N,x+1),N,x],fe.push(B),N=x);break}}return N++,B}function we(T){ne.push(T);}return {back:we,endOfFile:le,nextToken:ve,position:_e}},Bt}var $t,ks;function Hr(){if(ks)return $t;ks=1;let e=Ee();class t extends e{constructor(a){super(a),this.type="atrule";}append(...a){return this.proxyOf.nodes||(this.nodes=[]),super.append(...a)}prepend(...a){return this.proxyOf.nodes||(this.nodes=[]),super.prepend(...a)}}return $t=t,t.default=t,e.registerAtRule(t),$t}var Wt,Ps;function We(){if(Ps)return Wt;Ps=1;let e=Ee(),t,r;class a extends e{constructor(u){super(u),this.type="root",this.nodes||(this.nodes=[]);}normalize(u,f,m){let o=super.normalize(u);if(f){if(m==="prepend")this.nodes.length>1?f.raws.before=this.nodes[1].raws.before:delete f.raws.before;else if(this.first!==f)for(let d of o)d.raws.before=f.raws.before;}return o}removeChild(u,f){let m=this.index(u);return !f&&m===0&&this.nodes.length>1&&(this.nodes[1].raws.before=this.nodes[m].raws.before),super.removeChild(u)}toResult(u={}){return new t(new r,this,u).stringify()}}return a.registerLazyResult=s=>{t=s;},a.registerProcessor=s=>{r=s;},Wt=a,a.default=a,e.registerRoot(a),Wt}var zt,Ls;function Xi(){if(Ls)return zt;Ls=1;let e={comma(t){return e.split(t,[","],true)},space(t){let r=[" ",`
|
|
24
|
+
`," "];return e.split(t,r)},split(t,r,a){let s=[],u="",f=false,m=0,o=false,d="",i=false;for(let h of t)i?i=false:h==="\\"?i=true:o?h===d&&(o=false):h==='"'||h==="'"?(o=true,d=h):h==="("?m+=1:h===")"?m>0&&(m-=1):m===0&&r.includes(h)&&(f=true),f?(u!==""&&s.push(u.trim()),u="",f=false):u+=h;return (a||u!=="")&&s.push(u.trim()),s}};return zt=e,e.default=e,zt}var qt,Fs;function Yr(){if(Fs)return qt;Fs=1;let e=Ee(),t=Xi();class r extends e{constructor(s){super(s),this.type="rule",this.nodes||(this.nodes=[]);}get selectors(){return t.comma(this.selector)}set selectors(s){let u=this.selector?this.selector.match(/,\s*/):null,f=u?u[0]:","+this.raw("between","beforeOpen");this.selector=s.join(f);}}return qt=r,r.default=r,e.registerRule(r),qt}var Vt,Us;function Po(){if(Us)return Vt;Us=1;let e=ht(),t=ko(),r=dt(),a=Hr(),s=We(),u=Yr(),f={empty:true,space:true};function m(d){for(let i=d.length-1;i>=0;i--){let h=d[i],l=h[3]||h[2];if(l)return l}}class o{constructor(i){this.input=i,this.root=new s,this.current=this.root,this.spaces="",this.semicolon=false,this.createTokenizer(),this.root.source={input:i,start:{column:1,line:1,offset:0}};}atrule(i){let h=new a;h.name=i[1].slice(1),h.name===""&&this.unnamedAtrule(h,i),this.init(h,i[2]);let l,n,p,c=false,g=false,S=[],b=[];for(;!this.tokenizer.endOfFile();){if(i=this.tokenizer.nextToken(),l=i[0],l==="("||l==="["?b.push(l==="("?")":"]"):l==="{"&&b.length>0?b.push("}"):l===b[b.length-1]&&b.pop(),b.length===0)if(l===";"){h.source.end=this.getPosition(i[2]),h.source.end.offset++,this.semicolon=true;break}else if(l==="{"){g=true;break}else if(l==="}"){if(S.length>0){for(p=S.length-1,n=S[p];n&&n[0]==="space";)n=S[--p];n&&(h.source.end=this.getPosition(n[3]||n[2]),h.source.end.offset++);}this.end(i);break}else S.push(i);else S.push(i);if(this.tokenizer.endOfFile()){c=true;break}}h.raws.between=this.spacesAndCommentsFromEnd(S),S.length?(h.raws.afterName=this.spacesAndCommentsFromStart(S),this.raw(h,"params",S),c&&(i=S[S.length-1],h.source.end=this.getPosition(i[3]||i[2]),h.source.end.offset++,this.spaces=h.raws.between,h.raws.between="")):(h.raws.afterName="",h.params=""),g&&(h.nodes=[],this.current=h);}checkMissedSemicolon(i){let h=this.colon(i);if(h===false)return;let l=0,n;for(let p=h-1;p>=0&&(n=i[p],!(n[0]!=="space"&&(l+=1,l===2)));p--);throw this.input.error("Missed semicolon",n[0]==="word"?n[3]+1:n[2])}colon(i){let h=0,l,n,p;for(let[c,g]of i.entries()){if(l=g,n=l[0],n==="("&&(h+=1),n===")"&&(h-=1),h===0&&n===":")if(!p)this.doubleColon(l);else {if(p[0]==="word"&&p[1]==="progid")continue;return c}p=l;}return false}comment(i){let h=new r;this.init(h,i[2]),h.source.end=this.getPosition(i[3]||i[2]),h.source.end.offset++;let l=i[1].slice(2,-2);if(/^\s*$/.test(l))h.text="",h.raws.left=l,h.raws.right="";else {let n=l.match(/^(\s*)([^]*\S)(\s*)$/);h.text=n[2],h.raws.left=n[1],h.raws.right=n[3];}}createTokenizer(){this.tokenizer=t(this.input);}decl(i,h){let l=new e;this.init(l,i[0][2]);let n=i[i.length-1];for(n[0]===";"&&(this.semicolon=true,i.pop()),l.source.end=this.getPosition(n[3]||n[2]||m(i)),l.source.end.offset++;i[0][0]!=="word";)i.length===1&&this.unknownWord(i),l.raws.before+=i.shift()[1];for(l.source.start=this.getPosition(i[0][2]),l.prop="";i.length;){let b=i[0][0];if(b===":"||b==="space"||b==="comment")break;l.prop+=i.shift()[1];}l.raws.between="";let p;for(;i.length;)if(p=i.shift(),p[0]===":"){l.raws.between+=p[1];break}else p[0]==="word"&&/\w/.test(p[1])&&this.unknownWord([p]),l.raws.between+=p[1];(l.prop[0]==="_"||l.prop[0]==="*")&&(l.raws.before+=l.prop[0],l.prop=l.prop.slice(1));let c=[],g;for(;i.length&&(g=i[0][0],!(g!=="space"&&g!=="comment"));)c.push(i.shift());this.precheckMissedSemicolon(i);for(let b=i.length-1;b>=0;b--){if(p=i[b],p[1].toLowerCase()==="!important"){l.important=true;let v=this.stringFrom(i,b);v=this.spacesFromEnd(i)+v,v!==" !important"&&(l.raws.important=v);break}else if(p[1].toLowerCase()==="important"){let v=i.slice(0),E="";for(let w=b;w>0;w--){let y=v[w][0];if(E.trim().indexOf("!")===0&&y!=="space")break;E=v.pop()[1]+E;}E.trim().indexOf("!")===0&&(l.important=true,l.raws.important=E,i=v);}if(p[0]!=="space"&&p[0]!=="comment")break}i.some(b=>b[0]!=="space"&&b[0]!=="comment")&&(l.raws.between+=c.map(b=>b[1]).join(""),c=[]),this.raw(l,"value",c.concat(i),h),l.value.includes(":")&&!h&&this.checkMissedSemicolon(i);}doubleColon(i){throw this.input.error("Double colon",{offset:i[2]},{offset:i[2]+i[1].length})}emptyRule(i){let h=new u;this.init(h,i[2]),h.selector="",h.raws.between="",this.current=h;}end(i){this.current.nodes&&this.current.nodes.length&&(this.current.raws.semicolon=this.semicolon),this.semicolon=false,this.current.raws.after=(this.current.raws.after||"")+this.spaces,this.spaces="",this.current.parent?(this.current.source.end=this.getPosition(i[2]),this.current.source.end.offset++,this.current=this.current.parent):this.unexpectedClose(i);}endFile(){this.current.parent&&this.unclosedBlock(),this.current.nodes&&this.current.nodes.length&&(this.current.raws.semicolon=this.semicolon),this.current.raws.after=(this.current.raws.after||"")+this.spaces,this.root.source.end=this.getPosition(this.tokenizer.position());}freeSemicolon(i){if(this.spaces+=i[1],this.current.nodes){let h=this.current.nodes[this.current.nodes.length-1];h&&h.type==="rule"&&!h.raws.ownSemicolon&&(h.raws.ownSemicolon=this.spaces,this.spaces="");}}getPosition(i){let h=this.input.fromOffset(i);return {column:h.col,line:h.line,offset:i}}init(i,h){this.current.push(i),i.source={input:this.input,start:this.getPosition(h)},i.raws.before=this.spaces,this.spaces="",i.type!=="comment"&&(this.semicolon=false);}other(i){let h=false,l=null,n=false,p=null,c=[],g=i[1].startsWith("--"),S=[],b=i;for(;b;){if(l=b[0],S.push(b),l==="("||l==="[")p||(p=b),c.push(l==="("?")":"]");else if(g&&n&&l==="{")p||(p=b),c.push("}");else if(c.length===0)if(l===";")if(n){this.decl(S,g);return}else break;else if(l==="{"){this.rule(S);return}else if(l==="}"){this.tokenizer.back(S.pop()),h=true;break}else l===":"&&(n=true);else l===c[c.length-1]&&(c.pop(),c.length===0&&(p=null));b=this.tokenizer.nextToken();}if(this.tokenizer.endOfFile()&&(h=true),c.length>0&&this.unclosedBracket(p),h&&n){if(!g)for(;S.length&&(b=S[S.length-1][0],!(b!=="space"&&b!=="comment"));)this.tokenizer.back(S.pop());this.decl(S,g);}else this.unknownWord(S);}parse(){let i;for(;!this.tokenizer.endOfFile();)switch(i=this.tokenizer.nextToken(),i[0]){case "space":this.spaces+=i[1];break;case ";":this.freeSemicolon(i);break;case "}":this.end(i);break;case "comment":this.comment(i);break;case "at-word":this.atrule(i);break;case "{":this.emptyRule(i);break;default:this.other(i);break}this.endFile();}precheckMissedSemicolon(){}raw(i,h,l,n){let p,c,g=l.length,S="",b=true,v,E;for(let w=0;w<g;w+=1)p=l[w],c=p[0],c==="space"&&w===g-1&&!n?b=false:c==="comment"?(E=l[w-1]?l[w-1][0]:"empty",v=l[w+1]?l[w+1][0]:"empty",!f[E]&&!f[v]?S.slice(-1)===","?b=false:S+=p[1]:b=false):S+=p[1];if(!b){let w=l.reduce((y,C)=>y+C[1],"");i.raws[h]={raw:w,value:S};}i[h]=S;}rule(i){i.pop();let h=new u;this.init(h,i[0][2]),h.raws.between=this.spacesAndCommentsFromEnd(i),this.raw(h,"selector",i),this.current=h;}spacesAndCommentsFromEnd(i){let h,l="";for(;i.length&&(h=i[i.length-1][0],!(h!=="space"&&h!=="comment"));)l=i.pop()[1]+l;return l}spacesAndCommentsFromStart(i){let h,l="";for(;i.length&&(h=i[0][0],!(h!=="space"&&h!=="comment"));)l+=i.shift()[1];return l}spacesFromEnd(i){let h,l="";for(;i.length&&(h=i[i.length-1][0],h==="space");)l=i.pop()[1]+l;return l}stringFrom(i,h){let l="";for(let n=h;n<i.length;n++)l+=i[n][1];return i.splice(h,i.length-h),l}unclosedBlock(){let i=this.current.source.start;throw this.input.error("Unclosed block",i.line,i.column)}unclosedBracket(i){throw this.input.error("Unclosed bracket",{offset:i[2]},{offset:i[2]+1})}unexpectedClose(i){throw this.input.error("Unexpected }",{offset:i[2]},{offset:i[2]+1})}unknownWord(i){throw this.input.error("Unknown word",{offset:i[0][2]},{offset:i[0][2]+i[0][1].length})}unnamedAtrule(i,h){throw this.input.error("At-rule without name",{offset:h[2]},{offset:h[2]+h[1].length})}}return Vt=o,Vt}var jt,Bs;function Xr(){if(Bs)return jt;Bs=1;let e=Ee(),t=Po(),r=ft();function a(s,u){let f=new r(s,u),m=new t(f);try{m.parse();}catch(o){throw o}return m.root}return jt=a,a.default=a,e.registerParse(a),jt}var Gt,$s;function Ji(){if($s)return Gt;$s=1;let {isClean:e,my:t}=Vr(),r=Gi(),a=ut(),s=Ee(),u=jr(),m=Gr(),o=Xr(),d=We(),i={atrule:"AtRule",comment:"Comment",decl:"Declaration",document:"Document",root:"Root",rule:"Rule"},h={AtRule:true,AtRuleExit:true,Comment:true,CommentExit:true,Declaration:true,DeclarationExit:true,Document:true,DocumentExit:true,Once:true,OnceExit:true,postcssPlugin:true,prepare:true,Root:true,RootExit:true,Rule:true,RuleExit:true},l={Once:true,postcssPlugin:true,prepare:true},n=0;function p(E){return typeof E=="object"&&typeof E.then=="function"}function c(E){let w=false,y=i[E.type];return E.type==="decl"?w=E.prop.toLowerCase():E.type==="atrule"&&(w=E.name.toLowerCase()),w&&E.append?[y,y+"-"+w,n,y+"Exit",y+"Exit-"+w]:w?[y,y+"-"+w,y+"Exit",y+"Exit-"+w]:E.append?[y,n,y+"Exit"]:[y,y+"Exit"]}function g(E){let w;return E.type==="document"?w=["Document",n,"DocumentExit"]:E.type==="root"?w=["Root",n,"RootExit"]:w=c(E),{eventIndex:0,events:w,iterator:0,node:E,visitorIndex:0,visitors:[]}}function S(E){return E[e]=false,E.nodes&&E.nodes.forEach(w=>S(w)),E}let b={};class v{constructor(w,y,C){this.stringified=false,this.processed=false;let M;if(typeof y=="object"&&y!==null&&(y.type==="root"||y.type==="document"))M=S(y);else if(y instanceof v||y instanceof m)M=S(y.root),y.map&&(typeof C.map=="undefined"&&(C.map={}),C.map.inline||(C.map.inline=false),C.map.prev=y.map);else {let O=o;C.syntax&&(O=C.syntax.parse),C.parser&&(O=C.parser),O.parse&&(O=O.parse);try{M=O(y,C);}catch(R){this.processed=true,this.error=R;}M&&!M[t]&&s.rebuild(M);}this.result=new m(w,M,C),this.helpers={...b,postcss:b,result:this.result},this.plugins=this.processor.plugins.map(O=>typeof O=="object"&&O.prepare?{...O,...O.prepare(this.result)}:O);}async(){return this.error?Promise.reject(this.error):this.processed?Promise.resolve(this.result):(this.processing||(this.processing=this.runAsync()),this.processing)}catch(w){return this.async().catch(w)}finally(w){return this.async().then(w,w)}getAsyncError(){throw new Error("Use process(css).then(cb) to work with async plugins")}handleError(w,y){let C=this.result.lastPlugin;try{y&&y.addToError(w),this.error=w,w.name==="CssSyntaxError"&&!w.plugin?(w.plugin=C.postcssPlugin,w.setMessage()):C.postcssVersion;}catch(M){console&&console.error&&console.error(M);}return w}prepareVisitors(){this.listeners={};let w=(y,C,M)=>{this.listeners[C]||(this.listeners[C]=[]),this.listeners[C].push([y,M]);};for(let y of this.plugins)if(typeof y=="object")for(let C in y){if(!h[C]&&/^[A-Z]/.test(C))throw new Error(`Unknown event ${C} in ${y.postcssPlugin}. Try to update PostCSS (${this.processor.version} now).`);if(!l[C])if(typeof y[C]=="object")for(let M in y[C])M==="*"?w(y,C,y[C][M]):w(y,C+"-"+M.toLowerCase(),y[C][M]);else typeof y[C]=="function"&&w(y,C,y[C]);}this.hasListener=Object.keys(this.listeners).length>0;}async runAsync(){this.plugin=0;for(let w=0;w<this.plugins.length;w++){let y=this.plugins[w],C=this.runOnRoot(y);if(p(C))try{await C;}catch(M){throw this.handleError(M)}}if(this.prepareVisitors(),this.hasListener){let w=this.result.root;for(;!w[e];){w[e]=true;let y=[g(w)];for(;y.length>0;){let C=this.visitTick(y);if(p(C))try{await C;}catch(M){let O=y[y.length-1].node;throw this.handleError(M,O)}}}if(this.listeners.OnceExit)for(let[y,C]of this.listeners.OnceExit){this.result.lastPlugin=y;try{if(w.type==="document"){let M=w.nodes.map(O=>C(O,this.helpers));await Promise.all(M);}else await C(w,this.helpers);}catch(M){throw this.handleError(M)}}}return this.processed=true,this.stringify()}runOnRoot(w){this.result.lastPlugin=w;try{if(typeof w=="object"&&w.Once){if(this.result.root.type==="document"){let y=this.result.root.nodes.map(C=>w.Once(C,this.helpers));return p(y[0])?Promise.all(y):y}return w.Once(this.result.root,this.helpers)}else if(typeof w=="function")return w(this.result.root,this.result)}catch(y){throw this.handleError(y)}}stringify(){if(this.error)throw this.error;if(this.stringified)return this.result;this.stringified=true,this.sync();let w=this.result.opts,y=a;w.syntax&&(y=w.syntax.stringify),w.stringifier&&(y=w.stringifier),y.stringify&&(y=y.stringify);let M=new r(y,this.result.root,this.result.opts).generate();return this.result.css=M[0],this.result.map=M[1],this.result}sync(){if(this.error)throw this.error;if(this.processed)return this.result;if(this.processed=true,this.processing)throw this.getAsyncError();for(let w of this.plugins){let y=this.runOnRoot(w);if(p(y))throw this.getAsyncError()}if(this.prepareVisitors(),this.hasListener){let w=this.result.root;for(;!w[e];)w[e]=true,this.walkSync(w);if(this.listeners.OnceExit)if(w.type==="document")for(let y of w.nodes)this.visitSync(this.listeners.OnceExit,y);else this.visitSync(this.listeners.OnceExit,w);}return this.result}then(w,y){return this.async().then(w,y)}toString(){return this.css}visitSync(w,y){for(let[C,M]of w){this.result.lastPlugin=C;let O;try{O=M(y,this.helpers);}catch(R){throw this.handleError(R,y.proxyOf)}if(y.type!=="root"&&y.type!=="document"&&!y.parent)return true;if(p(O))throw this.getAsyncError()}}visitTick(w){let y=w[w.length-1],{node:C,visitors:M}=y;if(C.type!=="root"&&C.type!=="document"&&!C.parent){w.pop();return}if(M.length>0&&y.visitorIndex<M.length){let[R,D]=M[y.visitorIndex];y.visitorIndex+=1,y.visitorIndex===M.length&&(y.visitors=[],y.visitorIndex=0),this.result.lastPlugin=R;try{return D(C.toProxy(),this.helpers)}catch(A){throw this.handleError(A,C)}}if(y.iterator!==0){let R=y.iterator,D;for(;D=C.nodes[C.indexes[R]];)if(C.indexes[R]+=1,!D[e]){D[e]=true,w.push(g(D));return}y.iterator=0,delete C.indexes[R];}let O=y.events;for(;y.eventIndex<O.length;){let R=O[y.eventIndex];if(y.eventIndex+=1,R===n){C.nodes&&C.nodes.length&&(C[e]=true,y.iterator=C.getIterator());return}else if(this.listeners[R]){y.visitors=this.listeners[R];return}}w.pop();}walkSync(w){w[e]=true;let y=c(w);for(let C of y)if(C===n)w.nodes&&w.each(M=>{M[e]||this.walkSync(M);});else {let M=this.listeners[C];if(M&&this.visitSync(M,w.toProxy()))return}}warnings(){return this.sync().warnings()}get content(){return this.stringify().content}get css(){return this.stringify().css}get map(){return this.stringify().map}get messages(){return this.sync().messages}get opts(){return this.result.opts}get processor(){return this.result.processor}get root(){return this.sync().root}get[Symbol.toStringTag](){return "LazyResult"}}return v.registerPostcss=E=>{b=E;},Gt=v,v.default=v,d.registerLazyResult(v),u.registerLazyResult(v),Gt}var Ht,Ws;function Lo(){if(Ws)return Ht;Ws=1;let e=Gi(),t=ut(),a=Xr(),s=Gr();class u{constructor(m,o,d){o=o.toString(),this.stringified=false,this._processor=m,this._css=o,this._opts=d,this._map=void 0;let i,h=t;this.result=new s(this._processor,i,this._opts),this.result.css=o;let l=this;Object.defineProperty(this.result,"root",{get(){return l.root}});let n=new e(h,i,this._opts,o);if(n.isMap()){let[p,c]=n.generate();p&&(this.result.css=p),c&&(this.result.map=c);}else n.clearAnnotation(),this.result.css=n.css;}async(){return this.error?Promise.reject(this.error):Promise.resolve(this.result)}catch(m){return this.async().catch(m)}finally(m){return this.async().then(m,m)}sync(){if(this.error)throw this.error;return this.result}then(m,o){return this.async().then(m,o)}toString(){return this._css}warnings(){return []}get content(){return this.result.css}get css(){return this.result.css}get map(){return this.result.map}get messages(){return []}get opts(){return this.result.opts}get processor(){return this.result.processor}get root(){if(this._root)return this._root;let m,o=a;try{m=o(this._css,this._opts);}catch(d){this.error=d;}if(this.error)throw this.error;return this._root=m,m}get[Symbol.toStringTag](){return "NoWorkResult"}}return Ht=u,u.default=u,Ht}var Yt,zs;function Fo(){if(zs)return Yt;zs=1;let e=Lo(),t=Ji(),r=jr(),a=We();class s{constructor(f=[]){this.version="8.4.38",this.plugins=this.normalize(f);}normalize(f){let m=[];for(let o of f)if(o.postcss===true?o=o():o.postcss&&(o=o.postcss),typeof o=="object"&&Array.isArray(o.plugins))m=m.concat(o.plugins);else if(typeof o=="object"&&o.postcssPlugin)m.push(o);else if(typeof o=="function")m.push(o);else if(!(typeof o=="object"&&(o.parse||o.stringify)))throw new Error(o+" is not a PostCSS plugin");return m}process(f,m={}){return !this.plugins.length&&!m.parser&&!m.stringifier&&!m.syntax?new e(this,f,m):new t(this,f,m)}use(f){return this.plugins=this.plugins.concat(this.normalize([f])),this}}return Yt=s,s.default=s,a.registerProcessor(s),r.registerProcessor(s),Yt}var Xt,qs;function Uo(){if(qs)return Xt;qs=1;let e=ht(),t=ji(),r=dt(),a=Hr(),s=ft(),u=We(),f=Yr();function m(o,d){if(Array.isArray(o))return o.map(l=>m(l));let{inputs:i,...h}=o;if(i){d=[];for(let l of i){let n={...l,__proto__:s.prototype};n.map&&(n.map={...n.map,__proto__:t.prototype}),d.push(n);}}if(h.nodes&&(h.nodes=o.nodes.map(l=>m(l,d))),h.source){let{inputId:l,...n}=h.source;h.source=n,l!=null&&(h.source.input=d[l]);}if(h.type==="root")return new u(h);if(h.type==="decl")return new e(h);if(h.type==="rule")return new f(h);if(h.type==="comment")return new r(h);if(h.type==="atrule")return new a(h);throw new Error("Unknown node type: "+o.type)}return Xt=m,m.default=m,Xt}var Jt,Vs;function Bo(){if(Vs)return Jt;Vs=1;let e=qr(),t=ht(),r=Ji(),a=Ee(),s=Fo(),u=ut(),f=Uo(),m=jr(),o=Yi(),d=dt(),i=Hr(),h=Gr(),l=ft(),n=Xr(),p=Xi(),c=Yr(),g=We(),S=ct();function b(...v){return v.length===1&&Array.isArray(v[0])&&(v=v[0]),new s(v)}return b.plugin=function(E,w){let y=false;function C(...O){console&&console.warn&&!y&&(y=true,console.warn(E+`: postcss.plugin was deprecated. Migration guide:
|
|
25
|
+
https://evilmartians.com/chronicles/postcss-8-plugin-migration`),process.env.LANG&&process.env.LANG.startsWith("cn")&&console.warn(E+`: \u91CC\u9762 postcss.plugin \u88AB\u5F03\u7528. \u8FC1\u79FB\u6307\u5357:
|
|
26
|
+
https://www.w3ctech.com/topic/2226`));let R=w(...O);return R.postcssPlugin=E,R.postcssVersion=new s().version,R}let M;return Object.defineProperty(C,"postcss",{get(){return M||(M=C()),M}}),C.process=function(O,R,D){return b([C(D)]).process(O,R)},C},b.stringify=u,b.parse=n,b.fromJSON=f,b.list=p,b.comment=v=>new d(v),b.atRule=v=>new i(v),b.decl=v=>new t(v),b.rule=v=>new c(v),b.root=v=>new g(v),b.document=v=>new m(v),b.CssSyntaxError=e,b.Declaration=t,b.Container=a,b.Processor=s,b.Document=m,b.Comment=d,b.Warning=o,b.AtRule=i,b.Result=h,b.Input=l,b.Rule=c,b.Root=g,b.Node=S,r.registerPostcss(b),Jt=b,b.default=b,Jt}var $o=Bo(),q=Oo($o);q.stringify;q.fromJSON;q.plugin;q.parse;q.list;q.document;q.comment;q.atRule;q.rule;q.decl;q.root;q.CssSyntaxError;q.Declaration;q.Container;q.Processor;q.Document;q.Comment;q.Warning;q.AtRule;q.Result;q.Input;q.Rule;q.Root;q.Node;var Wo=Object.defineProperty,zo=(e,t,r)=>t in e?Wo(e,t,{enumerable:true,configurable:true,writable:true,value:r}):e[t]=r,oe=(e,t,r)=>zo(e,typeof t!="symbol"?t+"":t,r);Date.now().toString();function qo(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}function Vo(e){if(e.__esModule)return e;var t=e.default;if(typeof t=="function"){var r=function a(){return this instanceof a?Reflect.construct(t,arguments,this.constructor):t.apply(this,arguments)};r.prototype=t.prototype;}else r={};return Object.defineProperty(r,"__esModule",{value:true}),Object.keys(e).forEach(function(a){var s=Object.getOwnPropertyDescriptor(e,a);Object.defineProperty(r,a,s.get?s:{enumerable:true,get:function(){return e[a]}});}),r}var Ye={exports:{}},js;function jo(){if(js)return Ye.exports;js=1;var e=String,t=function(){return {isColorSupported:false,reset:e,bold:e,dim:e,italic:e,underline:e,inverse:e,hidden:e,strikethrough:e,black:e,red:e,green:e,yellow:e,blue:e,magenta:e,cyan:e,white:e,gray:e,bgBlack:e,bgRed:e,bgGreen:e,bgYellow:e,bgBlue:e,bgMagenta:e,bgCyan:e,bgWhite:e}};return Ye.exports=t(),Ye.exports.createColors=t,Ye.exports}var Go={},Ho=Object.freeze(Object.defineProperty({__proto__:null,default:Go},Symbol.toStringTag,{value:"Module"})),he=Vo(Ho),Qt,Gs;function Jr(){if(Gs)return Qt;Gs=1;let e=jo(),t=he;class r extends Error{constructor(s,u,f,m,o,d){super(s),this.name="CssSyntaxError",this.reason=s,o&&(this.file=o),m&&(this.source=m),d&&(this.plugin=d),typeof u!="undefined"&&typeof f!="undefined"&&(typeof u=="number"?(this.line=u,this.column=f):(this.line=u.line,this.column=u.column,this.endLine=f.line,this.endColumn=f.column)),this.setMessage(),Error.captureStackTrace&&Error.captureStackTrace(this,r);}setMessage(){this.message=this.plugin?this.plugin+": ":"",this.message+=this.file?this.file:"<css input>",typeof this.line!="undefined"&&(this.message+=":"+this.line+":"+this.column),this.message+=": "+this.reason;}showSourceCode(s){if(!this.source)return "";let u=this.source;s==null&&(s=e.isColorSupported),t&&s&&(u=t(u));let f=u.split(/\r?\n/),m=Math.max(this.line-3,0),o=Math.min(this.line+2,f.length),d=String(o).length,i,h;if(s){let{bold:l,gray:n,red:p}=e.createColors(true);i=c=>l(p(c)),h=c=>n(c);}else i=h=l=>l;return f.slice(m,o).map((l,n)=>{let p=m+1+n,c=" "+(" "+p).slice(-d)+" | ";if(p===this.line){let g=h(c.replace(/\d/g," "))+l.slice(0,this.column-1).replace(/[^\t]/g," ");return i(">")+h(c)+l+`
|
|
27
|
+
`+g+i("^")}return " "+h(c)+l}).join(`
|
|
28
|
+
`)}toString(){let s=this.showSourceCode();return s&&(s=`
|
|
29
|
+
|
|
30
|
+
`+s+`
|
|
31
|
+
`),this.name+": "+this.message+s}}return Qt=r,r.default=r,Qt}var Xe={},Hs;function Qr(){return Hs||(Hs=1,Xe.isClean=Symbol("isClean"),Xe.my=Symbol("my")),Xe}var Zt,Ys;function Qi(){if(Ys)return Zt;Ys=1;let e={after:`
|
|
32
|
+
`,beforeClose:`
|
|
33
|
+
`,beforeComment:`
|
|
34
|
+
`,beforeDecl:`
|
|
35
|
+
`,beforeOpen:" ",beforeRule:`
|
|
36
|
+
`,colon:": ",commentLeft:" ",commentRight:" ",emptyBody:"",indent:" ",semicolon:false};function t(a){return a[0].toUpperCase()+a.slice(1)}class r{constructor(s){this.builder=s;}atrule(s,u){let f="@"+s.name,m=s.params?this.rawValue(s,"params"):"";if(typeof s.raws.afterName!="undefined"?f+=s.raws.afterName:m&&(f+=" "),s.nodes)this.block(s,f+m);else {let o=(s.raws.between||"")+(u?";":"");this.builder(f+m+o,s);}}beforeAfter(s,u){let f;s.type==="decl"?f=this.raw(s,null,"beforeDecl"):s.type==="comment"?f=this.raw(s,null,"beforeComment"):u==="before"?f=this.raw(s,null,"beforeRule"):f=this.raw(s,null,"beforeClose");let m=s.parent,o=0;for(;m&&m.type!=="root";)o+=1,m=m.parent;if(f.includes(`
|
|
37
|
+
`)){let d=this.raw(s,null,"indent");if(d.length)for(let i=0;i<o;i++)f+=d;}return f}block(s,u){let f=this.raw(s,"between","beforeOpen");this.builder(u+f+"{",s,"start");let m;s.nodes&&s.nodes.length?(this.body(s),m=this.raw(s,"after")):m=this.raw(s,"after","emptyBody"),m&&this.builder(m),this.builder("}",s,"end");}body(s){let u=s.nodes.length-1;for(;u>0&&s.nodes[u].type==="comment";)u-=1;let f=this.raw(s,"semicolon");for(let m=0;m<s.nodes.length;m++){let o=s.nodes[m],d=this.raw(o,"before");d&&this.builder(d),this.stringify(o,u!==m||f);}}comment(s){let u=this.raw(s,"left","commentLeft"),f=this.raw(s,"right","commentRight");this.builder("/*"+u+s.text+f+"*/",s);}decl(s,u){let f=this.raw(s,"between","colon"),m=s.prop+f+this.rawValue(s,"value");s.important&&(m+=s.raws.important||" !important"),u&&(m+=";"),this.builder(m,s);}document(s){this.body(s);}raw(s,u,f){let m;if(f||(f=u),u&&(m=s.raws[u],typeof m!="undefined"))return m;let o=s.parent;if(f==="before"&&(!o||o.type==="root"&&o.first===s||o&&o.type==="document"))return "";if(!o)return e[f];let d=s.root();if(d.rawCache||(d.rawCache={}),typeof d.rawCache[f]!="undefined")return d.rawCache[f];if(f==="before"||f==="after")return this.beforeAfter(s,f);{let i="raw"+t(f);this[i]?m=this[i](d,s):d.walk(h=>{if(m=h.raws[u],typeof m!="undefined")return false});}return typeof m=="undefined"&&(m=e[f]),d.rawCache[f]=m,m}rawBeforeClose(s){let u;return s.walk(f=>{if(f.nodes&&f.nodes.length>0&&typeof f.raws.after!="undefined")return u=f.raws.after,u.includes(`
|
|
38
|
+
`)&&(u=u.replace(/[^\n]+$/,"")),false}),u&&(u=u.replace(/\S/g,"")),u}rawBeforeComment(s,u){let f;return s.walkComments(m=>{if(typeof m.raws.before!="undefined")return f=m.raws.before,f.includes(`
|
|
39
|
+
`)&&(f=f.replace(/[^\n]+$/,"")),false}),typeof f=="undefined"?f=this.raw(u,null,"beforeDecl"):f&&(f=f.replace(/\S/g,"")),f}rawBeforeDecl(s,u){let f;return s.walkDecls(m=>{if(typeof m.raws.before!="undefined")return f=m.raws.before,f.includes(`
|
|
40
|
+
`)&&(f=f.replace(/[^\n]+$/,"")),false}),typeof f=="undefined"?f=this.raw(u,null,"beforeRule"):f&&(f=f.replace(/\S/g,"")),f}rawBeforeOpen(s){let u;return s.walk(f=>{if(f.type!=="decl"&&(u=f.raws.between,typeof u!="undefined"))return false}),u}rawBeforeRule(s){let u;return s.walk(f=>{if(f.nodes&&(f.parent!==s||s.first!==f)&&typeof f.raws.before!="undefined")return u=f.raws.before,u.includes(`
|
|
41
|
+
`)&&(u=u.replace(/[^\n]+$/,"")),false}),u&&(u=u.replace(/\S/g,"")),u}rawColon(s){let u;return s.walkDecls(f=>{if(typeof f.raws.between!="undefined")return u=f.raws.between.replace(/[^\s:]/g,""),false}),u}rawEmptyBody(s){let u;return s.walk(f=>{if(f.nodes&&f.nodes.length===0&&(u=f.raws.after,typeof u!="undefined"))return false}),u}rawIndent(s){if(s.raws.indent)return s.raws.indent;let u;return s.walk(f=>{let m=f.parent;if(m&&m!==s&&m.parent&&m.parent===s&&typeof f.raws.before!="undefined"){let o=f.raws.before.split(`
|
|
42
|
+
`);return u=o[o.length-1],u=u.replace(/\S/g,""),false}}),u}rawSemicolon(s){let u;return s.walk(f=>{if(f.nodes&&f.nodes.length&&f.last.type==="decl"&&(u=f.raws.semicolon,typeof u!="undefined"))return false}),u}rawValue(s,u){let f=s[u],m=s.raws[u];return m&&m.value===f?m.raw:f}root(s){this.body(s),s.raws.after&&this.builder(s.raws.after);}rule(s){this.block(s,this.rawValue(s,"selector")),s.raws.ownSemicolon&&this.builder(s.raws.ownSemicolon,s,"end");}stringify(s,u){if(!this[s.type])throw new Error("Unknown AST node type "+s.type+". Maybe you need to change PostCSS stringifier.");this[s.type](s,u);}}return Zt=r,r.default=r,Zt}var Kt,Xs;function pt(){if(Xs)return Kt;Xs=1;let e=Qi();function t(r,a){new e(a).stringify(r);}return Kt=t,t.default=t,Kt}var er,Js;function mt(){if(Js)return er;Js=1;let{isClean:e,my:t}=Qr(),r=Jr(),a=Qi(),s=pt();function u(m,o){let d=new m.constructor;for(let i in m){if(!Object.prototype.hasOwnProperty.call(m,i)||i==="proxyCache")continue;let h=m[i],l=typeof h;i==="parent"&&l==="object"?o&&(d[i]=o):i==="source"?d[i]=h:Array.isArray(h)?d[i]=h.map(n=>u(n,d)):(l==="object"&&h!==null&&(h=u(h)),d[i]=h);}return d}class f{constructor(o={}){this.raws={},this[e]=false,this[t]=true;for(let d in o)if(d==="nodes"){this.nodes=[];for(let i of o[d])typeof i.clone=="function"?this.append(i.clone()):this.append(i);}else this[d]=o[d];}addToError(o){if(o.postcssNode=this,o.stack&&this.source&&/\n\s{4}at /.test(o.stack)){let d=this.source;o.stack=o.stack.replace(/\n\s{4}at /,`$&${d.input.from}:${d.start.line}:${d.start.column}$&`);}return o}after(o){return this.parent.insertAfter(this,o),this}assign(o={}){for(let d in o)this[d]=o[d];return this}before(o){return this.parent.insertBefore(this,o),this}cleanRaws(o){delete this.raws.before,delete this.raws.after,o||delete this.raws.between;}clone(o={}){let d=u(this);for(let i in o)d[i]=o[i];return d}cloneAfter(o={}){let d=this.clone(o);return this.parent.insertAfter(this,d),d}cloneBefore(o={}){let d=this.clone(o);return this.parent.insertBefore(this,d),d}error(o,d={}){if(this.source){let{end:i,start:h}=this.rangeBy(d);return this.source.input.error(o,{column:h.column,line:h.line},{column:i.column,line:i.line},d)}return new r(o)}getProxyProcessor(){return {get(o,d){return d==="proxyOf"?o:d==="root"?()=>o.root().toProxy():o[d]},set(o,d,i){return o[d]===i||(o[d]=i,(d==="prop"||d==="value"||d==="name"||d==="params"||d==="important"||d==="text")&&o.markDirty()),true}}}markDirty(){if(this[e]){this[e]=false;let o=this;for(;o=o.parent;)o[e]=false;}}next(){if(!this.parent)return;let o=this.parent.index(this);return this.parent.nodes[o+1]}positionBy(o,d){let i=this.source.start;if(o.index)i=this.positionInside(o.index,d);else if(o.word){d=this.toString();let h=d.indexOf(o.word);h!==-1&&(i=this.positionInside(h,d));}return i}positionInside(o,d){let i=d||this.toString(),h=this.source.start.column,l=this.source.start.line;for(let n=0;n<o;n++)i[n]===`
|
|
43
|
+
`?(h=1,l+=1):h+=1;return {column:h,line:l}}prev(){if(!this.parent)return;let o=this.parent.index(this);return this.parent.nodes[o-1]}rangeBy(o){let d={column:this.source.start.column,line:this.source.start.line},i=this.source.end?{column:this.source.end.column+1,line:this.source.end.line}:{column:d.column+1,line:d.line};if(o.word){let h=this.toString(),l=h.indexOf(o.word);l!==-1&&(d=this.positionInside(l,h),i=this.positionInside(l+o.word.length,h));}else o.start?d={column:o.start.column,line:o.start.line}:o.index&&(d=this.positionInside(o.index)),o.end?i={column:o.end.column,line:o.end.line}:typeof o.endIndex=="number"?i=this.positionInside(o.endIndex):o.index&&(i=this.positionInside(o.index+1));return (i.line<d.line||i.line===d.line&&i.column<=d.column)&&(i={column:d.column+1,line:d.line}),{end:i,start:d}}raw(o,d){return new a().raw(this,o,d)}remove(){return this.parent&&this.parent.removeChild(this),this.parent=void 0,this}replaceWith(...o){if(this.parent){let d=this,i=false;for(let h of o)h===this?i=true:i?(this.parent.insertAfter(d,h),d=h):this.parent.insertBefore(d,h);i||this.remove();}return this}root(){let o=this;for(;o.parent&&o.parent.type!=="document";)o=o.parent;return o}toJSON(o,d){let i={},h=d==null;d=d||new Map;let l=0;for(let n in this){if(!Object.prototype.hasOwnProperty.call(this,n)||n==="parent"||n==="proxyCache")continue;let p=this[n];if(Array.isArray(p))i[n]=p.map(c=>typeof c=="object"&&c.toJSON?c.toJSON(null,d):c);else if(typeof p=="object"&&p.toJSON)i[n]=p.toJSON(null,d);else if(n==="source"){let c=d.get(p.input);c==null&&(c=l,d.set(p.input,l),l++),i[n]={end:p.end,inputId:c,start:p.start};}else i[n]=p;}return h&&(i.inputs=[...d.keys()].map(n=>n.toJSON())),i}toProxy(){return this.proxyCache||(this.proxyCache=new Proxy(this,this.getProxyProcessor())),this.proxyCache}toString(o=s){o.stringify&&(o=o.stringify);let d="";return o(this,i=>{d+=i;}),d}warn(o,d,i){let h={node:this};for(let l in i)h[l]=i[l];return o.warn(d,h)}get proxyOf(){return this}}return er=f,f.default=f,er}var tr,Qs;function gt(){if(Qs)return tr;Qs=1;let e=mt();class t extends e{constructor(a){a&&typeof a.value!="undefined"&&typeof a.value!="string"&&(a={...a,value:String(a.value)}),super(a),this.type="decl";}get variable(){return this.prop.startsWith("--")||this.prop[0]==="$"}}return tr=t,t.default=t,tr}var rr,Zs;function Yo(){if(Zs)return rr;Zs=1;let e="useandom-26T198340PX75pxJACKVERYMINDBUSHWOLF_GQZbfghjklqvwyzrict";return rr={nanoid:(a=21)=>{let s="",u=a;for(;u--;)s+=e[Math.random()*64|0];return s},customAlphabet:(a,s=21)=>(u=s)=>{let f="",m=u;for(;m--;)f+=a[Math.random()*a.length|0];return f}},rr}var sr,Ks;function Zi(){if(Ks)return sr;Ks=1;let{SourceMapConsumer:e,SourceMapGenerator:t}=he,{existsSync:r,readFileSync:a}=he,{dirname:s,join:u}=he;function f(o){return Buffer?Buffer.from(o,"base64").toString():window.atob(o)}class m{constructor(d,i){if(i.map===false)return;this.loadAnnotation(d),this.inline=this.startWith(this.annotation,"data:");let h=i.map?i.map.prev:void 0,l=this.loadMap(i.from,h);!this.mapFile&&i.from&&(this.mapFile=i.from),this.mapFile&&(this.root=s(this.mapFile)),l&&(this.text=l);}consumer(){return this.consumerCache||(this.consumerCache=new e(this.text)),this.consumerCache}decodeInline(d){let i=/^data:application\/json;charset=utf-?8;base64,/,h=/^data:application\/json;base64,/,l=/^data:application\/json;charset=utf-?8,/,n=/^data:application\/json,/;if(l.test(d)||n.test(d))return decodeURIComponent(d.substr(RegExp.lastMatch.length));if(i.test(d)||h.test(d))return f(d.substr(RegExp.lastMatch.length));let p=d.match(/data:application\/json;([^,]+),/)[1];throw new Error("Unsupported source map encoding "+p)}getAnnotationURL(d){return d.replace(/^\/\*\s*# sourceMappingURL=/,"").trim()}isMap(d){return typeof d!="object"?false:typeof d.mappings=="string"||typeof d._mappings=="string"||Array.isArray(d.sections)}loadAnnotation(d){let i=d.match(/\/\*\s*# sourceMappingURL=/gm);if(!i)return;let h=d.lastIndexOf(i.pop()),l=d.indexOf("*/",h);h>-1&&l>-1&&(this.annotation=this.getAnnotationURL(d.substring(h,l)));}loadFile(d){if(this.root=s(d),r(d))return this.mapFile=d,a(d,"utf-8").toString().trim()}loadMap(d,i){if(i===false)return false;if(i){if(typeof i=="string")return i;if(typeof i=="function"){let h=i(d);if(h){let l=this.loadFile(h);if(!l)throw new Error("Unable to load previous source map: "+h.toString());return l}}else {if(i instanceof e)return t.fromSourceMap(i).toString();if(i instanceof t)return i.toString();if(this.isMap(i))return JSON.stringify(i);throw new Error("Unsupported previous source map format: "+i.toString())}}else {if(this.inline)return this.decodeInline(this.annotation);if(this.annotation){let h=this.annotation;return d&&(h=u(s(d),h)),this.loadFile(h)}}}startWith(d,i){return d?d.substr(0,i.length)===i:false}withContent(){return !!(this.consumer().sourcesContent&&this.consumer().sourcesContent.length>0)}}return sr=m,m.default=m,sr}var ir,ei;function yt(){if(ei)return ir;ei=1;let{SourceMapConsumer:e,SourceMapGenerator:t}=he,{fileURLToPath:r,pathToFileURL:a}=he,{isAbsolute:s,resolve:u}=he,{nanoid:f}=Yo(),m=he,o=Jr(),d=Zi(),i=Symbol("fromOffsetCache"),h=!!(e&&t),l=!!(u&&s);class n{constructor(c,g={}){if(c===null||typeof c=="undefined"||typeof c=="object"&&!c.toString)throw new Error(`PostCSS received ${c} instead of CSS string`);if(this.css=c.toString(),this.css[0]==="\uFEFF"||this.css[0]==="\uFFFE"?(this.hasBOM=true,this.css=this.css.slice(1)):this.hasBOM=false,g.from&&(!l||/^\w+:\/\//.test(g.from)||s(g.from)?this.file=g.from:this.file=u(g.from)),l&&h){let S=new d(this.css,g);if(S.text){this.map=S;let b=S.consumer().file;!this.file&&b&&(this.file=this.mapResolve(b));}}this.file||(this.id="<input css "+f(6)+">"),this.map&&(this.map.file=this.from);}error(c,g,S,b={}){let v,E,w;if(g&&typeof g=="object"){let C=g,M=S;if(typeof C.offset=="number"){let O=this.fromOffset(C.offset);g=O.line,S=O.col;}else g=C.line,S=C.column;if(typeof M.offset=="number"){let O=this.fromOffset(M.offset);E=O.line,w=O.col;}else E=M.line,w=M.column;}else if(!S){let C=this.fromOffset(g);g=C.line,S=C.col;}let y=this.origin(g,S,E,w);return y?v=new o(c,y.endLine===void 0?y.line:{column:y.column,line:y.line},y.endLine===void 0?y.column:{column:y.endColumn,line:y.endLine},y.source,y.file,b.plugin):v=new o(c,E===void 0?g:{column:S,line:g},E===void 0?S:{column:w,line:E},this.css,this.file,b.plugin),v.input={column:S,endColumn:w,endLine:E,line:g,source:this.css},this.file&&(a&&(v.input.url=a(this.file).toString()),v.input.file=this.file),v}fromOffset(c){let g,S;if(this[i])S=this[i];else {let v=this.css.split(`
|
|
44
|
+
`);S=new Array(v.length);let E=0;for(let w=0,y=v.length;w<y;w++)S[w]=E,E+=v[w].length+1;this[i]=S;}g=S[S.length-1];let b=0;if(c>=g)b=S.length-1;else {let v=S.length-2,E;for(;b<v;)if(E=b+(v-b>>1),c<S[E])v=E-1;else if(c>=S[E+1])b=E+1;else {b=E;break}}return {col:c-S[b]+1,line:b+1}}mapResolve(c){return /^\w+:\/\//.test(c)?c:u(this.map.consumer().sourceRoot||this.map.root||".",c)}origin(c,g,S,b){if(!this.map)return false;let v=this.map.consumer(),E=v.originalPositionFor({column:g,line:c});if(!E.source)return false;let w;typeof S=="number"&&(w=v.originalPositionFor({column:b,line:S}));let y;s(E.source)?y=a(E.source):y=new URL(E.source,this.map.consumer().sourceRoot||a(this.map.mapFile));let C={column:E.column,endColumn:w&&w.column,endLine:w&&w.line,line:E.line,url:y.toString()};if(y.protocol==="file:")if(r)C.file=r(y);else throw new Error("file: protocol is not available in this PostCSS build");let M=v.sourceContentFor(E.source);return M&&(C.source=M),C}toJSON(){let c={};for(let g of ["hasBOM","css","file","id"])this[g]!=null&&(c[g]=this[g]);return this.map&&(c.map={...this.map},c.map.consumerCache&&(c.map.consumerCache=void 0)),c}get from(){return this.file||this.id}}return ir=n,n.default=n,m&&m.registerInput&&m.registerInput(n),ir}var nr,ti;function Ki(){if(ti)return nr;ti=1;let{SourceMapConsumer:e,SourceMapGenerator:t}=he,{dirname:r,relative:a,resolve:s,sep:u}=he,{pathToFileURL:f}=he,m=yt(),o=!!(e&&t),d=!!(r&&s&&a&&u);class i{constructor(l,n,p,c){this.stringify=l,this.mapOpts=p.map||{},this.root=n,this.opts=p,this.css=c,this.originalCSS=c,this.usesFileUrls=!this.mapOpts.from&&this.mapOpts.absolute,this.memoizedFileURLs=new Map,this.memoizedPaths=new Map,this.memoizedURLs=new Map;}addAnnotation(){let l;this.isInline()?l="data:application/json;base64,"+this.toBase64(this.map.toString()):typeof this.mapOpts.annotation=="string"?l=this.mapOpts.annotation:typeof this.mapOpts.annotation=="function"?l=this.mapOpts.annotation(this.opts.to,this.root):l=this.outputFile()+".map";let n=`
|
|
45
|
+
`;this.css.includes(`\r
|
|
46
|
+
`)&&(n=`\r
|
|
47
|
+
`),this.css+=n+"/*# sourceMappingURL="+l+" */";}applyPrevMaps(){for(let l of this.previous()){let n=this.toUrl(this.path(l.file)),p=l.root||r(l.file),c;this.mapOpts.sourcesContent===false?(c=new e(l.text),c.sourcesContent&&(c.sourcesContent=null)):c=l.consumer(),this.map.applySourceMap(c,n,this.toUrl(this.path(p)));}}clearAnnotation(){if(this.mapOpts.annotation!==false)if(this.root){let l;for(let n=this.root.nodes.length-1;n>=0;n--)l=this.root.nodes[n],l.type==="comment"&&l.text.indexOf("# sourceMappingURL=")===0&&this.root.removeChild(n);}else this.css&&(this.css=this.css.replace(/\n*?\/\*#[\S\s]*?\*\/$/gm,""));}generate(){if(this.clearAnnotation(),d&&o&&this.isMap())return this.generateMap();{let l="";return this.stringify(this.root,n=>{l+=n;}),[l]}}generateMap(){if(this.root)this.generateString();else if(this.previous().length===1){let l=this.previous()[0].consumer();l.file=this.outputFile(),this.map=t.fromSourceMap(l,{ignoreInvalidMapping:true});}else this.map=new t({file:this.outputFile(),ignoreInvalidMapping:true}),this.map.addMapping({generated:{column:0,line:1},original:{column:0,line:1},source:this.opts.from?this.toUrl(this.path(this.opts.from)):"<no source>"});return this.isSourcesContent()&&this.setSourcesContent(),this.root&&this.previous().length>0&&this.applyPrevMaps(),this.isAnnotation()&&this.addAnnotation(),this.isInline()?[this.css]:[this.css,this.map]}generateString(){this.css="",this.map=new t({file:this.outputFile(),ignoreInvalidMapping:true});let l=1,n=1,p="<no source>",c={generated:{column:0,line:0},original:{column:0,line:0},source:""},g,S;this.stringify(this.root,(b,v,E)=>{if(this.css+=b,v&&E!=="end"&&(c.generated.line=l,c.generated.column=n-1,v.source&&v.source.start?(c.source=this.sourcePath(v),c.original.line=v.source.start.line,c.original.column=v.source.start.column-1,this.map.addMapping(c)):(c.source=p,c.original.line=1,c.original.column=0,this.map.addMapping(c))),g=b.match(/\n/g),g?(l+=g.length,S=b.lastIndexOf(`
|
|
48
|
+
`),n=b.length-S):n+=b.length,v&&E!=="start"){let w=v.parent||{raws:{}};(!(v.type==="decl"||v.type==="atrule"&&!v.nodes)||v!==w.last||w.raws.semicolon)&&(v.source&&v.source.end?(c.source=this.sourcePath(v),c.original.line=v.source.end.line,c.original.column=v.source.end.column-1,c.generated.line=l,c.generated.column=n-2,this.map.addMapping(c)):(c.source=p,c.original.line=1,c.original.column=0,c.generated.line=l,c.generated.column=n-1,this.map.addMapping(c)));}});}isAnnotation(){return this.isInline()?true:typeof this.mapOpts.annotation!="undefined"?this.mapOpts.annotation:this.previous().length?this.previous().some(l=>l.annotation):true}isInline(){if(typeof this.mapOpts.inline!="undefined")return this.mapOpts.inline;let l=this.mapOpts.annotation;return typeof l!="undefined"&&l!==true?false:this.previous().length?this.previous().some(n=>n.inline):true}isMap(){return typeof this.opts.map!="undefined"?!!this.opts.map:this.previous().length>0}isSourcesContent(){return typeof this.mapOpts.sourcesContent!="undefined"?this.mapOpts.sourcesContent:this.previous().length?this.previous().some(l=>l.withContent()):true}outputFile(){return this.opts.to?this.path(this.opts.to):this.opts.from?this.path(this.opts.from):"to.css"}path(l){if(this.mapOpts.absolute||l.charCodeAt(0)===60||/^\w+:\/\//.test(l))return l;let n=this.memoizedPaths.get(l);if(n)return n;let p=this.opts.to?r(this.opts.to):".";typeof this.mapOpts.annotation=="string"&&(p=r(s(p,this.mapOpts.annotation)));let c=a(p,l);return this.memoizedPaths.set(l,c),c}previous(){if(!this.previousMaps)if(this.previousMaps=[],this.root)this.root.walk(l=>{if(l.source&&l.source.input.map){let n=l.source.input.map;this.previousMaps.includes(n)||this.previousMaps.push(n);}});else {let l=new m(this.originalCSS,this.opts);l.map&&this.previousMaps.push(l.map);}return this.previousMaps}setSourcesContent(){let l={};if(this.root)this.root.walk(n=>{if(n.source){let p=n.source.input.from;if(p&&!l[p]){l[p]=true;let c=this.usesFileUrls?this.toFileUrl(p):this.toUrl(this.path(p));this.map.setSourceContent(c,n.source.input.css);}}});else if(this.css){let n=this.opts.from?this.toUrl(this.path(this.opts.from)):"<no source>";this.map.setSourceContent(n,this.css);}}sourcePath(l){return this.mapOpts.from?this.toUrl(this.mapOpts.from):this.usesFileUrls?this.toFileUrl(l.source.input.from):this.toUrl(this.path(l.source.input.from))}toBase64(l){return Buffer?Buffer.from(l).toString("base64"):window.btoa(unescape(encodeURIComponent(l)))}toFileUrl(l){let n=this.memoizedFileURLs.get(l);if(n)return n;if(f){let p=f(l).toString();return this.memoizedFileURLs.set(l,p),p}else throw new Error("`map.absolute` option is not available in this PostCSS build")}toUrl(l){let n=this.memoizedURLs.get(l);if(n)return n;u==="\\"&&(l=l.replace(/\\/g,"/"));let p=encodeURI(l).replace(/[#?]/g,encodeURIComponent);return this.memoizedURLs.set(l,p),p}}return nr=i,nr}var or,ri;function wt(){if(ri)return or;ri=1;let e=mt();class t extends e{constructor(a){super(a),this.type="comment";}}return or=t,t.default=t,or}var ar,si;function xe(){if(si)return ar;si=1;let{isClean:e,my:t}=Qr(),r=gt(),a=wt(),s=mt(),u,f,m,o;function d(l){return l.map(n=>(n.nodes&&(n.nodes=d(n.nodes)),delete n.source,n))}function i(l){if(l[e]=false,l.proxyOf.nodes)for(let n of l.proxyOf.nodes)i(n);}class h extends s{append(...n){for(let p of n){let c=this.normalize(p,this.last);for(let g of c)this.proxyOf.nodes.push(g);}return this.markDirty(),this}cleanRaws(n){if(super.cleanRaws(n),this.nodes)for(let p of this.nodes)p.cleanRaws(n);}each(n){if(!this.proxyOf.nodes)return;let p=this.getIterator(),c,g;for(;this.indexes[p]<this.proxyOf.nodes.length&&(c=this.indexes[p],g=n(this.proxyOf.nodes[c],c),g!==false);)this.indexes[p]+=1;return delete this.indexes[p],g}every(n){return this.nodes.every(n)}getIterator(){this.lastEach||(this.lastEach=0),this.indexes||(this.indexes={}),this.lastEach+=1;let n=this.lastEach;return this.indexes[n]=0,n}getProxyProcessor(){return {get(n,p){return p==="proxyOf"?n:n[p]?p==="each"||typeof p=="string"&&p.startsWith("walk")?(...c)=>n[p](...c.map(g=>typeof g=="function"?(S,b)=>g(S.toProxy(),b):g)):p==="every"||p==="some"?c=>n[p]((g,...S)=>c(g.toProxy(),...S)):p==="root"?()=>n.root().toProxy():p==="nodes"?n.nodes.map(c=>c.toProxy()):p==="first"||p==="last"?n[p].toProxy():n[p]:n[p]},set(n,p,c){return n[p]===c||(n[p]=c,(p==="name"||p==="params"||p==="selector")&&n.markDirty()),true}}}index(n){return typeof n=="number"?n:(n.proxyOf&&(n=n.proxyOf),this.proxyOf.nodes.indexOf(n))}insertAfter(n,p){let c=this.index(n),g=this.normalize(p,this.proxyOf.nodes[c]).reverse();c=this.index(n);for(let b of g)this.proxyOf.nodes.splice(c+1,0,b);let S;for(let b in this.indexes)S=this.indexes[b],c<S&&(this.indexes[b]=S+g.length);return this.markDirty(),this}insertBefore(n,p){let c=this.index(n),g=c===0?"prepend":false,S=this.normalize(p,this.proxyOf.nodes[c],g).reverse();c=this.index(n);for(let v of S)this.proxyOf.nodes.splice(c,0,v);let b;for(let v in this.indexes)b=this.indexes[v],c<=b&&(this.indexes[v]=b+S.length);return this.markDirty(),this}normalize(n,p){if(typeof n=="string")n=d(u(n).nodes);else if(typeof n=="undefined")n=[];else if(Array.isArray(n)){n=n.slice(0);for(let g of n)g.parent&&g.parent.removeChild(g,"ignore");}else if(n.type==="root"&&this.type!=="document"){n=n.nodes.slice(0);for(let g of n)g.parent&&g.parent.removeChild(g,"ignore");}else if(n.type)n=[n];else if(n.prop){if(typeof n.value=="undefined")throw new Error("Value field is missed in node creation");typeof n.value!="string"&&(n.value=String(n.value)),n=[new r(n)];}else if(n.selector)n=[new f(n)];else if(n.name)n=[new m(n)];else if(n.text)n=[new a(n)];else throw new Error("Unknown node type in node creation");return n.map(g=>(g[t]||h.rebuild(g),g=g.proxyOf,g.parent&&g.parent.removeChild(g),g[e]&&i(g),typeof g.raws.before=="undefined"&&p&&typeof p.raws.before!="undefined"&&(g.raws.before=p.raws.before.replace(/\S/g,"")),g.parent=this.proxyOf,g))}prepend(...n){n=n.reverse();for(let p of n){let c=this.normalize(p,this.first,"prepend").reverse();for(let g of c)this.proxyOf.nodes.unshift(g);for(let g in this.indexes)this.indexes[g]=this.indexes[g]+c.length;}return this.markDirty(),this}push(n){return n.parent=this,this.proxyOf.nodes.push(n),this}removeAll(){for(let n of this.proxyOf.nodes)n.parent=void 0;return this.proxyOf.nodes=[],this.markDirty(),this}removeChild(n){n=this.index(n),this.proxyOf.nodes[n].parent=void 0,this.proxyOf.nodes.splice(n,1);let p;for(let c in this.indexes)p=this.indexes[c],p>=n&&(this.indexes[c]=p-1);return this.markDirty(),this}replaceValues(n,p,c){return c||(c=p,p={}),this.walkDecls(g=>{p.props&&!p.props.includes(g.prop)||p.fast&&!g.value.includes(p.fast)||(g.value=g.value.replace(n,c));}),this.markDirty(),this}some(n){return this.nodes.some(n)}walk(n){return this.each((p,c)=>{let g;try{g=n(p,c);}catch(S){throw p.addToError(S)}return g!==false&&p.walk&&(g=p.walk(n)),g})}walkAtRules(n,p){return p?n instanceof RegExp?this.walk((c,g)=>{if(c.type==="atrule"&&n.test(c.name))return p(c,g)}):this.walk((c,g)=>{if(c.type==="atrule"&&c.name===n)return p(c,g)}):(p=n,this.walk((c,g)=>{if(c.type==="atrule")return p(c,g)}))}walkComments(n){return this.walk((p,c)=>{if(p.type==="comment")return n(p,c)})}walkDecls(n,p){return p?n instanceof RegExp?this.walk((c,g)=>{if(c.type==="decl"&&n.test(c.prop))return p(c,g)}):this.walk((c,g)=>{if(c.type==="decl"&&c.prop===n)return p(c,g)}):(p=n,this.walk((c,g)=>{if(c.type==="decl")return p(c,g)}))}walkRules(n,p){return p?n instanceof RegExp?this.walk((c,g)=>{if(c.type==="rule"&&n.test(c.selector))return p(c,g)}):this.walk((c,g)=>{if(c.type==="rule"&&c.selector===n)return p(c,g)}):(p=n,this.walk((c,g)=>{if(c.type==="rule")return p(c,g)}))}get first(){if(this.proxyOf.nodes)return this.proxyOf.nodes[0]}get last(){if(this.proxyOf.nodes)return this.proxyOf.nodes[this.proxyOf.nodes.length-1]}}return h.registerParse=l=>{u=l;},h.registerRule=l=>{f=l;},h.registerAtRule=l=>{m=l;},h.registerRoot=l=>{o=l;},ar=h,h.default=h,h.rebuild=l=>{l.type==="atrule"?Object.setPrototypeOf(l,m.prototype):l.type==="rule"?Object.setPrototypeOf(l,f.prototype):l.type==="decl"?Object.setPrototypeOf(l,r.prototype):l.type==="comment"?Object.setPrototypeOf(l,a.prototype):l.type==="root"&&Object.setPrototypeOf(l,o.prototype),l[t]=true,l.nodes&&l.nodes.forEach(n=>{h.rebuild(n);});},ar}var lr,ii;function Zr(){if(ii)return lr;ii=1;let e=xe(),t,r;class a extends e{constructor(u){super({type:"document",...u}),this.nodes||(this.nodes=[]);}toResult(u={}){return new t(new r,this,u).stringify()}}return a.registerLazyResult=s=>{t=s;},a.registerProcessor=s=>{r=s;},lr=a,a.default=a,lr}var cr,oi;function tn(){if(oi)return cr;oi=1;class e{constructor(r,a={}){if(this.type="warning",this.text=r,a.node&&a.node.source){let s=a.node.rangeBy(a);this.line=s.start.line,this.column=s.start.column,this.endLine=s.end.line,this.endColumn=s.end.column;}for(let s in a)this[s]=a[s];}toString(){return this.node?this.node.error(this.text,{index:this.index,plugin:this.plugin,word:this.word}).message:this.plugin?this.plugin+": "+this.text:this.text}}return cr=e,e.default=e,cr}var hr,ai;function Kr(){if(ai)return hr;ai=1;let e=tn();class t{constructor(a,s,u){this.processor=a,this.messages=[],this.root=s,this.opts=u,this.css=void 0,this.map=void 0;}toString(){return this.css}warn(a,s={}){s.plugin||this.lastPlugin&&this.lastPlugin.postcssPlugin&&(s.plugin=this.lastPlugin.postcssPlugin);let u=new e(a,s);return this.messages.push(u),u}warnings(){return this.messages.filter(a=>a.type==="warning")}get content(){return this.css}}return hr=t,t.default=t,hr}var fr,li;function Xo(){if(li)return fr;li=1;let e=39,t=34,r=92,a=47,s=10,u=32,f=12,m=9,o=13,d=91,i=93,h=40,l=41,n=123,p=125,c=59,g=42,S=58,b=64,v=/[\t\n\f\r "#'()/;[\\\]{}]/g,E=/[\t\n\f\r !"#'():;@[\\\]{}]|\/(?=\*)/g,w=/.[\r\n"'(/\\]/,y=/[\da-f]/i;return fr=function(M,O={}){let R=M.css.valueOf(),D=O.ignoreErrors,A,x,ae,se,U,F,H,Q,Y,B,ye=R.length,N=0,fe=[],ne=[];function _e(){return N}function K(T){throw M.error("Unclosed "+T,N)}function le(){return ne.length===0&&N>=ye}function ve(T){if(ne.length)return ne.pop();if(N>=ye)return;let X=T?T.ignoreUnclosed:false;switch(A=R.charCodeAt(N),A){case s:case u:case m:case o:case f:{x=N;do x+=1,A=R.charCodeAt(x);while(A===u||A===s||A===m||A===o||A===f);B=["space",R.slice(N,x)],N=x-1;break}case d:case i:case n:case p:case S:case c:case l:{let $=String.fromCharCode(A);B=[$,$,N];break}case h:{if(Q=fe.length?fe.pop()[1]:"",Y=R.charCodeAt(N+1),Q==="url"&&Y!==e&&Y!==t&&Y!==u&&Y!==s&&Y!==m&&Y!==f&&Y!==o){x=N;do{if(F=false,x=R.indexOf(")",x+1),x===-1)if(D||X){x=N;break}else K("bracket");for(H=x;R.charCodeAt(H-1)===r;)H-=1,F=!F;}while(F);B=["brackets",R.slice(N,x+1),N,x],N=x;}else x=R.indexOf(")",N+1),se=R.slice(N,x+1),x===-1||w.test(se)?B=["(","(",N]:(B=["brackets",se,N,x],N=x);break}case e:case t:{ae=A===e?"'":'"',x=N;do{if(F=false,x=R.indexOf(ae,x+1),x===-1)if(D||X){x=N+1;break}else K("string");for(H=x;R.charCodeAt(H-1)===r;)H-=1,F=!F;}while(F);B=["string",R.slice(N,x+1),N,x],N=x;break}case b:{v.lastIndex=N+1,v.test(R),v.lastIndex===0?x=R.length-1:x=v.lastIndex-2,B=["at-word",R.slice(N,x+1),N,x],N=x;break}case r:{for(x=N,U=true;R.charCodeAt(x+1)===r;)x+=1,U=!U;if(A=R.charCodeAt(x+1),U&&A!==a&&A!==u&&A!==s&&A!==m&&A!==o&&A!==f&&(x+=1,y.test(R.charAt(x)))){for(;y.test(R.charAt(x+1));)x+=1;R.charCodeAt(x+1)===u&&(x+=1);}B=["word",R.slice(N,x+1),N,x],N=x;break}default:{A===a&&R.charCodeAt(N+1)===g?(x=R.indexOf("*/",N+2)+1,x===0&&(D||X?x=R.length:K("comment")),B=["comment",R.slice(N,x+1),N,x],N=x):(E.lastIndex=N+1,E.test(R),E.lastIndex===0?x=R.length-1:x=E.lastIndex-2,B=["word",R.slice(N,x+1),N,x],fe.push(B),N=x);break}}return N++,B}function we(T){ne.push(T);}return {back:we,endOfFile:le,nextToken:ve,position:_e}},fr}var dr,ui;function es(){if(ui)return dr;ui=1;let e=xe();class t extends e{constructor(a){super(a),this.type="atrule";}append(...a){return this.proxyOf.nodes||(this.nodes=[]),super.append(...a)}prepend(...a){return this.proxyOf.nodes||(this.nodes=[]),super.prepend(...a)}}return dr=t,t.default=t,e.registerAtRule(t),dr}var pr,ci;function ze(){if(ci)return pr;ci=1;let e=xe(),t,r;class a extends e{constructor(u){super(u),this.type="root",this.nodes||(this.nodes=[]);}normalize(u,f,m){let o=super.normalize(u);if(f){if(m==="prepend")this.nodes.length>1?f.raws.before=this.nodes[1].raws.before:delete f.raws.before;else if(this.first!==f)for(let d of o)d.raws.before=f.raws.before;}return o}removeChild(u,f){let m=this.index(u);return !f&&m===0&&this.nodes.length>1&&(this.nodes[1].raws.before=this.nodes[m].raws.before),super.removeChild(u)}toResult(u={}){return new t(new r,this,u).stringify()}}return a.registerLazyResult=s=>{t=s;},a.registerProcessor=s=>{r=s;},pr=a,a.default=a,e.registerRoot(a),pr}var mr,hi;function rn(){if(hi)return mr;hi=1;let e={comma(t){return e.split(t,[","],true)},space(t){let r=[" ",`
|
|
49
|
+
`," "];return e.split(t,r)},split(t,r,a){let s=[],u="",f=false,m=0,o=false,d="",i=false;for(let h of t)i?i=false:h==="\\"?i=true:o?h===d&&(o=false):h==='"'||h==="'"?(o=true,d=h):h==="("?m+=1:h===")"?m>0&&(m-=1):m===0&&r.includes(h)&&(f=true),f?(u!==""&&s.push(u.trim()),u="",f=false):u+=h;return (a||u!=="")&&s.push(u.trim()),s}};return mr=e,e.default=e,mr}var gr,fi;function ts(){if(fi)return gr;fi=1;let e=xe(),t=rn();class r extends e{constructor(s){super(s),this.type="rule",this.nodes||(this.nodes=[]);}get selectors(){return t.comma(this.selector)}set selectors(s){let u=this.selector?this.selector.match(/,\s*/):null,f=u?u[0]:","+this.raw("between","beforeOpen");this.selector=s.join(f);}}return gr=r,r.default=r,e.registerRule(r),gr}var yr,di;function Jo(){if(di)return yr;di=1;let e=gt(),t=Xo(),r=wt(),a=es(),s=ze(),u=ts(),f={empty:true,space:true};function m(d){for(let i=d.length-1;i>=0;i--){let h=d[i],l=h[3]||h[2];if(l)return l}}class o{constructor(i){this.input=i,this.root=new s,this.current=this.root,this.spaces="",this.semicolon=false,this.createTokenizer(),this.root.source={input:i,start:{column:1,line:1,offset:0}};}atrule(i){let h=new a;h.name=i[1].slice(1),h.name===""&&this.unnamedAtrule(h,i),this.init(h,i[2]);let l,n,p,c=false,g=false,S=[],b=[];for(;!this.tokenizer.endOfFile();){if(i=this.tokenizer.nextToken(),l=i[0],l==="("||l==="["?b.push(l==="("?")":"]"):l==="{"&&b.length>0?b.push("}"):l===b[b.length-1]&&b.pop(),b.length===0)if(l===";"){h.source.end=this.getPosition(i[2]),h.source.end.offset++,this.semicolon=true;break}else if(l==="{"){g=true;break}else if(l==="}"){if(S.length>0){for(p=S.length-1,n=S[p];n&&n[0]==="space";)n=S[--p];n&&(h.source.end=this.getPosition(n[3]||n[2]),h.source.end.offset++);}this.end(i);break}else S.push(i);else S.push(i);if(this.tokenizer.endOfFile()){c=true;break}}h.raws.between=this.spacesAndCommentsFromEnd(S),S.length?(h.raws.afterName=this.spacesAndCommentsFromStart(S),this.raw(h,"params",S),c&&(i=S[S.length-1],h.source.end=this.getPosition(i[3]||i[2]),h.source.end.offset++,this.spaces=h.raws.between,h.raws.between="")):(h.raws.afterName="",h.params=""),g&&(h.nodes=[],this.current=h);}checkMissedSemicolon(i){let h=this.colon(i);if(h===false)return;let l=0,n;for(let p=h-1;p>=0&&(n=i[p],!(n[0]!=="space"&&(l+=1,l===2)));p--);throw this.input.error("Missed semicolon",n[0]==="word"?n[3]+1:n[2])}colon(i){let h=0,l,n,p;for(let[c,g]of i.entries()){if(l=g,n=l[0],n==="("&&(h+=1),n===")"&&(h-=1),h===0&&n===":")if(!p)this.doubleColon(l);else {if(p[0]==="word"&&p[1]==="progid")continue;return c}p=l;}return false}comment(i){let h=new r;this.init(h,i[2]),h.source.end=this.getPosition(i[3]||i[2]),h.source.end.offset++;let l=i[1].slice(2,-2);if(/^\s*$/.test(l))h.text="",h.raws.left=l,h.raws.right="";else {let n=l.match(/^(\s*)([^]*\S)(\s*)$/);h.text=n[2],h.raws.left=n[1],h.raws.right=n[3];}}createTokenizer(){this.tokenizer=t(this.input);}decl(i,h){let l=new e;this.init(l,i[0][2]);let n=i[i.length-1];for(n[0]===";"&&(this.semicolon=true,i.pop()),l.source.end=this.getPosition(n[3]||n[2]||m(i)),l.source.end.offset++;i[0][0]!=="word";)i.length===1&&this.unknownWord(i),l.raws.before+=i.shift()[1];for(l.source.start=this.getPosition(i[0][2]),l.prop="";i.length;){let b=i[0][0];if(b===":"||b==="space"||b==="comment")break;l.prop+=i.shift()[1];}l.raws.between="";let p;for(;i.length;)if(p=i.shift(),p[0]===":"){l.raws.between+=p[1];break}else p[0]==="word"&&/\w/.test(p[1])&&this.unknownWord([p]),l.raws.between+=p[1];(l.prop[0]==="_"||l.prop[0]==="*")&&(l.raws.before+=l.prop[0],l.prop=l.prop.slice(1));let c=[],g;for(;i.length&&(g=i[0][0],!(g!=="space"&&g!=="comment"));)c.push(i.shift());this.precheckMissedSemicolon(i);for(let b=i.length-1;b>=0;b--){if(p=i[b],p[1].toLowerCase()==="!important"){l.important=true;let v=this.stringFrom(i,b);v=this.spacesFromEnd(i)+v,v!==" !important"&&(l.raws.important=v);break}else if(p[1].toLowerCase()==="important"){let v=i.slice(0),E="";for(let w=b;w>0;w--){let y=v[w][0];if(E.trim().indexOf("!")===0&&y!=="space")break;E=v.pop()[1]+E;}E.trim().indexOf("!")===0&&(l.important=true,l.raws.important=E,i=v);}if(p[0]!=="space"&&p[0]!=="comment")break}i.some(b=>b[0]!=="space"&&b[0]!=="comment")&&(l.raws.between+=c.map(b=>b[1]).join(""),c=[]),this.raw(l,"value",c.concat(i),h),l.value.includes(":")&&!h&&this.checkMissedSemicolon(i);}doubleColon(i){throw this.input.error("Double colon",{offset:i[2]},{offset:i[2]+i[1].length})}emptyRule(i){let h=new u;this.init(h,i[2]),h.selector="",h.raws.between="",this.current=h;}end(i){this.current.nodes&&this.current.nodes.length&&(this.current.raws.semicolon=this.semicolon),this.semicolon=false,this.current.raws.after=(this.current.raws.after||"")+this.spaces,this.spaces="",this.current.parent?(this.current.source.end=this.getPosition(i[2]),this.current.source.end.offset++,this.current=this.current.parent):this.unexpectedClose(i);}endFile(){this.current.parent&&this.unclosedBlock(),this.current.nodes&&this.current.nodes.length&&(this.current.raws.semicolon=this.semicolon),this.current.raws.after=(this.current.raws.after||"")+this.spaces,this.root.source.end=this.getPosition(this.tokenizer.position());}freeSemicolon(i){if(this.spaces+=i[1],this.current.nodes){let h=this.current.nodes[this.current.nodes.length-1];h&&h.type==="rule"&&!h.raws.ownSemicolon&&(h.raws.ownSemicolon=this.spaces,this.spaces="");}}getPosition(i){let h=this.input.fromOffset(i);return {column:h.col,line:h.line,offset:i}}init(i,h){this.current.push(i),i.source={input:this.input,start:this.getPosition(h)},i.raws.before=this.spaces,this.spaces="",i.type!=="comment"&&(this.semicolon=false);}other(i){let h=false,l=null,n=false,p=null,c=[],g=i[1].startsWith("--"),S=[],b=i;for(;b;){if(l=b[0],S.push(b),l==="("||l==="[")p||(p=b),c.push(l==="("?")":"]");else if(g&&n&&l==="{")p||(p=b),c.push("}");else if(c.length===0)if(l===";")if(n){this.decl(S,g);return}else break;else if(l==="{"){this.rule(S);return}else if(l==="}"){this.tokenizer.back(S.pop()),h=true;break}else l===":"&&(n=true);else l===c[c.length-1]&&(c.pop(),c.length===0&&(p=null));b=this.tokenizer.nextToken();}if(this.tokenizer.endOfFile()&&(h=true),c.length>0&&this.unclosedBracket(p),h&&n){if(!g)for(;S.length&&(b=S[S.length-1][0],!(b!=="space"&&b!=="comment"));)this.tokenizer.back(S.pop());this.decl(S,g);}else this.unknownWord(S);}parse(){let i;for(;!this.tokenizer.endOfFile();)switch(i=this.tokenizer.nextToken(),i[0]){case "space":this.spaces+=i[1];break;case ";":this.freeSemicolon(i);break;case "}":this.end(i);break;case "comment":this.comment(i);break;case "at-word":this.atrule(i);break;case "{":this.emptyRule(i);break;default:this.other(i);break}this.endFile();}precheckMissedSemicolon(){}raw(i,h,l,n){let p,c,g=l.length,S="",b=true,v,E;for(let w=0;w<g;w+=1)p=l[w],c=p[0],c==="space"&&w===g-1&&!n?b=false:c==="comment"?(E=l[w-1]?l[w-1][0]:"empty",v=l[w+1]?l[w+1][0]:"empty",!f[E]&&!f[v]?S.slice(-1)===","?b=false:S+=p[1]:b=false):S+=p[1];if(!b){let w=l.reduce((y,C)=>y+C[1],"");i.raws[h]={raw:w,value:S};}i[h]=S;}rule(i){i.pop();let h=new u;this.init(h,i[0][2]),h.raws.between=this.spacesAndCommentsFromEnd(i),this.raw(h,"selector",i),this.current=h;}spacesAndCommentsFromEnd(i){let h,l="";for(;i.length&&(h=i[i.length-1][0],!(h!=="space"&&h!=="comment"));)l=i.pop()[1]+l;return l}spacesAndCommentsFromStart(i){let h,l="";for(;i.length&&(h=i[0][0],!(h!=="space"&&h!=="comment"));)l+=i.shift()[1];return l}spacesFromEnd(i){let h,l="";for(;i.length&&(h=i[i.length-1][0],h==="space");)l=i.pop()[1]+l;return l}stringFrom(i,h){let l="";for(let n=h;n<i.length;n++)l+=i[n][1];return i.splice(h,i.length-h),l}unclosedBlock(){let i=this.current.source.start;throw this.input.error("Unclosed block",i.line,i.column)}unclosedBracket(i){throw this.input.error("Unclosed bracket",{offset:i[2]},{offset:i[2]+1})}unexpectedClose(i){throw this.input.error("Unexpected }",{offset:i[2]},{offset:i[2]+1})}unknownWord(i){throw this.input.error("Unknown word",{offset:i[0][2]},{offset:i[0][2]+i[0][1].length})}unnamedAtrule(i,h){throw this.input.error("At-rule without name",{offset:h[2]},{offset:h[2]+h[1].length})}}return yr=o,yr}var wr,pi;function rs(){if(pi)return wr;pi=1;let e=xe(),t=Jo(),r=yt();function a(s,u){let f=new r(s,u),m=new t(f);try{m.parse();}catch(o){throw o}return m.root}return wr=a,a.default=a,e.registerParse(a),wr}var br,mi;function sn(){if(mi)return br;mi=1;let {isClean:e,my:t}=Qr(),r=Ki(),a=pt(),s=xe(),u=Zr(),m=Kr(),o=rs(),d=ze(),i={atrule:"AtRule",comment:"Comment",decl:"Declaration",document:"Document",root:"Root",rule:"Rule"},h={AtRule:true,AtRuleExit:true,Comment:true,CommentExit:true,Declaration:true,DeclarationExit:true,Document:true,DocumentExit:true,Once:true,OnceExit:true,postcssPlugin:true,prepare:true,Root:true,RootExit:true,Rule:true,RuleExit:true},l={Once:true,postcssPlugin:true,prepare:true},n=0;function p(E){return typeof E=="object"&&typeof E.then=="function"}function c(E){let w=false,y=i[E.type];return E.type==="decl"?w=E.prop.toLowerCase():E.type==="atrule"&&(w=E.name.toLowerCase()),w&&E.append?[y,y+"-"+w,n,y+"Exit",y+"Exit-"+w]:w?[y,y+"-"+w,y+"Exit",y+"Exit-"+w]:E.append?[y,n,y+"Exit"]:[y,y+"Exit"]}function g(E){let w;return E.type==="document"?w=["Document",n,"DocumentExit"]:E.type==="root"?w=["Root",n,"RootExit"]:w=c(E),{eventIndex:0,events:w,iterator:0,node:E,visitorIndex:0,visitors:[]}}function S(E){return E[e]=false,E.nodes&&E.nodes.forEach(w=>S(w)),E}let b={};class v{constructor(w,y,C){this.stringified=false,this.processed=false;let M;if(typeof y=="object"&&y!==null&&(y.type==="root"||y.type==="document"))M=S(y);else if(y instanceof v||y instanceof m)M=S(y.root),y.map&&(typeof C.map=="undefined"&&(C.map={}),C.map.inline||(C.map.inline=false),C.map.prev=y.map);else {let O=o;C.syntax&&(O=C.syntax.parse),C.parser&&(O=C.parser),O.parse&&(O=O.parse);try{M=O(y,C);}catch(R){this.processed=true,this.error=R;}M&&!M[t]&&s.rebuild(M);}this.result=new m(w,M,C),this.helpers={...b,postcss:b,result:this.result},this.plugins=this.processor.plugins.map(O=>typeof O=="object"&&O.prepare?{...O,...O.prepare(this.result)}:O);}async(){return this.error?Promise.reject(this.error):this.processed?Promise.resolve(this.result):(this.processing||(this.processing=this.runAsync()),this.processing)}catch(w){return this.async().catch(w)}finally(w){return this.async().then(w,w)}getAsyncError(){throw new Error("Use process(css).then(cb) to work with async plugins")}handleError(w,y){let C=this.result.lastPlugin;try{y&&y.addToError(w),this.error=w,w.name==="CssSyntaxError"&&!w.plugin?(w.plugin=C.postcssPlugin,w.setMessage()):C.postcssVersion;}catch(M){console&&console.error&&console.error(M);}return w}prepareVisitors(){this.listeners={};let w=(y,C,M)=>{this.listeners[C]||(this.listeners[C]=[]),this.listeners[C].push([y,M]);};for(let y of this.plugins)if(typeof y=="object")for(let C in y){if(!h[C]&&/^[A-Z]/.test(C))throw new Error(`Unknown event ${C} in ${y.postcssPlugin}. Try to update PostCSS (${this.processor.version} now).`);if(!l[C])if(typeof y[C]=="object")for(let M in y[C])M==="*"?w(y,C,y[C][M]):w(y,C+"-"+M.toLowerCase(),y[C][M]);else typeof y[C]=="function"&&w(y,C,y[C]);}this.hasListener=Object.keys(this.listeners).length>0;}async runAsync(){this.plugin=0;for(let w=0;w<this.plugins.length;w++){let y=this.plugins[w],C=this.runOnRoot(y);if(p(C))try{await C;}catch(M){throw this.handleError(M)}}if(this.prepareVisitors(),this.hasListener){let w=this.result.root;for(;!w[e];){w[e]=true;let y=[g(w)];for(;y.length>0;){let C=this.visitTick(y);if(p(C))try{await C;}catch(M){let O=y[y.length-1].node;throw this.handleError(M,O)}}}if(this.listeners.OnceExit)for(let[y,C]of this.listeners.OnceExit){this.result.lastPlugin=y;try{if(w.type==="document"){let M=w.nodes.map(O=>C(O,this.helpers));await Promise.all(M);}else await C(w,this.helpers);}catch(M){throw this.handleError(M)}}}return this.processed=true,this.stringify()}runOnRoot(w){this.result.lastPlugin=w;try{if(typeof w=="object"&&w.Once){if(this.result.root.type==="document"){let y=this.result.root.nodes.map(C=>w.Once(C,this.helpers));return p(y[0])?Promise.all(y):y}return w.Once(this.result.root,this.helpers)}else if(typeof w=="function")return w(this.result.root,this.result)}catch(y){throw this.handleError(y)}}stringify(){if(this.error)throw this.error;if(this.stringified)return this.result;this.stringified=true,this.sync();let w=this.result.opts,y=a;w.syntax&&(y=w.syntax.stringify),w.stringifier&&(y=w.stringifier),y.stringify&&(y=y.stringify);let M=new r(y,this.result.root,this.result.opts).generate();return this.result.css=M[0],this.result.map=M[1],this.result}sync(){if(this.error)throw this.error;if(this.processed)return this.result;if(this.processed=true,this.processing)throw this.getAsyncError();for(let w of this.plugins){let y=this.runOnRoot(w);if(p(y))throw this.getAsyncError()}if(this.prepareVisitors(),this.hasListener){let w=this.result.root;for(;!w[e];)w[e]=true,this.walkSync(w);if(this.listeners.OnceExit)if(w.type==="document")for(let y of w.nodes)this.visitSync(this.listeners.OnceExit,y);else this.visitSync(this.listeners.OnceExit,w);}return this.result}then(w,y){return this.async().then(w,y)}toString(){return this.css}visitSync(w,y){for(let[C,M]of w){this.result.lastPlugin=C;let O;try{O=M(y,this.helpers);}catch(R){throw this.handleError(R,y.proxyOf)}if(y.type!=="root"&&y.type!=="document"&&!y.parent)return true;if(p(O))throw this.getAsyncError()}}visitTick(w){let y=w[w.length-1],{node:C,visitors:M}=y;if(C.type!=="root"&&C.type!=="document"&&!C.parent){w.pop();return}if(M.length>0&&y.visitorIndex<M.length){let[R,D]=M[y.visitorIndex];y.visitorIndex+=1,y.visitorIndex===M.length&&(y.visitors=[],y.visitorIndex=0),this.result.lastPlugin=R;try{return D(C.toProxy(),this.helpers)}catch(A){throw this.handleError(A,C)}}if(y.iterator!==0){let R=y.iterator,D;for(;D=C.nodes[C.indexes[R]];)if(C.indexes[R]+=1,!D[e]){D[e]=true,w.push(g(D));return}y.iterator=0,delete C.indexes[R];}let O=y.events;for(;y.eventIndex<O.length;){let R=O[y.eventIndex];if(y.eventIndex+=1,R===n){C.nodes&&C.nodes.length&&(C[e]=true,y.iterator=C.getIterator());return}else if(this.listeners[R]){y.visitors=this.listeners[R];return}}w.pop();}walkSync(w){w[e]=true;let y=c(w);for(let C of y)if(C===n)w.nodes&&w.each(M=>{M[e]||this.walkSync(M);});else {let M=this.listeners[C];if(M&&this.visitSync(M,w.toProxy()))return}}warnings(){return this.sync().warnings()}get content(){return this.stringify().content}get css(){return this.stringify().css}get map(){return this.stringify().map}get messages(){return this.sync().messages}get opts(){return this.result.opts}get processor(){return this.result.processor}get root(){return this.sync().root}get[Symbol.toStringTag](){return "LazyResult"}}return v.registerPostcss=E=>{b=E;},br=v,v.default=v,d.registerLazyResult(v),u.registerLazyResult(v),br}var vr,gi;function Qo(){if(gi)return vr;gi=1;let e=Ki(),t=pt(),a=rs(),s=Kr();class u{constructor(m,o,d){o=o.toString(),this.stringified=false,this._processor=m,this._css=o,this._opts=d,this._map=void 0;let i,h=t;this.result=new s(this._processor,i,this._opts),this.result.css=o;let l=this;Object.defineProperty(this.result,"root",{get(){return l.root}});let n=new e(h,i,this._opts,o);if(n.isMap()){let[p,c]=n.generate();p&&(this.result.css=p),c&&(this.result.map=c);}else n.clearAnnotation(),this.result.css=n.css;}async(){return this.error?Promise.reject(this.error):Promise.resolve(this.result)}catch(m){return this.async().catch(m)}finally(m){return this.async().then(m,m)}sync(){if(this.error)throw this.error;return this.result}then(m,o){return this.async().then(m,o)}toString(){return this._css}warnings(){return []}get content(){return this.result.css}get css(){return this.result.css}get map(){return this.result.map}get messages(){return []}get opts(){return this.result.opts}get processor(){return this.result.processor}get root(){if(this._root)return this._root;let m,o=a;try{m=o(this._css,this._opts);}catch(d){this.error=d;}if(this.error)throw this.error;return this._root=m,m}get[Symbol.toStringTag](){return "NoWorkResult"}}return vr=u,u.default=u,vr}var Sr,yi;function Zo(){if(yi)return Sr;yi=1;let e=Qo(),t=sn(),r=Zr(),a=ze();class s{constructor(f=[]){this.version="8.4.38",this.plugins=this.normalize(f);}normalize(f){let m=[];for(let o of f)if(o.postcss===true?o=o():o.postcss&&(o=o.postcss),typeof o=="object"&&Array.isArray(o.plugins))m=m.concat(o.plugins);else if(typeof o=="object"&&o.postcssPlugin)m.push(o);else if(typeof o=="function")m.push(o);else if(!(typeof o=="object"&&(o.parse||o.stringify)))throw new Error(o+" is not a PostCSS plugin");return m}process(f,m={}){return !this.plugins.length&&!m.parser&&!m.stringifier&&!m.syntax?new e(this,f,m):new t(this,f,m)}use(f){return this.plugins=this.plugins.concat(this.normalize([f])),this}}return Sr=s,s.default=s,a.registerProcessor(s),r.registerProcessor(s),Sr}var Cr,wi;function Ko(){if(wi)return Cr;wi=1;let e=gt(),t=Zi(),r=wt(),a=es(),s=yt(),u=ze(),f=ts();function m(o,d){if(Array.isArray(o))return o.map(l=>m(l));let{inputs:i,...h}=o;if(i){d=[];for(let l of i){let n={...l,__proto__:s.prototype};n.map&&(n.map={...n.map,__proto__:t.prototype}),d.push(n);}}if(h.nodes&&(h.nodes=o.nodes.map(l=>m(l,d))),h.source){let{inputId:l,...n}=h.source;h.source=n,l!=null&&(h.source.input=d[l]);}if(h.type==="root")return new u(h);if(h.type==="decl")return new e(h);if(h.type==="rule")return new f(h);if(h.type==="comment")return new r(h);if(h.type==="atrule")return new a(h);throw new Error("Unknown node type: "+o.type)}return Cr=m,m.default=m,Cr}var Er,bi;function ea(){if(bi)return Er;bi=1;let e=Jr(),t=gt(),r=sn(),a=xe(),s=Zo(),u=pt(),f=Ko(),m=Zr(),o=tn(),d=wt(),i=es(),h=Kr(),l=yt(),n=rs(),p=rn(),c=ts(),g=ze(),S=mt();function b(...v){return v.length===1&&Array.isArray(v[0])&&(v=v[0]),new s(v)}return b.plugin=function(E,w){let y=false;function C(...O){console&&console.warn&&!y&&(y=true,console.warn(E+`: postcss.plugin was deprecated. Migration guide:
|
|
50
|
+
https://evilmartians.com/chronicles/postcss-8-plugin-migration`),process.env.LANG&&process.env.LANG.startsWith("cn")&&console.warn(E+`: \u91CC\u9762 postcss.plugin \u88AB\u5F03\u7528. \u8FC1\u79FB\u6307\u5357:
|
|
51
|
+
https://www.w3ctech.com/topic/2226`));let R=w(...O);return R.postcssPlugin=E,R.postcssVersion=new s().version,R}let M;return Object.defineProperty(C,"postcss",{get(){return M||(M=C()),M}}),C.process=function(O,R,D){return b([C(D)]).process(O,R)},C},b.stringify=u,b.parse=n,b.fromJSON=f,b.list=p,b.comment=v=>new d(v),b.atRule=v=>new i(v),b.decl=v=>new t(v),b.rule=v=>new c(v),b.root=v=>new g(v),b.document=v=>new m(v),b.CssSyntaxError=e,b.Declaration=t,b.Container=a,b.Processor=s,b.Document=m,b.Comment=d,b.Warning=o,b.AtRule=i,b.Result=h,b.Input=l,b.Rule=c,b.Root=g,b.Node=S,r.registerPostcss(b),Er=b,b.default=b,Er}var ta=ea(),V=qo(ta);V.stringify;V.fromJSON;V.plugin;V.parse;V.list;V.document;V.comment;V.atRule;V.rule;V.decl;V.root;V.CssSyntaxError;V.Declaration;V.Container;V.Processor;V.Document;V.Comment;V.Warning;V.AtRule;V.Result;V.Input;V.Rule;V.Root;V.Node;var Ir=class e{constructor(...t){oe(this,"parentElement",null),oe(this,"parentNode",null),oe(this,"ownerDocument"),oe(this,"firstChild",null),oe(this,"lastChild",null),oe(this,"previousSibling",null),oe(this,"nextSibling",null),oe(this,"ELEMENT_NODE",1),oe(this,"TEXT_NODE",3),oe(this,"nodeType"),oe(this,"nodeName"),oe(this,"RRNodeType");}get childNodes(){let t=[],r=this.firstChild;for(;r;)t.push(r),r=r.nextSibling;return t}contains(t){if(t instanceof e){if(t.ownerDocument!==this.ownerDocument)return false;if(t===this)return true}else return false;for(;t.parentNode;){if(t.parentNode===this)return true;t=t.parentNode;}return false}appendChild(t){throw new Error("RRDomException: Failed to execute 'appendChild' on 'RRNode': This RRNode type does not support this method.")}insertBefore(t,r){throw new Error("RRDomException: Failed to execute 'insertBefore' on 'RRNode': This RRNode type does not support this method.")}removeChild(t){throw new Error("RRDomException: Failed to execute 'removeChild' on 'RRNode': This RRNode type does not support this method.")}toString(){return "RRNode"}};var vi={Node:["childNodes","parentNode","parentElement","textContent","ownerDocument"],ShadowRoot:["host","styleSheets"],Element:["shadowRoot","querySelector","querySelectorAll"],MutationObserver:[]},Si={Node:["contains","getRootNode"],ShadowRoot:["getSelection"],Element:[],MutationObserver:["constructor"]},Je={},nn={},ra=()=>!!globalThis.Zone;function ss(e){if(Je[e])return Je[e];let t=globalThis[e],r=t.prototype,a=e in vi?vi[e]:void 0,s=!!(a&&a.every(m=>{var o,d;return !!((d=(o=Object.getOwnPropertyDescriptor(r,m))==null?void 0:o.get)!=null&&d.toString().includes("[native code]"))})),u=e in Si?Si[e]:void 0,f=!!(u&&u.every(m=>{var o;return typeof r[m]=="function"&&((o=r[m])==null?void 0:o.toString().includes("[native code]"))}));if(s&&f&&!ra())return Je[e]=t.prototype,t.prototype;try{let m=document.createElement("iframe");m.style.display="none",document.body.appendChild(m);let o=m.contentWindow;if(!o)return t.prototype;let d=o[e].prototype;if(!d)return m.remove(),r;let i=navigator.userAgent;return i.includes("Safari")&&!i.includes("Chrome")?(m.classList.add("rr-block"),m.setAttribute("__rrwebUntaintedMutationObserver",""),nn[e]=()=>m.remove()):m.remove(),Je[e]=d}catch(m){return r}}var xr={};function me(e,t,r){var a;let s=`${e}.${String(r)}`;if(xr[s])return xr[s].call(t);let u=ss(e),f=(a=Object.getOwnPropertyDescriptor(u,r))==null?void 0:a.get;return f?(xr[s]=f,f.call(t)):t[r]}var Mr={};function on(e,t,r){let a=`${e}.${String(r)}`;if(Mr[a])return Mr[a].bind(t);let u=ss(e)[r];return typeof u!="function"?t[r]:(Mr[a]=u,u.bind(t))}function sa(e){return me("Node",e,"ownerDocument")}function ia(e){return me("Node",e,"childNodes")}function na(e){return me("Node",e,"parentNode")}function oa(e){return me("Node",e,"parentElement")}function aa(e){return me("Node",e,"textContent")}function la(e,t){return on("Node",e,"contains")(t)}function ua(e){return on("Node",e,"getRootNode")()}function ca(e){return !e||!("host"in e)?null:me("ShadowRoot",e,"host")}function ha(e){return e.styleSheets}function fa(e){return !e||!("shadowRoot"in e)?null:me("Element",e,"shadowRoot")}function da(e,t){return me("Element",e,"querySelector")(t)}function pa(e,t){return me("Element",e,"querySelectorAll")(t)}function an(){var e;return [ss("MutationObserver").constructor,(e=nn.MutationObserver)!=null?e:(()=>{})]}var Be=Date.now;/[1-9][0-9]{12}/.test(Date.now().toString())||(Be=()=>new Date().getTime());function Me(e,t,r){try{if(!(t in e))return ()=>{};let a=e[t],s=r(a);return typeof s=="function"&&(s.prototype=s.prototype||{},Object.defineProperties(s,{__rrweb_original__:{enumerable:!1,value:a}})),e[t]=s,()=>{e[t]=a;}}catch(a){return ()=>{}}}var _={ownerDocument:sa,childNodes:ia,parentNode:na,parentElement:oa,textContent:aa,contains:la,getRootNode:ua,host:ca,styleSheets:ha,shadowRoot:fa,querySelector:da,querySelectorAll:pa,nowTimestamp:Be,mutationObserverCtor:an,patch:Me};function ee(e,t,r=document){let a={capture:true,passive:true};return r.addEventListener(e,t,a),()=>r.removeEventListener(e,t,a)}var Ne=`Please stop import mirror directly. Instead of that,\r
|
|
52
|
+
now you can use replayer.getMirror() to access the mirror instance of a replayer,\r
|
|
53
|
+
or you can use record.mirror to access the mirror instance during recording.`,Ci={map:{},getId(){return console.error(Ne),-1},getNode(){return console.error(Ne),null},removeNodeFromMap(){console.error(Ne);},has(){return console.error(Ne),false},reset(){console.error(Ne);}};typeof window!="undefined"&&window.Proxy&&window.Reflect&&(Ci=new Proxy(Ci,{get(e,t,r){return t==="map"&&console.error(Ne),Reflect.get(e,t,r)}}));function $e(e,t,r={}){let a=null,s=0;return function(...u){let f=Date.now();!s&&r.leading===false&&(s=f);let m=t-(f-s),o=this;m<=0||m>t?(a&&(clearTimeout(a),a=null),s=f,e.apply(o,u)):!a&&r.trailing!==false&&(a=setTimeout(()=>{s=r.leading===false?0:Date.now(),a=null,e.apply(o,u);},m));}}function bt(e,t,r,a,s=window){let u=s.Object.getOwnPropertyDescriptor(e,t);return s.Object.defineProperty(e,t,a?r:{set(f){setTimeout(()=>{r.set.call(this,f);},0),u&&u.set&&u.set.call(this,f);}}),()=>bt(e,t,u||{},true)}function ln(e){var t,r,a,s;let u=e.document;return {left:u.scrollingElement?u.scrollingElement.scrollLeft:e.pageXOffset!==void 0?e.pageXOffset:u.documentElement.scrollLeft||(u==null?void 0:u.body)&&((t=_.parentElement(u.body))==null?void 0:t.scrollLeft)||((r=u==null?void 0:u.body)==null?void 0:r.scrollLeft)||0,top:u.scrollingElement?u.scrollingElement.scrollTop:e.pageYOffset!==void 0?e.pageYOffset:(u==null?void 0:u.documentElement.scrollTop)||(u==null?void 0:u.body)&&((a=_.parentElement(u.body))==null?void 0:a.scrollTop)||((s=u==null?void 0:u.body)==null?void 0:s.scrollTop)||0}}function un(){return window.innerHeight||document.documentElement&&document.documentElement.clientHeight||document.body&&document.body.clientHeight}function cn(){return window.innerWidth||document.documentElement&&document.documentElement.clientWidth||document.body&&document.body.clientWidth}function hn(e){return e?e.nodeType===e.ELEMENT_NODE?e:_.parentElement(e):null}function te(e,t,r,a){if(!e)return false;let s=hn(e);if(!s)return false;try{if(typeof t=="string"){if(s.classList.contains(t)||a&&s.closest("."+t)!==null)return !0}else if(nt(s,t,a))return !0}catch(u){}return !!(r&&(s.matches(r)||a&&s.closest(r)!==null))}function ma(e,t){return t.getId(e)!==-1}function Rr(e,t,r){return e.tagName==="TITLE"&&r.headTitleMutations?true:t.getId(e)===Ue}function fn(e,t){if(Pe(e))return false;let r=t.getId(e);if(!t.has(r))return true;let a=_.parentNode(e);return a&&a.nodeType===e.DOCUMENT_NODE?false:a?fn(a,t):true}function Ar(e){return !!e.changedTouches}function ga(e=window){"NodeList"in e&&!e.NodeList.prototype.forEach&&(e.NodeList.prototype.forEach=Array.prototype.forEach),"DOMTokenList"in e&&!e.DOMTokenList.prototype.forEach&&(e.DOMTokenList.prototype.forEach=Array.prototype.forEach);}function dn(e,t){return !!(e.nodeName==="IFRAME"&&t.getMeta(e))}function pn(e,t){return !!(e.nodeName==="LINK"&&e.nodeType===e.ELEMENT_NODE&&e.getAttribute&&e.getAttribute("rel")==="stylesheet"&&t.getMeta(e))}function Tr(e){return e?e instanceof Ir&&"shadowRoot"in e?!!e.shadowRoot:!!_.shadowRoot(e):false}var Dr=class{constructor(){I(this,"id",1),I(this,"styleIDMap",new WeakMap),I(this,"idStyleMap",new Map);}getId(t){var r;return (r=this.styleIDMap.get(t))!=null?r:-1}has(t){return this.styleIDMap.has(t)}add(t,r){if(this.has(t))return this.getId(t);let a;return r===void 0?a=this.id++:a=r,this.styleIDMap.set(t,a),this.idStyleMap.set(a,t),a}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 mn(e){var t;let r=null;return "getRootNode"in e&&((t=_.getRootNode(e))==null?void 0:t.nodeType)===Node.DOCUMENT_FRAGMENT_NODE&&_.host(_.getRootNode(e))&&(r=_.host(_.getRootNode(e))),r}function ya(e){let t=e,r;for(;r=mn(t);)t=r;return t}function wa(e){let t=_.ownerDocument(e);if(!t)return false;let r=ya(e);return _.contains(t,r)}function gn(e){let t=_.ownerDocument(e);return t?_.contains(t,e)||wa(e):false}var L=(e=>(e[e.DomContentLoaded=0]="DomContentLoaded",e[e.Load=1]="Load",e[e.FullSnapshot=2]="FullSnapshot",e[e.IncrementalSnapshot=3]="IncrementalSnapshot",e[e.Meta=4]="Meta",e[e.Custom=5]="Custom",e[e.Plugin=6]="Plugin",e[e.Asset=7]="Asset",e))(L||{}),k=(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))(k||{}),re=(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))(re||{}),de=(e=>(e[e.Mouse=0]="Mouse",e[e.Pen=1]="Pen",e[e.Touch=2]="Touch",e))(de||{}),De=(e=>(e[e["2D"]=0]="2D",e[e.WebGL=1]="WebGL",e[e.WebGL2=2]="WebGL2",e))(De||{}),Oe=(e=>(e[e.Play=0]="Play",e[e.Pause=1]="Pause",e[e.Seeked=2]="Seeked",e[e.VolumeChange=3]="VolumeChange",e[e.RateChange=4]="RateChange",e))(Oe||{});var yn=(e=>(e[e.Document=0]="Document",e[e.DocumentType=1]="DocumentType",e[e.Element=2]="Element",e[e.Text=3]="Text",e[e.CDATA=4]="CDATA",e[e.Comment=5]="Comment",e))(yn||{});function Ei(e){return "__ln"in e}var _r=class{constructor(){I(this,"length",0),I(this,"head",null),I(this,"tail",null);}get(t){if(t>=this.length)throw new Error("Position outside of list range");let r=this.head;for(let a=0;a<t;a++)r=(r==null?void 0:r.next)||null;return r}addNode(t){let r={value:t,previous:null,next:null};if(t.__ln=r,t.previousSibling&&Ei(t.previousSibling)){let a=t.previousSibling.__ln.next;r.next=a,r.previous=t.previousSibling.__ln,t.previousSibling.__ln.next=r,a&&(a.previous=r);}else if(t.nextSibling&&Ei(t.nextSibling)&&t.nextSibling.__ln.previous){let a=t.nextSibling.__ln.previous;r.previous=a,r.next=t.nextSibling.__ln,t.nextSibling.__ln.previous=r,a&&(a.next=r);}else this.head&&(this.head.previous=r),r.next=this.head,this.head=r;r.next===null&&(this.tail=r),this.length++;}removeNode(t){let r=t.__ln;this.head&&(r.previous?(r.previous.next=r.next,r.next?r.next.previous=r.previous:this.tail=r.previous):(this.head=r.next,this.head?this.head.previous=null:this.tail=null),t.__ln&&delete t.__ln,this.length--);}},xi=(e,t)=>`${e}@${t}`,kr=class{constructor(){I(this,"frozen",false),I(this,"locked",false),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",t=>{t.forEach(this.processMutation),this.emit();}),I(this,"emit",()=>{if(this.frozen||this.locked)return;let t=[],r=new Set,a=new _r,s=o=>{let d=o,i=Ue;for(;i===Ue;)d=d&&d.nextSibling,i=d&&this.mirror.getId(d);return i},u=o=>{let d=_.parentNode(o);if(!d||!gn(o))return;let i=false;if(o.nodeType===Node.TEXT_NODE){let p=d.tagName;if(p==="TEXTAREA")return;p==="STYLE"&&this.addedSet.has(d)&&(i=true);}let h=Pe(d)?this.mirror.getId(mn(o)):this.mirror.getId(d),l=s(o);if(h===-1||l===-1)return a.addNode(o);let n=Ae(o,{doc:this.doc,mirror:this.mirror,blockClass:this.blockClass,blockSelector:this.blockSelector,maskTextClass:this.maskTextClass,maskTextSelector:this.maskTextSelector,skipChild:true,newlyAddedElement:true,inlineStylesheet:this.inlineStylesheet,maskInputOptions:this.maskInputOptions,maskTextFn:this.maskTextFn,maskInputFn:this.maskInputFn,slimDOMOptions:this.slimDOMOptions,dataURLOptions:this.dataURLOptions,recordCanvas:this.recordCanvas,inlineImages:this.inlineImages,onSerialize:p=>{dn(p,this.mirror)&&this.iframeManager.addIframe(p),pn(p,this.mirror)&&this.stylesheetManager.trackLinkElement(p),Tr(o)&&this.shadowDomManager.addShadowRoot(_.shadowRoot(o),this.doc);},onIframeLoad:(p,c)=>{this.iframeManager.attachIframe(p,c),this.shadowDomManager.observeAttachShadow(p);},onStylesheetLoad:(p,c)=>{this.stylesheetManager.attachLinkElement(p,c);},cssCaptured:i});n&&(t.push({parentId:h,nextId:l,node:n}),r.add(n.id));};for(;this.mapRemoves.length;)this.mirror.removeNodeFromMap(this.mapRemoves.shift());for(let o of this.movedSet)Mi(this.removesSubTreeCache,o,this.mirror)&&!this.movedSet.has(_.parentNode(o))||u(o);for(let o of this.addedSet)!Ri(this.droppedSet,o)&&!Mi(this.removesSubTreeCache,o,this.mirror)||Ri(this.movedSet,o)?u(o):this.droppedSet.add(o);let f=null;for(;a.length;){let o=null;if(f){let d=this.mirror.getId(_.parentNode(f.value)),i=s(f.value);d!==-1&&i!==-1&&(o=f);}if(!o){let d=a.tail;for(;d;){let i=d;if(d=d.previous,i){let h=this.mirror.getId(_.parentNode(i.value));if(s(i.value)===-1)continue;if(h!==-1){o=i;break}else {let n=i.value,p=_.parentNode(n);if(p&&p.nodeType===Node.DOCUMENT_FRAGMENT_NODE){let c=_.host(p);if(this.mirror.getId(c)!==-1){o=i;break}}}}}}if(!o){for(;a.head;)a.removeNode(a.head.value);break}f=o.previous,a.removeNode(o.value),u(o.value);}let m={texts:this.texts.map(o=>{let d=o.node,i=_.parentNode(d);return i&&i.tagName==="TEXTAREA"&&this.genTextAreaValueMutation(i),{id:this.mirror.getId(d),value:o.value}}).filter(o=>!r.has(o.id)).filter(o=>this.mirror.has(o.id)),attributes:this.attributes.map(o=>{let{attributes:d}=o;if(typeof d.style=="string"){let i=JSON.stringify(o.styleDiff),h=JSON.stringify(o._unchangedStyles);i.length<d.style.length&&(i+h).split("var(").length===d.style.split("var(").length&&(d.style=o.styleDiff);}return {id:this.mirror.getId(o.node),attributes:d}}).filter(o=>!r.has(o.id)).filter(o=>this.mirror.has(o.id)),removes:this.removes,adds:t};!m.texts.length&&!m.attributes.length&&!m.removes.length&&!m.adds.length||(this.texts=[],this.attributes=[],this.attributeMap=new WeakMap,this.removes=[],this.addedSet=new Set,this.movedSet=new Set,this.droppedSet=new Set,this.removesSubTreeCache=new Set,this.movedMap={},this.mutationCb(m));}),I(this,"genTextAreaValueMutation",t=>{let r=this.attributeMap.get(t);r||(r={node:t,attributes:{},styleDiff:{},_unchangedStyles:{}},this.attributes.push(r),this.attributeMap.set(t,r));let a=Array.from(_.childNodes(t),s=>_.textContent(s)||"").join("");r.attributes.value=rt({element:t,maskInputOptions:this.maskInputOptions,tagName:t.tagName,type:st(t),value:a,maskInputFn:this.maskInputFn});}),I(this,"processMutation",t=>{if(!Rr(t.target,this.mirror,this.slimDOMOptions))switch(t.type){case "characterData":{let r=_.textContent(t.target);!te(t.target,this.blockClass,this.blockSelector,false)&&r!==t.oldValue&&this.texts.push({value:zi(t.target,this.maskTextClass,this.maskTextSelector,true)&&r?this.maskTextFn?this.maskTextFn(r,hn(t.target)):r.replace(/[\S]/g,"*"):r,node:t.target});break}case "attributes":{let r=t.target,a=t.attributeName,s=t.target.getAttribute(a);if(a==="value"){let f=st(r);s=rt({element:r,maskInputOptions:this.maskInputOptions,tagName:r.tagName,type:f,value:s,maskInputFn:this.maskInputFn});}if(te(t.target,this.blockClass,this.blockSelector,false)||s===t.oldValue)return;let u=this.attributeMap.get(t.target);if(r.tagName==="IFRAME"&&a==="src"&&!this.keepIframeSrcFn(s))if(!r.contentDocument)a="rr_src";else return;if(u||(u={node:t.target,attributes:{},styleDiff:{},_unchangedStyles:{}},this.attributes.push(u),this.attributeMap.set(t.target,u)),a==="type"&&r.tagName==="INPUT"&&(t.oldValue||"").toLowerCase()==="password"&&r.setAttribute("data-rr-is-password","true"),!Wi(r.tagName,a))if(u.attributes[a]=$i(this.doc,Ce(r.tagName),Ce(a),s),a==="style"){if(!this.unattachedDoc)try{this.unattachedDoc=document.implementation.createHTMLDocument();}catch(m){this.unattachedDoc=this.doc;}let f=this.unattachedDoc.createElement("span");t.oldValue&&f.setAttribute("style",t.oldValue);for(let m of Array.from(r.style)){let o=r.style.getPropertyValue(m),d=r.style.getPropertyPriority(m);o!==f.style.getPropertyValue(m)||d!==f.style.getPropertyPriority(m)?d===""?u.styleDiff[m]=o:u.styleDiff[m]=[o,d]:u._unchangedStyles[m]=[o,d];}for(let m of Array.from(f.style))r.style.getPropertyValue(m)===""&&(u.styleDiff[m]=false);}else a==="open"&&r.tagName==="DIALOG"&&(r.matches("dialog:modal")?u.attributes.rr_open_mode="modal":u.attributes.rr_open_mode="non-modal");break}case "childList":{if(te(t.target,this.blockClass,this.blockSelector,true))return;if(t.target.tagName==="TEXTAREA"){this.genTextAreaValueMutation(t.target);return}t.addedNodes.forEach(r=>this.genAdds(r,t.target)),t.removedNodes.forEach(r=>{let a=this.mirror.getId(r),s=Pe(t.target)?this.mirror.getId(_.host(t.target)):this.mirror.getId(t.target);te(t.target,this.blockClass,this.blockSelector,false)||Rr(r,this.mirror,this.slimDOMOptions)||!ma(r,this.mirror)||(this.addedSet.has(r)?(Pr(this.addedSet,r),this.droppedSet.add(r)):this.addedSet.has(t.target)&&a===-1||fn(t.target,this.mirror)||(this.movedSet.has(r)&&this.movedMap[xi(a,s)]?Pr(this.movedSet,r):(this.removes.push({parentId:s,id:a,isShadow:Pe(t.target)&&Le(t.target)?true:void 0}),ba(r,this.removesSubTreeCache))),this.mapRemoves.push(r));});break}}}),I(this,"genAdds",(t,r)=>{if(!this.processedNodeManager.inOtherBuffer(t,this)&&!(this.addedSet.has(t)||this.movedSet.has(t))){if(this.mirror.hasNode(t)){if(Rr(t,this.mirror,this.slimDOMOptions))return;this.movedSet.add(t);let a=null;r&&this.mirror.hasNode(r)&&(a=this.mirror.getId(r)),a&&a!==-1&&(this.movedMap[xi(this.mirror.getId(t),a)]=true);}else this.addedSet.add(t),this.droppedSet.delete(t);te(t,this.blockClass,this.blockSelector,false)||(_.childNodes(t).forEach(a=>this.genAdds(a)),Tr(t)&&_.childNodes(_.shadowRoot(t)).forEach(a=>{this.processedNodeManager.add(a,this),this.genAdds(a,t);}));}});}init(t){["mutationCb","blockClass","blockSelector","maskTextClass","maskTextSelector","inlineStylesheet","maskInputOptions","maskTextFn","maskInputFn","keepIframeSrcFn","recordCanvas","inlineImages","slimDOMOptions","dataURLOptions","doc","mirror","iframeManager","stylesheetManager","shadowDomManager","canvasManager","processedNodeManager"].forEach(r=>{this[r]=t[r];});}freeze(){this.frozen=true,this.canvasManager.freeze();}unfreeze(){this.frozen=false,this.canvasManager.unfreeze(),this.emit();}isFrozen(){return this.frozen}lock(){this.locked=true,this.canvasManager.lock();}unlock(){this.locked=false,this.canvasManager.unlock(),this.emit();}reset(){this.shadowDomManager.reset(),this.canvasManager.reset();}};function Pr(e,t){e.delete(t),_.childNodes(t).forEach(r=>Pr(e,r));}function ba(e,t){let r=[e];for(;r.length;){let a=r.pop();t.has(a)||(t.add(a),_.childNodes(a).forEach(s=>r.push(s)));}}function Mi(e,t,r){return e.size===0?false:va(e,t)}function va(e,t,r){let a=_.parentNode(t);return a?e.has(a):false}function Ri(e,t){return e.size===0?false:wn(e,t)}function wn(e,t){let r=_.parentNode(t);return r?e.has(r)?true:wn(e,r):false}var Fe;function Sa(e){Fe=e;}function Ca(){Fe=void 0;}var P=e=>Fe?(...r)=>{try{return e(...r)}catch(a){if(Fe&&Fe(a)===true)return;throw a}}:e,Se=[];function qe(e){try{if("composedPath"in e){let t=e.composedPath();if(t.length)return t[0]}else if("path"in e&&e.path.length)return e.path[0]}catch(t){}return e&&e.target}function bn(e,t){let r=new kr;Se.push(r),r.init(e);let[a,s]=an(),u=new a(P(r.processMutations.bind(r)));return u.observe(t,{attributes:true,attributeOldValue:true,characterData:true,characterDataOldValue:true,childList:true,subtree:true}),[u,s]}function Ea({mousemoveCb:e,sampling:t,doc:r,mirror:a}){if(t.mousemove===false)return ()=>{};let s=typeof t.mousemove=="number"?t.mousemove:50,u=typeof t.mousemoveCallback=="number"?t.mousemoveCallback:500,f=[],m,o=$e(P(h=>{let l=Date.now()-m;e(f.map(n=>(n.timeOffset-=l,n)),h),f=[],m=null;}),u),d=P($e(P(h=>{let l=qe(h),{clientX:n,clientY:p}=Ar(h)?h.changedTouches[0]:h;m||(m=Be()),f.push({x:n,y:p,id:a.getId(l),timeOffset:Be()-m}),o(typeof DragEvent!="undefined"&&h instanceof DragEvent?k.Drag:h instanceof MouseEvent?k.MouseMove:k.TouchMove);}),s,{trailing:!1})),i=[ee("mousemove",d,r),ee("touchmove",d,r),ee("drag",d,r)];return P(()=>{i.forEach(h=>h());})}function xa({mouseInteractionCb:e,doc:t,mirror:r,blockClass:a,blockSelector:s,sampling:u}){if(u.mouseInteraction===false)return ()=>{};let f=u.mouseInteraction===true||u.mouseInteraction===void 0?{}:u.mouseInteraction,m=[],o=null,d=i=>h=>{let l=qe(h);if(te(l,a,s,true))return;let n=null,p=i;if("pointerType"in h){switch(h.pointerType){case "mouse":n=de.Mouse;break;case "touch":n=de.Touch;break;case "pen":n=de.Pen;break}n===de.Touch?re[i]===re.MouseDown?p="TouchStart":re[i]===re.MouseUp&&(p="TouchEnd"):de.Pen;}else Ar(h)&&(n=de.Touch);n!==null?(o=n,(p.startsWith("Touch")&&n===de.Touch||p.startsWith("Mouse")&&n===de.Mouse)&&(n=null)):re[i]===re.Click&&(n=o,o=null);let c=Ar(h)?h.changedTouches[0]:h;if(!c)return;let g=r.getId(l),{clientX:S,clientY:b}=c;P(e)({type:re[p],id:g,x:S,y:b,...n!==null&&{pointerType:n}});};return Object.keys(re).filter(i=>Number.isNaN(Number(i))&&!i.endsWith("_Departed")&&f[i]!==false).forEach(i=>{let h=Ce(i),l=d(i);if(window.PointerEvent)switch(re[i]){case re.MouseDown:case re.MouseUp:h=h.replace("mouse","pointer");break;case re.TouchStart:case re.TouchEnd:return}m.push(ee(h,l,t));}),P(()=>{m.forEach(i=>i());})}function vn({scrollCb:e,doc:t,mirror:r,blockClass:a,blockSelector:s,sampling:u}){let f=P($e(P(m=>{let o=qe(m);if(!o||te(o,a,s,!0))return;let d=r.getId(o);if(o===t&&t.defaultView){let i=ln(t.defaultView);e({id:d,x:i.left,y:i.top});}else e({id:d,x:o.scrollLeft,y:o.scrollTop});}),u.scroll||100));return ee("scroll",f,t)}function Ma({viewportResizeCb:e},{win:t}){let r=-1,a=-1,s=P($e(P(()=>{let u=un(),f=cn();(r!==u||a!==f)&&(e({width:Number(f),height:Number(u)}),r=u,a=f);}),200));return ee("resize",s,t)}var Ra=["INPUT","TEXTAREA","SELECT"],Ni=new WeakMap;function Na({inputCb:e,doc:t,mirror:r,blockClass:a,blockSelector:s,ignoreClass:u,ignoreSelector:f,maskInputOptions:m,maskInputFn:o,sampling:d,userTriggeredOnInput:i}){function h(b){let v=qe(b),E=b.isTrusted,w=v&&v.tagName;if(v&&w==="OPTION"&&(v=_.parentElement(v)),!v||!w||Ra.indexOf(w)<0||te(v,a,s,true)||v.classList.contains(u)||f&&v.matches(f))return;let y=v.value,C=false,M=st(v)||"";M==="radio"||M==="checkbox"?C=v.checked:(m[w.toLowerCase()]||m[M])&&(y=rt({element:v,maskInputOptions:m,tagName:w,type:M,value:y,maskInputFn:o})),l(v,i?{text:y,isChecked:C,userTriggered:E}:{text:y,isChecked:C});let O=v.name;M==="radio"&&O&&C&&t.querySelectorAll(`input[type="radio"][name="${O}"]`).forEach(R=>{if(R!==v){let D=R.value;l(R,i?{text:D,isChecked:!C,userTriggered:false}:{text:D,isChecked:!C});}});}function l(b,v){let E=Ni.get(b);if(!E||E.text!==v.text||E.isChecked!==v.isChecked){Ni.set(b,v);let w=r.getId(b);P(e)({...v,id:w});}}let p=(d.input==="last"?["change"]:["input","change"]).map(b=>ee(b,P(h),t)),c=t.defaultView;if(!c)return ()=>{p.forEach(b=>b());};let g=c.Object.getOwnPropertyDescriptor(c.HTMLInputElement.prototype,"value"),S=[[c.HTMLInputElement.prototype,"value"],[c.HTMLInputElement.prototype,"checked"],[c.HTMLSelectElement.prototype,"value"],[c.HTMLTextAreaElement.prototype,"value"],[c.HTMLSelectElement.prototype,"selectedIndex"],[c.HTMLOptionElement.prototype,"selected"]];return g&&g.set&&p.push(...S.map(b=>bt(b[0],b[1],{set(){P(h)({target:this,isTrusted:false});}},false,c))),P(()=>{p.forEach(b=>b());})}function ot(e){let t=[];function r(a,s){if(Qe("CSSGroupingRule")&&a.parentRule instanceof CSSGroupingRule||Qe("CSSMediaRule")&&a.parentRule instanceof CSSMediaRule||Qe("CSSSupportsRule")&&a.parentRule instanceof CSSSupportsRule||Qe("CSSConditionRule")&&a.parentRule instanceof CSSConditionRule){let f=Array.from(a.parentRule.cssRules).indexOf(a);return s.unshift(f),r(a.parentRule,s)}else if(a.parentStyleSheet){let f=Array.from(a.parentStyleSheet.cssRules).indexOf(a);s.unshift(f);}return s}return r(e,t)}function be(e,t,r){let a,s;return e?(e.ownerNode?a=t.getId(e.ownerNode):s=r.getId(e),{styleId:s,id:a}):{}}function Oa({styleSheetRuleCb:e,mirror:t,stylesheetManager:r},{win:a}){if(!a.CSSStyleSheet||!a.CSSStyleSheet.prototype)return ()=>{};let s=a.CSSStyleSheet.prototype.insertRule;a.CSSStyleSheet.prototype.insertRule=new Proxy(s,{apply:P((i,h,l)=>{let[n,p]=l,{id:c,styleId:g}=be(h,t,r.styleMirror);return (c&&c!==-1||g&&g!==-1)&&e({id:c,styleId:g,adds:[{rule:n,index:p}]}),i.apply(h,l)})}),a.CSSStyleSheet.prototype.addRule=function(i,h,l=this.cssRules.length){let n=`${i} { ${h} }`;return a.CSSStyleSheet.prototype.insertRule.apply(this,[n,l])};let u=a.CSSStyleSheet.prototype.deleteRule;a.CSSStyleSheet.prototype.deleteRule=new Proxy(u,{apply:P((i,h,l)=>{let[n]=l,{id:p,styleId:c}=be(h,t,r.styleMirror);return (p&&p!==-1||c&&c!==-1)&&e({id:p,styleId:c,removes:[{index:n}]}),i.apply(h,l)})}),a.CSSStyleSheet.prototype.removeRule=function(i){return a.CSSStyleSheet.prototype.deleteRule.apply(this,[i])};let f;a.CSSStyleSheet.prototype.replace&&(f=a.CSSStyleSheet.prototype.replace,a.CSSStyleSheet.prototype.replace=new Proxy(f,{apply:P((i,h,l)=>{let[n]=l,{id:p,styleId:c}=be(h,t,r.styleMirror);return (p&&p!==-1||c&&c!==-1)&&e({id:p,styleId:c,replace:n}),i.apply(h,l)})}));let m;a.CSSStyleSheet.prototype.replaceSync&&(m=a.CSSStyleSheet.prototype.replaceSync,a.CSSStyleSheet.prototype.replaceSync=new Proxy(m,{apply:P((i,h,l)=>{let[n]=l,{id:p,styleId:c}=be(h,t,r.styleMirror);return (p&&p!==-1||c&&c!==-1)&&e({id:p,styleId:c,replaceSync:n}),i.apply(h,l)})}));let o={};Ze("CSSGroupingRule")?o.CSSGroupingRule=a.CSSGroupingRule:(Ze("CSSMediaRule")&&(o.CSSMediaRule=a.CSSMediaRule),Ze("CSSConditionRule")&&(o.CSSConditionRule=a.CSSConditionRule),Ze("CSSSupportsRule")&&(o.CSSSupportsRule=a.CSSSupportsRule));let d={};return Object.entries(o).forEach(([i,h])=>{d[i]={insertRule:h.prototype.insertRule,deleteRule:h.prototype.deleteRule},h.prototype.insertRule=new Proxy(d[i].insertRule,{apply:P((l,n,p)=>{let[c,g]=p,{id:S,styleId:b}=be(n.parentStyleSheet,t,r.styleMirror);return (S&&S!==-1||b&&b!==-1)&&e({id:S,styleId:b,adds:[{rule:c,index:[...ot(n),g||0]}]}),l.apply(n,p)})}),h.prototype.deleteRule=new Proxy(d[i].deleteRule,{apply:P((l,n,p)=>{let[c]=p,{id:g,styleId:S}=be(n.parentStyleSheet,t,r.styleMirror);return (g&&g!==-1||S&&S!==-1)&&e({id:g,styleId:S,removes:[{index:[...ot(n),c]}]}),l.apply(n,p)})});}),P(()=>{a.CSSStyleSheet.prototype.insertRule=s,a.CSSStyleSheet.prototype.deleteRule=u,f&&(a.CSSStyleSheet.prototype.replace=f),m&&(a.CSSStyleSheet.prototype.replaceSync=m),Object.entries(o).forEach(([i,h])=>{h.prototype.insertRule=d[i].insertRule,h.prototype.deleteRule=d[i].deleteRule;});})}function Sn({mirror:e,stylesheetManager:t},r){var a,s,u;let f=null;r.nodeName==="#document"?f=e.getId(r):f=e.getId(_.host(r));let m=r.nodeName==="#document"?(a=r.defaultView)==null?void 0:a.Document:(u=(s=r.ownerDocument)==null?void 0:s.defaultView)==null?void 0:u.ShadowRoot,o=m!=null&&m.prototype?Object.getOwnPropertyDescriptor(m==null?void 0:m.prototype,"adoptedStyleSheets"):void 0;return f===null||f===-1||!m||!o?()=>{}:(Object.defineProperty(r,"adoptedStyleSheets",{configurable:o.configurable,enumerable:o.enumerable,get(){var d;return (d=o.get)==null?void 0:d.call(this)},set(d){var i;let h=(i=o.set)==null?void 0:i.call(this,d);if(f!==null&&f!==-1)try{t.adoptStyleSheets(d,f);}catch(l){}return h}}),P(()=>{Object.defineProperty(r,"adoptedStyleSheets",{configurable:o.configurable,enumerable:o.enumerable,get:o.get,set:o.set});}))}function Ia({styleDeclarationCb:e,mirror:t,ignoreCSSAttributes:r,stylesheetManager:a},{win:s}){let u=s.CSSStyleDeclaration.prototype.setProperty;s.CSSStyleDeclaration.prototype.setProperty=new Proxy(u,{apply:P((m,o,d)=>{var i;let[h,l,n]=d;if(r.has(h))return u.apply(o,[h,l,n]);let{id:p,styleId:c}=be((i=o.parentRule)==null?void 0:i.parentStyleSheet,t,a.styleMirror);return (p&&p!==-1||c&&c!==-1)&&e({id:p,styleId:c,set:{property:h,value:l,priority:n},index:ot(o.parentRule)}),m.apply(o,d)})});let f=s.CSSStyleDeclaration.prototype.removeProperty;return s.CSSStyleDeclaration.prototype.removeProperty=new Proxy(f,{apply:P((m,o,d)=>{var i;let[h]=d;if(r.has(h))return f.apply(o,[h]);let{id:l,styleId:n}=be((i=o.parentRule)==null?void 0:i.parentStyleSheet,t,a.styleMirror);return (l&&l!==-1||n&&n!==-1)&&e({id:l,styleId:n,remove:{property:h},index:ot(o.parentRule)}),m.apply(o,d)})}),P(()=>{s.CSSStyleDeclaration.prototype.setProperty=u,s.CSSStyleDeclaration.prototype.removeProperty=f;})}function Aa({mediaInteractionCb:e,blockClass:t,blockSelector:r,mirror:a,sampling:s,doc:u}){let f=P(o=>$e(P(d=>{let i=qe(d);if(!i||te(i,t,r,!0))return;let{currentTime:h,volume:l,muted:n,playbackRate:p,loop:c}=i;e({type:o,id:a.getId(i),currentTime:h,volume:l,muted:n,playbackRate:p,loop:c});}),s.media||500)),m=[ee("play",f(Oe.Play),u),ee("pause",f(Oe.Pause),u),ee("seeked",f(Oe.Seeked),u),ee("volumechange",f(Oe.VolumeChange),u),ee("ratechange",f(Oe.RateChange),u)];return P(()=>{m.forEach(o=>o());})}function Ta({fontCb:e,doc:t}){let r=t.defaultView;if(!r)return ()=>{};let a=[],s=new WeakMap,u=r.FontFace;r.FontFace=function(o,d,i){let h=new u(o,d,i);return s.set(h,{family:o,buffer:typeof d!="string",descriptors:i,fontSource:typeof d=="string"?d:JSON.stringify(Array.from(new Uint8Array(d)))}),h};let f=Me(t.fonts,"add",function(m){return function(o){return setTimeout(P(()=>{let d=s.get(o);d&&(e(d),s.delete(o));}),0),m.apply(this,[o])}});return a.push(()=>{r.FontFace=u;}),a.push(f),P(()=>{a.forEach(m=>m());})}function Da(e){let{doc:t,mirror:r,blockClass:a,blockSelector:s,selectionCb:u}=e,f=true,m=P(()=>{let o=t.getSelection();if(!o||f&&(o!=null&&o.isCollapsed))return;f=o.isCollapsed||!1;let d=[],i=o.rangeCount||0;for(let h=0;h<i;h++){let l=o.getRangeAt(h),{startContainer:n,startOffset:p,endContainer:c,endOffset:g}=l;te(n,a,s,!0)||te(c,a,s,!0)||d.push({start:r.getId(n),startOffset:p,end:r.getId(c),endOffset:g});}u({ranges:d});});return m(),ee("selectionchange",m)}function _a({doc:e,customElementCb:t}){let r=e.defaultView;return !r||!r.customElements?()=>{}:Me(r.customElements,"define",function(s){return function(u,f,m){try{t({define:{name:u}});}catch(o){console.warn(`Custom element callback failed for ${u}`);}return s.apply(this,[u,f,m])}})}function ka(e,t){let{mutationCb:r,mousemoveCb:a,mouseInteractionCb:s,scrollCb:u,viewportResizeCb:f,inputCb:m,mediaInteractionCb:o,styleSheetRuleCb:d,styleDeclarationCb:i,canvasMutationCb:h,fontCb:l,selectionCb:n,customElementCb:p}=e;e.mutationCb=(...c)=>{t.mutation&&t.mutation(...c),r(...c);},e.mousemoveCb=(...c)=>{t.mousemove&&t.mousemove(...c),a(...c);},e.mouseInteractionCb=(...c)=>{t.mouseInteraction&&t.mouseInteraction(...c),s(...c);},e.scrollCb=(...c)=>{t.scroll&&t.scroll(...c),u(...c);},e.viewportResizeCb=(...c)=>{t.viewportResize&&t.viewportResize(...c),f(...c);},e.inputCb=(...c)=>{t.input&&t.input(...c),m(...c);},e.mediaInteractionCb=(...c)=>{t.mediaInteaction&&t.mediaInteaction(...c),o(...c);},e.styleSheetRuleCb=(...c)=>{t.styleSheetRule&&t.styleSheetRule(...c),d(...c);},e.styleDeclarationCb=(...c)=>{t.styleDeclaration&&t.styleDeclaration(...c),i(...c);},e.canvasMutationCb=(...c)=>{t.canvasMutation&&t.canvasMutation(...c),h(...c);},e.fontCb=(...c)=>{t.font&&t.font(...c),l(...c);},e.selectionCb=(...c)=>{t.selection&&t.selection(...c),n(...c);},e.customElementCb=(...c)=>{t.customElement&&t.customElement(...c),p(...c);};}function Pa(e,t={}){let r=e.doc.defaultView;if(!r)return ()=>{};ka(e,t);let a,s=()=>{};e.recordDOM&&([a,s]=bn(e,e.doc));let u=Ea(e),f=xa(e),m=vn(e),o=Ma(e,{win:r}),d=Na(e),i=Aa(e),h=()=>{},l=()=>{},n=()=>{},p=()=>{};e.recordDOM&&(h=Oa(e,{win:r}),l=Sn(e,e.doc),n=Ia(e,{win:r}),e.collectFonts&&(p=Ta(e)));let c=Da(e),g=_a(e),S=[];for(let b of e.plugins)S.push(b.observer(b.callback,r,b.options));return P(()=>{Se.forEach(b=>b.reset()),a==null||a.disconnect(),s(),u(),f(),m(),o(),d(),i(),h(),l(),n(),p(),c(),g(),S.forEach(b=>b());})}function Qe(e){return typeof window[e]!="undefined"}function Ze(e){return !!(typeof window[e]!="undefined"&&window[e].prototype&&"insertRule"in window[e].prototype&&"deleteRule"in window[e].prototype)}var at=class{constructor(t){I(this,"iframeIdToRemoteIdMap",new WeakMap),I(this,"iframeRemoteIdToIdMap",new WeakMap),this.generateIdFn=t;}getId(t,r,a,s){let u=a||this.getIdToRemoteIdMap(t),f=s||this.getRemoteIdToIdMap(t),m=u.get(r);return m||(m=this.generateIdFn(),u.set(r,m),f.set(m,r)),m}getIds(t,r){let a=this.getIdToRemoteIdMap(t),s=this.getRemoteIdToIdMap(t);return r.map(u=>this.getId(t,u,a,s))}getRemoteId(t,r,a){let s=a||this.getRemoteIdToIdMap(t);if(typeof r!="number")return r;let u=s.get(r);return u||-1}getRemoteIds(t,r){let a=this.getRemoteIdToIdMap(t);return r.map(s=>this.getRemoteId(t,s,a))}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}},Lr=class{constructor(t){I(this,"iframes",new WeakMap),I(this,"crossOriginIframeMap",new WeakMap),I(this,"crossOriginIframeMirror",new at(Bi)),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=t.mutationCb,this.wrappedEmit=t.wrappedEmit,this.stylesheetManager=t.stylesheetManager,this.recordCrossOriginIframes=t.recordCrossOriginIframes,this.crossOriginIframeStyleMirror=new at(this.stylesheetManager.styleMirror.generateId.bind(this.stylesheetManager.styleMirror)),this.mirror=t.mirror,this.recordCrossOriginIframes&&window.addEventListener("message",this.handleMessage.bind(this));}addIframe(t){this.iframes.set(t,true),t.contentWindow&&this.crossOriginIframeMap.set(t.contentWindow,t);}addLoadListener(t){this.loadListener=t;}attachIframe(t,r){var a,s;this.mutationCb({adds:[{parentId:this.mirror.getId(t),nextId:null,node:r}],removes:[],texts:[],attributes:[],isAttachIframe:true}),this.recordCrossOriginIframes&&((a=t.contentWindow)==null||a.addEventListener("message",this.handleMessage.bind(this))),(s=this.loadListener)==null||s.call(this,t),t.contentDocument&&t.contentDocument.adoptedStyleSheets&&t.contentDocument.adoptedStyleSheets.length>0&&this.stylesheetManager.adoptStyleSheets(t.contentDocument.adoptedStyleSheets,this.mirror.getId(t.contentDocument));}handleMessage(t){let r=t;if(r.data.type!=="rrweb"||r.origin!==r.data.origin||!t.source)return;let s=this.crossOriginIframeMap.get(t.source);if(!s)return;let u=this.transformCrossOriginEvent(s,r.data.event);u&&this.wrappedEmit(u,r.data.isCheckout);}transformCrossOriginEvent(t,r){var a;switch(r.type){case L.FullSnapshot:{this.crossOriginIframeMirror.reset(t),this.crossOriginIframeStyleMirror.reset(t),this.replaceIdOnNode(r.data.node,t);let s=r.data.node.id;return this.crossOriginIframeRootIdMap.set(t,s),this.patchRootIdOnNode(r.data.node,s),{timestamp:r.timestamp,type:L.IncrementalSnapshot,data:{source:k.Mutation,adds:[{parentId:this.mirror.getId(t),nextId:null,node:r.data.node}],removes:[],texts:[],attributes:[],isAttachIframe:true}}}case L.Meta:case L.Load:case L.DomContentLoaded:return false;case L.Plugin:return r;case L.Custom:return this.replaceIds(r.data.payload,t,["id","parentId","previousId","nextId"]),r;case L.IncrementalSnapshot:switch(r.data.source){case k.Mutation:return r.data.adds.forEach(s=>{this.replaceIds(s,t,["parentId","nextId","previousId"]),this.replaceIdOnNode(s.node,t);let u=this.crossOriginIframeRootIdMap.get(t);u&&this.patchRootIdOnNode(s.node,u);}),r.data.removes.forEach(s=>{this.replaceIds(s,t,["parentId","id"]);}),r.data.attributes.forEach(s=>{this.replaceIds(s,t,["id"]);}),r.data.texts.forEach(s=>{this.replaceIds(s,t,["id"]);}),r;case k.Drag:case k.TouchMove:case k.MouseMove:return r.data.positions.forEach(s=>{this.replaceIds(s,t,["id"]);}),r;case k.ViewportResize:return false;case k.MediaInteraction:case k.MouseInteraction:case k.Scroll:case k.CanvasMutation:case k.Input:return this.replaceIds(r.data,t,["id"]),r;case k.StyleSheetRule:case k.StyleDeclaration:return this.replaceIds(r.data,t,["id"]),this.replaceStyleIds(r.data,t,["styleId"]),r;case k.Font:return r;case k.Selection:return r.data.ranges.forEach(s=>{this.replaceIds(s,t,["start","end"]);}),r;case k.AdoptedStyleSheet:return this.replaceIds(r.data,t,["id"]),this.replaceStyleIds(r.data,t,["styleIds"]),(a=r.data.styles)==null||a.forEach(s=>{this.replaceStyleIds(s,t,["styleId"]);}),r}}return false}replace(t,r,a,s){for(let u of s)!Array.isArray(r[u])&&typeof r[u]!="number"||(Array.isArray(r[u])?r[u]=t.getIds(a,r[u]):r[u]=t.getId(a,r[u]));return r}replaceIds(t,r,a){return this.replace(this.crossOriginIframeMirror,t,r,a)}replaceStyleIds(t,r,a){return this.replace(this.crossOriginIframeStyleMirror,t,r,a)}replaceIdOnNode(t,r){this.replaceIds(t,r,["id","rootId"]),"childNodes"in t&&t.childNodes.forEach(a=>{this.replaceIdOnNode(a,r);});}patchRootIdOnNode(t,r){t.type!==yn.Document&&!t.rootId&&(t.rootId=r),"childNodes"in t&&t.childNodes.forEach(a=>{this.patchRootIdOnNode(a,r);});}},Fr=class{constructor(t){I(this,"shadowDoms",new WeakSet),I(this,"mutationCb"),I(this,"scrollCb"),I(this,"bypassOptions"),I(this,"mirror"),I(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(!Le(t)||this.shadowDoms.has(t))return;this.shadowDoms.add(t);let[a]=bn({...this.bypassOptions,doc:r,mutationCb:this.mutationCb,mirror:this.mirror,shadowDomManager:this},t);this.restoreHandlers.push(()=>a.disconnect()),this.restoreHandlers.push(vn({...this.bypassOptions,scrollCb:this.scrollCb,doc:t,mirror:this.mirror})),setTimeout(()=>{t.adoptedStyleSheets&&t.adoptedStyleSheets.length>0&&this.bypassOptions.stylesheetManager.adoptStyleSheets(t.adoptedStyleSheets,this.mirror.getId(_.host(t))),this.restoreHandlers.push(Sn({mirror:this.mirror,stylesheetManager:this.bypassOptions.stylesheetManager},t));},0);}observeAttachShadow(t){!t.contentWindow||!t.contentDocument||this.patchAttachShadow(t.contentWindow.Element,t.contentDocument);}patchAttachShadow(t,r){let a=this;this.restoreHandlers.push(Me(t.prototype,"attachShadow",function(s){return function(u){let f=s.call(this,u),m=_.shadowRoot(this);return m&&gn(this)&&a.addShadowRoot(m,r),f}}));}reset(){this.restoreHandlers.forEach(t=>{try{t();}catch(r){}}),this.restoreHandlers=[],this.shadowDoms=new WeakSet;}},Te="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",La=typeof Uint8Array=="undefined"?[]:new Uint8Array(256);for(ke=0;ke<Te.length;ke++)La[Te.charCodeAt(ke)]=ke;var ke,Fa=function(e){var t=new Uint8Array(e),r,a=t.length,s="";for(r=0;r<a;r+=3)s+=Te[t[r]>>2],s+=Te[(t[r]&3)<<4|t[r+1]>>4],s+=Te[(t[r+1]&15)<<2|t[r+2]>>6],s+=Te[t[r+2]&63];return a%3===2?s=s.substring(0,s.length-1)+"=":a%3===1&&(s=s.substring(0,s.length-2)+"=="),s};var Oi=new Map;function Ua(e,t){let r=Oi.get(e);return r||(r=new Map,Oi.set(e,r)),r.has(t)||r.set(t,[]),r.get(t)}var Cn=(e,t,r)=>{if(!e||!(xn(e,t)||typeof e=="object"))return;let a=e.constructor.name,s=Ua(r,a),u=s.indexOf(e);return u===-1&&(u=s.length,s.push(e)),u};function Ke(e,t,r){if(e instanceof Array)return e.map(a=>Ke(a,t,r));if(e===null)return e;if(e instanceof Float32Array||e instanceof Float64Array||e instanceof Int32Array||e instanceof Uint32Array||e instanceof Uint8Array||e instanceof Uint16Array||e instanceof Int16Array||e instanceof Int8Array||e instanceof Uint8ClampedArray)return {rr_type:e.constructor.name,args:[Object.values(e)]};if(e instanceof ArrayBuffer){let a=e.constructor.name,s=Fa(e);return {rr_type:a,base64:s}}else {if(e instanceof DataView)return {rr_type:e.constructor.name,args:[Ke(e.buffer,t,r),e.byteOffset,e.byteLength]};if(e instanceof HTMLImageElement){let a=e.constructor.name,{src:s}=e;return {rr_type:a,src:s}}else if(e instanceof HTMLCanvasElement){let a="HTMLImageElement",s=e.toDataURL();return {rr_type:a,src:s}}else {if(e instanceof ImageData)return {rr_type:e.constructor.name,args:[Ke(e.data,t,r),e.width,e.height]};if(xn(e,t)||typeof e=="object"){let a=e.constructor.name,s=Cn(e,t,r);return {rr_type:a,index:s}}}}return e}var En=(e,t,r)=>e.map(a=>Ke(a,t,r)),xn=(e,t)=>!!["WebGLActiveInfo","WebGLBuffer","WebGLFramebuffer","WebGLProgram","WebGLRenderbuffer","WebGLShader","WebGLShaderPrecisionFormat","WebGLTexture","WebGLUniformLocation","WebGLVertexArrayObject","WebGLVertexArrayObjectOES"].filter(s=>typeof t[s]=="function").find(s=>e instanceof t[s]);function Ba(e,t,r,a){let s=[],u=Object.getOwnPropertyNames(t.CanvasRenderingContext2D.prototype);for(let f of u)try{if(typeof t.CanvasRenderingContext2D.prototype[f]!="function")continue;let m=Me(t.CanvasRenderingContext2D.prototype,f,function(o){return function(...d){return te(this.canvas,r,a,!0)||setTimeout(()=>{let i=En(d,t,this);e(this.canvas,{type:De["2D"],property:f,args:i});},0),o.apply(this,d)}});s.push(m);}catch(m){let o=bt(t.CanvasRenderingContext2D.prototype,f,{set(d){e(this.canvas,{type:De["2D"],property:f,args:[d],setter:true});}});s.push(o);}return ()=>{s.forEach(f=>f());}}function $a(e){return e==="experimental-webgl"?"webgl":e}function Ii(e,t,r,a){let s=[];try{let u=Me(e.HTMLCanvasElement.prototype,"getContext",function(f){return function(m,...o){if(!te(this,t,r,!0)){let d=$a(m);if("__context"in this||(this.__context=d),a&&["webgl","webgl2"].includes(d))if(o[0]&&typeof o[0]=="object"){let i=o[0];i.preserveDrawingBuffer||(i.preserveDrawingBuffer=!0);}else o.splice(0,1,{preserveDrawingBuffer:!0});}return f.apply(this,[m,...o])}});s.push(u);}catch(u){console.error("failed to patch HTMLCanvasElement.prototype.getContext");}return ()=>{s.forEach(u=>u());}}function Ai(e,t,r,a,s,u){let f=[],m=Object.getOwnPropertyNames(e);for(let o of m)if(!["isContextLost","canvas","drawingBufferWidth","drawingBufferHeight"].includes(o))try{if(typeof e[o]!="function")continue;let d=Me(e,o,function(i){return function(...h){let l=i.apply(this,h);if(Cn(l,u,this),"tagName"in this.canvas&&!te(this.canvas,a,s,!0)){let n=En(h,u,this),p={type:t,property:o,args:n};r(this.canvas,p);}return l}});f.push(d);}catch(d){let i=bt(e,o,{set(h){r(this.canvas,{type:t,property:o,args:[h],setter:true});}});f.push(i);}return f}function Wa(e,t,r,a){let s=[];return typeof t.WebGLRenderingContext!="undefined"&&s.push(...Ai(t.WebGLRenderingContext.prototype,De.WebGL,e,r,a,t)),typeof t.WebGL2RenderingContext!="undefined"&&s.push(...Ai(t.WebGL2RenderingContext.prototype,De.WebGL2,e,r,a,t)),()=>{s.forEach(u=>u());}}var Mn=`(function() {
|
|
54
|
+
"use strict";
|
|
55
|
+
var chars = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/";
|
|
56
|
+
var lookup = typeof Uint8Array === "undefined" ? [] : new Uint8Array(256);
|
|
57
|
+
for (var i = 0; i < chars.length; i++) {
|
|
58
|
+
lookup[chars.charCodeAt(i)] = i;
|
|
59
|
+
}
|
|
60
|
+
var encode = function(arraybuffer) {
|
|
61
|
+
var bytes = new Uint8Array(arraybuffer), i2, len = bytes.length, base64 = "";
|
|
62
|
+
for (i2 = 0; i2 < len; i2 += 3) {
|
|
63
|
+
base64 += chars[bytes[i2] >> 2];
|
|
64
|
+
base64 += chars[(bytes[i2] & 3) << 4 | bytes[i2 + 1] >> 4];
|
|
65
|
+
base64 += chars[(bytes[i2 + 1] & 15) << 2 | bytes[i2 + 2] >> 6];
|
|
66
|
+
base64 += chars[bytes[i2 + 2] & 63];
|
|
67
|
+
}
|
|
68
|
+
if (len % 3 === 2) {
|
|
69
|
+
base64 = base64.substring(0, base64.length - 1) + "=";
|
|
70
|
+
} else if (len % 3 === 1) {
|
|
71
|
+
base64 = base64.substring(0, base64.length - 2) + "==";
|
|
72
|
+
}
|
|
73
|
+
return base64;
|
|
74
|
+
};
|
|
75
|
+
const lastBlobMap = /* @__PURE__ */ new Map();
|
|
76
|
+
const transparentBlobMap = /* @__PURE__ */ new Map();
|
|
77
|
+
async function getTransparentBlobFor(width, height, dataURLOptions) {
|
|
78
|
+
const id = \`\${width}-\${height}\`;
|
|
79
|
+
if ("OffscreenCanvas" in globalThis) {
|
|
80
|
+
if (transparentBlobMap.has(id)) return transparentBlobMap.get(id);
|
|
81
|
+
const offscreen = new OffscreenCanvas(width, height);
|
|
82
|
+
offscreen.getContext("2d");
|
|
83
|
+
const blob = await offscreen.convertToBlob(dataURLOptions);
|
|
84
|
+
const arrayBuffer = await blob.arrayBuffer();
|
|
85
|
+
const base64 = encode(arrayBuffer);
|
|
86
|
+
transparentBlobMap.set(id, base64);
|
|
87
|
+
return base64;
|
|
88
|
+
} else {
|
|
89
|
+
return "";
|
|
90
|
+
}
|
|
91
|
+
}
|
|
92
|
+
const worker = self;
|
|
93
|
+
worker.onmessage = async function(e) {
|
|
94
|
+
if ("OffscreenCanvas" in globalThis) {
|
|
95
|
+
const { id, bitmap, width, height, dataURLOptions } = e.data;
|
|
96
|
+
const transparentBase64 = getTransparentBlobFor(
|
|
97
|
+
width,
|
|
98
|
+
height,
|
|
99
|
+
dataURLOptions
|
|
100
|
+
);
|
|
101
|
+
const offscreen = new OffscreenCanvas(width, height);
|
|
102
|
+
const ctx = offscreen.getContext("2d");
|
|
103
|
+
ctx.drawImage(bitmap, 0, 0);
|
|
104
|
+
bitmap.close();
|
|
105
|
+
const blob = await offscreen.convertToBlob(dataURLOptions);
|
|
106
|
+
const type = blob.type;
|
|
107
|
+
const arrayBuffer = await blob.arrayBuffer();
|
|
108
|
+
const base64 = encode(arrayBuffer);
|
|
109
|
+
if (!lastBlobMap.has(id) && await transparentBase64 === base64) {
|
|
110
|
+
lastBlobMap.set(id, base64);
|
|
111
|
+
return worker.postMessage({ id });
|
|
112
|
+
}
|
|
113
|
+
if (lastBlobMap.get(id) === base64) return worker.postMessage({ id });
|
|
114
|
+
worker.postMessage({
|
|
115
|
+
id,
|
|
116
|
+
type,
|
|
117
|
+
base64,
|
|
118
|
+
width,
|
|
119
|
+
height
|
|
120
|
+
});
|
|
121
|
+
lastBlobMap.set(id, base64);
|
|
122
|
+
} else {
|
|
123
|
+
return worker.postMessage({ id: e.data.id });
|
|
124
|
+
}
|
|
125
|
+
};
|
|
126
|
+
})();
|
|
127
|
+
//# sourceMappingURL=image-bitmap-data-url-worker-IJpC7g_b.js.map
|
|
128
|
+
`,Ti=typeof self!="undefined"&&self.Blob&&new Blob([Mn],{type:"text/javascript;charset=utf-8"});function za(e){let t;try{if(t=Ti&&(self.URL||self.webkitURL).createObjectURL(Ti),!t)throw "";let r=new Worker(t,{name:e==null?void 0:e.name});return r.addEventListener("error",()=>{(self.URL||self.webkitURL).revokeObjectURL(t);}),r}catch(r){return new Worker("data:text/javascript;charset=utf-8,"+encodeURIComponent(Mn),{name:e==null?void 0:e.name})}finally{t&&(self.URL||self.webkitURL).revokeObjectURL(t);}}var Ur=class{constructor(t){I(this,"pendingCanvasMutations",new Map),I(this,"rafStamps",{latestId:0,invokeId:null}),I(this,"mirror"),I(this,"mutationCb"),I(this,"resetObservers"),I(this,"frozen",false),I(this,"locked",false),I(this,"processMutation",(o,d)=>{(this.rafStamps.invokeId&&this.rafStamps.latestId!==this.rafStamps.invokeId||!this.rafStamps.invokeId)&&(this.rafStamps.invokeId=this.rafStamps.latestId),this.pendingCanvasMutations.has(o)||this.pendingCanvasMutations.set(o,[]),this.pendingCanvasMutations.get(o).push(d);});let{sampling:r="all",win:a,blockClass:s,blockSelector:u,recordCanvas:f,dataURLOptions:m}=t;this.mutationCb=t.mutationCb,this.mirror=t.mirror,f&&r==="all"&&this.initCanvasMutationObserver(a,s,u),f&&typeof r=="number"&&this.initCanvasFPSObserver(r,a,s,u,{dataURLOptions:m});}reset(){this.pendingCanvasMutations.clear(),this.resetObservers&&this.resetObservers();}freeze(){this.frozen=true;}unfreeze(){this.frozen=false;}lock(){this.locked=true;}unlock(){this.locked=false;}initCanvasFPSObserver(t,r,a,s,u){let f=Ii(r,a,s,true),m=new Map,o=new za;o.onmessage=p=>{let{id:c}=p.data;if(m.set(c,false),!("base64"in p.data))return;let{base64:g,type:S,width:b,height:v}=p.data;this.mutationCb({id:c,type:De["2D"],commands:[{property:"clearRect",args:[0,0,b,v]},{property:"drawImage",args:[{rr_type:"ImageBitmap",args:[{rr_type:"Blob",data:[{rr_type:"ArrayBuffer",base64:g}],type:S}]},0,0]}]});};let d=1e3/t,i=0,h,l=()=>{let p=[];return r.document.querySelectorAll("canvas").forEach(c=>{te(c,a,s,true)||p.push(c);}),p},n=p=>{if(i&&p-i<d){h=requestAnimationFrame(n);return}i=p,l().forEach(async c=>{var g;let S=this.mirror.getId(c);if(m.get(S)||c.width===0||c.height===0)return;if(m.set(S,true),["webgl","webgl2"].includes(c.__context)){let v=c.getContext(c.__context);((g=v==null?void 0:v.getContextAttributes())==null?void 0:g.preserveDrawingBuffer)===false&&v.clear(v.COLOR_BUFFER_BIT);}let b=await createImageBitmap(c);o.postMessage({id:S,bitmap:b,width:c.width,height:c.height,dataURLOptions:u.dataURLOptions},[b]);}),h=requestAnimationFrame(n);};h=requestAnimationFrame(n),this.resetObservers=()=>{f(),cancelAnimationFrame(h);};}initCanvasMutationObserver(t,r,a){this.startRAFTimestamping(),this.startPendingCanvasMutationFlusher();let s=Ii(t,r,a,false),u=Ba(this.processMutation.bind(this),t,r,a),f=Wa(this.processMutation.bind(this),t,r,a);this.resetObservers=()=>{s(),u(),f();};}startPendingCanvasMutationFlusher(){requestAnimationFrame(()=>this.flushPendingCanvasMutations());}startRAFTimestamping(){let t=r=>{this.rafStamps.latestId=r,requestAnimationFrame(t);};requestAnimationFrame(t);}flushPendingCanvasMutations(){this.pendingCanvasMutations.forEach((t,r)=>{let a=this.mirror.getId(r);this.flushPendingCanvasMutationFor(r,a);}),requestAnimationFrame(()=>this.flushPendingCanvasMutations());}flushPendingCanvasMutationFor(t,r){if(this.frozen||this.locked)return;let a=this.pendingCanvasMutations.get(t);if(!a||r===-1)return;let s=a.map(f=>{let{type:m,...o}=f;return o}),{type:u}=a[0];this.mutationCb({id:r,type:u,commands:s}),this.pendingCanvasMutations.delete(t);}},Br=class{constructor(t){I(this,"trackedLinkElements",new WeakSet),I(this,"mutationCb"),I(this,"adoptedStyleSheetCb"),I(this,"styleMirror",new Dr),this.mutationCb=t.mutationCb,this.adoptedStyleSheetCb=t.adoptedStyleSheetCb;}attachLinkElement(t,r){"_cssText"in r.attributes&&this.mutationCb({adds:[],removes:[],texts:[],attributes:[{id:r.id,attributes:r.attributes}]}),this.trackLinkElement(t);}trackLinkElement(t){this.trackedLinkElements.has(t)||(this.trackedLinkElements.add(t),this.trackStylesheetInLinkElement(t));}adoptStyleSheets(t,r){if(t.length===0)return;let a={id:r,styleIds:[]},s=[];for(let u of t){let f;this.styleMirror.has(u)?f=this.styleMirror.getId(u):(f=this.styleMirror.add(u),s.push({styleId:f,rules:Array.from(u.rules||CSSRule,(m,o)=>({rule:Fi(m,u.href),index:o}))})),a.styleIds.push(f);}s.length>0&&(a.styles=s),this.adoptedStyleSheetCb(a);}reset(){this.styleMirror.reset(),this.trackedLinkElements=new WeakSet;}trackStylesheetInLinkElement(t){}},$r=class{constructor(){I(this,"nodeMap",new WeakMap),I(this,"active",false);}inOtherBuffer(t,r){let a=this.nodeMap.get(t);return a&&Array.from(a).some(s=>s!==r)}add(t,r){this.active||(this.active=true,requestAnimationFrame(()=>{this.nodeMap=new WeakMap,this.active=false;})),this.nodeMap.set(t,(this.nodeMap.get(t)||new Set).add(r));}destroy(){}},G,et,Nr,lt=false;try{if(Array.from([1],e=>e*2)[0]!==2){let e=document.createElement("iframe");document.body.appendChild(e),Array.from=((us=e.contentWindow)==null?void 0:us.Array.from)||Array.from,document.body.removeChild(e);}}catch(e){console.debug("Unable to override Array.from",e);}var ue=to();function ge(e={}){let{emit:t,checkoutEveryNms:r,checkoutEveryNth:a,blockClass:s="rr-block",blockSelector:u=null,ignoreClass:f="rr-ignore",ignoreSelector:m=null,maskTextClass:o="rr-mask",maskTextSelector:d=null,inlineStylesheet:i=true,maskAllInputs:h,maskInputOptions:l,slimDOMOptions:n,maskInputFn:p,maskTextFn:c,hooks:g,packFn:S,sampling:b={},dataURLOptions:v={},mousemoveWait:E,recordDOM:w=true,recordCanvas:y=false,recordCrossOriginIframes:C=false,recordAfter:M=e.recordAfter==="DOMContentLoaded"?e.recordAfter:"load",userTriggeredOnInput:O=false,collectFonts:R=false,inlineImages:D=false,plugins:A,keepIframeSrcFn:x=()=>false,ignoreCSSAttributes:ae=new Set([]),errorHandler:se}=e;Sa(se);let U=C?window.parent===window:true,F=false;if(!U)try{window.parent.document&&(F=!1);}catch(T){F=true;}if(U&&!t)throw new Error("emit function is required");if(!U&&!F)return ()=>{};E!==void 0&&b.mousemove===void 0&&(b.mousemove=E),ue.reset();let H=h===true?{color:true,date:true,"datetime-local":true,email:true,month:true,number:true,range:true,search:true,tel:true,text:true,time:true,url:true,week:true,textarea:true,select:true,password:true}:l!==void 0?l:{password:true},Q=qi(n);ga();let Y,B=0,ye=T=>{for(let X of A||[])X.eventProcessor&&(T=X.eventProcessor(T));return S&&!F&&(T=S(T)),T};G=(T,X)=>{var $;let j=T;if(j.timestamp=Be(),($=Se[0])!=null&&$.isFrozen()&&j.type!==L.FullSnapshot&&!(j.type===L.IncrementalSnapshot&&j.data.source===k.Mutation)&&Se.forEach(ie=>ie.unfreeze()),U)t==null||t(ye(j),X);else if(F){let ie={type:"rrweb",event:ye(j),origin:window.location.origin,isCheckout:X};window.parent.postMessage(ie,"*");}if(j.type===L.FullSnapshot)Y=j,B=0;else if(j.type===L.IncrementalSnapshot){if(j.data.source===k.Mutation&&j.data.isAttachIframe)return;B++;let ie=a&&B>=a,W=r&&j.timestamp-Y.timestamp>r;(ie||W)&&et(true);}};let N=T=>{G({type:L.IncrementalSnapshot,data:{source:k.Mutation,...T}});},fe=T=>G({type:L.IncrementalSnapshot,data:{source:k.Scroll,...T}}),ne=T=>G({type:L.IncrementalSnapshot,data:{source:k.CanvasMutation,...T}}),_e=T=>G({type:L.IncrementalSnapshot,data:{source:k.AdoptedStyleSheet,...T}}),K=new Br({mutationCb:N,adoptedStyleSheetCb:_e}),le=new Lr({mirror:ue,mutationCb:N,stylesheetManager:K,recordCrossOriginIframes:C,wrappedEmit:G});for(let T of A||[])T.getMirror&&T.getMirror({nodeMirror:ue,crossOriginIframeMirror:le.crossOriginIframeMirror,crossOriginIframeStyleMirror:le.crossOriginIframeStyleMirror});let ve=new $r;Nr=new Ur({recordCanvas:y,mutationCb:ne,win:window,blockClass:s,blockSelector:u,mirror:ue,sampling:b.canvas,dataURLOptions:v});let we=new Fr({mutationCb:N,scrollCb:fe,bypassOptions:{blockClass:s,blockSelector:u,maskTextClass:o,maskTextSelector:d,inlineStylesheet:i,maskInputOptions:H,dataURLOptions:v,maskTextFn:c,maskInputFn:p,recordCanvas:y,inlineImages:D,sampling:b,slimDOMOptions:Q,iframeManager:le,stylesheetManager:K,canvasManager:Nr,keepIframeSrcFn:x,processedNodeManager:ve},mirror:ue});et=(T=false)=>{if(!w)return;G({type:L.Meta,data:{href:window.location.href,width:cn(),height:un()}},T),K.reset(),we.init(),Se.forEach($=>$.lock());let X=Ro(document,{mirror:ue,blockClass:s,blockSelector:u,maskTextClass:o,maskTextSelector:d,inlineStylesheet:i,maskAllInputs:H,maskTextFn:c,maskInputFn:p,slimDOM:Q,dataURLOptions:v,recordCanvas:y,inlineImages:D,onSerialize:$=>{dn($,ue)&&le.addIframe($),pn($,ue)&&K.trackLinkElement($),Tr($)&&we.addShadowRoot(_.shadowRoot($),document);},onIframeLoad:($,j)=>{le.attachIframe($,j),we.observeAttachShadow($);},onStylesheetLoad:($,j)=>{K.attachLinkElement($,j);},keepIframeSrcFn:x});if(!X)return console.warn("Failed to snapshot the document");G({type:L.FullSnapshot,data:{node:X,initialOffset:ln(window)}},T),Se.forEach($=>$.unlock()),document.adoptedStyleSheets&&document.adoptedStyleSheets.length>0&&K.adoptStyleSheets(document.adoptedStyleSheets,ue.getId(document));};try{let T=[],X=j=>{var ie;return P(Pa)({mutationCb:N,mousemoveCb:(W,St)=>G({type:L.IncrementalSnapshot,data:{source:St,positions:W}}),mouseInteractionCb:W=>G({type:L.IncrementalSnapshot,data:{source:k.MouseInteraction,...W}}),scrollCb:fe,viewportResizeCb:W=>G({type:L.IncrementalSnapshot,data:{source:k.ViewportResize,...W}}),inputCb:W=>G({type:L.IncrementalSnapshot,data:{source:k.Input,...W}}),mediaInteractionCb:W=>G({type:L.IncrementalSnapshot,data:{source:k.MediaInteraction,...W}}),styleSheetRuleCb:W=>G({type:L.IncrementalSnapshot,data:{source:k.StyleSheetRule,...W}}),styleDeclarationCb:W=>G({type:L.IncrementalSnapshot,data:{source:k.StyleDeclaration,...W}}),canvasMutationCb:ne,fontCb:W=>G({type:L.IncrementalSnapshot,data:{source:k.Font,...W}}),selectionCb:W=>{G({type:L.IncrementalSnapshot,data:{source:k.Selection,...W}});},customElementCb:W=>{G({type:L.IncrementalSnapshot,data:{source:k.CustomElement,...W}});},blockClass:s,ignoreClass:f,ignoreSelector:m,maskTextClass:o,maskTextSelector:d,maskInputOptions:H,inlineStylesheet:i,sampling:b,recordDOM:w,recordCanvas:y,inlineImages:D,userTriggeredOnInput:O,collectFonts:R,doc:j,maskInputFn:p,maskTextFn:c,keepIframeSrcFn:x,blockSelector:u,slimDOMOptions:Q,dataURLOptions:v,mirror:ue,iframeManager:le,stylesheetManager:K,shadowDomManager:we,processedNodeManager:ve,canvasManager:Nr,ignoreCSSAttributes:ae,plugins:((ie=A==null?void 0:A.filter(W=>W.observer))==null?void 0:ie.map(W=>({observer:W.observer,options:W.options,callback:St=>G({type:L.Plugin,data:{plugin:W.name,payload:St}})})))||[]},g)};le.addLoadListener(j=>{try{T.push(X(j.contentDocument));}catch(ie){console.warn(ie);}});let $=()=>{et(),T.push(X(document)),lt=!0;};return ["interactive","complete"].includes(document.readyState)?$():(T.push(ee("DOMContentLoaded",()=>{G({type:L.DomContentLoaded,data:{}}),M==="DOMContentLoaded"&&$();})),T.push(ee("load",()=>{G({type:L.Load,data:{}}),M==="load"&&$();},window))),()=>{T.forEach(j=>{try{j();}catch(ie){String(ie).toLowerCase().includes("cross-origin")||console.warn(ie);}}),ve.destroy(),lt=!1,Ca();}}catch(T){console.warn(T);}}ge.addCustomEvent=(e,t)=>{if(!lt)throw new Error("please add custom event after start recording");G({type:L.Custom,data:{tag:e,payload:t}});};ge.freezePage=()=>{Se.forEach(e=>e.freeze());};ge.takeFullSnapshot=e=>{if(!lt)throw new Error("please take full snapshot after start recording");et(e);};ge.mirror=ue;var Di;(function(e){e[e.NotStarted=0]="NotStarted",e[e.Running=1]="Running",e[e.Stopped=2]="Stopped";})(Di||(Di={}));function is(e){return typeof TextEncoder!="undefined"?new TextEncoder().encode(e).length:e.length*2}var os=1e6,as=6e4,ns=false;async function vt(e,t,r,a=false){if(ns)return 401;let s={"Content-Type":"application/json",Authorization:`Bearer ${e.key}`},u=r;if(!a&&r.length>2048&&typeof CompressionStream!="undefined")try{u=await new Response(new Blob([r]).stream().pipeThrough(new CompressionStream("gzip"))).arrayBuffer(),s["Content-Encoding"]="gzip";}catch(f){u=r;}try{let f=await e.fetch.call(globalThis,`${e.url}/v1/${t}`,{method:"POST",headers:s,body:u,keepalive:a,credentials:"omit"});return (f.status===401||f.status===403)&&(ns||(ns=!0,console.warn(`[Zharp] The key was rejected (HTTP ${f.status}); nothing more will be sent from this page. Check Zharp.init({ key }) and the app's allowed origins.`))),f.status}catch(f){return 0}}var Rn=e=>e===0||e===429||e>=500;function Nn(e,t,r){let a=is(JSON.stringify(r([]))),s=[],u=[],f=a;for(let m of e){let o=is(JSON.stringify(m))+1;u.length&&f+o>t&&(s.push({body:JSON.stringify(r(u)),items:u}),u=[],f=a),u.push(m),f+=o;}return u.length&&s.push({body:JSON.stringify(r(u)),items:u}),s}var qa=5e3,Va=500,On=1e4,ja=3e4,Ga=5*6e4,In=30,Ha=3,Ya=200,Xa=4,ls=class{constructor(t,r){this.host=t;this.events=[];this.segments=[[]];this.pending=[];this.traces=new Map;this.hasError=false;this.inFlight=null;var s;let a=t.session();this.sessionId=a.id,this.sequence=(s=a.seq)!=null?s:0,this.mode=r,this.start();}linkTrace(t){this.traces.size<Ya&&this.traces.set(t,Date.now());}onError(){this.hasError=true,this.mode==="buffer"&&(this.events=this.segments.flat(),this.segments=[[]],this.mode="session",this.host.saveMode(this.sessionId,"session"),this.restart(),this.flush());}renew(t){var a;this.mode==="session"&&this.cut(os),this.flush();let r=this.host.session();this.sessionId=r.id,this.sequence=(a=r.seq)!=null?a:0,this.events=[],this.segments=[[]],this.traces.clear(),this.hasError=false,this.mode=t,t==="off"?this.halt():this.restart();}async flush(){for(;this.inFlight;)await this.inFlight;return this.inFlight=this.deliver().finally(()=>this.inFlight=null),this.inFlight}flushOnHide(){if(this.mode!=="session")return;this.cut(as);let t=this.pending;this.pending=[];for(let r of t){let a=r.body.length<=as;vt(this.host.endpoint,"replays",r.body,a).then(s=>{a&&s===0&&vt(this.host.endpoint,"replays",r.body);});}}async stop(){this.halt(),this.mode==="session"&&await this.flush();}start(){var r;let t=this.host.options;this.stopRecording=(r=ge({emit:(a,s)=>this.onEvent(a,!!s),checkoutEveryNms:this.mode==="buffer"?ja:Ga,maskAllInputs:t.maskAllInputs!==false,maskTextSelector:t.maskAllText?"*":t.maskTextSelector,blockSelector:t.blockSelector,inlineStylesheet:true,recordCanvas:false}))!=null?r:void 0,this.timer||(this.timer=setInterval(()=>this.mode==="session"&&this.flush(),qa));}restart(){var t;(t=this.stopRecording)==null||t.call(this),this.start();}halt(){var t;(t=this.stopRecording)==null||t.call(this),this.stopRecording=void 0,this.timer&&clearInterval(this.timer),this.timer=void 0;}onEvent(t,r){var a,s;if(this.mode==="buffer"){if(r&&t.type===Xa&&(this.segments.push([]),this.segments.length>2)){this.segments.shift();let u=(s=(a=this.segments[0][0])==null?void 0:a.timestamp)!=null?s:t.timestamp;for(let[f,m]of this.traces)m<u&&this.traces.delete(f);}this.segments[this.segments.length-1].push(t);return}this.events.push(t),this.events.length>=Va&&this.flush();}cut(t){if(!this.events.length)return;let r=this.events;this.events=[];let a=this.host.options.beforeSend;if(a&&a(r)===false)return;let s=Array.from(this.traces.keys());this.traces.clear();let u={sessionId:this.sessionId,service:this.host.service,url:location.href,userAgent:navigator.userAgent,hasError:this.hasError,traceIds:s};for(;r.length;){let f=r.slice(0,On);r=r.slice(On);for(let{items:m}of Nn(f,t,o=>o)){let o=this.sequence++;this.pending.push({sequence:o,attempts:0,body:JSON.stringify({...u,sequence:o,events:m})});}}this.host.saveSequence(this.sessionId,this.sequence),this.pending.length>In&&this.pending.splice(0,this.pending.length-In);}async deliver(){for(this.cut(os);this.pending.length;){let t=this.pending[0],r=await vt(this.host.endpoint,"replays",t.body);if(this.pending[0]===t){if(Rn(r)&&++t.attempts<Ha)return;this.pending.shift();}}}},An=(e,t)=>new ls(e,t);globalThis.__ZHARP_REPLAY__={createRecorder:An};
|
|
129
|
+
/*! Bundled license information:
|
|
130
|
+
|
|
131
|
+
rrweb/dist/rrweb.js:
|
|
132
|
+
(*! *****************************************************************************
|
|
133
|
+
Copyright (c) Microsoft Corporation.
|
|
134
|
+
|
|
135
|
+
Permission to use, copy, modify, and/or distribute this software for any
|
|
136
|
+
purpose with or without fee is hereby granted.
|
|
137
|
+
|
|
138
|
+
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
|
|
139
|
+
REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
|
|
140
|
+
AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
|
|
141
|
+
INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
|
|
142
|
+
LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
|
|
143
|
+
OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
|
|
144
|
+
PERFORMANCE OF THIS SOFTWARE.
|
|
145
|
+
***************************************************************************** *)
|
|
146
|
+
*/})();//# sourceMappingURL=zharp-replay.min.js.map
|
|
147
|
+
//# sourceMappingURL=zharp-replay.min.js.map
|