@posthog/rrweb-record 0.0.46 → 0.0.48
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/dist/rrweb-record.cjs +56 -8
- package/dist/rrweb-record.cjs.map +1 -1
- package/dist/rrweb-record.js +56 -8
- package/dist/rrweb-record.js.map +1 -1
- package/dist/rrweb-record.umd.cjs +56 -8
- package/dist/rrweb-record.umd.cjs.map +2 -2
- package/dist/rrweb-record.umd.min.cjs +17 -17
- package/dist/rrweb-record.umd.min.cjs.map +3 -3
- package/package.json +4 -4
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
(function (g, f) {if ("object" == typeof exports && "object" == typeof module) {module.exports = f();} else if ("function" == typeof define && define.amd) {define("rrweb", [], f);} else if ("object" == typeof exports) {exports["rrweb"] = f();} else {g["rrweb"] = f();}}(typeof self !== 'undefined' ? self : typeof globalThis !== 'undefined' ? globalThis : this, () => {var exports = {};var module = { exports };
|
|
2
|
-
"use strict";var Dn=Object.defineProperty,Ln=Object.defineProperties;var Tn=Object.getOwnPropertyDescriptors;var Ye=Object.getOwnPropertySymbols;var os=Object.prototype.hasOwnProperty,as=Object.prototype.propertyIsEnumerable;var ns=(e,t,s)=>t in e?Dn(e,t,{enumerable:!0,configurable:!0,writable:!0,value:s}):e[t]=s,T=(e,t)=>{for(var s in t||(t={}))os.call(t,s)&&ns(e,s,t[s]);if(Ye)for(var s of Ye(t))as.call(t,s)&&ns(e,s,t[s]);return e},le=(e,t)=>Ln(e,Tn(t));var Ne=(e,t)=>{var s={};for(var o in e)os.call(e,o)&&t.indexOf(o)<0&&(s[o]=e[o]);if(e!=null&&Ye)for(var o of Ye(e))t.indexOf(o)<0&&as.call(e,o)&&(s[o]=e[o]);return s};Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});var Fn=Object.defineProperty,$n=(e,t,s)=>t in e?Fn(e,t,{enumerable:!0,configurable:!0,writable:!0,value:s}):e[t]=s,A=(e,t,s)=>$n(e,typeof t!="symbol"?t+"":t,s),ls,Bn=Object.defineProperty,Un=(e,t,s)=>t in e?Bn(e,t,{enumerable:!0,configurable:!0,writable:!0,value:s}):e[t]=s,us=(e,t,s)=>Un(e,typeof t!="symbol"?t+"":t,s),Q=(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))(Q||{});const cs={Node:["childNodes","parentNode","parentElement","textContent"],ShadowRoot:["host","styleSheets"],Element:["shadowRoot","querySelector","querySelectorAll"],MutationObserver:[]},hs={Node:["contains","getRootNode"],ShadowRoot:["getSelection"],Element:[],MutationObserver:["constructor"]},Ze={};function Wn(e){var t,s;const o=(s=(t=globalThis==null?void 0:globalThis.Zone)==null?void 0:t.__symbol__)==null?void 0:s.call(t,e);if(o&&globalThis[o])return globalThis[o]}function Fr(e){if(Ze[e])return Ze[e];const t=Wn(e)||globalThis[e],s=t.prototype,o=e in cs?cs[e]:void 0,i=!!(o&&o.every(d=>{var m,h;return!!((h=(m=Object.getOwnPropertyDescriptor(s,d))==null?void 0:m.get)!=null&&h.toString().includes("[native code]"))})),a=e in hs?hs[e]:void 0,c=!!(a&&a.every(d=>{var m;return typeof s[d]=="function"&&((m=s[d])==null?void 0:m.toString().includes("[native code]"))}));if(i&&c)return Ze[e]=t.prototype,t.prototype;try{const d=document.createElement("iframe");document.body.appendChild(d);const m=d.contentWindow;if(!m)return t.prototype;const h=m[e].prototype;return document.body.removeChild(d),h?Ze[e]=h:s}catch(d){return s}}const xt={};function ve(e,t,s){var o;const i=`${e}.${String(s)}`;if(xt[i])return xt[i].call(t);const a=Fr(e),c=(o=Object.getOwnPropertyDescriptor(a,s))==null?void 0:o.get;return c?(xt[i]=c,c.call(t)):t[s]}const Rt={};function Bi(e,t,s){const o=`${e}.${String(s)}`;if(Rt[o])return Rt[o].bind(t);const a=Fr(e)[s];return typeof a!="function"?t[s]:(Rt[o]=a,a.bind(t))}function zn(e){return ve("Node",e,"childNodes")}function qn(e){return ve("Node",e,"parentNode")}function jn(e){return ve("Node",e,"parentElement")}function Hn(e){return ve("Node",e,"textContent")}function Vn(e,t){return Bi("Node",e,"contains")(t)}function Gn(e){return Bi("Node",e,"getRootNode")()}function Jn(e){return!e||!("host"in e)?null:ve("ShadowRoot",e,"host")}function Yn(e){return e.styleSheets}function Zn(e){return!e||!("shadowRoot"in e)?null:ve("Element",e,"shadowRoot")}function Xn(e,t){return ve("Element",e,"querySelector")(t)}function Qn(e,t){return ve("Element",e,"querySelectorAll")(t)}function Kn(){return Fr("MutationObserver").constructor}function eo(e,t,s){try{if(!(t in e))return()=>{};const o=e[t],i=s(o);return typeof i=="function"&&(i.prototype=i.prototype||{},Object.defineProperties(i,{__rrweb_original__:{enumerable:!1,value:o}})),e[t]=i,()=>{e[t]=o}}catch(o){return()=>{}}}const K={childNodes:zn,parentNode:qn,parentElement:jn,textContent:Hn,contains:Vn,getRootNode:Gn,host:Jn,styleSheets:Yn,shadowRoot:Zn,querySelector:Xn,querySelectorAll:Qn,mutationObserver:Kn,patch:eo};function $r(e){return e.nodeType===e.ELEMENT_NODE}function Be(e){const t=e&&"host"in e&&"mode"in e&&K.host(e)||null;return!!(t&&"shadowRoot"in t&&K.shadowRoot(t)===e)}function Ue(e){return Object.prototype.toString.call(e)==="[object ShadowRoot]"}function to(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 ro(e){const{cssText:t}=e;if(t.split('"').length<3)return t;const s=["@import",`url(${JSON.stringify(e.href)})`];return e.layerName===""?s.push("layer"):e.layerName&&s.push(`layer(${e.layerName})`),e.supportsText&&s.push(`supports(${e.supportsText})`),e.media.length&&s.push(e.media.mediaText),s.join(" ")+";"}function at(e){try{const t=e.rules||e.cssRules;if(!t)return null;let s=e.href;!s&&e.ownerNode&&(s=e.ownerNode.baseURI);const o=Array.from(t,i=>Ui(i,s)).join("");return to(o)}catch(t){return null}}function Ui(e,t){var s;if(io(e)){let o;try{o=at(e.styleSheet)||ro(e)}catch(i){o=e.cssText}try{if(o&&((s=e.styleSheet)!=null&&s.href))return lt(o,e.styleSheet.href)}catch(i){}return o}else{let o=e.cssText;return no(e)&&e.selectorText.includes(":")&&(o=so(o)),t?lt(o,t):o}}function so(e){const t=/(\[(?:[\w-]+)[^\\])(:(?:[\w-]+)\])/gm;return e.replace(t,"$1\\$2")}function io(e){return"styleSheet"in e}function no(e){return"selectorText"in e}class Wi{constructor(){us(this,"idNodeMap",new Map),us(this,"nodeMetaMap",new WeakMap)}getId(t){var s;if(!t)return-1;const o=(s=this.getMeta(t))==null?void 0:s.id;return o!=null?o:-1}getNode(t){return this.idNodeMap.get(t)||null}getIds(){return Array.from(this.idNodeMap.keys())}getMeta(t){return this.nodeMetaMap.get(t)||null}removeNodeFromMap(t){const s=this.getId(t);if(this.idNodeMap.delete(s),t.childNodes&&t.childNodes.forEach(o=>this.removeNodeFromMap(o)),$r(t)){const o=K.shadowRoot(t);o&&this.removeNodeFromMap(o),t.nodeName==="IFRAME"&&t.contentDocument&&this.removeNodeFromMap(t.contentDocument)}}has(t){return this.idNodeMap.has(t)}hasNode(t){return this.nodeMetaMap.has(t)}add(t,s){const o=s.id;this.idNodeMap.set(o,t),this.nodeMetaMap.set(t,s)}replace(t,s){const o=this.getNode(t);if(o){const i=this.nodeMetaMap.get(o);i&&this.nodeMetaMap.set(s,i)}this.idNodeMap.set(t,s)}reset(){this.idNodeMap=new Map,this.nodeMetaMap=new WeakMap}}function oo(){return new Wi}function Br({element:e,maskInputOptions:t,tagName:s,type:o,value:i,maskInputFn:a}){let c=i||"";const d=o&&Oe(o);return(t[s.toLowerCase()]||d&&t[d])&&(a?c=a(c,e):c="*".repeat(c.length)),c}function Oe(e){return e.toLowerCase()}const fs="__rrweb_original__";function ao(e){const t=e.getContext("2d");if(!t)return!0;const s=50;for(let o=0;o<e.width;o+=s)for(let i=0;i<e.height;i+=s){const a=t.getImageData,c=fs in a?a[fs]:a;if(new Uint32Array(c.call(t,o,i,Math.min(s,e.width-o),Math.min(s,e.height-i)).data.buffer).some(m=>m!==0))return!1}return!0}function Ur(e){const t=e.type;return e.hasAttribute("data-rr-is-password")?"password":t?Oe(t):null}function zi(e,t){var a;let s;try{s=new URL(e,t!=null?t:window.location.href)}catch(c){return null}const o=/\.([0-9a-z]+)(?:$)/i,i=s.pathname.match(o);return(a=i==null?void 0:i[1])!=null?a:null}function lo(e){let t="";return e.indexOf("//")>-1?t=e.split("/").slice(0,3).join("/"):t=e.split("/")[0],t=t.split("?")[0],t}const uo=/url\((?:(')([^']*)'|(")(.*?)"|([^)]*))\)/gm,co=/^(?:[a-z+]+:)?\/\//i,ho=/^www\..*/i,fo=/^(data:)([^,]*),(.*)/i;function lt(e,t){return(e||"").replace(uo,(s,o,i,a,c,d)=>{const m=i||c||d,h=o||a||"";if(!m)return s;if(co.test(m)||ho.test(m))return`url(${h}${m}${h})`;if(fo.test(m))return`url(${h}${m}${h})`;if(m[0]==="/")return`url(${h}${lo(t)+m}${h})`;const r=t.split("/"),u=m.split("/");r.pop();for(const l of u)l!=="."&&(l===".."?r.pop():r.push(l));return`url(${h}${r.join("/")}${h})`})}const po="data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMTAwJSIgaGVpZ2h0PSIxMDAlIiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciPgogIDxkZWZzPgogICAgPHBhdHRlcm4gaWQ9InN0cmlwZXMiIHBhdHRlcm5Vbml0cz0idXNlclNwYWNlT25Vc2UiIHdpZHRoPSIxNiIgaGVpZ2h0PSIxNiI+CiAgICAgIDxyZWN0IHdpZHRoPSIxNiIgaGVpZ2h0PSIxNiIgZmlsbD0iYmxhY2siLz4KICAgICAgPHBhdGggZD0iTTggMEgxNkwwIDE2VjhMOCAwWiIgZmlsbD0iIzJEMkQyRCIvPgogICAgICA8cGF0aCBkPSJNMTYgOFYxNkg4TDE2IDhaIiBmaWxsPSIjMkQyRDJEIi8+CiAgICA8L3BhdHRlcm4+CiAgPC9kZWZzPgogIDxyZWN0IHdpZHRoPSIxMDAlIiBoZWlnaHQ9IjEwMCUiIGZpbGw9InVybCgjc3RyaXBlcykiLz4KPC9zdmc+Cg==",ps=4096;function mo(e,t,s,o){if(!e.complete||e.naturalWidth===0||e.naturalWidth>ps||e.naturalHeight>ps)return t;try{const i=document.createElement("canvas");i.width=e.naturalWidth,i.height=e.naturalHeight;const a=i.getContext("2d");return a?(a.drawImage(e,0,0),i.toDataURL(s||"image/webp",o!=null?o:.4)):t}catch(i){return t}}function go(e,t){return!t||e.length<=t?e:po}let yo=1;const wo=new RegExp("[^a-z0-9-_:]"),ze=-2;function qi(){return yo++}function bo(e){if(e instanceof HTMLFormElement)return"form";const t=Oe(e.tagName);return wo.test(t)?"div":t}let _e,ds;const So=/^[^ \t\n\r\u000c]+/,vo=/^[, \t\n\r\u000c]+/;function Co(e,t){if(t.trim()==="")return t;let s=0;function o(a){let c;const d=a.exec(t.substring(s));return d?(c=d[0],s+=c.length,c):""}const i=[];for(;o(vo),!(s>=t.length);){let a=o(So);if(a.slice(-1)===",")a=Le(e,a.substring(0,a.length-1)),i.push(a);else{let c="";a=Le(e,a);let d=!1;for(;;){const m=t.charAt(s);if(m===""){i.push((a+c).trim());break}else if(d)m===")"&&(d=!1);else if(m===","){s+=1,i.push((a+c).trim());break}else m==="("&&(d=!0);c+=m,s+=1}}}return i.join(", ")}const ms=new WeakMap;function Le(e,t){return!t||t.trim()===""?t:Wr(e,t)}function xo(e){return!!(e.tagName==="svg"||e.ownerSVGElement)}function Wr(e,t){let s=ms.get(e);if(s||(s=e.createElement("a"),ms.set(e,s)),!t)t="";else if(t.startsWith("blob:")||t.startsWith("data:"))return t;return s.setAttribute("href",t),s.href}function ji(e,t,s,o,i,a){if(!o)return o;if(s==="src"||s==="href"&&!(t==="use"&&o[0]==="#")){const c=Le(e,o);if(t==="img"&&c.startsWith("data:")&&i){const d=i;let m=c;return(a!=null&&a.type||(a==null?void 0:a.quality)!==void 0)&&(m=mo(d,c,a.type,a.quality)),a!=null&&a.maxBase64ImageLength&&(m=go(m,a.maxBase64ImageLength)),m}return c}else{if(s==="xlink:href"&&o[0]!=="#")return Le(e,o);if(s==="background"&&(t==="table"||t==="td"||t==="th"))return Le(e,o);if(s==="srcset")return Co(e,o);if(s==="style")return lt(o,Wr(e));if(t==="object"&&s==="data")return Le(e,o)}return o}function Hi(e,t,s){return(e==="video"||e==="audio")&&t==="autoplay"}function Ro(e,t,s){try{if(typeof t=="string"){if(e.classList.contains(t))return!0}else for(let o=e.classList.length;o--;){const i=e.classList[o];if(t.test(i))return!0}if(s)return e.matches(s)}catch(o){}return!1}function ut(e,t,s){if(!e)return!1;if(e.nodeType!==e.ELEMENT_NODE)return s?ut(K.parentNode(e),t,s):!1;for(let o=e.classList.length;o--;){const i=e.classList[o];if(t.test(i))return!0}return s?ut(K.parentNode(e),t,s):!1}function Vi(e,t,s,o){let i;if($r(e)){if(i=e,!K.childNodes(i).length)return!1}else{if(K.parentElement(e)===null)return!1;i=K.parentElement(e)}try{if(typeof t=="string"){if(o){if(i.closest(`.${t}`))return!0}else if(i.classList.contains(t))return!0}else if(ut(i,t,o))return!0;if(s){if(o){if(i.closest(s))return!0}else if(i.matches(s))return!0}}catch(a){}return!1}function Oo(e,t,s){const o=e.contentWindow;if(!o)return;let i=!1,a;try{a=o.document.readyState}catch(d){return}if(a!=="complete"){const d=setTimeout(()=>{i||(t(),i=!0)},s);e.addEventListener("load",()=>{clearTimeout(d),i=!0,t()});return}const c="about:blank";if(o.location.href!==c||e.src===c||e.src==="")return setTimeout(t,0),e.addEventListener("load",t);e.addEventListener("load",t)}function Mo(e,t,s){let o=!1,i;try{i=e.sheet}catch(c){return}if(i)return;const a=setTimeout(()=>{o||(t(),o=!0)},s);e.addEventListener("load",()=>{clearTimeout(a),o=!0,t()})}function Io(e,t){const{doc:s,mirror:o,blockClass:i,blockSelector:a,needsMask:c,inlineStylesheet:d,maskInputOptions:m={},maskTextFn:h,maskInputFn:r,dataURLOptions:u={},inlineImages:l,recordCanvas:n,keepIframeSrcFn:p,newlyAddedElement:f=!1}=t,g=Eo(s,o);switch(e.nodeType){case e.DOCUMENT_NODE:return e.compatMode!=="CSS1Compat"?{type:Q.Document,childNodes:[],compatMode:e.compatMode}:{type:Q.Document,childNodes:[]};case e.DOCUMENT_TYPE_NODE:return{type:Q.DocumentType,name:e.name,publicId:e.publicId,systemId:e.systemId,rootId:g};case e.ELEMENT_NODE:return No(e,{doc:s,blockClass:i,blockSelector:a,inlineStylesheet:d,maskInputOptions:m,maskInputFn:r,dataURLOptions:u,inlineImages:l,recordCanvas:n,keepIframeSrcFn:p,newlyAddedElement:f,rootId:g});case e.TEXT_NODE:return Ao(e,{doc:s,needsMask:c,maskTextFn:h,rootId:g});case e.CDATA_SECTION_NODE:return{type:Q.CDATA,textContent:"",rootId:g};case e.COMMENT_NODE:return{type:Q.Comment,textContent:K.textContent(e)||"",rootId:g};default:return!1}}function Eo(e,t){if(!t.hasNode(e))return;const s=t.getId(e);return s===1?void 0:s}function Ao(e,t){var s;const{needsMask:o,maskTextFn:i,rootId:a}=t,c=K.parentNode(e),d=c&&c.tagName;let m=K.textContent(e);const h=d==="STYLE"?!0:void 0,r=d==="SCRIPT"?!0:void 0;if(h&&m){try{e.nextSibling||e.previousSibling||(s=c.sheet)!=null&&s.cssRules&&(m=at(c.sheet))}catch(u){console.warn(`Cannot get CSS styles from text's parentNode. Error: ${u}`,e)}m=lt(m,Wr(t.doc))}return r&&(m="SCRIPT_PLACEHOLDER"),!h&&!r&&m&&o&&(m=i?i(m,K.parentElement(e)):m.replace(/[\S]/g,"*")),{type:Q.Text,textContent:m||"",isStyle:h,rootId:a}}function gs(e,t){return Array.from(e.styleSheets).find(s=>s.href===t)}function Po(e){return e.href}function No(e,t){var s,o;const{doc:i,blockClass:a,blockSelector:c,inlineStylesheet:d,maskInputOptions:m={},maskInputFn:h,dataURLOptions:r={},inlineImages:u,recordCanvas:l,keepIframeSrcFn:n,newlyAddedElement:p=!1,rootId:f}=t,g=Ro(e,a,c),S=bo(e);let w={};const v=e.attributes.length;for(let y=0;y<v;y++){const b=e.attributes[y];Hi(S,b.name,b.value)||(w[b.name]=ji(i,S,Oe(b.name),b.value,e,r))}if(S==="link"&&d){const y=Po(e);if(y){let b=gs(i,y);if(!b&&y.includes(".css")){const R=window.location.origin,I=y.replace(window.location.href,""),O=R+"/"+I;b=gs(i,O)}let C=null;b&&(C=at(b)),C&&(delete w.rel,delete w.href,w._cssText=C)}}if(S==="style"&&e.sheet&&!(e.innerText||K.textContent(e)||"").trim().length){const y=at(e.sheet);y&&(w._cssText=y)}if(S==="input"||S==="textarea"||S==="select"){const y=e.value,b=e.checked;w.type!=="radio"&&w.type!=="checkbox"&&w.type!=="submit"&&w.type!=="button"&&y?w.value=Br({element:e,type:Ur(e),tagName:S,value:y,maskInputOptions:m,maskInputFn:h}):b&&(w.checked=b)}if(S==="option"&&(e.selected&&!m.select?w.selected=!0:delete w.selected),S==="dialog"&&e.open)try{w.rr_open_mode=e.matches("dialog:modal")?"modal":"non-modal"}catch(y){w.rr_open_mode="modal",w.ph_rr_could_not_detect_modal=!0}if(S==="canvas"&&l){if(e.__context==="2d")ao(e)||(w.rr_dataURL=e.toDataURL(r.type,r.quality));else if(!("__context"in e)){const y=e.toDataURL(r.type,r.quality),b=i.createElement("canvas");b.width=e.width,b.height=e.height;const C=b.toDataURL(r.type,r.quality);y!==C&&(w.rr_dataURL=y)}}if(S==="img"&&u){_e||(_e=i.createElement("canvas"),ds=_e.getContext("2d"));const y=e,b=y.currentSrc||y.getAttribute("src")||"<unknown-src>",C=y.crossOrigin,R=()=>{y.removeEventListener("load",R);try{_e.width=y.naturalWidth,_e.height=y.naturalHeight,ds.drawImage(y,0,0),w.rr_dataURL=_e.toDataURL(r.type,r.quality)}catch(I){if(y.crossOrigin!=="anonymous"){y.crossOrigin="anonymous",y.complete&&y.naturalWidth!==0?R():y.addEventListener("load",R);return}else console.warn(`Cannot inline img src=${b}! Error: ${I}`)}y.crossOrigin==="anonymous"&&(C?w.crossOrigin=C:y.removeAttribute("crossorigin"))};y.complete&&y.naturalWidth!==0?R():y.addEventListener("load",R)}if(S==="audio"||S==="video"){const y=w;y.rr_mediaState=e.paused?"paused":"played",y.rr_mediaCurrentTime=e.currentTime,y.rr_mediaPlaybackRate=e.playbackRate,y.rr_mediaMuted=e.muted,y.rr_mediaLoop=e.loop,y.rr_mediaVolume=e.volume}if(p||(e.scrollLeft&&(w.rr_scrollLeft=e.scrollLeft),e.scrollTop&&(w.rr_scrollTop=e.scrollTop)),g){const{width:y,height:b,left:C,top:R}=e.getBoundingClientRect();w={class:w.class,rr_width:`${y}px`,rr_height:`${b}px`,rr_left:`${Math.floor(C+(((s=i.defaultView)==null?void 0:s.scrollX)||0))}px`,rr_top:`${Math.floor(R+(((o=i.defaultView)==null?void 0:o.scrollY)||0))}px`}}S==="iframe"&&!n(w.src)&&(e.contentDocument||(w.rr_src=w.src),delete w.src);let x;try{customElements.get(S)&&(x=!0)}catch(y){}return{type:Q.Element,tagName:S,attributes:w,childNodes:[],isSVG:xo(e)||void 0,needBlock:g,rootId:f,isCustom:x}}function z(e){return e==null?"":e.toLowerCase()}function _o(e,t){if(t.comment&&e.type===Q.Comment)return!0;if(e.type===Q.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"&&zi(e.attributes.href)==="js"))return!0;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!0;if(e.tagName==="meta"){if(t.headMetaDescKeywords&&z(e.attributes.name).match(/^description|keywords$/))return!0;if(t.headMetaSocial&&(z(e.attributes.property).match(/^(og|twitter|fb):/)||z(e.attributes.name).match(/^(og|twitter):/)||z(e.attributes.name)==="pinterest"))return!0;if(t.headMetaRobots&&(z(e.attributes.name)==="robots"||z(e.attributes.name)==="googlebot"||z(e.attributes.name)==="bingbot"))return!0;if(t.headMetaHttpEquiv&&e.attributes["http-equiv"]!==void 0)return!0;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!0;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!0}}return!1}const ko=50;let kr=!1,zr=!1;function Do(){return zr}function Lo(){zr=!1,kr=!1}function Te(e,t){const{doc:s,mirror:o,blockClass:i,blockSelector:a,maskTextClass:c,maskTextSelector:d,skipChild:m=!1,inlineStylesheet:h=!0,maskInputOptions:r={},maskTextFn:u,maskInputFn:l,slimDOMOptions:n,dataURLOptions:p={},inlineImages:f=!1,recordCanvas:g=!1,onSerialize:S,onIframeLoad:w,iframeLoadTimeout:v=5e3,onStylesheetLoad:x,stylesheetLoadTimeout:y=5e3,keepIframeSrcFn:b=()=>!1,newlyAddedElement:C=!1,depth:R=0,maxDepth:I=ko}=t;let{needsMask:O}=t,{preserveWhiteSpace:N=!0}=t;if(R>=I)return zr=!0,kr||(kr=!0,console.warn(`[rrweb-snapshot] DOM tree depth exceeded max depth of ${I}. Children beyond this depth will not be recorded. This may indicate deeply nested DOM structures.`)),null;O||(O=Vi(e,c,d,O===void 0));const P=Io(e,{doc:s,mirror:o,blockClass:i,blockSelector:a,needsMask:O,inlineStylesheet:h,maskInputOptions:r,maskTextFn:u,maskInputFn:l,dataURLOptions:p,inlineImages:f,recordCanvas:g,keepIframeSrcFn:b,newlyAddedElement:C});if(!P)return console.warn(e,"not serialized"),null;let ee;o.hasNode(e)?ee=o.getId(e):_o(P,n)||!N&&P.type===Q.Text&&!P.isStyle&&!P.textContent.replace(/^\s+|\s+$/gm,"").length?ee=ze:ee=qi();const D=Object.assign(P,{id:ee});if(o.add(e,D),ee===ze)return null;S&&S(e);let M=!m;if(D.type===Q.Element){M=M&&!D.needBlock,delete D.needBlock;const _=K.shadowRoot(e);_&&Ue(_)&&(D.isShadowHost=!0)}if((D.type===Q.Document||D.type===Q.Element)&&M){n.headWhitespace&&D.type===Q.Element&&D.tagName==="head"&&(N=!1);const _={doc:s,mirror:o,blockClass:i,blockSelector:a,needsMask:O,maskTextClass:c,maskTextSelector:d,skipChild:m,inlineStylesheet:h,maskInputOptions:r,maskTextFn:u,maskInputFn:l,slimDOMOptions:n,dataURLOptions:p,inlineImages:f,recordCanvas:g,preserveWhiteSpace:N,onSerialize:S,onIframeLoad:w,iframeLoadTimeout:v,onStylesheetLoad:x,stylesheetLoadTimeout:y,keepIframeSrcFn:b,depth:R+1,maxDepth:I};if(!(D.type===Q.Element&&D.tagName==="textarea"&&D.attributes.value!==void 0))for(const J of Array.from(K.childNodes(e))){const W=Te(J,_);W&&D.childNodes.push(W)}let U=null;if($r(e)&&(U=K.shadowRoot(e)))for(const J of Array.from(K.childNodes(U))){const W=Te(J,_);W&&(Ue(U)&&(W.isShadow=!0),D.childNodes.push(W))}}const ie=K.parentNode(e);return ie&&Be(ie)&&Ue(ie)&&(D.isShadow=!0),D.type===Q.Element&&D.tagName==="iframe"&&Oo(e,()=>{const _=e.contentDocument;if(_&&w){const U=Te(_,{doc:_,mirror:o,blockClass:i,blockSelector:a,needsMask:O,maskTextClass:c,maskTextSelector:d,skipChild:!1,inlineStylesheet:h,maskInputOptions:r,maskTextFn:u,maskInputFn:l,slimDOMOptions:n,dataURLOptions:p,inlineImages:f,recordCanvas:g,preserveWhiteSpace:N,onSerialize:S,onIframeLoad:w,iframeLoadTimeout:v,onStylesheetLoad:x,stylesheetLoadTimeout:y,keepIframeSrcFn:b,depth:R+1,maxDepth:I});U&&w(e,U)}},v),D.type===Q.Element&&D.tagName==="link"&&typeof D.attributes.rel=="string"&&(D.attributes.rel==="stylesheet"||D.attributes.rel==="preload"&&typeof D.attributes.href=="string"&&zi(D.attributes.href)==="css")&&Mo(e,()=>{if(x){const _=Te(e,{doc:s,mirror:o,blockClass:i,blockSelector:a,needsMask:O,maskTextClass:c,maskTextSelector:d,skipChild:!1,inlineStylesheet:h,maskInputOptions:r,maskTextFn:u,maskInputFn:l,slimDOMOptions:n,dataURLOptions:p,inlineImages:f,recordCanvas:g,preserveWhiteSpace:N,onSerialize:S,onIframeLoad:w,iframeLoadTimeout:v,onStylesheetLoad:x,stylesheetLoadTimeout:y,keepIframeSrcFn:b,depth:R,maxDepth:I});_&&x(e,_)}},y),D}function To(e,t){const{mirror:s=new Wi,blockClass:o="rr-block",blockSelector:i=null,maskTextClass:a="rr-mask",maskTextSelector:c=null,inlineStylesheet:d=!0,inlineImages:m=!1,recordCanvas:h=!1,maskAllInputs:r=!1,maskTextFn:u,maskInputFn:l,slimDOM:n=!1,dataURLOptions:p,preserveWhiteSpace:f,onSerialize:g,onIframeLoad:S,iframeLoadTimeout:w,onStylesheetLoad:v,stylesheetLoadTimeout:x,keepIframeSrcFn:y=()=>!1,maxDepth:b}=t||{};return Te(e,{doc:e,mirror:s,blockClass:o,blockSelector:i,maskTextClass:a,maskTextSelector:c,skipChild:!1,inlineStylesheet:d,maskInputOptions:r===!0?{color:!0,date:!0,"datetime-local":!0,email:!0,month:!0,number:!0,range:!0,search:!0,tel:!0,text:!0,time:!0,url:!0,week:!0,textarea:!0,select:!0,password:!0}:r===!1?{password:!0}:r,maskTextFn:u,maskInputFn:l,slimDOMOptions:n===!0||n==="all"?{script:!0,comment:!0,headFavicon:!0,headWhitespace:!0,headMetaDescKeywords:n==="all",headMetaSocial:!0,headMetaRobots:!0,headMetaHttpEquiv:!0,headMetaAuthorship:!0,headMetaVerification:!0}:n===!1?{}:n,dataURLOptions:p,inlineImages:m,recordCanvas:h,preserveWhiteSpace:f,onSerialize:g,onIframeLoad:S,iframeLoadTimeout:w,onStylesheetLoad:v,stylesheetLoadTimeout:x,keepIframeSrcFn:y,newlyAddedElement:!1,maxDepth:b})}function Fo(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}function $o(e){if(Object.prototype.hasOwnProperty.call(e,"__esModule"))return e;var t=e.default;if(typeof t=="function"){var s=function o(){return this instanceof o?Reflect.construct(t,arguments,this.constructor):t.apply(this,arguments)};s.prototype=t.prototype}else s={};return Object.defineProperty(s,"__esModule",{value:!0}),Object.keys(e).forEach(function(o){var i=Object.getOwnPropertyDescriptor(e,o);Object.defineProperty(s,o,i.get?i:{enumerable:!0,get:function(){return e[o]}})}),s}var Xe={exports:{}},ys;function Bo(){if(ys)return Xe.exports;ys=1;var e=String,t=function(){return{isColorSupported:!1,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,blackBright:e,redBright:e,greenBright:e,yellowBright:e,blueBright:e,magentaBright:e,cyanBright:e,whiteBright:e,bgBlackBright:e,bgRedBright:e,bgGreenBright:e,bgYellowBright:e,bgBlueBright:e,bgMagentaBright:e,bgCyanBright:e,bgWhiteBright:e}};return Xe.exports=t(),Xe.exports.createColors=t,Xe.exports}const Uo={},Wo=Object.freeze(Object.defineProperty({__proto__:null,default:Uo},Symbol.toStringTag,{value:"Module"})),pe=$o(Wo);var Ot,ws;function qr(){if(ws)return Ot;ws=1;let e=Bo(),t=pe;class s extends Error{constructor(i,a,c,d,m,h){super(i),this.name="CssSyntaxError",this.reason=i,m&&(this.file=m),d&&(this.source=d),h&&(this.plugin=h),typeof a!="undefined"&&typeof c!="undefined"&&(typeof a=="number"?(this.line=a,this.column=c):(this.line=a.line,this.column=a.column,this.endLine=c.line,this.endColumn=c.column)),this.setMessage(),Error.captureStackTrace&&Error.captureStackTrace(this,s)}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(i){if(!this.source)return"";let a=this.source;i==null&&(i=e.isColorSupported);let c=n=>n,d=n=>n,m=n=>n;if(i){let{bold:n,gray:p,red:f}=e.createColors(!0);d=g=>n(f(g)),c=g=>p(g),t&&(m=g=>t(g))}let h=a.split(/\r?\n/),r=Math.max(this.line-3,0),u=Math.min(this.line+2,h.length),l=String(u).length;return h.slice(r,u).map((n,p)=>{let f=r+1+p,g=" "+(" "+f).slice(-l)+" | ";if(f===this.line){if(n.length>160){let w=20,v=Math.max(0,this.column-w),x=Math.max(this.column+w,this.endColumn+w),y=n.slice(v,x),b=c(g.replace(/\d/g," "))+n.slice(0,Math.min(this.column-1,w-1)).replace(/[^\t]/g," ");return d(">")+c(g)+m(y)+`
|
|
2
|
+
"use strict";var Tn=Object.defineProperty,Fn=Object.defineProperties;var $n=Object.getOwnPropertyDescriptors;var Xe=Object.getOwnPropertySymbols;var ls=Object.prototype.hasOwnProperty,us=Object.prototype.propertyIsEnumerable;var as=(e,t,s)=>t in e?Tn(e,t,{enumerable:!0,configurable:!0,writable:!0,value:s}):e[t]=s,T=(e,t)=>{for(var s in t||(t={}))ls.call(t,s)&&as(e,s,t[s]);if(Xe)for(var s of Xe(t))us.call(t,s)&&as(e,s,t[s]);return e},le=(e,t)=>Fn(e,$n(t));var _e=(e,t)=>{var s={};for(var o in e)ls.call(e,o)&&t.indexOf(o)<0&&(s[o]=e[o]);if(e!=null&&Xe)for(var o of Xe(e))t.indexOf(o)<0&&us.call(e,o)&&(s[o]=e[o]);return s};Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});var Bn=Object.defineProperty,Un=(e,t,s)=>t in e?Bn(e,t,{enumerable:!0,configurable:!0,writable:!0,value:s}):e[t]=s,A=(e,t,s)=>Un(e,typeof t!="symbol"?t+"":t,s),cs,Wn=Object.defineProperty,zn=(e,t,s)=>t in e?Wn(e,t,{enumerable:!0,configurable:!0,writable:!0,value:s}):e[t]=s,hs=(e,t,s)=>zn(e,typeof t!="symbol"?t+"":t,s),Q=(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))(Q||{});const fs={Node:["childNodes","parentNode","parentElement","textContent"],ShadowRoot:["host","styleSheets"],Element:["shadowRoot","querySelector","querySelectorAll"],MutationObserver:[]},ps={Node:["contains","getRootNode"],ShadowRoot:["getSelection"],Element:[],MutationObserver:["constructor"]},Qe={};function qn(e){var t,s;const o=(s=(t=globalThis==null?void 0:globalThis.Zone)==null?void 0:t.__symbol__)==null?void 0:s.call(t,e);if(o&&globalThis[o])return globalThis[o]}function Br(e){if(Qe[e])return Qe[e];const t=qn(e)||globalThis[e],s=t.prototype,o=e in fs?fs[e]:void 0,i=!!(o&&o.every(d=>{var m,h;return!!((h=(m=Object.getOwnPropertyDescriptor(s,d))==null?void 0:m.get)!=null&&h.toString().includes("[native code]"))})),a=e in ps?ps[e]:void 0,c=!!(a&&a.every(d=>{var m;return typeof s[d]=="function"&&((m=s[d])==null?void 0:m.toString().includes("[native code]"))}));if(i&&c)return Qe[e]=t.prototype,t.prototype;try{const d=document.createElement("iframe");document.body.appendChild(d);const m=d.contentWindow;if(!m)return t.prototype;const h=m[e].prototype;return document.body.removeChild(d),h?Qe[e]=h:s}catch(d){return s}}const Ot={};function Re(e,t,s){var o;const i=`${e}.${String(s)}`;if(Ot[i])return Ot[i].call(t);const a=Br(e),c=(o=Object.getOwnPropertyDescriptor(a,s))==null?void 0:o.get;return c?(Ot[i]=c,c.call(t)):t[s]}const Mt={};function Wi(e,t,s){const o=`${e}.${String(s)}`;if(Mt[o])return Mt[o].bind(t);const a=Br(e)[s];return typeof a!="function"?t[s]:(Mt[o]=a,a.bind(t))}function jn(e){return Re("Node",e,"childNodes")}function Hn(e){return Re("Node",e,"parentNode")}function Vn(e){return Re("Node",e,"parentElement")}function Gn(e){return Re("Node",e,"textContent")}function Jn(e,t){return Wi("Node",e,"contains")(t)}function Yn(e){return Wi("Node",e,"getRootNode")()}function Zn(e){return!e||!("host"in e)?null:Re("ShadowRoot",e,"host")}function Xn(e){return e.styleSheets}function Qn(e){return!e||!("shadowRoot"in e)?null:Re("Element",e,"shadowRoot")}function Kn(e,t){return Re("Element",e,"querySelector")(t)}function eo(e,t){return Re("Element",e,"querySelectorAll")(t)}function to(){return Br("MutationObserver").constructor}function ro(e,t,s){try{if(!(t in e))return()=>{};const o=e[t],i=s(o);return typeof i=="function"&&(i.prototype=i.prototype||{},Object.defineProperties(i,{__rrweb_original__:{enumerable:!1,value:o}})),e[t]=i,()=>{e[t]=o}}catch(o){return()=>{}}}const K={childNodes:jn,parentNode:Hn,parentElement:Vn,textContent:Gn,contains:Jn,getRootNode:Yn,host:Zn,styleSheets:Xn,shadowRoot:Qn,querySelector:Kn,querySelectorAll:eo,mutationObserver:to,patch:ro};function Ur(e){return e.nodeType===e.ELEMENT_NODE}function We(e){const t=e&&"host"in e&&"mode"in e&&K.host(e)||null;return!!(t&&"shadowRoot"in t&&K.shadowRoot(t)===e)}function ze(e){return Object.prototype.toString.call(e)==="[object ShadowRoot]"}function so(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 io(e){const{cssText:t}=e;if(t.split('"').length<3)return t;const s=["@import",`url(${JSON.stringify(e.href)})`];return e.layerName===""?s.push("layer"):e.layerName&&s.push(`layer(${e.layerName})`),e.supportsText&&s.push(`supports(${e.supportsText})`),e.media.length&&s.push(e.media.mediaText),s.join(" ")+";"}function ut(e){try{const t=e.rules||e.cssRules;if(!t)return null;let s=e.href;!s&&e.ownerNode&&(s=e.ownerNode.baseURI);const o=Array.from(t,i=>zi(i,s)).join("");return so(o)}catch(t){return null}}function zi(e,t){var s;if(oo(e)){let o;try{o=ut(e.styleSheet)||io(e)}catch(i){o=e.cssText}try{if(o&&((s=e.styleSheet)!=null&&s.href))return ct(o,e.styleSheet.href)}catch(i){}return o}else{let o=e.cssText;return ao(e)&&e.selectorText.includes(":")&&(o=no(o)),t?ct(o,t):o}}function no(e){const t=/(\[(?:[\w-]+)[^\\])(:(?:[\w-]+)\])/gm;return e.replace(t,"$1\\$2")}function oo(e){return"styleSheet"in e}function ao(e){return"selectorText"in e}class qi{constructor(){hs(this,"idNodeMap",new Map),hs(this,"nodeMetaMap",new WeakMap)}getId(t){var s;if(!t)return-1;const o=(s=this.getMeta(t))==null?void 0:s.id;return o!=null?o:-1}getNode(t){return this.idNodeMap.get(t)||null}getIds(){return Array.from(this.idNodeMap.keys())}getMeta(t){return this.nodeMetaMap.get(t)||null}removeNodeFromMap(t){const s=this.getId(t);if(this.idNodeMap.delete(s),t.childNodes&&t.childNodes.forEach(o=>this.removeNodeFromMap(o)),Ur(t)){const o=K.shadowRoot(t);o&&this.removeNodeFromMap(o),t.nodeName==="IFRAME"&&t.contentDocument&&this.removeNodeFromMap(t.contentDocument)}}has(t){return this.idNodeMap.has(t)}hasNode(t){return this.nodeMetaMap.has(t)}add(t,s){const o=s.id;this.idNodeMap.set(o,t),this.nodeMetaMap.set(t,s)}replace(t,s){const o=this.getNode(t);if(o){const i=this.nodeMetaMap.get(o);i&&this.nodeMetaMap.set(s,i)}this.idNodeMap.set(t,s)}reset(){this.idNodeMap=new Map,this.nodeMetaMap=new WeakMap}}function lo(){return new qi}function Wr({element:e,maskInputOptions:t,tagName:s,type:o,value:i,maskInputFn:a}){let c=i||"";const d=o&&Ie(o);return(t[s.toLowerCase()]||d&&t[d])&&(a?c=a(c,e):c="*".repeat(c.length)),c}function Ie(e){return e.toLowerCase()}const ds="__rrweb_original__";function uo(e){const t=e.getContext("2d");if(!t)return!0;const s=50;for(let o=0;o<e.width;o+=s)for(let i=0;i<e.height;i+=s){const a=t.getImageData,c=ds in a?a[ds]:a;if(new Uint32Array(c.call(t,o,i,Math.min(s,e.width-o),Math.min(s,e.height-i)).data.buffer).some(m=>m!==0))return!1}return!0}function zr(e){const t=e.type;return e.hasAttribute("data-rr-is-password")?"password":t?Ie(t):null}function ji(e,t){var a;let s;try{s=new URL(e,t!=null?t:window.location.href)}catch(c){return null}const o=/\.([0-9a-z]+)(?:$)/i,i=s.pathname.match(o);return(a=i==null?void 0:i[1])!=null?a:null}function co(e){let t="";return e.indexOf("//")>-1?t=e.split("/").slice(0,3).join("/"):t=e.split("/")[0],t=t.split("?")[0],t}const ho=/url\((?:(')([^']*)'|(")(.*?)"|([^)]*))\)/gm,fo=/^(?:[a-z+]+:)?\/\//i,po=/^www\..*/i,mo=/^(data:)([^,]*),(.*)/i;function ct(e,t){return(e||"").replace(ho,(s,o,i,a,c,d)=>{const m=i||c||d,h=o||a||"";if(!m)return s;if(fo.test(m)||po.test(m))return`url(${h}${m}${h})`;if(mo.test(m))return`url(${h}${m}${h})`;if(m[0]==="/")return`url(${h}${co(t)+m}${h})`;const r=t.split("/"),u=m.split("/");r.pop();for(const l of u)l!=="."&&(l===".."?r.pop():r.push(l));return`url(${h}${r.join("/")}${h})`})}const go="data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMTAwJSIgaGVpZ2h0PSIxMDAlIiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciPgogIDxkZWZzPgogICAgPHBhdHRlcm4gaWQ9InN0cmlwZXMiIHBhdHRlcm5Vbml0cz0idXNlclNwYWNlT25Vc2UiIHdpZHRoPSIxNiIgaGVpZ2h0PSIxNiI+CiAgICAgIDxyZWN0IHdpZHRoPSIxNiIgaGVpZ2h0PSIxNiIgZmlsbD0iYmxhY2siLz4KICAgICAgPHBhdGggZD0iTTggMEgxNkwwIDE2VjhMOCAwWiIgZmlsbD0iIzJEMkQyRCIvPgogICAgICA8cGF0aCBkPSJNMTYgOFYxNkg4TDE2IDhaIiBmaWxsPSIjMkQyRDJEIi8+CiAgICA8L3BhdHRlcm4+CiAgPC9kZWZzPgogIDxyZWN0IHdpZHRoPSIxMDAlIiBoZWlnaHQ9IjEwMCUiIGZpbGw9InVybCgjc3RyaXBlcykiLz4KPC9zdmc+Cg==",ms=4096;function yo(e,t,s,o){if(!e.complete||e.naturalWidth===0||e.naturalWidth>ms||e.naturalHeight>ms)return t;try{const i=document.createElement("canvas");i.width=e.naturalWidth,i.height=e.naturalHeight;const a=i.getContext("2d");return a?(a.drawImage(e,0,0),i.toDataURL(s||"image/webp",o!=null?o:.4)):t}catch(i){return t}}function wo(e,t){return!t||e.length<=t?e:go}let bo=1;const So=new RegExp("[^a-z0-9-_:]"),je=-2;function Hi(){return bo++}function vo(e){if(e instanceof HTMLFormElement)return"form";const t=Ie(e.tagName);return So.test(t)?"div":t}let ke,gs;const Co=/^[^ \t\n\r\u000c]+/,xo=/^[, \t\n\r\u000c]+/;function Ro(e,t){if(t.trim()==="")return t;let s=0;function o(a){let c;const d=a.exec(t.substring(s));return d?(c=d[0],s+=c.length,c):""}const i=[];for(;o(xo),!(s>=t.length);){let a=o(Co);if(a.slice(-1)===",")a=Te(e,a.substring(0,a.length-1)),i.push(a);else{let c="";a=Te(e,a);let d=!1;for(;;){const m=t.charAt(s);if(m===""){i.push((a+c).trim());break}else if(d)m===")"&&(d=!1);else if(m===","){s+=1,i.push((a+c).trim());break}else m==="("&&(d=!0);c+=m,s+=1}}}return i.join(", ")}const ys=new WeakMap;function Te(e,t){return!t||t.trim()===""?t:qr(e,t)}function Oo(e){return!!(e.tagName==="svg"||e.ownerSVGElement)}function qr(e,t){let s=ys.get(e);if(s||(s=e.createElement("a"),ys.set(e,s)),!t)t="";else if(t.startsWith("blob:")||t.startsWith("data:"))return t;return s.setAttribute("href",t),s.href}function Vi(e,t,s,o,i,a){if(!o)return o;if(s==="src"||s==="href"&&!(t==="use"&&o[0]==="#")){const c=Te(e,o);if(t==="img"&&c.startsWith("data:")&&i){const d=i;let m=c;return(a!=null&&a.type||(a==null?void 0:a.quality)!==void 0)&&(m=yo(d,c,a.type,a.quality)),a!=null&&a.maxBase64ImageLength&&(m=wo(m,a.maxBase64ImageLength)),m}return c}else{if(s==="xlink:href"&&o[0]!=="#")return Te(e,o);if(s==="background"&&(t==="table"||t==="td"||t==="th"))return Te(e,o);if(s==="srcset")return Ro(e,o);if(s==="style")return ct(o,qr(e));if(t==="object"&&s==="data")return Te(e,o)}return o}function Gi(e,t,s){return(e==="video"||e==="audio")&&t==="autoplay"}function Mo(e,t,s){try{if(typeof t=="string"){if(e.classList.contains(t))return!0}else for(let o=e.classList.length;o--;){const i=e.classList[o];if(t.test(i))return!0}if(s)return e.matches(s)}catch(o){}return!1}function ht(e,t,s){if(!e)return!1;if(e.nodeType!==e.ELEMENT_NODE)return s?ht(K.parentNode(e),t,s):!1;for(let o=e.classList.length;o--;){const i=e.classList[o];if(t.test(i))return!0}return s?ht(K.parentNode(e),t,s):!1}function Ji(e,t,s,o){let i;if(Ur(e)){if(i=e,!K.childNodes(i).length)return!1}else{if(K.parentElement(e)===null)return!1;i=K.parentElement(e)}try{if(typeof t=="string"){if(o){if(i.closest(`.${t}`))return!0}else if(i.classList.contains(t))return!0}else if(ht(i,t,o))return!0;if(s){if(o){if(i.closest(s))return!0}else if(i.matches(s))return!0}}catch(a){}return!1}function Io(e,t,s){const o=e.contentWindow;if(!o)return;let i=!1,a;try{a=o.document.readyState}catch(d){return}if(a!=="complete"){const d=setTimeout(()=>{i||(t(),i=!0)},s);e.addEventListener("load",()=>{clearTimeout(d),i=!0,t()});return}const c="about:blank";if(o.location.href!==c||e.src===c||e.src==="")return setTimeout(t,0),e.addEventListener("load",t);e.addEventListener("load",t)}function Eo(e,t,s){let o=!1,i;try{i=e.sheet}catch(c){return}if(i)return;const a=setTimeout(()=>{o||(t(),o=!0)},s);e.addEventListener("load",()=>{clearTimeout(a),o=!0,t()})}function Ao(e,t){const{doc:s,mirror:o,blockClass:i,blockSelector:a,needsMask:c,inlineStylesheet:d,maskInputOptions:m={},maskTextFn:h,maskInputFn:r,dataURLOptions:u={},inlineImages:l,recordCanvas:n,keepIframeSrcFn:p,newlyAddedElement:f=!1}=t,g=Po(s,o);switch(e.nodeType){case e.DOCUMENT_NODE:return e.compatMode!=="CSS1Compat"?{type:Q.Document,childNodes:[],compatMode:e.compatMode}:{type:Q.Document,childNodes:[]};case e.DOCUMENT_TYPE_NODE:return{type:Q.DocumentType,name:e.name,publicId:e.publicId,systemId:e.systemId,rootId:g};case e.ELEMENT_NODE:return ko(e,{doc:s,blockClass:i,blockSelector:a,inlineStylesheet:d,maskInputOptions:m,maskInputFn:r,dataURLOptions:u,inlineImages:l,recordCanvas:n,keepIframeSrcFn:p,newlyAddedElement:f,rootId:g});case e.TEXT_NODE:return No(e,{doc:s,needsMask:c,maskTextFn:h,rootId:g});case e.CDATA_SECTION_NODE:return{type:Q.CDATA,textContent:"",rootId:g};case e.COMMENT_NODE:return{type:Q.Comment,textContent:K.textContent(e)||"",rootId:g};default:return!1}}function Po(e,t){if(!t.hasNode(e))return;const s=t.getId(e);return s===1?void 0:s}function No(e,t){var s;const{needsMask:o,maskTextFn:i,rootId:a}=t,c=K.parentNode(e),d=c&&c.tagName;let m=K.textContent(e);const h=d==="STYLE"?!0:void 0,r=d==="SCRIPT"?!0:void 0;if(h&&m){try{e.nextSibling||e.previousSibling||(s=c.sheet)!=null&&s.cssRules&&(m=ut(c.sheet))}catch(u){console.warn(`Cannot get CSS styles from text's parentNode. Error: ${u}`,e)}m=ct(m,qr(t.doc))}return r&&(m="SCRIPT_PLACEHOLDER"),!h&&!r&&m&&o&&(m=i?i(m,K.parentElement(e)):m.replace(/[\S]/g,"*")),{type:Q.Text,textContent:m||"",isStyle:h,rootId:a}}function ws(e,t){return Array.from(e.styleSheets).find(s=>s.href===t)}function _o(e){return e.href}function ko(e,t){var s,o;const{doc:i,blockClass:a,blockSelector:c,inlineStylesheet:d,maskInputOptions:m={},maskInputFn:h,dataURLOptions:r={},inlineImages:u,recordCanvas:l,keepIframeSrcFn:n,newlyAddedElement:p=!1,rootId:f}=t,g=Mo(e,a,c),S=vo(e);let w={};const v=e.attributes.length;for(let y=0;y<v;y++){const b=e.attributes[y];Gi(S,b.name,b.value)||(w[b.name]=Vi(i,S,Ie(b.name),b.value,e,r))}if(S==="link"&&d){const y=_o(e);if(y){let b=ws(i,y);if(!b&&y.includes(".css")){const R=window.location.origin,I=y.replace(window.location.href,""),O=R+"/"+I;b=ws(i,O)}let C=null;b&&(C=ut(b)),C&&(delete w.rel,delete w.href,w._cssText=C)}}if(S==="style"&&e.sheet&&!(e.innerText||K.textContent(e)||"").trim().length){const y=ut(e.sheet);y&&(w._cssText=y)}if(S==="input"||S==="textarea"||S==="select"){const y=e.value,b=e.checked;w.type!=="radio"&&w.type!=="checkbox"&&w.type!=="submit"&&w.type!=="button"&&y?w.value=Wr({element:e,type:zr(e),tagName:S,value:y,maskInputOptions:m,maskInputFn:h}):b&&(w.checked=b)}if(S==="option"&&(e.selected&&!m.select?w.selected=!0:delete w.selected),S==="dialog"&&e.open)try{w.rr_open_mode=e.matches("dialog:modal")?"modal":"non-modal"}catch(y){w.rr_open_mode="modal",w.ph_rr_could_not_detect_modal=!0}if(S==="canvas"&&l){if(e.__context==="2d")uo(e)||(w.rr_dataURL=e.toDataURL(r.type,r.quality));else if(!("__context"in e)){const y=e.toDataURL(r.type,r.quality),b=i.createElement("canvas");b.width=e.width,b.height=e.height;const C=b.toDataURL(r.type,r.quality);y!==C&&(w.rr_dataURL=y)}}if(S==="img"&&u){ke||(ke=i.createElement("canvas"),gs=ke.getContext("2d"));const y=e,b=y.currentSrc||y.getAttribute("src")||"<unknown-src>",C=y.crossOrigin,R=()=>{y.removeEventListener("load",R);try{ke.width=y.naturalWidth,ke.height=y.naturalHeight,gs.drawImage(y,0,0),w.rr_dataURL=ke.toDataURL(r.type,r.quality)}catch(I){if(y.crossOrigin!=="anonymous"){y.crossOrigin="anonymous",y.complete&&y.naturalWidth!==0?R():y.addEventListener("load",R);return}else console.warn(`Cannot inline img src=${b}! Error: ${I}`)}y.crossOrigin==="anonymous"&&(C?w.crossOrigin=C:y.removeAttribute("crossorigin"))};y.complete&&y.naturalWidth!==0?R():y.addEventListener("load",R)}if(S==="audio"||S==="video"){const y=w;y.rr_mediaState=e.paused?"paused":"played",y.rr_mediaCurrentTime=e.currentTime,y.rr_mediaPlaybackRate=e.playbackRate,y.rr_mediaMuted=e.muted,y.rr_mediaLoop=e.loop,y.rr_mediaVolume=e.volume}if(p||(e.scrollLeft&&(w.rr_scrollLeft=e.scrollLeft),e.scrollTop&&(w.rr_scrollTop=e.scrollTop)),g){const{width:y,height:b,left:C,top:R}=e.getBoundingClientRect();w={class:w.class,rr_width:`${y}px`,rr_height:`${b}px`,rr_left:`${Math.floor(C+(((s=i.defaultView)==null?void 0:s.scrollX)||0))}px`,rr_top:`${Math.floor(R+(((o=i.defaultView)==null?void 0:o.scrollY)||0))}px`}}S==="iframe"&&!n(w.src)&&(e.contentDocument||(w.rr_src=w.src),delete w.src);let x;try{customElements.get(S)&&(x=!0)}catch(y){}return{type:Q.Element,tagName:S,attributes:w,childNodes:[],isSVG:Oo(e)||void 0,needBlock:g,rootId:f,isCustom:x}}function j(e){return e==null?"":e.toLowerCase()}function Do(e,t){if(t.comment&&e.type===Q.Comment)return!0;if(e.type===Q.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"&&ji(e.attributes.href)==="js"))return!0;if(t.headFavicon&&(e.tagName==="link"&&e.attributes.rel==="shortcut icon"||e.tagName==="meta"&&(j(e.attributes.name).match(/^msapplication-tile(image|color)$/)||j(e.attributes.name)==="application-name"||j(e.attributes.rel)==="icon"||j(e.attributes.rel)==="apple-touch-icon"||j(e.attributes.rel)==="shortcut icon")))return!0;if(e.tagName==="meta"){if(t.headMetaDescKeywords&&j(e.attributes.name).match(/^description|keywords$/))return!0;if(t.headMetaSocial&&(j(e.attributes.property).match(/^(og|twitter|fb):/)||j(e.attributes.name).match(/^(og|twitter):/)||j(e.attributes.name)==="pinterest"))return!0;if(t.headMetaRobots&&(j(e.attributes.name)==="robots"||j(e.attributes.name)==="googlebot"||j(e.attributes.name)==="bingbot"))return!0;if(t.headMetaHttpEquiv&&e.attributes["http-equiv"]!==void 0)return!0;if(t.headMetaAuthorship&&(j(e.attributes.name)==="author"||j(e.attributes.name)==="generator"||j(e.attributes.name)==="framework"||j(e.attributes.name)==="publisher"||j(e.attributes.name)==="progid"||j(e.attributes.property).match(/^article:/)||j(e.attributes.property).match(/^product:/)))return!0;if(t.headMetaVerification&&(j(e.attributes.name)==="google-site-verification"||j(e.attributes.name)==="yandex-verification"||j(e.attributes.name)==="csrf-token"||j(e.attributes.name)==="p:domain_verify"||j(e.attributes.name)==="verify-v1"||j(e.attributes.name)==="verification"||j(e.attributes.name)==="shopify-checkout-api-token"))return!0}}return!1}const Lo=50;let Lr=!1,jr=!1;function To(){return jr}function Fo(){jr=!1,Lr=!1}function Fe(e,t){const{doc:s,mirror:o,blockClass:i,blockSelector:a,maskTextClass:c,maskTextSelector:d,skipChild:m=!1,inlineStylesheet:h=!0,maskInputOptions:r={},maskTextFn:u,maskInputFn:l,slimDOMOptions:n,dataURLOptions:p={},inlineImages:f=!1,recordCanvas:g=!1,onSerialize:S,onIframeLoad:w,iframeLoadTimeout:v=5e3,onStylesheetLoad:x,stylesheetLoadTimeout:y=5e3,keepIframeSrcFn:b=()=>!1,newlyAddedElement:C=!1,depth:R=0,maxDepth:I=Lo}=t;let{needsMask:O}=t,{preserveWhiteSpace:N=!0}=t;if(R>=I)return jr=!0,Lr||(Lr=!0,console.warn(`[rrweb-snapshot] DOM tree depth exceeded max depth of ${I}. Children beyond this depth will not be recorded. This may indicate deeply nested DOM structures.`)),null;O||(O=Ji(e,c,d,O===void 0));const P=Ao(e,{doc:s,mirror:o,blockClass:i,blockSelector:a,needsMask:O,inlineStylesheet:h,maskInputOptions:r,maskTextFn:u,maskInputFn:l,dataURLOptions:p,inlineImages:f,recordCanvas:g,keepIframeSrcFn:b,newlyAddedElement:C});if(!P)return console.warn(e,"not serialized"),null;let ee;o.hasNode(e)?ee=o.getId(e):Do(P,n)||!N&&P.type===Q.Text&&!P.isStyle&&!P.textContent.replace(/^\s+|\s+$/gm,"").length?ee=je:ee=Hi();const D=Object.assign(P,{id:ee});if(o.add(e,D),ee===je)return null;S&&S(e);let M=!m;if(D.type===Q.Element){M=M&&!D.needBlock,delete D.needBlock;const _=K.shadowRoot(e);_&&ze(_)&&(D.isShadowHost=!0)}if((D.type===Q.Document||D.type===Q.Element)&&M){n.headWhitespace&&D.type===Q.Element&&D.tagName==="head"&&(N=!1);const _={doc:s,mirror:o,blockClass:i,blockSelector:a,needsMask:O,maskTextClass:c,maskTextSelector:d,skipChild:m,inlineStylesheet:h,maskInputOptions:r,maskTextFn:u,maskInputFn:l,slimDOMOptions:n,dataURLOptions:p,inlineImages:f,recordCanvas:g,preserveWhiteSpace:N,onSerialize:S,onIframeLoad:w,iframeLoadTimeout:v,onStylesheetLoad:x,stylesheetLoadTimeout:y,keepIframeSrcFn:b,depth:R+1,maxDepth:I};if(!(D.type===Q.Element&&D.tagName==="textarea"&&D.attributes.value!==void 0))for(const Z of Array.from(K.childNodes(e))){const z=Fe(Z,_);z&&D.childNodes.push(z)}let W=null;if(Ur(e)&&(W=K.shadowRoot(e)))for(const Z of Array.from(K.childNodes(W))){const z=Fe(Z,_);z&&(ze(W)&&(z.isShadow=!0),D.childNodes.push(z))}}const se=K.parentNode(e);return se&&We(se)&&ze(se)&&(D.isShadow=!0),D.type===Q.Element&&D.tagName==="iframe"&&Io(e,()=>{const _=e.contentDocument;if(_&&w){const W=Fe(_,{doc:_,mirror:o,blockClass:i,blockSelector:a,needsMask:O,maskTextClass:c,maskTextSelector:d,skipChild:!1,inlineStylesheet:h,maskInputOptions:r,maskTextFn:u,maskInputFn:l,slimDOMOptions:n,dataURLOptions:p,inlineImages:f,recordCanvas:g,preserveWhiteSpace:N,onSerialize:S,onIframeLoad:w,iframeLoadTimeout:v,onStylesheetLoad:x,stylesheetLoadTimeout:y,keepIframeSrcFn:b,depth:R+1,maxDepth:I});W&&w(e,W)}},v),D.type===Q.Element&&D.tagName==="link"&&typeof D.attributes.rel=="string"&&(D.attributes.rel==="stylesheet"||D.attributes.rel==="preload"&&typeof D.attributes.href=="string"&&ji(D.attributes.href)==="css")&&Eo(e,()=>{if(x){const _=Fe(e,{doc:s,mirror:o,blockClass:i,blockSelector:a,needsMask:O,maskTextClass:c,maskTextSelector:d,skipChild:!1,inlineStylesheet:h,maskInputOptions:r,maskTextFn:u,maskInputFn:l,slimDOMOptions:n,dataURLOptions:p,inlineImages:f,recordCanvas:g,preserveWhiteSpace:N,onSerialize:S,onIframeLoad:w,iframeLoadTimeout:v,onStylesheetLoad:x,stylesheetLoadTimeout:y,keepIframeSrcFn:b,depth:R,maxDepth:I});_&&x(e,_)}},y),D}function $o(e,t){const{mirror:s=new qi,blockClass:o="rr-block",blockSelector:i=null,maskTextClass:a="rr-mask",maskTextSelector:c=null,inlineStylesheet:d=!0,inlineImages:m=!1,recordCanvas:h=!1,maskAllInputs:r=!1,maskTextFn:u,maskInputFn:l,slimDOM:n=!1,dataURLOptions:p,preserveWhiteSpace:f,onSerialize:g,onIframeLoad:S,iframeLoadTimeout:w,onStylesheetLoad:v,stylesheetLoadTimeout:x,keepIframeSrcFn:y=()=>!1,maxDepth:b}=t||{};return Fe(e,{doc:e,mirror:s,blockClass:o,blockSelector:i,maskTextClass:a,maskTextSelector:c,skipChild:!1,inlineStylesheet:d,maskInputOptions:r===!0?{color:!0,date:!0,"datetime-local":!0,email:!0,month:!0,number:!0,range:!0,search:!0,tel:!0,text:!0,time:!0,url:!0,week:!0,textarea:!0,select:!0,password:!0}:r===!1?{password:!0}:r,maskTextFn:u,maskInputFn:l,slimDOMOptions:n===!0||n==="all"?{script:!0,comment:!0,headFavicon:!0,headWhitespace:!0,headMetaDescKeywords:n==="all",headMetaSocial:!0,headMetaRobots:!0,headMetaHttpEquiv:!0,headMetaAuthorship:!0,headMetaVerification:!0}:n===!1?{}:n,dataURLOptions:p,inlineImages:m,recordCanvas:h,preserveWhiteSpace:f,onSerialize:g,onIframeLoad:S,iframeLoadTimeout:w,onStylesheetLoad:v,stylesheetLoadTimeout:x,keepIframeSrcFn:y,newlyAddedElement:!1,maxDepth:b})}function Bo(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}function Uo(e){if(Object.prototype.hasOwnProperty.call(e,"__esModule"))return e;var t=e.default;if(typeof t=="function"){var s=function o(){return this instanceof o?Reflect.construct(t,arguments,this.constructor):t.apply(this,arguments)};s.prototype=t.prototype}else s={};return Object.defineProperty(s,"__esModule",{value:!0}),Object.keys(e).forEach(function(o){var i=Object.getOwnPropertyDescriptor(e,o);Object.defineProperty(s,o,i.get?i:{enumerable:!0,get:function(){return e[o]}})}),s}var Ke={exports:{}},bs;function Wo(){if(bs)return Ke.exports;bs=1;var e=String,t=function(){return{isColorSupported:!1,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,blackBright:e,redBright:e,greenBright:e,yellowBright:e,blueBright:e,magentaBright:e,cyanBright:e,whiteBright:e,bgBlackBright:e,bgRedBright:e,bgGreenBright:e,bgYellowBright:e,bgBlueBright:e,bgMagentaBright:e,bgCyanBright:e,bgWhiteBright:e}};return Ke.exports=t(),Ke.exports.createColors=t,Ke.exports}const zo={},qo=Object.freeze(Object.defineProperty({__proto__:null,default:zo},Symbol.toStringTag,{value:"Module"})),fe=Uo(qo);var It,Ss;function Hr(){if(Ss)return It;Ss=1;let e=Wo(),t=fe;class s extends Error{constructor(i,a,c,d,m,h){super(i),this.name="CssSyntaxError",this.reason=i,m&&(this.file=m),d&&(this.source=d),h&&(this.plugin=h),typeof a!="undefined"&&typeof c!="undefined"&&(typeof a=="number"?(this.line=a,this.column=c):(this.line=a.line,this.column=a.column,this.endLine=c.line,this.endColumn=c.column)),this.setMessage(),Error.captureStackTrace&&Error.captureStackTrace(this,s)}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(i){if(!this.source)return"";let a=this.source;i==null&&(i=e.isColorSupported);let c=n=>n,d=n=>n,m=n=>n;if(i){let{bold:n,gray:p,red:f}=e.createColors(!0);d=g=>n(f(g)),c=g=>p(g),t&&(m=g=>t(g))}let h=a.split(/\r?\n/),r=Math.max(this.line-3,0),u=Math.min(this.line+2,h.length),l=String(u).length;return h.slice(r,u).map((n,p)=>{let f=r+1+p,g=" "+(" "+f).slice(-l)+" | ";if(f===this.line){if(n.length>160){let w=20,v=Math.max(0,this.column-w),x=Math.max(this.column+w,this.endColumn+w),y=n.slice(v,x),b=c(g.replace(/\d/g," "))+n.slice(0,Math.min(this.column-1,w-1)).replace(/[^\t]/g," ");return d(">")+c(g)+m(y)+`
|
|
3
3
|
`+b+d("^")}let S=c(g.replace(/\d/g," "))+n.slice(0,this.column-1).replace(/[^\t]/g," ");return d(">")+c(g)+m(n)+`
|
|
4
4
|
`+S+d("^")}return" "+c(g)+m(n)}).join(`
|
|
5
5
|
`)}toString(){let i=this.showSourceCode();return i&&(i=`
|
|
6
6
|
|
|
7
7
|
`+i+`
|
|
8
|
-
`),this.name+": "+this.message+i}}return
|
|
8
|
+
`),this.name+": "+this.message+i}}return It=s,s.default=s,It}var Et,vs;function Yi(){if(vs)return Et;vs=1;const e={after:`
|
|
9
9
|
`,beforeClose:`
|
|
10
10
|
`,beforeComment:`
|
|
11
11
|
`,beforeDecl:`
|
|
@@ -16,23 +16,23 @@
|
|
|
16
16
|
`)&&(c=c.replace(/[^\n]+$/,"")),!1}),typeof c=="undefined"?c=this.raw(a,null,"beforeDecl"):c&&(c=c.replace(/\S/g,"")),c}rawBeforeDecl(i,a){let c;return i.walkDecls(d=>{if(typeof d.raws.before!="undefined")return c=d.raws.before,c.includes(`
|
|
17
17
|
`)&&(c=c.replace(/[^\n]+$/,"")),!1}),typeof c=="undefined"?c=this.raw(a,null,"beforeRule"):c&&(c=c.replace(/\S/g,"")),c}rawBeforeOpen(i){let a;return i.walk(c=>{if(c.type!=="decl"&&(a=c.raws.between,typeof a!="undefined"))return!1}),a}rawBeforeRule(i){let a;return i.walk(c=>{if(c.nodes&&(c.parent!==i||i.first!==c)&&typeof c.raws.before!="undefined")return a=c.raws.before,a.includes(`
|
|
18
18
|
`)&&(a=a.replace(/[^\n]+$/,"")),!1}),a&&(a=a.replace(/\S/g,"")),a}rawColon(i){let a;return i.walkDecls(c=>{if(typeof c.raws.between!="undefined")return a=c.raws.between.replace(/[^\s:]/g,""),!1}),a}rawEmptyBody(i){let a;return i.walk(c=>{if(c.nodes&&c.nodes.length===0&&(a=c.raws.after,typeof a!="undefined"))return!1}),a}rawIndent(i){if(i.raws.indent)return i.raws.indent;let a;return i.walk(c=>{let d=c.parent;if(d&&d!==i&&d.parent&&d.parent===i&&typeof c.raws.before!="undefined"){let m=c.raws.before.split(`
|
|
19
|
-
`);return a=m[m.length-1],a=a.replace(/\S/g,""),!1}}),a}rawSemicolon(i){let a;return i.walk(c=>{if(c.nodes&&c.nodes.length&&c.last.type==="decl"&&(a=c.raws.semicolon,typeof a!="undefined"))return!1}),a}rawValue(i,a){let c=i[a],d=i.raws[a];return d&&d.value===c?d.raw:c}root(i){this.body(i),i.raws.after&&this.builder(i.raws.after)}rule(i){this.block(i,this.rawValue(i,"selector")),i.raws.ownSemicolon&&this.builder(i.raws.ownSemicolon,i,"end")}stringify(i,a){if(!this[i.type])throw new Error("Unknown AST node type "+i.type+". Maybe you need to change PostCSS stringifier.");this[i.type](i,a)}}return
|
|
19
|
+
`);return a=m[m.length-1],a=a.replace(/\S/g,""),!1}}),a}rawSemicolon(i){let a;return i.walk(c=>{if(c.nodes&&c.nodes.length&&c.last.type==="decl"&&(a=c.raws.semicolon,typeof a!="undefined"))return!1}),a}rawValue(i,a){let c=i[a],d=i.raws[a];return d&&d.value===c?d.raw:c}root(i){this.body(i),i.raws.after&&this.builder(i.raws.after)}rule(i){this.block(i,this.rawValue(i,"selector")),i.raws.ownSemicolon&&this.builder(i.raws.ownSemicolon,i,"end")}stringify(i,a){if(!this[i.type])throw new Error("Unknown AST node type "+i.type+". Maybe you need to change PostCSS stringifier.");this[i.type](i,a)}}return Et=s,s.default=s,Et}var At,Cs;function mt(){if(Cs)return At;Cs=1;let e=Yi();function t(s,o){new e(o).stringify(s)}return At=t,t.default=t,At}var et={},xs;function Vr(){return xs||(xs=1,et.isClean=Symbol("isClean"),et.my=Symbol("my")),et}var Pt,Rs;function gt(){if(Rs)return Pt;Rs=1;let e=Hr(),t=Yi(),s=mt(),{isClean:o,my:i}=Vr();function a(m,h){let r=new m.constructor;for(let u in m){if(!Object.prototype.hasOwnProperty.call(m,u)||u==="proxyCache")continue;let l=m[u],n=typeof l;u==="parent"&&n==="object"?h&&(r[u]=h):u==="source"?r[u]=l:Array.isArray(l)?r[u]=l.map(p=>a(p,r)):(n==="object"&&l!==null&&(l=a(l)),r[u]=l)}return r}function c(m,h){if(h&&typeof h.offset!="undefined")return h.offset;let r=1,u=1,l=0;for(let n=0;n<m.length;n++){if(u===h.line&&r===h.column){l=n;break}m[n]===`
|
|
20
20
|
`?(r=1,u+=1):r+=1}return l}class d{get proxyOf(){return this}constructor(h={}){this.raws={},this[o]=!1,this[i]=!0;for(let r in h)if(r==="nodes"){this.nodes=[];for(let u of h[r])typeof u.clone=="function"?this.append(u.clone()):this.append(u)}else this[r]=h[r]}addToError(h){if(h.postcssNode=this,h.stack&&this.source&&/\n\s{4}at /.test(h.stack)){let r=this.source;h.stack=h.stack.replace(/\n\s{4}at /,`$&${r.input.from}:${r.start.line}:${r.start.column}$&`)}return h}after(h){return this.parent.insertAfter(this,h),this}assign(h={}){for(let r in h)this[r]=h[r];return this}before(h){return this.parent.insertBefore(this,h),this}cleanRaws(h){delete this.raws.before,delete this.raws.after,h||delete this.raws.between}clone(h={}){let r=a(this);for(let u in h)r[u]=h[u];return r}cloneAfter(h={}){let r=this.clone(h);return this.parent.insertAfter(this,r),r}cloneBefore(h={}){let r=this.clone(h);return this.parent.insertBefore(this,r),r}error(h,r={}){if(this.source){let{end:u,start:l}=this.rangeBy(r);return this.source.input.error(h,{column:l.column,line:l.line},{column:u.column,line:u.line},r)}return new e(h)}getProxyProcessor(){return{get(h,r){return r==="proxyOf"?h:r==="root"?()=>h.root().toProxy():h[r]},set(h,r,u){return h[r]===u||(h[r]=u,(r==="prop"||r==="value"||r==="name"||r==="params"||r==="important"||r==="text")&&h.markDirty()),!0}}}markClean(){this[o]=!0}markDirty(){if(this[o]){this[o]=!1;let h=this;for(;h=h.parent;)h[o]=!1}}next(){if(!this.parent)return;let h=this.parent.index(this);return this.parent.nodes[h+1]}positionBy(h={}){let r=this.source.start;if(h.index)r=this.positionInside(h.index);else if(h.word){let u="document"in this.source.input?this.source.input.document:this.source.input.css,n=u.slice(c(u,this.source.start),c(u,this.source.end)).indexOf(h.word);n!==-1&&(r=this.positionInside(n))}return r}positionInside(h){let r=this.source.start.column,u=this.source.start.line,l="document"in this.source.input?this.source.input.document:this.source.input.css,n=c(l,this.source.start),p=n+h;for(let f=n;f<p;f++)l[f]===`
|
|
21
|
-
`?(r=1,u+=1):r+=1;return{column:r,line:u,offset:p}}prev(){if(!this.parent)return;let h=this.parent.index(this);return this.parent.nodes[h-1]}rangeBy(h={}){let r="document"in this.source.input?this.source.input.document:this.source.input.css,u={column:this.source.start.column,line:this.source.start.line,offset:c(r,this.source.start)},l=this.source.end?{column:this.source.end.column+1,line:this.source.end.line,offset:typeof this.source.end.offset=="number"?this.source.end.offset:c(r,this.source.end)+1}:{column:u.column+1,line:u.line,offset:u.offset+1};if(h.word){let p=r.slice(c(r,this.source.start),c(r,this.source.end)).indexOf(h.word);p!==-1&&(u=this.positionInside(p),l=this.positionInside(p+h.word.length))}else h.start?u={column:h.start.column,line:h.start.line,offset:c(r,h.start)}:h.index&&(u=this.positionInside(h.index)),h.end?l={column:h.end.column,line:h.end.line,offset:c(r,h.end)}:typeof h.endIndex=="number"?l=this.positionInside(h.endIndex):h.index&&(l=this.positionInside(h.index+1));return(l.line<u.line||l.line===u.line&&l.column<=u.column)&&(l={column:u.column+1,line:u.line,offset:u.offset+1}),{end:l,start:u}}raw(h,r){return new t().raw(this,h,r)}remove(){return this.parent&&this.parent.removeChild(this),this.parent=void 0,this}replaceWith(...h){if(this.parent){let r=this,u=!1;for(let l of h)l===this?u=!0:u?(this.parent.insertAfter(r,l),r=l):this.parent.insertBefore(r,l);u||this.remove()}return this}root(){let h=this;for(;h.parent&&h.parent.type!=="document";)h=h.parent;return h}toJSON(h,r){let u={},l=r==null;r=r||new Map;let n=0;for(let p in this){if(!Object.prototype.hasOwnProperty.call(this,p)||p==="parent"||p==="proxyCache")continue;let f=this[p];if(Array.isArray(f))u[p]=f.map(g=>typeof g=="object"&&g.toJSON?g.toJSON(null,r):g);else if(typeof f=="object"&&f.toJSON)u[p]=f.toJSON(null,r);else if(p==="source"){if(f==null)continue;let g=r.get(f.input);g==null&&(g=n,r.set(f.input,n),n++),u[p]={end:f.end,inputId:g,start:f.start}}else u[p]=f}return l&&(u.inputs=[...r.keys()].map(p=>p.toJSON())),u}toProxy(){return this.proxyCache||(this.proxyCache=new Proxy(this,this.getProxyProcessor())),this.proxyCache}toString(h=s){h.stringify&&(h=h.stringify);let r="";return h(this,u=>{r+=u}),r}warn(h,r,u={}){let l={node:this};for(let n in u)l[n]=u[n];return h.warn(r,l)}}return Et=d,d.default=d,Et}var At,xs;function je(){if(xs)return At;xs=1;let e=dt();class t extends e{constructor(o){super(o),this.type="comment"}}return At=t,t.default=t,At}var Pt,Rs;function mt(){if(Rs)return Pt;Rs=1;let e=dt();class t extends e{get variable(){return this.prop.startsWith("--")||this.prop[0]==="$"}constructor(o){o&&typeof o.value!="undefined"&&typeof o.value!="string"&&(o=le(T({},o),{value:String(o.value)})),super(o),this.type="decl"}}return Pt=t,t.default=t,Pt}var Nt,Os;function Me(){if(Os)return Nt;Os=1;let e=je(),t=mt(),s=dt(),{isClean:o,my:i}=jr(),a,c,d,m;function h(l){return l.map(n=>(n.nodes&&(n.nodes=h(n.nodes)),delete n.source,n))}function r(l){if(l[o]=!1,l.proxyOf.nodes)for(let n of l.proxyOf.nodes)r(n)}class u extends s{get first(){if(this.proxyOf.nodes)return this.proxyOf.nodes[0]}get last(){if(this.proxyOf.nodes)return this.proxyOf.nodes[this.proxyOf.nodes.length-1]}append(...n){for(let p of n){let f=this.normalize(p,this.last);for(let g of f)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(),f,g;for(;this.indexes[p]<this.proxyOf.nodes.length&&(f=this.indexes[p],g=n(this.proxyOf.nodes[f],f),g!==!1);)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")?(...f)=>n[p](...f.map(g=>typeof g=="function"?(S,w)=>g(S.toProxy(),w):g)):p==="every"||p==="some"?f=>n[p]((g,...S)=>f(g.toProxy(),...S)):p==="root"?()=>n.root().toProxy():p==="nodes"?n.nodes.map(f=>f.toProxy()):p==="first"||p==="last"?n[p].toProxy():n[p]:n[p]},set(n,p,f){return n[p]===f||(n[p]=f,(p==="name"||p==="params"||p==="selector")&&n.markDirty()),!0}}}index(n){return typeof n=="number"?n:(n.proxyOf&&(n=n.proxyOf),this.proxyOf.nodes.indexOf(n))}insertAfter(n,p){let f=this.index(n),g=this.normalize(p,this.proxyOf.nodes[f]).reverse();f=this.index(n);for(let w of g)this.proxyOf.nodes.splice(f+1,0,w);let S;for(let w in this.indexes)S=this.indexes[w],f<S&&(this.indexes[w]=S+g.length);return this.markDirty(),this}insertBefore(n,p){let f=this.index(n),g=f===0?"prepend":!1,S=this.normalize(p,this.proxyOf.nodes[f],g).reverse();f=this.index(n);for(let v of S)this.proxyOf.nodes.splice(f,0,v);let w;for(let v in this.indexes)w=this.indexes[v],f<=w&&(this.indexes[v]=w+S.length);return this.markDirty(),this}normalize(n,p){if(typeof n=="string")n=h(c(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 t(n)]}else if(n.selector||n.selectors)n=[new m(n)];else if(n.name)n=[new a(n)];else if(n.text)n=[new e(n)];else throw new Error("Unknown node type in node creation");return n.map(g=>(g[i]||u.rebuild(g),g=g.proxyOf,g.parent&&g.parent.removeChild(g),g[o]&&r(g),g.raws||(g.raws={}),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 f=this.normalize(p,this.first,"prepend").reverse();for(let g of f)this.proxyOf.nodes.unshift(g);for(let g in this.indexes)this.indexes[g]=this.indexes[g]+f.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 f in this.indexes)p=this.indexes[f],p>=n&&(this.indexes[f]=p-1);return this.markDirty(),this}replaceValues(n,p,f){return f||(f=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,f))}),this.markDirty(),this}some(n){return this.nodes.some(n)}walk(n){return this.each((p,f)=>{let g;try{g=n(p,f)}catch(S){throw p.addToError(S)}return g!==!1&&p.walk&&(g=p.walk(n)),g})}walkAtRules(n,p){return p?n instanceof RegExp?this.walk((f,g)=>{if(f.type==="atrule"&&n.test(f.name))return p(f,g)}):this.walk((f,g)=>{if(f.type==="atrule"&&f.name===n)return p(f,g)}):(p=n,this.walk((f,g)=>{if(f.type==="atrule")return p(f,g)}))}walkComments(n){return this.walk((p,f)=>{if(p.type==="comment")return n(p,f)})}walkDecls(n,p){return p?n instanceof RegExp?this.walk((f,g)=>{if(f.type==="decl"&&n.test(f.prop))return p(f,g)}):this.walk((f,g)=>{if(f.type==="decl"&&f.prop===n)return p(f,g)}):(p=n,this.walk((f,g)=>{if(f.type==="decl")return p(f,g)}))}walkRules(n,p){return p?n instanceof RegExp?this.walk((f,g)=>{if(f.type==="rule"&&n.test(f.selector))return p(f,g)}):this.walk((f,g)=>{if(f.type==="rule"&&f.selector===n)return p(f,g)}):(p=n,this.walk((f,g)=>{if(f.type==="rule")return p(f,g)}))}}return u.registerParse=l=>{c=l},u.registerRule=l=>{m=l},u.registerAtRule=l=>{a=l},u.registerRoot=l=>{d=l},Nt=u,u.default=u,u.rebuild=l=>{l.type==="atrule"?Object.setPrototypeOf(l,a.prototype):l.type==="rule"?Object.setPrototypeOf(l,m.prototype):l.type==="decl"?Object.setPrototypeOf(l,t.prototype):l.type==="comment"?Object.setPrototypeOf(l,e.prototype):l.type==="root"&&Object.setPrototypeOf(l,d.prototype),l[i]=!0,l.nodes&&l.nodes.forEach(n=>{u.rebuild(n)})},Nt}var _t,Ms;function Hr(){if(Ms)return _t;Ms=1;let e=Me();class t extends e{constructor(o){super(o),this.type="atrule"}append(...o){return this.proxyOf.nodes||(this.nodes=[]),super.append(...o)}prepend(...o){return this.proxyOf.nodes||(this.nodes=[]),super.prepend(...o)}}return _t=t,t.default=t,e.registerAtRule(t),_t}var kt,Is;function Vr(){if(Is)return kt;Is=1;let e=Me(),t,s;class o extends e{constructor(a){super(T({type:"document"},a)),this.nodes||(this.nodes=[])}toResult(a={}){return new t(new s,this,a).stringify()}}return o.registerLazyResult=i=>{t=i},o.registerProcessor=i=>{s=i},kt=o,o.default=o,kt}var Dt,Es;function zo(){if(Es)return Dt;Es=1;let e="useandom-26T198340PX75pxJACKVERYMINDBUSHWOLF_GQZbfghjklqvwyzrict";return Dt={nanoid:(o=21)=>{let i="",a=o|0;for(;a--;)i+=e[Math.random()*64|0];return i},customAlphabet:(o,i=21)=>(a=i)=>{let c="",d=a|0;for(;d--;)c+=o[Math.random()*o.length|0];return c}},Dt}var Lt,As;function Ji(){if(As)return Lt;As=1;let{existsSync:e,readFileSync:t}=pe,{dirname:s,join:o}=pe,{SourceMapConsumer:i,SourceMapGenerator:a}=pe;function c(m){return Buffer?Buffer.from(m,"base64").toString():window.atob(m)}class d{constructor(h,r){if(r.map===!1)return;this.loadAnnotation(h),this.inline=this.startWith(this.annotation,"data:");let u=r.map?r.map.prev:void 0,l=this.loadMap(r.from,u);!this.mapFile&&r.from&&(this.mapFile=r.from),this.mapFile&&(this.root=s(this.mapFile)),l&&(this.text=l)}consumer(){return this.consumerCache||(this.consumerCache=new i(this.text)),this.consumerCache}decodeInline(h){let r=/^data:application\/json;charset=utf-?8;base64,/,u=/^data:application\/json;base64,/,l=/^data:application\/json;charset=utf-?8,/,n=/^data:application\/json,/,p=h.match(l)||h.match(n);if(p)return decodeURIComponent(h.substr(p[0].length));let f=h.match(r)||h.match(u);if(f)return c(h.substr(f[0].length));let g=h.match(/data:application\/json;([^,]+),/)[1];throw new Error("Unsupported source map encoding "+g)}getAnnotationURL(h){return h.replace(/^\/\*\s*# sourceMappingURL=/,"").trim()}isMap(h){return typeof h!="object"?!1:typeof h.mappings=="string"||typeof h._mappings=="string"||Array.isArray(h.sections)}loadAnnotation(h){let r=h.match(/\/\*\s*# sourceMappingURL=/g);if(!r)return;let u=h.lastIndexOf(r.pop()),l=h.indexOf("*/",u);u>-1&&l>-1&&(this.annotation=this.getAnnotationURL(h.substring(u,l)))}loadFile(h){if(this.root=s(h),e(h))return this.mapFile=h,t(h,"utf-8").toString().trim()}loadMap(h,r){if(r===!1)return!1;if(r){if(typeof r=="string")return r;if(typeof r=="function"){let u=r(h);if(u){let l=this.loadFile(u);if(!l)throw new Error("Unable to load previous source map: "+u.toString());return l}}else{if(r instanceof i)return a.fromSourceMap(r).toString();if(r instanceof a)return r.toString();if(this.isMap(r))return JSON.stringify(r);throw new Error("Unsupported previous source map format: "+r.toString())}}else{if(this.inline)return this.decodeInline(this.annotation);if(this.annotation){let u=this.annotation;return h&&(u=o(s(h),u)),this.loadFile(u)}}}startWith(h,r){return h?h.substr(0,r.length)===r:!1}withContent(){return!!(this.consumer().sourcesContent&&this.consumer().sourcesContent.length>0)}}return Lt=d,d.default=d,Lt}var Tt,Ps;function gt(){if(Ps)return Tt;Ps=1;let{nanoid:e}=zo(),{isAbsolute:t,resolve:s}=pe,{SourceMapConsumer:o,SourceMapGenerator:i}=pe,{fileURLToPath:a,pathToFileURL:c}=pe,d=qr(),m=Ji(),h=pe,r=Symbol("lineToIndexCache"),u=!!(o&&i),l=!!(s&&t);function n(f){if(f[r])return f[r];let g=f.css.split(`
|
|
22
|
-
`),S=new Array(g.length),w=0;for(let v=0,x=g.length;v<x;v++)S[v]=w,w+=g[v].length+1;return f[r]=S,S}class p{get from(){return this.file||this.id}constructor(g,S={}){if(g===null||typeof g=="undefined"||typeof g=="object"&&!g.toString)throw new Error(`PostCSS received ${g} instead of CSS string`);if(this.css=g.toString(),this.css[0]==="\uFEFF"||this.css[0]==="\uFFFE"?(this.hasBOM=!0,this.css=this.css.slice(1)):this.hasBOM=!1,this.document=this.css,S.document&&(this.document=S.document.toString()),S.from&&(!l||/^\w+:\/\//.test(S.from)||t(S.from)?this.file=S.from:this.file=s(S.from)),l&&u){let w=new m(this.css,S);if(w.text){this.map=w;let v=w.consumer().file;!this.file&&v&&(this.file=this.mapResolve(v))}}this.file||(this.id="<input css "+e(6)+">"),this.map&&(this.map.file=this.from)}error(g,S,w,v={}){let x,y,b,C,R;if(S&&typeof S=="object"){let O=S,N=w;if(typeof O.offset=="number"){C=O.offset;let P=this.fromOffset(C);S=P.line,w=P.col}else S=O.line,w=O.column,C=this.fromLineAndColumn(S,w);if(typeof N.offset=="number"){b=N.offset;let P=this.fromOffset(b);y=P.line,x=P.col}else y=N.line,x=N.column,b=this.fromLineAndColumn(N.line,N.column)}else if(w)C=this.fromLineAndColumn(S,w);else{C=S;let O=this.fromOffset(C);S=O.line,w=O.col}let I=this.origin(S,w,y,x);return I?R=new d(g,I.endLine===void 0?I.line:{column:I.column,line:I.line},I.endLine===void 0?I.column:{column:I.endColumn,line:I.endLine},I.source,I.file,v.plugin):R=new d(g,y===void 0?S:{column:w,line:S},y===void 0?w:{column:x,line:y},this.css,this.file,v.plugin),R.input={column:w,endColumn:x,endLine:y,endOffset:b,line:S,offset:C,source:this.css},this.file&&(c&&(R.input.url=c(this.file).toString()),R.input.file=this.file),R}fromLineAndColumn(g,S){return n(this)[g-1]+S-1}fromOffset(g){let S=n(this),w=S[S.length-1],v=0;if(g>=w)v=S.length-1;else{let x=S.length-2,y;for(;v<x;)if(y=v+(x-v>>1),g<S[y])x=y-1;else if(g>=S[y+1])v=y+1;else{v=y;break}}return{col:g-S[v]+1,line:v+1}}mapResolve(g){return/^\w+:\/\//.test(g)?g:s(this.map.consumer().sourceRoot||this.map.root||".",g)}origin(g,S,w,v){if(!this.map)return!1;let x=this.map.consumer(),y=x.originalPositionFor({column:S,line:g});if(!y.source)return!1;let b;typeof w=="number"&&(b=x.originalPositionFor({column:v,line:w}));let C;t(y.source)?C=c(y.source):C=new URL(y.source,this.map.consumer().sourceRoot||c(this.map.mapFile));let R={column:y.column,endColumn:b&&b.column,endLine:b&&b.line,line:y.line,url:C.toString()};if(C.protocol==="file:")if(a)R.file=a(C);else throw new Error("file: protocol is not available in this PostCSS build");let I=x.sourceContentFor(y.source);return I&&(R.source=I),R}toJSON(){let g={};for(let S of["hasBOM","css","file","id"])this[S]!=null&&(g[S]=this[S]);return this.map&&(g.map=T({},this.map),g.map.consumerCache&&(g.map.consumerCache=void 0)),g}}return
|
|
23
|
-
`," "];return e.split(t,s)},split(t,s,o){let i=[],a="",c=!1,d=0,m=!1,h="",r=!1;for(let u of t)r?r=!1:u==="\\"?r=!0:m?u===h&&(m=!1):u==='"'||u==="'"?(m=!0,h=u):u==="("?d+=1:u===")"?d>0&&(d-=1):d===0&&s.includes(u)&&(c=!0),c?(a!==""&&i.push(a.trim()),a="",c=!1):a+=u;return(o||a!=="")&&i.push(a.trim()),i}};return
|
|
21
|
+
`?(r=1,u+=1):r+=1;return{column:r,line:u,offset:p}}prev(){if(!this.parent)return;let h=this.parent.index(this);return this.parent.nodes[h-1]}rangeBy(h={}){let r="document"in this.source.input?this.source.input.document:this.source.input.css,u={column:this.source.start.column,line:this.source.start.line,offset:c(r,this.source.start)},l=this.source.end?{column:this.source.end.column+1,line:this.source.end.line,offset:typeof this.source.end.offset=="number"?this.source.end.offset:c(r,this.source.end)+1}:{column:u.column+1,line:u.line,offset:u.offset+1};if(h.word){let p=r.slice(c(r,this.source.start),c(r,this.source.end)).indexOf(h.word);p!==-1&&(u=this.positionInside(p),l=this.positionInside(p+h.word.length))}else h.start?u={column:h.start.column,line:h.start.line,offset:c(r,h.start)}:h.index&&(u=this.positionInside(h.index)),h.end?l={column:h.end.column,line:h.end.line,offset:c(r,h.end)}:typeof h.endIndex=="number"?l=this.positionInside(h.endIndex):h.index&&(l=this.positionInside(h.index+1));return(l.line<u.line||l.line===u.line&&l.column<=u.column)&&(l={column:u.column+1,line:u.line,offset:u.offset+1}),{end:l,start:u}}raw(h,r){return new t().raw(this,h,r)}remove(){return this.parent&&this.parent.removeChild(this),this.parent=void 0,this}replaceWith(...h){if(this.parent){let r=this,u=!1;for(let l of h)l===this?u=!0:u?(this.parent.insertAfter(r,l),r=l):this.parent.insertBefore(r,l);u||this.remove()}return this}root(){let h=this;for(;h.parent&&h.parent.type!=="document";)h=h.parent;return h}toJSON(h,r){let u={},l=r==null;r=r||new Map;let n=0;for(let p in this){if(!Object.prototype.hasOwnProperty.call(this,p)||p==="parent"||p==="proxyCache")continue;let f=this[p];if(Array.isArray(f))u[p]=f.map(g=>typeof g=="object"&&g.toJSON?g.toJSON(null,r):g);else if(typeof f=="object"&&f.toJSON)u[p]=f.toJSON(null,r);else if(p==="source"){if(f==null)continue;let g=r.get(f.input);g==null&&(g=n,r.set(f.input,n),n++),u[p]={end:f.end,inputId:g,start:f.start}}else u[p]=f}return l&&(u.inputs=[...r.keys()].map(p=>p.toJSON())),u}toProxy(){return this.proxyCache||(this.proxyCache=new Proxy(this,this.getProxyProcessor())),this.proxyCache}toString(h=s){h.stringify&&(h=h.stringify);let r="";return h(this,u=>{r+=u}),r}warn(h,r,u={}){let l={node:this};for(let n in u)l[n]=u[n];return h.warn(r,l)}}return Pt=d,d.default=d,Pt}var Nt,Os;function Ve(){if(Os)return Nt;Os=1;let e=gt();class t extends e{constructor(o){super(o),this.type="comment"}}return Nt=t,t.default=t,Nt}var _t,Ms;function yt(){if(Ms)return _t;Ms=1;let e=gt();class t extends e{get variable(){return this.prop.startsWith("--")||this.prop[0]==="$"}constructor(o){o&&typeof o.value!="undefined"&&typeof o.value!="string"&&(o=le(T({},o),{value:String(o.value)})),super(o),this.type="decl"}}return _t=t,t.default=t,_t}var kt,Is;function Ee(){if(Is)return kt;Is=1;let e=Ve(),t=yt(),s=gt(),{isClean:o,my:i}=Vr(),a,c,d,m;function h(l){return l.map(n=>(n.nodes&&(n.nodes=h(n.nodes)),delete n.source,n))}function r(l){if(l[o]=!1,l.proxyOf.nodes)for(let n of l.proxyOf.nodes)r(n)}class u extends s{get first(){if(this.proxyOf.nodes)return this.proxyOf.nodes[0]}get last(){if(this.proxyOf.nodes)return this.proxyOf.nodes[this.proxyOf.nodes.length-1]}append(...n){for(let p of n){let f=this.normalize(p,this.last);for(let g of f)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(),f,g;for(;this.indexes[p]<this.proxyOf.nodes.length&&(f=this.indexes[p],g=n(this.proxyOf.nodes[f],f),g!==!1);)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")?(...f)=>n[p](...f.map(g=>typeof g=="function"?(S,w)=>g(S.toProxy(),w):g)):p==="every"||p==="some"?f=>n[p]((g,...S)=>f(g.toProxy(),...S)):p==="root"?()=>n.root().toProxy():p==="nodes"?n.nodes.map(f=>f.toProxy()):p==="first"||p==="last"?n[p].toProxy():n[p]:n[p]},set(n,p,f){return n[p]===f||(n[p]=f,(p==="name"||p==="params"||p==="selector")&&n.markDirty()),!0}}}index(n){return typeof n=="number"?n:(n.proxyOf&&(n=n.proxyOf),this.proxyOf.nodes.indexOf(n))}insertAfter(n,p){let f=this.index(n),g=this.normalize(p,this.proxyOf.nodes[f]).reverse();f=this.index(n);for(let w of g)this.proxyOf.nodes.splice(f+1,0,w);let S;for(let w in this.indexes)S=this.indexes[w],f<S&&(this.indexes[w]=S+g.length);return this.markDirty(),this}insertBefore(n,p){let f=this.index(n),g=f===0?"prepend":!1,S=this.normalize(p,this.proxyOf.nodes[f],g).reverse();f=this.index(n);for(let v of S)this.proxyOf.nodes.splice(f,0,v);let w;for(let v in this.indexes)w=this.indexes[v],f<=w&&(this.indexes[v]=w+S.length);return this.markDirty(),this}normalize(n,p){if(typeof n=="string")n=h(c(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 t(n)]}else if(n.selector||n.selectors)n=[new m(n)];else if(n.name)n=[new a(n)];else if(n.text)n=[new e(n)];else throw new Error("Unknown node type in node creation");return n.map(g=>(g[i]||u.rebuild(g),g=g.proxyOf,g.parent&&g.parent.removeChild(g),g[o]&&r(g),g.raws||(g.raws={}),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 f=this.normalize(p,this.first,"prepend").reverse();for(let g of f)this.proxyOf.nodes.unshift(g);for(let g in this.indexes)this.indexes[g]=this.indexes[g]+f.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 f in this.indexes)p=this.indexes[f],p>=n&&(this.indexes[f]=p-1);return this.markDirty(),this}replaceValues(n,p,f){return f||(f=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,f))}),this.markDirty(),this}some(n){return this.nodes.some(n)}walk(n){return this.each((p,f)=>{let g;try{g=n(p,f)}catch(S){throw p.addToError(S)}return g!==!1&&p.walk&&(g=p.walk(n)),g})}walkAtRules(n,p){return p?n instanceof RegExp?this.walk((f,g)=>{if(f.type==="atrule"&&n.test(f.name))return p(f,g)}):this.walk((f,g)=>{if(f.type==="atrule"&&f.name===n)return p(f,g)}):(p=n,this.walk((f,g)=>{if(f.type==="atrule")return p(f,g)}))}walkComments(n){return this.walk((p,f)=>{if(p.type==="comment")return n(p,f)})}walkDecls(n,p){return p?n instanceof RegExp?this.walk((f,g)=>{if(f.type==="decl"&&n.test(f.prop))return p(f,g)}):this.walk((f,g)=>{if(f.type==="decl"&&f.prop===n)return p(f,g)}):(p=n,this.walk((f,g)=>{if(f.type==="decl")return p(f,g)}))}walkRules(n,p){return p?n instanceof RegExp?this.walk((f,g)=>{if(f.type==="rule"&&n.test(f.selector))return p(f,g)}):this.walk((f,g)=>{if(f.type==="rule"&&f.selector===n)return p(f,g)}):(p=n,this.walk((f,g)=>{if(f.type==="rule")return p(f,g)}))}}return u.registerParse=l=>{c=l},u.registerRule=l=>{m=l},u.registerAtRule=l=>{a=l},u.registerRoot=l=>{d=l},kt=u,u.default=u,u.rebuild=l=>{l.type==="atrule"?Object.setPrototypeOf(l,a.prototype):l.type==="rule"?Object.setPrototypeOf(l,m.prototype):l.type==="decl"?Object.setPrototypeOf(l,t.prototype):l.type==="comment"?Object.setPrototypeOf(l,e.prototype):l.type==="root"&&Object.setPrototypeOf(l,d.prototype),l[i]=!0,l.nodes&&l.nodes.forEach(n=>{u.rebuild(n)})},kt}var Dt,Es;function Gr(){if(Es)return Dt;Es=1;let e=Ee();class t extends e{constructor(o){super(o),this.type="atrule"}append(...o){return this.proxyOf.nodes||(this.nodes=[]),super.append(...o)}prepend(...o){return this.proxyOf.nodes||(this.nodes=[]),super.prepend(...o)}}return Dt=t,t.default=t,e.registerAtRule(t),Dt}var Lt,As;function Jr(){if(As)return Lt;As=1;let e=Ee(),t,s;class o extends e{constructor(a){super(T({type:"document"},a)),this.nodes||(this.nodes=[])}toResult(a={}){return new t(new s,this,a).stringify()}}return o.registerLazyResult=i=>{t=i},o.registerProcessor=i=>{s=i},Lt=o,o.default=o,Lt}var Tt,Ps;function jo(){if(Ps)return Tt;Ps=1;let e="useandom-26T198340PX75pxJACKVERYMINDBUSHWOLF_GQZbfghjklqvwyzrict";return Tt={nanoid:(o=21)=>{let i="",a=o|0;for(;a--;)i+=e[Math.random()*64|0];return i},customAlphabet:(o,i=21)=>(a=i)=>{let c="",d=a|0;for(;d--;)c+=o[Math.random()*o.length|0];return c}},Tt}var Ft,Ns;function Zi(){if(Ns)return Ft;Ns=1;let{existsSync:e,readFileSync:t}=fe,{dirname:s,join:o}=fe,{SourceMapConsumer:i,SourceMapGenerator:a}=fe;function c(m){return Buffer?Buffer.from(m,"base64").toString():window.atob(m)}class d{constructor(h,r){if(r.map===!1)return;this.loadAnnotation(h),this.inline=this.startWith(this.annotation,"data:");let u=r.map?r.map.prev:void 0,l=this.loadMap(r.from,u);!this.mapFile&&r.from&&(this.mapFile=r.from),this.mapFile&&(this.root=s(this.mapFile)),l&&(this.text=l)}consumer(){return this.consumerCache||(this.consumerCache=new i(this.text)),this.consumerCache}decodeInline(h){let r=/^data:application\/json;charset=utf-?8;base64,/,u=/^data:application\/json;base64,/,l=/^data:application\/json;charset=utf-?8,/,n=/^data:application\/json,/,p=h.match(l)||h.match(n);if(p)return decodeURIComponent(h.substr(p[0].length));let f=h.match(r)||h.match(u);if(f)return c(h.substr(f[0].length));let g=h.match(/data:application\/json;([^,]+),/)[1];throw new Error("Unsupported source map encoding "+g)}getAnnotationURL(h){return h.replace(/^\/\*\s*# sourceMappingURL=/,"").trim()}isMap(h){return typeof h!="object"?!1:typeof h.mappings=="string"||typeof h._mappings=="string"||Array.isArray(h.sections)}loadAnnotation(h){let r=h.match(/\/\*\s*# sourceMappingURL=/g);if(!r)return;let u=h.lastIndexOf(r.pop()),l=h.indexOf("*/",u);u>-1&&l>-1&&(this.annotation=this.getAnnotationURL(h.substring(u,l)))}loadFile(h){if(this.root=s(h),e(h))return this.mapFile=h,t(h,"utf-8").toString().trim()}loadMap(h,r){if(r===!1)return!1;if(r){if(typeof r=="string")return r;if(typeof r=="function"){let u=r(h);if(u){let l=this.loadFile(u);if(!l)throw new Error("Unable to load previous source map: "+u.toString());return l}}else{if(r instanceof i)return a.fromSourceMap(r).toString();if(r instanceof a)return r.toString();if(this.isMap(r))return JSON.stringify(r);throw new Error("Unsupported previous source map format: "+r.toString())}}else{if(this.inline)return this.decodeInline(this.annotation);if(this.annotation){let u=this.annotation;return h&&(u=o(s(h),u)),this.loadFile(u)}}}startWith(h,r){return h?h.substr(0,r.length)===r:!1}withContent(){return!!(this.consumer().sourcesContent&&this.consumer().sourcesContent.length>0)}}return Ft=d,d.default=d,Ft}var $t,_s;function wt(){if(_s)return $t;_s=1;let{nanoid:e}=jo(),{isAbsolute:t,resolve:s}=fe,{SourceMapConsumer:o,SourceMapGenerator:i}=fe,{fileURLToPath:a,pathToFileURL:c}=fe,d=Hr(),m=Zi(),h=fe,r=Symbol("lineToIndexCache"),u=!!(o&&i),l=!!(s&&t);function n(f){if(f[r])return f[r];let g=f.css.split(`
|
|
22
|
+
`),S=new Array(g.length),w=0;for(let v=0,x=g.length;v<x;v++)S[v]=w,w+=g[v].length+1;return f[r]=S,S}class p{get from(){return this.file||this.id}constructor(g,S={}){if(g===null||typeof g=="undefined"||typeof g=="object"&&!g.toString)throw new Error(`PostCSS received ${g} instead of CSS string`);if(this.css=g.toString(),this.css[0]==="\uFEFF"||this.css[0]==="\uFFFE"?(this.hasBOM=!0,this.css=this.css.slice(1)):this.hasBOM=!1,this.document=this.css,S.document&&(this.document=S.document.toString()),S.from&&(!l||/^\w+:\/\//.test(S.from)||t(S.from)?this.file=S.from:this.file=s(S.from)),l&&u){let w=new m(this.css,S);if(w.text){this.map=w;let v=w.consumer().file;!this.file&&v&&(this.file=this.mapResolve(v))}}this.file||(this.id="<input css "+e(6)+">"),this.map&&(this.map.file=this.from)}error(g,S,w,v={}){let x,y,b,C,R;if(S&&typeof S=="object"){let O=S,N=w;if(typeof O.offset=="number"){C=O.offset;let P=this.fromOffset(C);S=P.line,w=P.col}else S=O.line,w=O.column,C=this.fromLineAndColumn(S,w);if(typeof N.offset=="number"){b=N.offset;let P=this.fromOffset(b);y=P.line,x=P.col}else y=N.line,x=N.column,b=this.fromLineAndColumn(N.line,N.column)}else if(w)C=this.fromLineAndColumn(S,w);else{C=S;let O=this.fromOffset(C);S=O.line,w=O.col}let I=this.origin(S,w,y,x);return I?R=new d(g,I.endLine===void 0?I.line:{column:I.column,line:I.line},I.endLine===void 0?I.column:{column:I.endColumn,line:I.endLine},I.source,I.file,v.plugin):R=new d(g,y===void 0?S:{column:w,line:S},y===void 0?w:{column:x,line:y},this.css,this.file,v.plugin),R.input={column:w,endColumn:x,endLine:y,endOffset:b,line:S,offset:C,source:this.css},this.file&&(c&&(R.input.url=c(this.file).toString()),R.input.file=this.file),R}fromLineAndColumn(g,S){return n(this)[g-1]+S-1}fromOffset(g){let S=n(this),w=S[S.length-1],v=0;if(g>=w)v=S.length-1;else{let x=S.length-2,y;for(;v<x;)if(y=v+(x-v>>1),g<S[y])x=y-1;else if(g>=S[y+1])v=y+1;else{v=y;break}}return{col:g-S[v]+1,line:v+1}}mapResolve(g){return/^\w+:\/\//.test(g)?g:s(this.map.consumer().sourceRoot||this.map.root||".",g)}origin(g,S,w,v){if(!this.map)return!1;let x=this.map.consumer(),y=x.originalPositionFor({column:S,line:g});if(!y.source)return!1;let b;typeof w=="number"&&(b=x.originalPositionFor({column:v,line:w}));let C;t(y.source)?C=c(y.source):C=new URL(y.source,this.map.consumer().sourceRoot||c(this.map.mapFile));let R={column:y.column,endColumn:b&&b.column,endLine:b&&b.line,line:y.line,url:C.toString()};if(C.protocol==="file:")if(a)R.file=a(C);else throw new Error("file: protocol is not available in this PostCSS build");let I=x.sourceContentFor(y.source);return I&&(R.source=I),R}toJSON(){let g={};for(let S of["hasBOM","css","file","id"])this[S]!=null&&(g[S]=this[S]);return this.map&&(g.map=T({},this.map),g.map.consumerCache&&(g.map.consumerCache=void 0)),g}}return $t=p,p.default=p,h&&h.registerInput&&h.registerInput(p),$t}var Bt,ks;function Ge(){if(ks)return Bt;ks=1;let e=Ee(),t,s;class o extends e{constructor(a){super(a),this.type="root",this.nodes||(this.nodes=[])}normalize(a,c,d){let m=super.normalize(a);if(c){if(d==="prepend")this.nodes.length>1?c.raws.before=this.nodes[1].raws.before:delete c.raws.before;else if(this.first!==c)for(let h of m)h.raws.before=c.raws.before}return m}removeChild(a,c){let d=this.index(a);return!c&&d===0&&this.nodes.length>1&&(this.nodes[1].raws.before=this.nodes[d].raws.before),super.removeChild(a)}toResult(a={}){return new t(new s,this,a).stringify()}}return o.registerLazyResult=i=>{t=i},o.registerProcessor=i=>{s=i},Bt=o,o.default=o,e.registerRoot(o),Bt}var Ut,Ds;function Xi(){if(Ds)return Ut;Ds=1;let e={comma(t){return e.split(t,[","],!0)},space(t){let s=[" ",`
|
|
23
|
+
`," "];return e.split(t,s)},split(t,s,o){let i=[],a="",c=!1,d=0,m=!1,h="",r=!1;for(let u of t)r?r=!1:u==="\\"?r=!0:m?u===h&&(m=!1):u==='"'||u==="'"?(m=!0,h=u):u==="("?d+=1:u===")"?d>0&&(d-=1):d===0&&s.includes(u)&&(c=!0),c?(a!==""&&i.push(a.trim()),a="",c=!1):a+=u;return(o||a!=="")&&i.push(a.trim()),i}};return Ut=e,e.default=e,Ut}var Wt,Ls;function Yr(){if(Ls)return Wt;Ls=1;let e=Ee(),t=Xi();class s extends e{get selectors(){return t.comma(this.selector)}set selectors(i){let a=this.selector?this.selector.match(/,\s*/):null,c=a?a[0]:","+this.raw("between","beforeOpen");this.selector=i.join(c)}constructor(i){super(i),this.type="rule",this.nodes||(this.nodes=[])}}return Wt=s,s.default=s,e.registerRule(s),Wt}var zt,Ts;function Ho(){if(Ts)return zt;Ts=1;let e=Gr(),t=Ve(),s=yt(),o=wt(),i=Zi(),a=Ge(),c=Yr();function d(m,h){if(Array.isArray(m))return m.map(p=>d(p));let l=m,{inputs:r}=l,u=_e(l,["inputs"]);if(r){h=[];for(let p of r){let f=le(T({},p),{__proto__:o.prototype});f.map&&(f.map=le(T({},f.map),{__proto__:i.prototype})),h.push(f)}}if(u.nodes&&(u.nodes=m.nodes.map(p=>d(p,h))),u.source){let n=u.source,{inputId:p}=n,f=_e(n,["inputId"]);u.source=f,p!=null&&(u.source.input=h[p])}if(u.type==="root")return new a(u);if(u.type==="decl")return new s(u);if(u.type==="rule")return new c(u);if(u.type==="comment")return new t(u);if(u.type==="atrule")return new e(u);throw new Error("Unknown node type: "+m.type)}return zt=d,d.default=d,zt}var qt,Fs;function Qi(){if(Fs)return qt;Fs=1;let{dirname:e,relative:t,resolve:s,sep:o}=fe,{SourceMapConsumer:i,SourceMapGenerator:a}=fe,{pathToFileURL:c}=fe,d=wt(),m=!!(i&&a),h=!!(e&&s&&t&&o);class r{constructor(l,n,p,f){this.stringify=l,this.mapOpts=p.map||{},this.root=n,this.opts=p,this.css=f,this.originalCSS=f,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=`
|
|
24
24
|
`;this.css.includes(`\r
|
|
25
25
|
`)&&(n=`\r
|
|
26
26
|
`),this.css+=n+"/*# sourceMappingURL="+l+" */"}applyPrevMaps(){for(let l of this.previous()){let n=this.toUrl(this.path(l.file)),p=l.root||e(l.file),f;this.mapOpts.sourcesContent===!1?(f=new i(l.text),f.sourcesContent&&(f.sourcesContent=null)):f=l.consumer(),this.map.applySourceMap(f,n,this.toUrl(this.path(p)))}}clearAnnotation(){if(this.mapOpts.annotation!==!1)if(this.root){let l;for(let n=this.root.nodes.length-1;n>=0;n--)l=this.root.nodes[n],l.type==="comment"&&l.text.startsWith("# sourceMappingURL=")&&this.root.removeChild(n)}else this.css&&(this.css=this.css.replace(/\n*\/\*#[\S\s]*?\*\/$/gm,""))}generate(){if(this.clearAnnotation(),h&&m&&this.isMap())return this.generateMap();{let l="";return this.stringify(this.root,n=>{l+=n}),[l]}}generateMap(){if(this.root)this.generateString();else if(this.previous().length===1){let l=this.previous()[0].consumer();l.file=this.outputFile(),this.map=a.fromSourceMap(l,{ignoreInvalidMapping:!0})}else this.map=new a({file:this.outputFile(),ignoreInvalidMapping:!0}),this.map.addMapping({generated:{column:0,line:1},original:{column:0,line:1},source:this.opts.from?this.toUrl(this.path(this.opts.from)):"<no source>"});return this.isSourcesContent()&&this.setSourcesContent(),this.root&&this.previous().length>0&&this.applyPrevMaps(),this.isAnnotation()&&this.addAnnotation(),this.isInline()?[this.css]:[this.css,this.map]}generateString(){this.css="",this.map=new a({file:this.outputFile(),ignoreInvalidMapping:!0});let l=1,n=1,p="<no source>",f={generated:{column:0,line:0},original:{column:0,line:0},source:""},g,S;this.stringify(this.root,(w,v,x)=>{if(this.css+=w,v&&x!=="end"&&(f.generated.line=l,f.generated.column=n-1,v.source&&v.source.start?(f.source=this.sourcePath(v),f.original.line=v.source.start.line,f.original.column=v.source.start.column-1,this.map.addMapping(f)):(f.source=p,f.original.line=1,f.original.column=0,this.map.addMapping(f))),S=w.match(/\n/g),S?(l+=S.length,g=w.lastIndexOf(`
|
|
27
|
-
`),n=w.length-g):n+=w.length,v&&x!=="start"){let y=v.parent||{raws:{}};(!(v.type==="decl"||v.type==="atrule"&&!v.nodes)||v!==y.last||y.raws.semicolon)&&(v.source&&v.source.end?(f.source=this.sourcePath(v),f.original.line=v.source.end.line,f.original.column=v.source.end.column-1,f.generated.line=l,f.generated.column=n-2,this.map.addMapping(f)):(f.source=p,f.original.line=1,f.original.column=0,f.generated.line=l,f.generated.column=n-1,this.map.addMapping(f)))}})}isAnnotation(){return this.isInline()?!0:typeof this.mapOpts.annotation!="undefined"?this.mapOpts.annotation:this.previous().length?this.previous().some(l=>l.annotation):!0}isInline(){if(typeof this.mapOpts.inline!="undefined")return this.mapOpts.inline;let l=this.mapOpts.annotation;return typeof l!="undefined"&&l!==!0?!1:this.previous().length?this.previous().some(n=>n.inline):!0}isMap(){return typeof this.opts.map!="undefined"?!!this.opts.map:this.previous().length>0}isSourcesContent(){return typeof this.mapOpts.sourcesContent!="undefined"?this.mapOpts.sourcesContent:this.previous().length?this.previous().some(l=>l.withContent()):!0}outputFile(){return this.opts.to?this.path(this.opts.to):this.opts.from?this.path(this.opts.from):"to.css"}path(l){if(this.mapOpts.absolute||l.charCodeAt(0)===60||/^\w+:\/\//.test(l))return l;let n=this.memoizedPaths.get(l);if(n)return n;let p=this.opts.to?e(this.opts.to):".";typeof this.mapOpts.annotation=="string"&&(p=e(s(p,this.mapOpts.annotation)));let f=t(p,l);return this.memoizedPaths.set(l,f),f}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 d(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]=!0;let f=this.usesFileUrls?this.toFileUrl(p):this.toUrl(this.path(p));this.map.setSourceContent(f,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(c){let p=c(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;o==="\\"&&(l=l.replace(/\\/g,"/"));let p=encodeURI(l).replace(/[#?]/g,encodeURIComponent);return this.memoizedURLs.set(l,p),p}}return Wt=r,Wt}var zt,Ts;function Xi(){if(Ts)return zt;Ts=1;const e=39,t=34,s=92,o=47,i=10,a=32,c=12,d=9,m=13,h=91,r=93,u=40,l=41,n=123,p=125,f=59,g=42,S=58,w=64,v=/[\t\n\f\r "#'()/;[\\\]{}]/g,x=/[\t\n\f\r !"#'():;@[\\\]{}]|\/(?=\*)/g,y=/.[\r\n"'(/\\]/,b=/[\da-f]/i;return zt=function(R,I={}){let O=R.css.valueOf(),N=I.ignoreErrors,P,ee,D,M,ie,_,U,J,W,be,me=O.length,E=0,oe=[],ae=[];function Ae(){return E}function ge(X){throw R.error("Unclosed "+X,E)}function he(){return ae.length===0&&E>=me}function te(X){if(ae.length)return ae.pop();if(E>=me)return;let k=X?X.ignoreUnclosed:!1;switch(P=O.charCodeAt(E),P){case i:case a:case d:case m:case c:{M=E;do M+=1,P=O.charCodeAt(M);while(P===a||P===i||P===d||P===m||P===c);_=["space",O.slice(E,M)],E=M-1;break}case h:case r:case n:case p:case S:case f:case l:{let Y=String.fromCharCode(P);_=[Y,Y,E];break}case u:{if(be=oe.length?oe.pop()[1]:"",W=O.charCodeAt(E+1),be==="url"&&W!==e&&W!==t&&W!==a&&W!==i&&W!==d&&W!==c&&W!==m){M=E;do{if(U=!1,M=O.indexOf(")",M+1),M===-1)if(N||k){M=E;break}else ge("bracket");for(J=M;O.charCodeAt(J-1)===s;)J-=1,U=!U}while(U);_=["brackets",O.slice(E,M+1),E,M],E=M}else M=O.indexOf(")",E+1),ee=O.slice(E,M+1),M===-1||y.test(ee)?_=["(","(",E]:(_=["brackets",ee,E,M],E=M);break}case e:case t:{ie=P===e?"'":'"',M=E;do{if(U=!1,M=O.indexOf(ie,M+1),M===-1)if(N||k){M=E+1;break}else ge("string");for(J=M;O.charCodeAt(J-1)===s;)J-=1,U=!U}while(U);_=["string",O.slice(E,M+1),E,M],E=M;break}case w:{v.lastIndex=E+1,v.test(O),v.lastIndex===0?M=O.length-1:M=v.lastIndex-2,_=["at-word",O.slice(E,M+1),E,M],E=M;break}case s:{for(M=E,D=!0;O.charCodeAt(M+1)===s;)M+=1,D=!D;if(P=O.charCodeAt(M+1),D&&P!==o&&P!==a&&P!==i&&P!==d&&P!==m&&P!==c&&(M+=1,b.test(O.charAt(M)))){for(;b.test(O.charAt(M+1));)M+=1;O.charCodeAt(M+1)===a&&(M+=1)}_=["word",O.slice(E,M+1),E,M],E=M;break}default:{P===o&&O.charCodeAt(E+1)===g?(M=O.indexOf("*/",E+2)+1,M===0&&(N||k?M=O.length:ge("comment")),_=["comment",O.slice(E,M+1),E,M],E=M):(x.lastIndex=E+1,x.test(O),x.lastIndex===0?M=O.length-1:M=x.lastIndex-2,_=["word",O.slice(E,M+1),E,M],oe.push(_),E=M);break}}return E++,_}function Re(X){ae.push(X)}return{back:Re,endOfFile:he,nextToken:te,position:Ae}},zt}var qt,Fs;function Qi(){if(Fs)return qt;Fs=1;let e=Hr(),t=je(),s=mt(),o=He(),i=Gr(),a=Xi();const c={empty:!0,space:!0};function d(h){for(let r=h.length-1;r>=0;r--){let u=h[r],l=u[3]||u[2];if(l)return l}}class m{constructor(r){this.input=r,this.root=new o,this.current=this.root,this.spaces="",this.semicolon=!1,this.createTokenizer(),this.root.source={input:r,start:{column:1,line:1,offset:0}}}atrule(r){let u=new e;u.name=r[1].slice(1),u.name===""&&this.unnamedAtrule(u,r),this.init(u,r[2]);let l,n,p,f=!1,g=!1,S=[],w=[];for(;!this.tokenizer.endOfFile();){if(r=this.tokenizer.nextToken(),l=r[0],l==="("||l==="["?w.push(l==="("?")":"]"):l==="{"&&w.length>0?w.push("}"):l===w[w.length-1]&&w.pop(),w.length===0)if(l===";"){u.source.end=this.getPosition(r[2]),u.source.end.offset++,this.semicolon=!0;break}else if(l==="{"){g=!0;break}else if(l==="}"){if(S.length>0){for(p=S.length-1,n=S[p];n&&n[0]==="space";)n=S[--p];n&&(u.source.end=this.getPosition(n[3]||n[2]),u.source.end.offset++)}this.end(r);break}else S.push(r);else S.push(r);if(this.tokenizer.endOfFile()){f=!0;break}}u.raws.between=this.spacesAndCommentsFromEnd(S),S.length?(u.raws.afterName=this.spacesAndCommentsFromStart(S),this.raw(u,"params",S),f&&(r=S[S.length-1],u.source.end=this.getPosition(r[3]||r[2]),u.source.end.offset++,this.spaces=u.raws.between,u.raws.between="")):(u.raws.afterName="",u.params=""),g&&(u.nodes=[],this.current=u)}checkMissedSemicolon(r){let u=this.colon(r);if(u===!1)return;let l=0,n;for(let p=u-1;p>=0&&(n=r[p],!(n[0]!=="space"&&(l+=1,l===2)));p--);throw this.input.error("Missed semicolon",n[0]==="word"?n[3]+1:n[2])}colon(r){let u=0,l,n,p;for(let[f,g]of r.entries()){if(n=g,p=n[0],p==="("&&(u+=1),p===")"&&(u-=1),u===0&&p===":")if(!l)this.doubleColon(n);else{if(l[0]==="word"&&l[1]==="progid")continue;return f}l=n}return!1}comment(r){let u=new t;this.init(u,r[2]),u.source.end=this.getPosition(r[3]||r[2]),u.source.end.offset++;let l=r[1].slice(2,-2);if(/^\s*$/.test(l))u.text="",u.raws.left=l,u.raws.right="";else{let n=l.match(/^(\s*)([^]*\S)(\s*)$/);u.text=n[2],u.raws.left=n[1],u.raws.right=n[3]}}createTokenizer(){this.tokenizer=a(this.input)}decl(r,u){let l=new s;this.init(l,r[0][2]);let n=r[r.length-1];for(n[0]===";"&&(this.semicolon=!0,r.pop()),l.source.end=this.getPosition(n[3]||n[2]||d(r)),l.source.end.offset++;r[0][0]!=="word";)r.length===1&&this.unknownWord(r),l.raws.before+=r.shift()[1];for(l.source.start=this.getPosition(r[0][2]),l.prop="";r.length;){let w=r[0][0];if(w===":"||w==="space"||w==="comment")break;l.prop+=r.shift()[1]}l.raws.between="";let p;for(;r.length;)if(p=r.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 f=[],g;for(;r.length&&(g=r[0][0],!(g!=="space"&&g!=="comment"));)f.push(r.shift());this.precheckMissedSemicolon(r);for(let w=r.length-1;w>=0;w--){if(p=r[w],p[1].toLowerCase()==="!important"){l.important=!0;let v=this.stringFrom(r,w);v=this.spacesFromEnd(r)+v,v!==" !important"&&(l.raws.important=v);break}else if(p[1].toLowerCase()==="important"){let v=r.slice(0),x="";for(let y=w;y>0;y--){let b=v[y][0];if(x.trim().startsWith("!")&&b!=="space")break;x=v.pop()[1]+x}x.trim().startsWith("!")&&(l.important=!0,l.raws.important=x,r=v)}if(p[0]!=="space"&&p[0]!=="comment")break}r.some(w=>w[0]!=="space"&&w[0]!=="comment")&&(l.raws.between+=f.map(w=>w[1]).join(""),f=[]),this.raw(l,"value",f.concat(r),u),l.value.includes(":")&&!u&&this.checkMissedSemicolon(r)}doubleColon(r){throw this.input.error("Double colon",{offset:r[2]},{offset:r[2]+r[1].length})}emptyRule(r){let u=new i;this.init(u,r[2]),u.selector="",u.raws.between="",this.current=u}end(r){this.current.nodes&&this.current.nodes.length&&(this.current.raws.semicolon=this.semicolon),this.semicolon=!1,this.current.raws.after=(this.current.raws.after||"")+this.spaces,this.spaces="",this.current.parent?(this.current.source.end=this.getPosition(r[2]),this.current.source.end.offset++,this.current=this.current.parent):this.unexpectedClose(r)}endFile(){this.current.parent&&this.unclosedBlock(),this.current.nodes&&this.current.nodes.length&&(this.current.raws.semicolon=this.semicolon),this.current.raws.after=(this.current.raws.after||"")+this.spaces,this.root.source.end=this.getPosition(this.tokenizer.position())}freeSemicolon(r){if(this.spaces+=r[1],this.current.nodes){let u=this.current.nodes[this.current.nodes.length-1];u&&u.type==="rule"&&!u.raws.ownSemicolon&&(u.raws.ownSemicolon=this.spaces,this.spaces="",u.source.end=this.getPosition(r[2]),u.source.end.offset+=u.raws.ownSemicolon.length)}}getPosition(r){let u=this.input.fromOffset(r);return{column:u.col,line:u.line,offset:r}}init(r,u){this.current.push(r),r.source={input:this.input,start:this.getPosition(u)},r.raws.before=this.spaces,this.spaces="",r.type!=="comment"&&(this.semicolon=!1)}other(r){let u=!1,l=null,n=!1,p=null,f=[],g=r[1].startsWith("--"),S=[],w=r;for(;w;){if(l=w[0],S.push(w),l==="("||l==="[")p||(p=w),f.push(l==="("?")":"]");else if(g&&n&&l==="{")p||(p=w),f.push("}");else if(f.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()),u=!0;break}else l===":"&&(n=!0);else l===f[f.length-1]&&(f.pop(),f.length===0&&(p=null));w=this.tokenizer.nextToken()}if(this.tokenizer.endOfFile()&&(u=!0),f.length>0&&this.unclosedBracket(p),u&&n){if(!g)for(;S.length&&(w=S[S.length-1][0],!(w!=="space"&&w!=="comment"));)this.tokenizer.back(S.pop());this.decl(S,g)}else this.unknownWord(S)}parse(){let r;for(;!this.tokenizer.endOfFile();)switch(r=this.tokenizer.nextToken(),r[0]){case"space":this.spaces+=r[1];break;case";":this.freeSemicolon(r);break;case"}":this.end(r);break;case"comment":this.comment(r);break;case"at-word":this.atrule(r);break;case"{":this.emptyRule(r);break;default:this.other(r);break}this.endFile()}precheckMissedSemicolon(){}raw(r,u,l,n){let p,f,g=l.length,S="",w=!0,v,x;for(let y=0;y<g;y+=1)p=l[y],f=p[0],f==="space"&&y===g-1&&!n?w=!1:f==="comment"?(x=l[y-1]?l[y-1][0]:"empty",v=l[y+1]?l[y+1][0]:"empty",!c[x]&&!c[v]?S.slice(-1)===","?w=!1:S+=p[1]:w=!1):S+=p[1];if(!w){let y=l.reduce((b,C)=>b+C[1],"");r.raws[u]={raw:y,value:S}}r[u]=S}rule(r){r.pop();let u=new i;this.init(u,r[0][2]),u.raws.between=this.spacesAndCommentsFromEnd(r),this.raw(u,"selector",r),this.current=u}spacesAndCommentsFromEnd(r){let u,l="";for(;r.length&&(u=r[r.length-1][0],!(u!=="space"&&u!=="comment"));)l=r.pop()[1]+l;return l}spacesAndCommentsFromStart(r){let u,l="";for(;r.length&&(u=r[0][0],!(u!=="space"&&u!=="comment"));)l+=r.shift()[1];return l}spacesFromEnd(r){let u,l="";for(;r.length&&(u=r[r.length-1][0],u==="space");)l=r.pop()[1]+l;return l}stringFrom(r,u){let l="";for(let n=u;n<r.length;n++)l+=r[n][1];return r.splice(u,r.length-u),l}unclosedBlock(){let r=this.current.source.start;throw this.input.error("Unclosed block",r.line,r.column)}unclosedBracket(r){throw this.input.error("Unclosed bracket",{offset:r[2]},{offset:r[2]+1})}unexpectedClose(r){throw this.input.error("Unexpected }",{offset:r[2]},{offset:r[2]+1})}unknownWord(r){throw this.input.error("Unknown word "+r[0][1],{offset:r[0][2]},{offset:r[0][2]+r[0][1].length})}unnamedAtrule(r,u){throw this.input.error("At-rule without name",{offset:u[2]},{offset:u[2]+u[1].length})}}return qt=m,qt}var jt,$s;function Jr(){if($s)return jt;$s=1;let e=Me(),t=gt(),s=Qi();function o(i,a){let c=new t(i,a),d=new s(c);try{d.parse()}catch(m){throw m}return d.root}return jt=o,o.default=o,e.registerParse(o),jt}var Ht,Bs;function Ki(){if(Bs)return Ht;Bs=1;class e{constructor(s,o={}){if(this.type="warning",this.text=s,o.node&&o.node.source){let i=o.node.rangeBy(o);this.line=i.start.line,this.column=i.start.column,this.endLine=i.end.line,this.endColumn=i.end.column}for(let i in o)this[i]=o[i]}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 Ht=e,e.default=e,Ht}var Vt,Us;function Yr(){if(Us)return Vt;Us=1;let e=Ki();class t{get content(){return this.css}constructor(o,i,a){this.processor=o,this.messages=[],this.root=i,this.opts=a,this.css="",this.map=void 0}toString(){return this.css}warn(o,i={}){i.plugin||this.lastPlugin&&this.lastPlugin.postcssPlugin&&(i.plugin=this.lastPlugin.postcssPlugin);let a=new e(o,i);return this.messages.push(a),a}warnings(){return this.messages.filter(o=>o.type==="warning")}}return Vt=t,t.default=t,Vt}var Gt,Ws;function en(){if(Ws)return Gt;Ws=1;let e={};return Gt=function(s){e[s]||(e[s]=!0,typeof console!="undefined"&&console.warn&&console.warn(s))},Gt}var Jt,zs;function tn(){if(zs)return Jt;zs=1;let e=Me(),t=Vr(),s=Zi(),o=Jr(),i=Yr(),a=He(),c=pt(),{isClean:d,my:m}=jr(),h=en();const r={atrule:"AtRule",comment:"Comment",decl:"Declaration",document:"Document",root:"Root",rule:"Rule"},u={AtRule:!0,AtRuleExit:!0,Comment:!0,CommentExit:!0,Declaration:!0,DeclarationExit:!0,Document:!0,DocumentExit:!0,Once:!0,OnceExit:!0,postcssPlugin:!0,prepare:!0,Root:!0,RootExit:!0,Rule:!0,RuleExit:!0},l={Once:!0,postcssPlugin:!0,prepare:!0},n=0;function p(x){return typeof x=="object"&&typeof x.then=="function"}function f(x){let y=!1,b=r[x.type];return x.type==="decl"?y=x.prop.toLowerCase():x.type==="atrule"&&(y=x.name.toLowerCase()),y&&x.append?[b,b+"-"+y,n,b+"Exit",b+"Exit-"+y]:y?[b,b+"-"+y,b+"Exit",b+"Exit-"+y]:x.append?[b,n,b+"Exit"]:[b,b+"Exit"]}function g(x){let y;return x.type==="document"?y=["Document",n,"DocumentExit"]:x.type==="root"?y=["Root",n,"RootExit"]:y=f(x),{eventIndex:0,events:y,iterator:0,node:x,visitorIndex:0,visitors:[]}}function S(x){return x[d]=!1,x.nodes&&x.nodes.forEach(y=>S(y)),x}let w={};class v{get content(){return this.stringify().content}get css(){return this.stringify().css}get map(){return this.stringify().map}get messages(){return this.sync().messages}get opts(){return this.result.opts}get processor(){return this.result.processor}get root(){return this.sync().root}get[Symbol.toStringTag](){return"LazyResult"}constructor(y,b,C){this.stringified=!1,this.processed=!1;let R;if(typeof b=="object"&&b!==null&&(b.type==="root"||b.type==="document"))R=S(b);else if(b instanceof v||b instanceof i)R=S(b.root),b.map&&(typeof C.map=="undefined"&&(C.map={}),C.map.inline||(C.map.inline=!1),C.map.prev=b.map);else{let I=o;C.syntax&&(I=C.syntax.parse),C.parser&&(I=C.parser),I.parse&&(I=I.parse);try{R=I(b,C)}catch(O){this.processed=!0,this.error=O}R&&!R[m]&&e.rebuild(R)}this.result=new i(y,R,C),this.helpers=le(T({},w),{postcss:w,result:this.result}),this.plugins=this.processor.plugins.map(I=>typeof I=="object"&&I.prepare?T(T({},I),I.prepare(this.result)):I)}async(){return this.error?Promise.reject(this.error):this.processed?Promise.resolve(this.result):(this.processing||(this.processing=this.runAsync()),this.processing)}catch(y){return this.async().catch(y)}finally(y){return this.async().then(y,y)}getAsyncError(){throw new Error("Use process(css).then(cb) to work with async plugins")}handleError(y,b){let C=this.result.lastPlugin;try{b&&b.addToError(y),this.error=y,y.name==="CssSyntaxError"&&!y.plugin?(y.plugin=C.postcssPlugin,y.setMessage()):C.postcssVersion}catch(R){console&&console.error&&console.error(R)}return y}prepareVisitors(){this.listeners={};let y=(b,C,R)=>{this.listeners[C]||(this.listeners[C]=[]),this.listeners[C].push([b,R])};for(let b of this.plugins)if(typeof b=="object")for(let C in b){if(!u[C]&&/^[A-Z]/.test(C))throw new Error(`Unknown event ${C} in ${b.postcssPlugin}. Try to update PostCSS (${this.processor.version} now).`);if(!l[C])if(typeof b[C]=="object")for(let R in b[C])R==="*"?y(b,C,b[C][R]):y(b,C+"-"+R.toLowerCase(),b[C][R]);else typeof b[C]=="function"&&y(b,C,b[C])}this.hasListener=Object.keys(this.listeners).length>0}async runAsync(){this.plugin=0;for(let y=0;y<this.plugins.length;y++){let b=this.plugins[y],C=this.runOnRoot(b);if(p(C))try{await C}catch(R){throw this.handleError(R)}}if(this.prepareVisitors(),this.hasListener){let y=this.result.root;for(;!y[d];){y[d]=!0;let b=[g(y)];for(;b.length>0;){let C=this.visitTick(b);if(p(C))try{await C}catch(R){let I=b[b.length-1].node;throw this.handleError(R,I)}}}if(this.listeners.OnceExit)for(let[b,C]of this.listeners.OnceExit){this.result.lastPlugin=b;try{if(y.type==="document"){let R=y.nodes.map(I=>C(I,this.helpers));await Promise.all(R)}else await C(y,this.helpers)}catch(R){throw this.handleError(R)}}}return this.processed=!0,this.stringify()}runOnRoot(y){this.result.lastPlugin=y;try{if(typeof y=="object"&&y.Once){if(this.result.root.type==="document"){let b=this.result.root.nodes.map(C=>y.Once(C,this.helpers));return p(b[0])?Promise.all(b):b}return y.Once(this.result.root,this.helpers)}else if(typeof y=="function")return y(this.result.root,this.result)}catch(b){throw this.handleError(b)}}stringify(){if(this.error)throw this.error;if(this.stringified)return this.result;this.stringified=!0,this.sync();let y=this.result.opts,b=c;y.syntax&&(b=y.syntax.stringify),y.stringifier&&(b=y.stringifier),b.stringify&&(b=b.stringify);let R=new s(b,this.result.root,this.result.opts).generate();return this.result.css=R[0],this.result.map=R[1],this.result}sync(){if(this.error)throw this.error;if(this.processed)return this.result;if(this.processed=!0,this.processing)throw this.getAsyncError();for(let y of this.plugins){let b=this.runOnRoot(y);if(p(b))throw this.getAsyncError()}if(this.prepareVisitors(),this.hasListener){let y=this.result.root;for(;!y[d];)y[d]=!0,this.walkSync(y);if(this.listeners.OnceExit)if(y.type==="document")for(let b of y.nodes)this.visitSync(this.listeners.OnceExit,b);else this.visitSync(this.listeners.OnceExit,y)}return this.result}then(y,b){return this.async().then(y,b)}toString(){return this.css}visitSync(y,b){for(let[C,R]of y){this.result.lastPlugin=C;let I;try{I=R(b,this.helpers)}catch(O){throw this.handleError(O,b.proxyOf)}if(b.type!=="root"&&b.type!=="document"&&!b.parent)return!0;if(p(I))throw this.getAsyncError()}}visitTick(y){let b=y[y.length-1],{node:C,visitors:R}=b;if(C.type!=="root"&&C.type!=="document"&&!C.parent){y.pop();return}if(R.length>0&&b.visitorIndex<R.length){let[O,N]=R[b.visitorIndex];b.visitorIndex+=1,b.visitorIndex===R.length&&(b.visitors=[],b.visitorIndex=0),this.result.lastPlugin=O;try{return N(C.toProxy(),this.helpers)}catch(P){throw this.handleError(P,C)}}if(b.iterator!==0){let O=b.iterator,N;for(;N=C.nodes[C.indexes[O]];)if(C.indexes[O]+=1,!N[d]){N[d]=!0,y.push(g(N));return}b.iterator=0,delete C.indexes[O]}let I=b.events;for(;b.eventIndex<I.length;){let O=I[b.eventIndex];if(b.eventIndex+=1,O===n){C.nodes&&C.nodes.length&&(C[d]=!0,b.iterator=C.getIterator());return}else if(this.listeners[O]){b.visitors=this.listeners[O];return}}y.pop()}walkSync(y){y[d]=!0;let b=f(y);for(let C of b)if(C===n)y.nodes&&y.each(R=>{R[d]||this.walkSync(R)});else{let R=this.listeners[C];if(R&&this.visitSync(R,y.toProxy()))return}}warnings(){return this.sync().warnings()}}return v.registerPostcss=x=>{w=x},Jt=v,v.default=v,a.registerLazyResult(v),t.registerLazyResult(v),Jt}var Yt,qs;function jo(){if(qs)return Yt;qs=1;let e=Zi(),t=Jr();const s=Yr();let o=pt(),i=en();class a{get content(){return this.result.css}get css(){return this.result.css}get map(){return this.result.map}get messages(){return[]}get opts(){return this.result.opts}get processor(){return this.result.processor}get root(){if(this._root)return this._root;let d,m=t;try{d=m(this._css,this._opts)}catch(h){this.error=h}if(this.error)throw this.error;return this._root=d,d}get[Symbol.toStringTag](){return"NoWorkResult"}constructor(d,m,h){m=m.toString(),this.stringified=!1,this._processor=d,this._css=m,this._opts=h,this._map=void 0;let r,u=o;this.result=new s(this._processor,r,this._opts),this.result.css=m;let l=this;Object.defineProperty(this.result,"root",{get(){return l.root}});let n=new e(u,r,this._opts,m);if(n.isMap()){let[p,f]=n.generate();p&&(this.result.css=p),f&&(this.result.map=f)}else n.clearAnnotation(),this.result.css=n.css}async(){return this.error?Promise.reject(this.error):Promise.resolve(this.result)}catch(d){return this.async().catch(d)}finally(d){return this.async().then(d,d)}sync(){if(this.error)throw this.error;return this.result}then(d,m){return this.async().then(d,m)}toString(){return this._css}warnings(){return[]}}return Yt=a,a.default=a,Yt}var Zt,js;function Ho(){if(js)return Zt;js=1;let e=Vr(),t=tn(),s=jo(),o=He();class i{constructor(c=[]){this.version="8.5.6",this.plugins=this.normalize(c)}normalize(c){let d=[];for(let m of c)if(m.postcss===!0?m=m():m.postcss&&(m=m.postcss),typeof m=="object"&&Array.isArray(m.plugins))d=d.concat(m.plugins);else if(typeof m=="object"&&m.postcssPlugin)d.push(m);else if(typeof m=="function")d.push(m);else if(!(typeof m=="object"&&(m.parse||m.stringify)))throw new Error(m+" is not a PostCSS plugin");return d}process(c,d={}){return!this.plugins.length&&!d.parser&&!d.stringifier&&!d.syntax?new s(this,c,d):new t(this,c,d)}use(c){return this.plugins=this.plugins.concat(this.normalize([c])),this}}return Zt=i,i.default=i,o.registerProcessor(i),e.registerProcessor(i),Zt}var Xt,Hs;function rn(){if(Hs)return Xt;Hs=1;let e=Hr(),t=je(),s=Me(),o=qr(),i=mt(),a=Vr(),c=qo(),d=gt(),m=tn(),h=Yi(),r=dt(),u=Jr(),l=Ho(),n=Yr(),p=He(),f=Gr(),g=pt(),S=Ki();function w(...v){return v.length===1&&Array.isArray(v[0])&&(v=v[0]),new l(v)}return w.plugin=function(x,y){let b=!1;function C(...I){console&&console.warn&&!b&&(b=!0,console.warn(x+`: postcss.plugin was deprecated. Migration guide:
|
|
27
|
+
`),n=w.length-g):n+=w.length,v&&x!=="start"){let y=v.parent||{raws:{}};(!(v.type==="decl"||v.type==="atrule"&&!v.nodes)||v!==y.last||y.raws.semicolon)&&(v.source&&v.source.end?(f.source=this.sourcePath(v),f.original.line=v.source.end.line,f.original.column=v.source.end.column-1,f.generated.line=l,f.generated.column=n-2,this.map.addMapping(f)):(f.source=p,f.original.line=1,f.original.column=0,f.generated.line=l,f.generated.column=n-1,this.map.addMapping(f)))}})}isAnnotation(){return this.isInline()?!0:typeof this.mapOpts.annotation!="undefined"?this.mapOpts.annotation:this.previous().length?this.previous().some(l=>l.annotation):!0}isInline(){if(typeof this.mapOpts.inline!="undefined")return this.mapOpts.inline;let l=this.mapOpts.annotation;return typeof l!="undefined"&&l!==!0?!1:this.previous().length?this.previous().some(n=>n.inline):!0}isMap(){return typeof this.opts.map!="undefined"?!!this.opts.map:this.previous().length>0}isSourcesContent(){return typeof this.mapOpts.sourcesContent!="undefined"?this.mapOpts.sourcesContent:this.previous().length?this.previous().some(l=>l.withContent()):!0}outputFile(){return this.opts.to?this.path(this.opts.to):this.opts.from?this.path(this.opts.from):"to.css"}path(l){if(this.mapOpts.absolute||l.charCodeAt(0)===60||/^\w+:\/\//.test(l))return l;let n=this.memoizedPaths.get(l);if(n)return n;let p=this.opts.to?e(this.opts.to):".";typeof this.mapOpts.annotation=="string"&&(p=e(s(p,this.mapOpts.annotation)));let f=t(p,l);return this.memoizedPaths.set(l,f),f}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 d(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]=!0;let f=this.usesFileUrls?this.toFileUrl(p):this.toUrl(this.path(p));this.map.setSourceContent(f,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(c){let p=c(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;o==="\\"&&(l=l.replace(/\\/g,"/"));let p=encodeURI(l).replace(/[#?]/g,encodeURIComponent);return this.memoizedURLs.set(l,p),p}}return qt=r,qt}var jt,$s;function Ki(){if($s)return jt;$s=1;const e=39,t=34,s=92,o=47,i=10,a=32,c=12,d=9,m=13,h=91,r=93,u=40,l=41,n=123,p=125,f=59,g=42,S=58,w=64,v=/[\t\n\f\r "#'()/;[\\\]{}]/g,x=/[\t\n\f\r !"#'():;@[\\\]{}]|\/(?=\*)/g,y=/.[\r\n"'(/\\]/,b=/[\da-f]/i;return jt=function(R,I={}){let O=R.css.valueOf(),N=I.ignoreErrors,P,ee,D,M,se,_,W,Z,z,ve,ye=O.length,E=0,we=[],oe=[];function Ce(){return E}function de(H){throw R.error("Unclosed "+H,E)}function Ne(){return oe.length===0&&E>=ye}function Ue(H){if(oe.length)return oe.pop();if(E>=ye)return;let he=H?H.ignoreUnclosed:!1;switch(P=O.charCodeAt(E),P){case i:case a:case d:case m:case c:{M=E;do M+=1,P=O.charCodeAt(M);while(P===a||P===i||P===d||P===m||P===c);_=["space",O.slice(E,M)],E=M-1;break}case h:case r:case n:case p:case S:case f:case l:{let me=String.fromCharCode(P);_=[me,me,E];break}case u:{if(ve=we.length?we.pop()[1]:"",z=O.charCodeAt(E+1),ve==="url"&&z!==e&&z!==t&&z!==a&&z!==i&&z!==d&&z!==c&&z!==m){M=E;do{if(W=!1,M=O.indexOf(")",M+1),M===-1)if(N||he){M=E;break}else de("bracket");for(Z=M;O.charCodeAt(Z-1)===s;)Z-=1,W=!W}while(W);_=["brackets",O.slice(E,M+1),E,M],E=M}else M=O.indexOf(")",E+1),ee=O.slice(E,M+1),M===-1||y.test(ee)?_=["(","(",E]:(_=["brackets",ee,E,M],E=M);break}case e:case t:{se=P===e?"'":'"',M=E;do{if(W=!1,M=O.indexOf(se,M+1),M===-1)if(N||he){M=E+1;break}else de("string");for(Z=M;O.charCodeAt(Z-1)===s;)Z-=1,W=!W}while(W);_=["string",O.slice(E,M+1),E,M],E=M;break}case w:{v.lastIndex=E+1,v.test(O),v.lastIndex===0?M=O.length-1:M=v.lastIndex-2,_=["at-word",O.slice(E,M+1),E,M],E=M;break}case s:{for(M=E,D=!0;O.charCodeAt(M+1)===s;)M+=1,D=!D;if(P=O.charCodeAt(M+1),D&&P!==o&&P!==a&&P!==i&&P!==d&&P!==m&&P!==c&&(M+=1,b.test(O.charAt(M)))){for(;b.test(O.charAt(M+1));)M+=1;O.charCodeAt(M+1)===a&&(M+=1)}_=["word",O.slice(E,M+1),E,M],E=M;break}default:{P===o&&O.charCodeAt(E+1)===g?(M=O.indexOf("*/",E+2)+1,M===0&&(N||he?M=O.length:de("comment")),_=["comment",O.slice(E,M+1),E,M],E=M):(x.lastIndex=E+1,x.test(O),x.lastIndex===0?M=O.length-1:M=x.lastIndex-2,_=["word",O.slice(E,M+1),E,M],we.push(_),E=M);break}}return E++,_}function ce(H){oe.push(H)}return{back:ce,endOfFile:Ne,nextToken:Ue,position:Ce}},jt}var Ht,Bs;function en(){if(Bs)return Ht;Bs=1;let e=Gr(),t=Ve(),s=yt(),o=Ge(),i=Yr(),a=Ki();const c={empty:!0,space:!0};function d(h){for(let r=h.length-1;r>=0;r--){let u=h[r],l=u[3]||u[2];if(l)return l}}class m{constructor(r){this.input=r,this.root=new o,this.current=this.root,this.spaces="",this.semicolon=!1,this.createTokenizer(),this.root.source={input:r,start:{column:1,line:1,offset:0}}}atrule(r){let u=new e;u.name=r[1].slice(1),u.name===""&&this.unnamedAtrule(u,r),this.init(u,r[2]);let l,n,p,f=!1,g=!1,S=[],w=[];for(;!this.tokenizer.endOfFile();){if(r=this.tokenizer.nextToken(),l=r[0],l==="("||l==="["?w.push(l==="("?")":"]"):l==="{"&&w.length>0?w.push("}"):l===w[w.length-1]&&w.pop(),w.length===0)if(l===";"){u.source.end=this.getPosition(r[2]),u.source.end.offset++,this.semicolon=!0;break}else if(l==="{"){g=!0;break}else if(l==="}"){if(S.length>0){for(p=S.length-1,n=S[p];n&&n[0]==="space";)n=S[--p];n&&(u.source.end=this.getPosition(n[3]||n[2]),u.source.end.offset++)}this.end(r);break}else S.push(r);else S.push(r);if(this.tokenizer.endOfFile()){f=!0;break}}u.raws.between=this.spacesAndCommentsFromEnd(S),S.length?(u.raws.afterName=this.spacesAndCommentsFromStart(S),this.raw(u,"params",S),f&&(r=S[S.length-1],u.source.end=this.getPosition(r[3]||r[2]),u.source.end.offset++,this.spaces=u.raws.between,u.raws.between="")):(u.raws.afterName="",u.params=""),g&&(u.nodes=[],this.current=u)}checkMissedSemicolon(r){let u=this.colon(r);if(u===!1)return;let l=0,n;for(let p=u-1;p>=0&&(n=r[p],!(n[0]!=="space"&&(l+=1,l===2)));p--);throw this.input.error("Missed semicolon",n[0]==="word"?n[3]+1:n[2])}colon(r){let u=0,l,n,p;for(let[f,g]of r.entries()){if(n=g,p=n[0],p==="("&&(u+=1),p===")"&&(u-=1),u===0&&p===":")if(!l)this.doubleColon(n);else{if(l[0]==="word"&&l[1]==="progid")continue;return f}l=n}return!1}comment(r){let u=new t;this.init(u,r[2]),u.source.end=this.getPosition(r[3]||r[2]),u.source.end.offset++;let l=r[1].slice(2,-2);if(/^\s*$/.test(l))u.text="",u.raws.left=l,u.raws.right="";else{let n=l.match(/^(\s*)([^]*\S)(\s*)$/);u.text=n[2],u.raws.left=n[1],u.raws.right=n[3]}}createTokenizer(){this.tokenizer=a(this.input)}decl(r,u){let l=new s;this.init(l,r[0][2]);let n=r[r.length-1];for(n[0]===";"&&(this.semicolon=!0,r.pop()),l.source.end=this.getPosition(n[3]||n[2]||d(r)),l.source.end.offset++;r[0][0]!=="word";)r.length===1&&this.unknownWord(r),l.raws.before+=r.shift()[1];for(l.source.start=this.getPosition(r[0][2]),l.prop="";r.length;){let w=r[0][0];if(w===":"||w==="space"||w==="comment")break;l.prop+=r.shift()[1]}l.raws.between="";let p;for(;r.length;)if(p=r.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 f=[],g;for(;r.length&&(g=r[0][0],!(g!=="space"&&g!=="comment"));)f.push(r.shift());this.precheckMissedSemicolon(r);for(let w=r.length-1;w>=0;w--){if(p=r[w],p[1].toLowerCase()==="!important"){l.important=!0;let v=this.stringFrom(r,w);v=this.spacesFromEnd(r)+v,v!==" !important"&&(l.raws.important=v);break}else if(p[1].toLowerCase()==="important"){let v=r.slice(0),x="";for(let y=w;y>0;y--){let b=v[y][0];if(x.trim().startsWith("!")&&b!=="space")break;x=v.pop()[1]+x}x.trim().startsWith("!")&&(l.important=!0,l.raws.important=x,r=v)}if(p[0]!=="space"&&p[0]!=="comment")break}r.some(w=>w[0]!=="space"&&w[0]!=="comment")&&(l.raws.between+=f.map(w=>w[1]).join(""),f=[]),this.raw(l,"value",f.concat(r),u),l.value.includes(":")&&!u&&this.checkMissedSemicolon(r)}doubleColon(r){throw this.input.error("Double colon",{offset:r[2]},{offset:r[2]+r[1].length})}emptyRule(r){let u=new i;this.init(u,r[2]),u.selector="",u.raws.between="",this.current=u}end(r){this.current.nodes&&this.current.nodes.length&&(this.current.raws.semicolon=this.semicolon),this.semicolon=!1,this.current.raws.after=(this.current.raws.after||"")+this.spaces,this.spaces="",this.current.parent?(this.current.source.end=this.getPosition(r[2]),this.current.source.end.offset++,this.current=this.current.parent):this.unexpectedClose(r)}endFile(){this.current.parent&&this.unclosedBlock(),this.current.nodes&&this.current.nodes.length&&(this.current.raws.semicolon=this.semicolon),this.current.raws.after=(this.current.raws.after||"")+this.spaces,this.root.source.end=this.getPosition(this.tokenizer.position())}freeSemicolon(r){if(this.spaces+=r[1],this.current.nodes){let u=this.current.nodes[this.current.nodes.length-1];u&&u.type==="rule"&&!u.raws.ownSemicolon&&(u.raws.ownSemicolon=this.spaces,this.spaces="",u.source.end=this.getPosition(r[2]),u.source.end.offset+=u.raws.ownSemicolon.length)}}getPosition(r){let u=this.input.fromOffset(r);return{column:u.col,line:u.line,offset:r}}init(r,u){this.current.push(r),r.source={input:this.input,start:this.getPosition(u)},r.raws.before=this.spaces,this.spaces="",r.type!=="comment"&&(this.semicolon=!1)}other(r){let u=!1,l=null,n=!1,p=null,f=[],g=r[1].startsWith("--"),S=[],w=r;for(;w;){if(l=w[0],S.push(w),l==="("||l==="[")p||(p=w),f.push(l==="("?")":"]");else if(g&&n&&l==="{")p||(p=w),f.push("}");else if(f.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()),u=!0;break}else l===":"&&(n=!0);else l===f[f.length-1]&&(f.pop(),f.length===0&&(p=null));w=this.tokenizer.nextToken()}if(this.tokenizer.endOfFile()&&(u=!0),f.length>0&&this.unclosedBracket(p),u&&n){if(!g)for(;S.length&&(w=S[S.length-1][0],!(w!=="space"&&w!=="comment"));)this.tokenizer.back(S.pop());this.decl(S,g)}else this.unknownWord(S)}parse(){let r;for(;!this.tokenizer.endOfFile();)switch(r=this.tokenizer.nextToken(),r[0]){case"space":this.spaces+=r[1];break;case";":this.freeSemicolon(r);break;case"}":this.end(r);break;case"comment":this.comment(r);break;case"at-word":this.atrule(r);break;case"{":this.emptyRule(r);break;default:this.other(r);break}this.endFile()}precheckMissedSemicolon(){}raw(r,u,l,n){let p,f,g=l.length,S="",w=!0,v,x;for(let y=0;y<g;y+=1)p=l[y],f=p[0],f==="space"&&y===g-1&&!n?w=!1:f==="comment"?(x=l[y-1]?l[y-1][0]:"empty",v=l[y+1]?l[y+1][0]:"empty",!c[x]&&!c[v]?S.slice(-1)===","?w=!1:S+=p[1]:w=!1):S+=p[1];if(!w){let y=l.reduce((b,C)=>b+C[1],"");r.raws[u]={raw:y,value:S}}r[u]=S}rule(r){r.pop();let u=new i;this.init(u,r[0][2]),u.raws.between=this.spacesAndCommentsFromEnd(r),this.raw(u,"selector",r),this.current=u}spacesAndCommentsFromEnd(r){let u,l="";for(;r.length&&(u=r[r.length-1][0],!(u!=="space"&&u!=="comment"));)l=r.pop()[1]+l;return l}spacesAndCommentsFromStart(r){let u,l="";for(;r.length&&(u=r[0][0],!(u!=="space"&&u!=="comment"));)l+=r.shift()[1];return l}spacesFromEnd(r){let u,l="";for(;r.length&&(u=r[r.length-1][0],u==="space");)l=r.pop()[1]+l;return l}stringFrom(r,u){let l="";for(let n=u;n<r.length;n++)l+=r[n][1];return r.splice(u,r.length-u),l}unclosedBlock(){let r=this.current.source.start;throw this.input.error("Unclosed block",r.line,r.column)}unclosedBracket(r){throw this.input.error("Unclosed bracket",{offset:r[2]},{offset:r[2]+1})}unexpectedClose(r){throw this.input.error("Unexpected }",{offset:r[2]},{offset:r[2]+1})}unknownWord(r){throw this.input.error("Unknown word "+r[0][1],{offset:r[0][2]},{offset:r[0][2]+r[0][1].length})}unnamedAtrule(r,u){throw this.input.error("At-rule without name",{offset:u[2]},{offset:u[2]+u[1].length})}}return Ht=m,Ht}var Vt,Us;function Zr(){if(Us)return Vt;Us=1;let e=Ee(),t=wt(),s=en();function o(i,a){let c=new t(i,a),d=new s(c);try{d.parse()}catch(m){throw m}return d.root}return Vt=o,o.default=o,e.registerParse(o),Vt}var Gt,Ws;function tn(){if(Ws)return Gt;Ws=1;class e{constructor(s,o={}){if(this.type="warning",this.text=s,o.node&&o.node.source){let i=o.node.rangeBy(o);this.line=i.start.line,this.column=i.start.column,this.endLine=i.end.line,this.endColumn=i.end.column}for(let i in o)this[i]=o[i]}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 Gt=e,e.default=e,Gt}var Jt,zs;function Xr(){if(zs)return Jt;zs=1;let e=tn();class t{get content(){return this.css}constructor(o,i,a){this.processor=o,this.messages=[],this.root=i,this.opts=a,this.css="",this.map=void 0}toString(){return this.css}warn(o,i={}){i.plugin||this.lastPlugin&&this.lastPlugin.postcssPlugin&&(i.plugin=this.lastPlugin.postcssPlugin);let a=new e(o,i);return this.messages.push(a),a}warnings(){return this.messages.filter(o=>o.type==="warning")}}return Jt=t,t.default=t,Jt}var Yt,qs;function rn(){if(qs)return Yt;qs=1;let e={};return Yt=function(s){e[s]||(e[s]=!0,typeof console!="undefined"&&console.warn&&console.warn(s))},Yt}var Zt,js;function sn(){if(js)return Zt;js=1;let e=Ee(),t=Jr(),s=Qi(),o=Zr(),i=Xr(),a=Ge(),c=mt(),{isClean:d,my:m}=Vr(),h=rn();const r={atrule:"AtRule",comment:"Comment",decl:"Declaration",document:"Document",root:"Root",rule:"Rule"},u={AtRule:!0,AtRuleExit:!0,Comment:!0,CommentExit:!0,Declaration:!0,DeclarationExit:!0,Document:!0,DocumentExit:!0,Once:!0,OnceExit:!0,postcssPlugin:!0,prepare:!0,Root:!0,RootExit:!0,Rule:!0,RuleExit:!0},l={Once:!0,postcssPlugin:!0,prepare:!0},n=0;function p(x){return typeof x=="object"&&typeof x.then=="function"}function f(x){let y=!1,b=r[x.type];return x.type==="decl"?y=x.prop.toLowerCase():x.type==="atrule"&&(y=x.name.toLowerCase()),y&&x.append?[b,b+"-"+y,n,b+"Exit",b+"Exit-"+y]:y?[b,b+"-"+y,b+"Exit",b+"Exit-"+y]:x.append?[b,n,b+"Exit"]:[b,b+"Exit"]}function g(x){let y;return x.type==="document"?y=["Document",n,"DocumentExit"]:x.type==="root"?y=["Root",n,"RootExit"]:y=f(x),{eventIndex:0,events:y,iterator:0,node:x,visitorIndex:0,visitors:[]}}function S(x){return x[d]=!1,x.nodes&&x.nodes.forEach(y=>S(y)),x}let w={};class v{get content(){return this.stringify().content}get css(){return this.stringify().css}get map(){return this.stringify().map}get messages(){return this.sync().messages}get opts(){return this.result.opts}get processor(){return this.result.processor}get root(){return this.sync().root}get[Symbol.toStringTag](){return"LazyResult"}constructor(y,b,C){this.stringified=!1,this.processed=!1;let R;if(typeof b=="object"&&b!==null&&(b.type==="root"||b.type==="document"))R=S(b);else if(b instanceof v||b instanceof i)R=S(b.root),b.map&&(typeof C.map=="undefined"&&(C.map={}),C.map.inline||(C.map.inline=!1),C.map.prev=b.map);else{let I=o;C.syntax&&(I=C.syntax.parse),C.parser&&(I=C.parser),I.parse&&(I=I.parse);try{R=I(b,C)}catch(O){this.processed=!0,this.error=O}R&&!R[m]&&e.rebuild(R)}this.result=new i(y,R,C),this.helpers=le(T({},w),{postcss:w,result:this.result}),this.plugins=this.processor.plugins.map(I=>typeof I=="object"&&I.prepare?T(T({},I),I.prepare(this.result)):I)}async(){return this.error?Promise.reject(this.error):this.processed?Promise.resolve(this.result):(this.processing||(this.processing=this.runAsync()),this.processing)}catch(y){return this.async().catch(y)}finally(y){return this.async().then(y,y)}getAsyncError(){throw new Error("Use process(css).then(cb) to work with async plugins")}handleError(y,b){let C=this.result.lastPlugin;try{b&&b.addToError(y),this.error=y,y.name==="CssSyntaxError"&&!y.plugin?(y.plugin=C.postcssPlugin,y.setMessage()):C.postcssVersion}catch(R){console&&console.error&&console.error(R)}return y}prepareVisitors(){this.listeners={};let y=(b,C,R)=>{this.listeners[C]||(this.listeners[C]=[]),this.listeners[C].push([b,R])};for(let b of this.plugins)if(typeof b=="object")for(let C in b){if(!u[C]&&/^[A-Z]/.test(C))throw new Error(`Unknown event ${C} in ${b.postcssPlugin}. Try to update PostCSS (${this.processor.version} now).`);if(!l[C])if(typeof b[C]=="object")for(let R in b[C])R==="*"?y(b,C,b[C][R]):y(b,C+"-"+R.toLowerCase(),b[C][R]);else typeof b[C]=="function"&&y(b,C,b[C])}this.hasListener=Object.keys(this.listeners).length>0}async runAsync(){this.plugin=0;for(let y=0;y<this.plugins.length;y++){let b=this.plugins[y],C=this.runOnRoot(b);if(p(C))try{await C}catch(R){throw this.handleError(R)}}if(this.prepareVisitors(),this.hasListener){let y=this.result.root;for(;!y[d];){y[d]=!0;let b=[g(y)];for(;b.length>0;){let C=this.visitTick(b);if(p(C))try{await C}catch(R){let I=b[b.length-1].node;throw this.handleError(R,I)}}}if(this.listeners.OnceExit)for(let[b,C]of this.listeners.OnceExit){this.result.lastPlugin=b;try{if(y.type==="document"){let R=y.nodes.map(I=>C(I,this.helpers));await Promise.all(R)}else await C(y,this.helpers)}catch(R){throw this.handleError(R)}}}return this.processed=!0,this.stringify()}runOnRoot(y){this.result.lastPlugin=y;try{if(typeof y=="object"&&y.Once){if(this.result.root.type==="document"){let b=this.result.root.nodes.map(C=>y.Once(C,this.helpers));return p(b[0])?Promise.all(b):b}return y.Once(this.result.root,this.helpers)}else if(typeof y=="function")return y(this.result.root,this.result)}catch(b){throw this.handleError(b)}}stringify(){if(this.error)throw this.error;if(this.stringified)return this.result;this.stringified=!0,this.sync();let y=this.result.opts,b=c;y.syntax&&(b=y.syntax.stringify),y.stringifier&&(b=y.stringifier),b.stringify&&(b=b.stringify);let R=new s(b,this.result.root,this.result.opts).generate();return this.result.css=R[0],this.result.map=R[1],this.result}sync(){if(this.error)throw this.error;if(this.processed)return this.result;if(this.processed=!0,this.processing)throw this.getAsyncError();for(let y of this.plugins){let b=this.runOnRoot(y);if(p(b))throw this.getAsyncError()}if(this.prepareVisitors(),this.hasListener){let y=this.result.root;for(;!y[d];)y[d]=!0,this.walkSync(y);if(this.listeners.OnceExit)if(y.type==="document")for(let b of y.nodes)this.visitSync(this.listeners.OnceExit,b);else this.visitSync(this.listeners.OnceExit,y)}return this.result}then(y,b){return this.async().then(y,b)}toString(){return this.css}visitSync(y,b){for(let[C,R]of y){this.result.lastPlugin=C;let I;try{I=R(b,this.helpers)}catch(O){throw this.handleError(O,b.proxyOf)}if(b.type!=="root"&&b.type!=="document"&&!b.parent)return!0;if(p(I))throw this.getAsyncError()}}visitTick(y){let b=y[y.length-1],{node:C,visitors:R}=b;if(C.type!=="root"&&C.type!=="document"&&!C.parent){y.pop();return}if(R.length>0&&b.visitorIndex<R.length){let[O,N]=R[b.visitorIndex];b.visitorIndex+=1,b.visitorIndex===R.length&&(b.visitors=[],b.visitorIndex=0),this.result.lastPlugin=O;try{return N(C.toProxy(),this.helpers)}catch(P){throw this.handleError(P,C)}}if(b.iterator!==0){let O=b.iterator,N;for(;N=C.nodes[C.indexes[O]];)if(C.indexes[O]+=1,!N[d]){N[d]=!0,y.push(g(N));return}b.iterator=0,delete C.indexes[O]}let I=b.events;for(;b.eventIndex<I.length;){let O=I[b.eventIndex];if(b.eventIndex+=1,O===n){C.nodes&&C.nodes.length&&(C[d]=!0,b.iterator=C.getIterator());return}else if(this.listeners[O]){b.visitors=this.listeners[O];return}}y.pop()}walkSync(y){y[d]=!0;let b=f(y);for(let C of b)if(C===n)y.nodes&&y.each(R=>{R[d]||this.walkSync(R)});else{let R=this.listeners[C];if(R&&this.visitSync(R,y.toProxy()))return}}warnings(){return this.sync().warnings()}}return v.registerPostcss=x=>{w=x},Zt=v,v.default=v,a.registerLazyResult(v),t.registerLazyResult(v),Zt}var Xt,Hs;function Vo(){if(Hs)return Xt;Hs=1;let e=Qi(),t=Zr();const s=Xr();let o=mt(),i=rn();class a{get content(){return this.result.css}get css(){return this.result.css}get map(){return this.result.map}get messages(){return[]}get opts(){return this.result.opts}get processor(){return this.result.processor}get root(){if(this._root)return this._root;let d,m=t;try{d=m(this._css,this._opts)}catch(h){this.error=h}if(this.error)throw this.error;return this._root=d,d}get[Symbol.toStringTag](){return"NoWorkResult"}constructor(d,m,h){m=m.toString(),this.stringified=!1,this._processor=d,this._css=m,this._opts=h,this._map=void 0;let r,u=o;this.result=new s(this._processor,r,this._opts),this.result.css=m;let l=this;Object.defineProperty(this.result,"root",{get(){return l.root}});let n=new e(u,r,this._opts,m);if(n.isMap()){let[p,f]=n.generate();p&&(this.result.css=p),f&&(this.result.map=f)}else n.clearAnnotation(),this.result.css=n.css}async(){return this.error?Promise.reject(this.error):Promise.resolve(this.result)}catch(d){return this.async().catch(d)}finally(d){return this.async().then(d,d)}sync(){if(this.error)throw this.error;return this.result}then(d,m){return this.async().then(d,m)}toString(){return this._css}warnings(){return[]}}return Xt=a,a.default=a,Xt}var Qt,Vs;function Go(){if(Vs)return Qt;Vs=1;let e=Jr(),t=sn(),s=Vo(),o=Ge();class i{constructor(c=[]){this.version="8.5.6",this.plugins=this.normalize(c)}normalize(c){let d=[];for(let m of c)if(m.postcss===!0?m=m():m.postcss&&(m=m.postcss),typeof m=="object"&&Array.isArray(m.plugins))d=d.concat(m.plugins);else if(typeof m=="object"&&m.postcssPlugin)d.push(m);else if(typeof m=="function")d.push(m);else if(!(typeof m=="object"&&(m.parse||m.stringify)))throw new Error(m+" is not a PostCSS plugin");return d}process(c,d={}){return!this.plugins.length&&!d.parser&&!d.stringifier&&!d.syntax?new s(this,c,d):new t(this,c,d)}use(c){return this.plugins=this.plugins.concat(this.normalize([c])),this}}return Qt=i,i.default=i,o.registerProcessor(i),e.registerProcessor(i),Qt}var Kt,Gs;function nn(){if(Gs)return Kt;Gs=1;let e=Gr(),t=Ve(),s=Ee(),o=Hr(),i=yt(),a=Jr(),c=Ho(),d=wt(),m=sn(),h=Xi(),r=gt(),u=Zr(),l=Go(),n=Xr(),p=Ge(),f=Yr(),g=mt(),S=tn();function w(...v){return v.length===1&&Array.isArray(v[0])&&(v=v[0]),new l(v)}return w.plugin=function(x,y){let b=!1;function C(...I){console&&console.warn&&!b&&(b=!0,console.warn(x+`: postcss.plugin was deprecated. Migration guide:
|
|
28
28
|
https://evilmartians.com/chronicles/postcss-8-plugin-migration`),process.env.LANG&&process.env.LANG.startsWith("cn")&&console.warn(x+`: \u91CC\u9762 postcss.plugin \u88AB\u5F03\u7528. \u8FC1\u79FB\u6307\u5357:
|
|
29
|
-
https://www.w3ctech.com/topic/2226`));let O=y(...I);return O.postcssPlugin=x,O.postcssVersion=new l().version,O}let R;return Object.defineProperty(C,"postcss",{get(){return R||(R=C()),R}}),C.process=function(I,O,N){return w([C(N)]).process(I,O)},C},w.stringify=g,w.parse=u,w.fromJSON=c,w.list=h,w.comment=v=>new t(v),w.atRule=v=>new e(v),w.decl=v=>new i(v),w.rule=v=>new f(v),w.root=v=>new p(v),w.document=v=>new a(v),w.CssSyntaxError=o,w.Declaration=i,w.Container=s,w.Processor=l,w.Document=a,w.Comment=t,w.Warning=S,w.AtRule=e,w.Result=n,w.Input=d,w.Rule=f,w.Root=p,w.Node=r,m.registerPostcss(w),
|
|
29
|
+
https://www.w3ctech.com/topic/2226`));let O=y(...I);return O.postcssPlugin=x,O.postcssVersion=new l().version,O}let R;return Object.defineProperty(C,"postcss",{get(){return R||(R=C()),R}}),C.process=function(I,O,N){return w([C(N)]).process(I,O)},C},w.stringify=g,w.parse=u,w.fromJSON=c,w.list=h,w.comment=v=>new t(v),w.atRule=v=>new e(v),w.decl=v=>new i(v),w.rule=v=>new f(v),w.root=v=>new p(v),w.document=v=>new a(v),w.CssSyntaxError=o,w.Declaration=i,w.Container=s,w.Processor=l,w.Document=a,w.Comment=t,w.Warning=S,w.AtRule=e,w.Result=n,w.Input=d,w.Rule=f,w.Root=p,w.Node=r,m.registerPostcss(w),Kt=w,w.default=w,Kt}var er,Js;function Jo(){if(Js)return er;Js=1;let e=Ve(),t=en(),s=Ki();class o extends t{checkMissedSemicolon(){}comment(a){let c=new e;this.init(c,a[2]);let d=this.input.fromOffset(a[3])||this.input.fromOffset(this.input.css.length-1);c.source.end={column:d.col,line:d.line,offset:a[3]+1};let m=a[1].slice(2);if(m.slice(-2)==="*/"&&(m=m.slice(0,-2)),/^\s*$/.test(m))c.text="",c.raws.left=m,c.raws.right="";else{let h=m.match(/^(\s*)([^]*\S)(\s*)$/);c.text=h[2],c.raws.left=h[1],c.raws.right=h[3]}}createTokenizer(){this.tokenizer=s(this.input,{ignoreErrors:!0})}decl(a){a.length>1&&a.some(c=>c[0]==="word")&&super.decl(a)}doubleColon(){}endFile(){for(this.current.nodes&&this.current.nodes.length&&(this.current.raws.semicolon=this.semicolon),this.current.raws.after=(this.current.raws.after||"")+this.spaces;this.current.parent;)this.current=this.current.parent,this.current.raws.after="";this.root.source.end=this.getPosition(this.tokenizer.position())}precheckMissedSemicolon(a){let c=this.colon(a);if(c===!1)return;let d,m;for(d=c-1;d>=0&&a[d][0]!=="word";d--);if(d===0||d<0)return;for(m=d-1;m>=0;m--)if(a[m][0]!=="space"){m+=1;break}let h=a.slice(d),r=a.slice(m,d);a.splice(m,a.length-m),this.spaces=r.map(u=>u[1]).join(""),this.decl(h)}unclosedBracket(){}unexpectedClose(){this.current.raws.after+="}"}unknownWord(a){this.spaces+=a.map(c=>c[1]).join("")}unnamedAtrule(a){a.name=""}}return er=o,er}var tr,Ys;function Yo(){if(Ys)return tr;Ys=1;let{Input:e}=nn(),t=Jo();return tr=function(o,i){let a=new e(o,i),c=new t(a);return c.parse(),c.root},tr}Yo();var Zo=nn();const G=Bo(Zo);G.stringify;G.fromJSON;G.plugin;G.parse;G.list;G.document;G.comment;G.atRule;G.rule;G.decl;G.root;G.CssSyntaxError;G.Declaration;G.Container;G.Processor;G.Document;G.Comment;G.Warning;G.AtRule;G.Result;G.Input;G.Rule;G.Root;G.Node;var Xo=Object.defineProperty,Qo=(e,t,s)=>t in e?Xo(e,t,{enumerable:!0,configurable:!0,writable:!0,value:s}):e[t]=s,ue=(e,t,s)=>Qo(e,typeof t!="symbol"?t+"":t,s);function Ko(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}function ea(e){if(Object.prototype.hasOwnProperty.call(e,"__esModule"))return e;var t=e.default;if(typeof t=="function"){var s=function o(){return this instanceof o?Reflect.construct(t,arguments,this.constructor):t.apply(this,arguments)};s.prototype=t.prototype}else s={};return Object.defineProperty(s,"__esModule",{value:!0}),Object.keys(e).forEach(function(o){var i=Object.getOwnPropertyDescriptor(e,o);Object.defineProperty(s,o,i.get?i:{enumerable:!0,get:function(){return e[o]}})}),s}var tt={exports:{}},Zs;function ta(){if(Zs)return tt.exports;Zs=1;var e=String,t=function(){return{isColorSupported:!1,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,blackBright:e,redBright:e,greenBright:e,yellowBright:e,blueBright:e,magentaBright:e,cyanBright:e,whiteBright:e,bgBlackBright:e,bgRedBright:e,bgGreenBright:e,bgYellowBright:e,bgBlueBright:e,bgMagentaBright:e,bgCyanBright:e,bgWhiteBright:e}};return tt.exports=t(),tt.exports.createColors=t,tt.exports}const ra={},sa=Object.freeze(Object.defineProperty({__proto__:null,default:ra},Symbol.toStringTag,{value:"Module"})),pe=ea(sa);var rr,Xs;function Qr(){if(Xs)return rr;Xs=1;let e=ta(),t=pe;class s extends Error{constructor(i,a,c,d,m,h){super(i),this.name="CssSyntaxError",this.reason=i,m&&(this.file=m),d&&(this.source=d),h&&(this.plugin=h),typeof a!="undefined"&&typeof c!="undefined"&&(typeof a=="number"?(this.line=a,this.column=c):(this.line=a.line,this.column=a.column,this.endLine=c.line,this.endColumn=c.column)),this.setMessage(),Error.captureStackTrace&&Error.captureStackTrace(this,s)}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(i){if(!this.source)return"";let a=this.source;i==null&&(i=e.isColorSupported);let c=n=>n,d=n=>n,m=n=>n;if(i){let{bold:n,gray:p,red:f}=e.createColors(!0);d=g=>n(f(g)),c=g=>p(g),t&&(m=g=>t(g))}let h=a.split(/\r?\n/),r=Math.max(this.line-3,0),u=Math.min(this.line+2,h.length),l=String(u).length;return h.slice(r,u).map((n,p)=>{let f=r+1+p,g=" "+(" "+f).slice(-l)+" | ";if(f===this.line){if(n.length>160){let w=20,v=Math.max(0,this.column-w),x=Math.max(this.column+w,this.endColumn+w),y=n.slice(v,x),b=c(g.replace(/\d/g," "))+n.slice(0,Math.min(this.column-1,w-1)).replace(/[^\t]/g," ");return d(">")+c(g)+m(y)+`
|
|
30
30
|
`+b+d("^")}let S=c(g.replace(/\d/g," "))+n.slice(0,this.column-1).replace(/[^\t]/g," ");return d(">")+c(g)+m(n)+`
|
|
31
31
|
`+S+d("^")}return" "+c(g)+m(n)}).join(`
|
|
32
32
|
`)}toString(){let i=this.showSourceCode();return i&&(i=`
|
|
33
33
|
|
|
34
34
|
`+i+`
|
|
35
|
-
`),this.name+": "+this.message+i}}return
|
|
35
|
+
`),this.name+": "+this.message+i}}return rr=s,s.default=s,rr}var sr,Qs;function on(){if(Qs)return sr;Qs=1;const e={after:`
|
|
36
36
|
`,beforeClose:`
|
|
37
37
|
`,beforeComment:`
|
|
38
38
|
`,beforeDecl:`
|
|
@@ -43,19 +43,19 @@ https://www.w3ctech.com/topic/2226`));let O=y(...I);return O.postcssPlugin=x,O.p
|
|
|
43
43
|
`)&&(c=c.replace(/[^\n]+$/,"")),!1}),typeof c=="undefined"?c=this.raw(a,null,"beforeDecl"):c&&(c=c.replace(/\S/g,"")),c}rawBeforeDecl(i,a){let c;return i.walkDecls(d=>{if(typeof d.raws.before!="undefined")return c=d.raws.before,c.includes(`
|
|
44
44
|
`)&&(c=c.replace(/[^\n]+$/,"")),!1}),typeof c=="undefined"?c=this.raw(a,null,"beforeRule"):c&&(c=c.replace(/\S/g,"")),c}rawBeforeOpen(i){let a;return i.walk(c=>{if(c.type!=="decl"&&(a=c.raws.between,typeof a!="undefined"))return!1}),a}rawBeforeRule(i){let a;return i.walk(c=>{if(c.nodes&&(c.parent!==i||i.first!==c)&&typeof c.raws.before!="undefined")return a=c.raws.before,a.includes(`
|
|
45
45
|
`)&&(a=a.replace(/[^\n]+$/,"")),!1}),a&&(a=a.replace(/\S/g,"")),a}rawColon(i){let a;return i.walkDecls(c=>{if(typeof c.raws.between!="undefined")return a=c.raws.between.replace(/[^\s:]/g,""),!1}),a}rawEmptyBody(i){let a;return i.walk(c=>{if(c.nodes&&c.nodes.length===0&&(a=c.raws.after,typeof a!="undefined"))return!1}),a}rawIndent(i){if(i.raws.indent)return i.raws.indent;let a;return i.walk(c=>{let d=c.parent;if(d&&d!==i&&d.parent&&d.parent===i&&typeof c.raws.before!="undefined"){let m=c.raws.before.split(`
|
|
46
|
-
`);return a=m[m.length-1],a=a.replace(/\S/g,""),!1}}),a}rawSemicolon(i){let a;return i.walk(c=>{if(c.nodes&&c.nodes.length&&c.last.type==="decl"&&(a=c.raws.semicolon,typeof a!="undefined"))return!1}),a}rawValue(i,a){let c=i[a],d=i.raws[a];return d&&d.value===c?d.raw:c}root(i){this.body(i),i.raws.after&&this.builder(i.raws.after)}rule(i){this.block(i,this.rawValue(i,"selector")),i.raws.ownSemicolon&&this.builder(i.raws.ownSemicolon,i,"end")}stringify(i,a){if(!this[i.type])throw new Error("Unknown AST node type "+i.type+". Maybe you need to change PostCSS stringifier.");this[i.type](i,a)}}return
|
|
46
|
+
`);return a=m[m.length-1],a=a.replace(/\S/g,""),!1}}),a}rawSemicolon(i){let a;return i.walk(c=>{if(c.nodes&&c.nodes.length&&c.last.type==="decl"&&(a=c.raws.semicolon,typeof a!="undefined"))return!1}),a}rawValue(i,a){let c=i[a],d=i.raws[a];return d&&d.value===c?d.raw:c}root(i){this.body(i),i.raws.after&&this.builder(i.raws.after)}rule(i){this.block(i,this.rawValue(i,"selector")),i.raws.ownSemicolon&&this.builder(i.raws.ownSemicolon,i,"end")}stringify(i,a){if(!this[i.type])throw new Error("Unknown AST node type "+i.type+". Maybe you need to change PostCSS stringifier.");this[i.type](i,a)}}return sr=s,s.default=s,sr}var ir,Ks;function bt(){if(Ks)return ir;Ks=1;let e=on();function t(s,o){new e(o).stringify(s)}return ir=t,t.default=t,ir}var rt={},ei;function Kr(){return ei||(ei=1,rt.isClean=Symbol("isClean"),rt.my=Symbol("my")),rt}var nr,ti;function St(){if(ti)return nr;ti=1;let e=Qr(),t=on(),s=bt(),{isClean:o,my:i}=Kr();function a(m,h){let r=new m.constructor;for(let u in m){if(!Object.prototype.hasOwnProperty.call(m,u)||u==="proxyCache")continue;let l=m[u],n=typeof l;u==="parent"&&n==="object"?h&&(r[u]=h):u==="source"?r[u]=l:Array.isArray(l)?r[u]=l.map(p=>a(p,r)):(n==="object"&&l!==null&&(l=a(l)),r[u]=l)}return r}function c(m,h){if(h&&typeof h.offset!="undefined")return h.offset;let r=1,u=1,l=0;for(let n=0;n<m.length;n++){if(u===h.line&&r===h.column){l=n;break}m[n]===`
|
|
47
47
|
`?(r=1,u+=1):r+=1}return l}class d{get proxyOf(){return this}constructor(h={}){this.raws={},this[o]=!1,this[i]=!0;for(let r in h)if(r==="nodes"){this.nodes=[];for(let u of h[r])typeof u.clone=="function"?this.append(u.clone()):this.append(u)}else this[r]=h[r]}addToError(h){if(h.postcssNode=this,h.stack&&this.source&&/\n\s{4}at /.test(h.stack)){let r=this.source;h.stack=h.stack.replace(/\n\s{4}at /,`$&${r.input.from}:${r.start.line}:${r.start.column}$&`)}return h}after(h){return this.parent.insertAfter(this,h),this}assign(h={}){for(let r in h)this[r]=h[r];return this}before(h){return this.parent.insertBefore(this,h),this}cleanRaws(h){delete this.raws.before,delete this.raws.after,h||delete this.raws.between}clone(h={}){let r=a(this);for(let u in h)r[u]=h[u];return r}cloneAfter(h={}){let r=this.clone(h);return this.parent.insertAfter(this,r),r}cloneBefore(h={}){let r=this.clone(h);return this.parent.insertBefore(this,r),r}error(h,r={}){if(this.source){let{end:u,start:l}=this.rangeBy(r);return this.source.input.error(h,{column:l.column,line:l.line},{column:u.column,line:u.line},r)}return new e(h)}getProxyProcessor(){return{get(h,r){return r==="proxyOf"?h:r==="root"?()=>h.root().toProxy():h[r]},set(h,r,u){return h[r]===u||(h[r]=u,(r==="prop"||r==="value"||r==="name"||r==="params"||r==="important"||r==="text")&&h.markDirty()),!0}}}markClean(){this[o]=!0}markDirty(){if(this[o]){this[o]=!1;let h=this;for(;h=h.parent;)h[o]=!1}}next(){if(!this.parent)return;let h=this.parent.index(this);return this.parent.nodes[h+1]}positionBy(h={}){let r=this.source.start;if(h.index)r=this.positionInside(h.index);else if(h.word){let u="document"in this.source.input?this.source.input.document:this.source.input.css,n=u.slice(c(u,this.source.start),c(u,this.source.end)).indexOf(h.word);n!==-1&&(r=this.positionInside(n))}return r}positionInside(h){let r=this.source.start.column,u=this.source.start.line,l="document"in this.source.input?this.source.input.document:this.source.input.css,n=c(l,this.source.start),p=n+h;for(let f=n;f<p;f++)l[f]===`
|
|
48
|
-
`?(r=1,u+=1):r+=1;return{column:r,line:u,offset:p}}prev(){if(!this.parent)return;let h=this.parent.index(this);return this.parent.nodes[h-1]}rangeBy(h={}){let r="document"in this.source.input?this.source.input.document:this.source.input.css,u={column:this.source.start.column,line:this.source.start.line,offset:c(r,this.source.start)},l=this.source.end?{column:this.source.end.column+1,line:this.source.end.line,offset:typeof this.source.end.offset=="number"?this.source.end.offset:c(r,this.source.end)+1}:{column:u.column+1,line:u.line,offset:u.offset+1};if(h.word){let p=r.slice(c(r,this.source.start),c(r,this.source.end)).indexOf(h.word);p!==-1&&(u=this.positionInside(p),l=this.positionInside(p+h.word.length))}else h.start?u={column:h.start.column,line:h.start.line,offset:c(r,h.start)}:h.index&&(u=this.positionInside(h.index)),h.end?l={column:h.end.column,line:h.end.line,offset:c(r,h.end)}:typeof h.endIndex=="number"?l=this.positionInside(h.endIndex):h.index&&(l=this.positionInside(h.index+1));return(l.line<u.line||l.line===u.line&&l.column<=u.column)&&(l={column:u.column+1,line:u.line,offset:u.offset+1}),{end:l,start:u}}raw(h,r){return new t().raw(this,h,r)}remove(){return this.parent&&this.parent.removeChild(this),this.parent=void 0,this}replaceWith(...h){if(this.parent){let r=this,u=!1;for(let l of h)l===this?u=!0:u?(this.parent.insertAfter(r,l),r=l):this.parent.insertBefore(r,l);u||this.remove()}return this}root(){let h=this;for(;h.parent&&h.parent.type!=="document";)h=h.parent;return h}toJSON(h,r){let u={},l=r==null;r=r||new Map;let n=0;for(let p in this){if(!Object.prototype.hasOwnProperty.call(this,p)||p==="parent"||p==="proxyCache")continue;let f=this[p];if(Array.isArray(f))u[p]=f.map(g=>typeof g=="object"&&g.toJSON?g.toJSON(null,r):g);else if(typeof f=="object"&&f.toJSON)u[p]=f.toJSON(null,r);else if(p==="source"){if(f==null)continue;let g=r.get(f.input);g==null&&(g=n,r.set(f.input,n),n++),u[p]={end:f.end,inputId:g,start:f.start}}else u[p]=f}return l&&(u.inputs=[...r.keys()].map(p=>p.toJSON())),u}toProxy(){return this.proxyCache||(this.proxyCache=new Proxy(this,this.getProxyProcessor())),this.proxyCache}toString(h=s){h.stringify&&(h=h.stringify);let r="";return h(this,u=>{r+=u}),r}warn(h,r,u={}){let l={node:this};for(let n in u)l[n]=u[n];return h.warn(r,l)}}return sr=d,d.default=d,sr}var ir,ei;function Ve(){if(ei)return ir;ei=1;let e=wt();class t extends e{constructor(o){super(o),this.type="comment"}}return ir=t,t.default=t,ir}var nr,ti;function bt(){if(ti)return nr;ti=1;let e=wt();class t extends e{get variable(){return this.prop.startsWith("--")||this.prop[0]==="$"}constructor(o){o&&typeof o.value!="undefined"&&typeof o.value!="string"&&(o=le(T({},o),{value:String(o.value)})),super(o),this.type="decl"}}return nr=t,t.default=t,nr}var or,ri;function Ie(){if(ri)return or;ri=1;let e=Ve(),t=bt(),s=wt(),{isClean:o,my:i}=Xr(),a,c,d,m;function h(l){return l.map(n=>(n.nodes&&(n.nodes=h(n.nodes)),delete n.source,n))}function r(l){if(l[o]=!1,l.proxyOf.nodes)for(let n of l.proxyOf.nodes)r(n)}class u extends s{get first(){if(this.proxyOf.nodes)return this.proxyOf.nodes[0]}get last(){if(this.proxyOf.nodes)return this.proxyOf.nodes[this.proxyOf.nodes.length-1]}append(...n){for(let p of n){let f=this.normalize(p,this.last);for(let g of f)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(),f,g;for(;this.indexes[p]<this.proxyOf.nodes.length&&(f=this.indexes[p],g=n(this.proxyOf.nodes[f],f),g!==!1);)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")?(...f)=>n[p](...f.map(g=>typeof g=="function"?(S,w)=>g(S.toProxy(),w):g)):p==="every"||p==="some"?f=>n[p]((g,...S)=>f(g.toProxy(),...S)):p==="root"?()=>n.root().toProxy():p==="nodes"?n.nodes.map(f=>f.toProxy()):p==="first"||p==="last"?n[p].toProxy():n[p]:n[p]},set(n,p,f){return n[p]===f||(n[p]=f,(p==="name"||p==="params"||p==="selector")&&n.markDirty()),!0}}}index(n){return typeof n=="number"?n:(n.proxyOf&&(n=n.proxyOf),this.proxyOf.nodes.indexOf(n))}insertAfter(n,p){let f=this.index(n),g=this.normalize(p,this.proxyOf.nodes[f]).reverse();f=this.index(n);for(let w of g)this.proxyOf.nodes.splice(f+1,0,w);let S;for(let w in this.indexes)S=this.indexes[w],f<S&&(this.indexes[w]=S+g.length);return this.markDirty(),this}insertBefore(n,p){let f=this.index(n),g=f===0?"prepend":!1,S=this.normalize(p,this.proxyOf.nodes[f],g).reverse();f=this.index(n);for(let v of S)this.proxyOf.nodes.splice(f,0,v);let w;for(let v in this.indexes)w=this.indexes[v],f<=w&&(this.indexes[v]=w+S.length);return this.markDirty(),this}normalize(n,p){if(typeof n=="string")n=h(c(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 t(n)]}else if(n.selector||n.selectors)n=[new m(n)];else if(n.name)n=[new a(n)];else if(n.text)n=[new e(n)];else throw new Error("Unknown node type in node creation");return n.map(g=>(g[i]||u.rebuild(g),g=g.proxyOf,g.parent&&g.parent.removeChild(g),g[o]&&r(g),g.raws||(g.raws={}),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 f=this.normalize(p,this.first,"prepend").reverse();for(let g of f)this.proxyOf.nodes.unshift(g);for(let g in this.indexes)this.indexes[g]=this.indexes[g]+f.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 f in this.indexes)p=this.indexes[f],p>=n&&(this.indexes[f]=p-1);return this.markDirty(),this}replaceValues(n,p,f){return f||(f=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,f))}),this.markDirty(),this}some(n){return this.nodes.some(n)}walk(n){return this.each((p,f)=>{let g;try{g=n(p,f)}catch(S){throw p.addToError(S)}return g!==!1&&p.walk&&(g=p.walk(n)),g})}walkAtRules(n,p){return p?n instanceof RegExp?this.walk((f,g)=>{if(f.type==="atrule"&&n.test(f.name))return p(f,g)}):this.walk((f,g)=>{if(f.type==="atrule"&&f.name===n)return p(f,g)}):(p=n,this.walk((f,g)=>{if(f.type==="atrule")return p(f,g)}))}walkComments(n){return this.walk((p,f)=>{if(p.type==="comment")return n(p,f)})}walkDecls(n,p){return p?n instanceof RegExp?this.walk((f,g)=>{if(f.type==="decl"&&n.test(f.prop))return p(f,g)}):this.walk((f,g)=>{if(f.type==="decl"&&f.prop===n)return p(f,g)}):(p=n,this.walk((f,g)=>{if(f.type==="decl")return p(f,g)}))}walkRules(n,p){return p?n instanceof RegExp?this.walk((f,g)=>{if(f.type==="rule"&&n.test(f.selector))return p(f,g)}):this.walk((f,g)=>{if(f.type==="rule"&&f.selector===n)return p(f,g)}):(p=n,this.walk((f,g)=>{if(f.type==="rule")return p(f,g)}))}}return u.registerParse=l=>{c=l},u.registerRule=l=>{m=l},u.registerAtRule=l=>{a=l},u.registerRoot=l=>{d=l},or=u,u.default=u,u.rebuild=l=>{l.type==="atrule"?Object.setPrototypeOf(l,a.prototype):l.type==="rule"?Object.setPrototypeOf(l,m.prototype):l.type==="decl"?Object.setPrototypeOf(l,t.prototype):l.type==="comment"?Object.setPrototypeOf(l,e.prototype):l.type==="root"&&Object.setPrototypeOf(l,d.prototype),l[i]=!0,l.nodes&&l.nodes.forEach(n=>{u.rebuild(n)})},or}var ar,si;function Qr(){if(si)return ar;si=1;let e=Ie();class t extends e{constructor(o){super(o),this.type="atrule"}append(...o){return this.proxyOf.nodes||(this.nodes=[]),super.append(...o)}prepend(...o){return this.proxyOf.nodes||(this.nodes=[]),super.prepend(...o)}}return ar=t,t.default=t,e.registerAtRule(t),ar}var lr,ii;function Kr(){if(ii)return lr;ii=1;let e=Ie(),t,s;class o extends e{constructor(a){super(T({type:"document"},a)),this.nodes||(this.nodes=[])}toResult(a={}){return new t(new s,this,a).stringify()}}return o.registerLazyResult=i=>{t=i},o.registerProcessor=i=>{s=i},lr=o,o.default=o,lr}var ur,ni;function ra(){if(ni)return ur;ni=1;let e="useandom-26T198340PX75pxJACKVERYMINDBUSHWOLF_GQZbfghjklqvwyzrict";return ur={nanoid:(o=21)=>{let i="",a=o|0;for(;a--;)i+=e[Math.random()*64|0];return i},customAlphabet:(o,i=21)=>(a=i)=>{let c="",d=a|0;for(;d--;)c+=o[Math.random()*o.length|0];return c}},ur}var cr,oi;function nn(){if(oi)return cr;oi=1;let{existsSync:e,readFileSync:t}=de,{dirname:s,join:o}=de,{SourceMapConsumer:i,SourceMapGenerator:a}=de;function c(m){return Buffer?Buffer.from(m,"base64").toString():window.atob(m)}class d{constructor(h,r){if(r.map===!1)return;this.loadAnnotation(h),this.inline=this.startWith(this.annotation,"data:");let u=r.map?r.map.prev:void 0,l=this.loadMap(r.from,u);!this.mapFile&&r.from&&(this.mapFile=r.from),this.mapFile&&(this.root=s(this.mapFile)),l&&(this.text=l)}consumer(){return this.consumerCache||(this.consumerCache=new i(this.text)),this.consumerCache}decodeInline(h){let r=/^data:application\/json;charset=utf-?8;base64,/,u=/^data:application\/json;base64,/,l=/^data:application\/json;charset=utf-?8,/,n=/^data:application\/json,/,p=h.match(l)||h.match(n);if(p)return decodeURIComponent(h.substr(p[0].length));let f=h.match(r)||h.match(u);if(f)return c(h.substr(f[0].length));let g=h.match(/data:application\/json;([^,]+),/)[1];throw new Error("Unsupported source map encoding "+g)}getAnnotationURL(h){return h.replace(/^\/\*\s*# sourceMappingURL=/,"").trim()}isMap(h){return typeof h!="object"?!1:typeof h.mappings=="string"||typeof h._mappings=="string"||Array.isArray(h.sections)}loadAnnotation(h){let r=h.match(/\/\*\s*# sourceMappingURL=/g);if(!r)return;let u=h.lastIndexOf(r.pop()),l=h.indexOf("*/",u);u>-1&&l>-1&&(this.annotation=this.getAnnotationURL(h.substring(u,l)))}loadFile(h){if(this.root=s(h),e(h))return this.mapFile=h,t(h,"utf-8").toString().trim()}loadMap(h,r){if(r===!1)return!1;if(r){if(typeof r=="string")return r;if(typeof r=="function"){let u=r(h);if(u){let l=this.loadFile(u);if(!l)throw new Error("Unable to load previous source map: "+u.toString());return l}}else{if(r instanceof i)return a.fromSourceMap(r).toString();if(r instanceof a)return r.toString();if(this.isMap(r))return JSON.stringify(r);throw new Error("Unsupported previous source map format: "+r.toString())}}else{if(this.inline)return this.decodeInline(this.annotation);if(this.annotation){let u=this.annotation;return h&&(u=o(s(h),u)),this.loadFile(u)}}}startWith(h,r){return h?h.substr(0,r.length)===r:!1}withContent(){return!!(this.consumer().sourcesContent&&this.consumer().sourcesContent.length>0)}}return cr=d,d.default=d,cr}var hr,ai;function St(){if(ai)return hr;ai=1;let{nanoid:e}=ra(),{isAbsolute:t,resolve:s}=de,{SourceMapConsumer:o,SourceMapGenerator:i}=de,{fileURLToPath:a,pathToFileURL:c}=de,d=Zr(),m=nn(),h=de,r=Symbol("lineToIndexCache"),u=!!(o&&i),l=!!(s&&t);function n(f){if(f[r])return f[r];let g=f.css.split(`
|
|
49
|
-
`),S=new Array(g.length),w=0;for(let v=0,x=g.length;v<x;v++)S[v]=w,w+=g[v].length+1;return f[r]=S,S}class p{get from(){return this.file||this.id}constructor(g,S={}){if(g===null||typeof g=="undefined"||typeof g=="object"&&!g.toString)throw new Error(`PostCSS received ${g} instead of CSS string`);if(this.css=g.toString(),this.css[0]==="\uFEFF"||this.css[0]==="\uFFFE"?(this.hasBOM=!0,this.css=this.css.slice(1)):this.hasBOM=!1,this.document=this.css,S.document&&(this.document=S.document.toString()),S.from&&(!l||/^\w+:\/\//.test(S.from)||t(S.from)?this.file=S.from:this.file=s(S.from)),l&&u){let w=new m(this.css,S);if(w.text){this.map=w;let v=w.consumer().file;!this.file&&v&&(this.file=this.mapResolve(v))}}this.file||(this.id="<input css "+e(6)+">"),this.map&&(this.map.file=this.from)}error(g,S,w,v={}){let x,y,b,C,R;if(S&&typeof S=="object"){let O=S,N=w;if(typeof O.offset=="number"){C=O.offset;let P=this.fromOffset(C);S=P.line,w=P.col}else S=O.line,w=O.column,C=this.fromLineAndColumn(S,w);if(typeof N.offset=="number"){b=N.offset;let P=this.fromOffset(b);y=P.line,x=P.col}else y=N.line,x=N.column,b=this.fromLineAndColumn(N.line,N.column)}else if(w)C=this.fromLineAndColumn(S,w);else{C=S;let O=this.fromOffset(C);S=O.line,w=O.col}let I=this.origin(S,w,y,x);return I?R=new d(g,I.endLine===void 0?I.line:{column:I.column,line:I.line},I.endLine===void 0?I.column:{column:I.endColumn,line:I.endLine},I.source,I.file,v.plugin):R=new d(g,y===void 0?S:{column:w,line:S},y===void 0?w:{column:x,line:y},this.css,this.file,v.plugin),R.input={column:w,endColumn:x,endLine:y,endOffset:b,line:S,offset:C,source:this.css},this.file&&(c&&(R.input.url=c(this.file).toString()),R.input.file=this.file),R}fromLineAndColumn(g,S){return n(this)[g-1]+S-1}fromOffset(g){let S=n(this),w=S[S.length-1],v=0;if(g>=w)v=S.length-1;else{let x=S.length-2,y;for(;v<x;)if(y=v+(x-v>>1),g<S[y])x=y-1;else if(g>=S[y+1])v=y+1;else{v=y;break}}return{col:g-S[v]+1,line:v+1}}mapResolve(g){return/^\w+:\/\//.test(g)?g:s(this.map.consumer().sourceRoot||this.map.root||".",g)}origin(g,S,w,v){if(!this.map)return!1;let x=this.map.consumer(),y=x.originalPositionFor({column:S,line:g});if(!y.source)return!1;let b;typeof w=="number"&&(b=x.originalPositionFor({column:v,line:w}));let C;t(y.source)?C=c(y.source):C=new URL(y.source,this.map.consumer().sourceRoot||c(this.map.mapFile));let R={column:y.column,endColumn:b&&b.column,endLine:b&&b.line,line:y.line,url:C.toString()};if(C.protocol==="file:")if(a)R.file=a(C);else throw new Error("file: protocol is not available in this PostCSS build");let I=x.sourceContentFor(y.source);return I&&(R.source=I),R}toJSON(){let g={};for(let S of["hasBOM","css","file","id"])this[S]!=null&&(g[S]=this[S]);return this.map&&(g.map=T({},this.map),g.map.consumerCache&&(g.map.consumerCache=void 0)),g}}return
|
|
50
|
-
`," "];return e.split(t,s)},split(t,s,o){let i=[],a="",c=!1,d=0,m=!1,h="",r=!1;for(let u of t)r?r=!1:u==="\\"?r=!0:m?u===h&&(m=!1):u==='"'||u==="'"?(m=!0,h=u):u==="("?d+=1:u===")"?d>0&&(d-=1):d===0&&s.includes(u)&&(c=!0),c?(a!==""&&i.push(a.trim()),a="",c=!1):a+=u;return(o||a!=="")&&i.push(a.trim()),i}};return
|
|
48
|
+
`?(r=1,u+=1):r+=1;return{column:r,line:u,offset:p}}prev(){if(!this.parent)return;let h=this.parent.index(this);return this.parent.nodes[h-1]}rangeBy(h={}){let r="document"in this.source.input?this.source.input.document:this.source.input.css,u={column:this.source.start.column,line:this.source.start.line,offset:c(r,this.source.start)},l=this.source.end?{column:this.source.end.column+1,line:this.source.end.line,offset:typeof this.source.end.offset=="number"?this.source.end.offset:c(r,this.source.end)+1}:{column:u.column+1,line:u.line,offset:u.offset+1};if(h.word){let p=r.slice(c(r,this.source.start),c(r,this.source.end)).indexOf(h.word);p!==-1&&(u=this.positionInside(p),l=this.positionInside(p+h.word.length))}else h.start?u={column:h.start.column,line:h.start.line,offset:c(r,h.start)}:h.index&&(u=this.positionInside(h.index)),h.end?l={column:h.end.column,line:h.end.line,offset:c(r,h.end)}:typeof h.endIndex=="number"?l=this.positionInside(h.endIndex):h.index&&(l=this.positionInside(h.index+1));return(l.line<u.line||l.line===u.line&&l.column<=u.column)&&(l={column:u.column+1,line:u.line,offset:u.offset+1}),{end:l,start:u}}raw(h,r){return new t().raw(this,h,r)}remove(){return this.parent&&this.parent.removeChild(this),this.parent=void 0,this}replaceWith(...h){if(this.parent){let r=this,u=!1;for(let l of h)l===this?u=!0:u?(this.parent.insertAfter(r,l),r=l):this.parent.insertBefore(r,l);u||this.remove()}return this}root(){let h=this;for(;h.parent&&h.parent.type!=="document";)h=h.parent;return h}toJSON(h,r){let u={},l=r==null;r=r||new Map;let n=0;for(let p in this){if(!Object.prototype.hasOwnProperty.call(this,p)||p==="parent"||p==="proxyCache")continue;let f=this[p];if(Array.isArray(f))u[p]=f.map(g=>typeof g=="object"&&g.toJSON?g.toJSON(null,r):g);else if(typeof f=="object"&&f.toJSON)u[p]=f.toJSON(null,r);else if(p==="source"){if(f==null)continue;let g=r.get(f.input);g==null&&(g=n,r.set(f.input,n),n++),u[p]={end:f.end,inputId:g,start:f.start}}else u[p]=f}return l&&(u.inputs=[...r.keys()].map(p=>p.toJSON())),u}toProxy(){return this.proxyCache||(this.proxyCache=new Proxy(this,this.getProxyProcessor())),this.proxyCache}toString(h=s){h.stringify&&(h=h.stringify);let r="";return h(this,u=>{r+=u}),r}warn(h,r,u={}){let l={node:this};for(let n in u)l[n]=u[n];return h.warn(r,l)}}return nr=d,d.default=d,nr}var or,ri;function Je(){if(ri)return or;ri=1;let e=St();class t extends e{constructor(o){super(o),this.type="comment"}}return or=t,t.default=t,or}var ar,si;function vt(){if(si)return ar;si=1;let e=St();class t extends e{get variable(){return this.prop.startsWith("--")||this.prop[0]==="$"}constructor(o){o&&typeof o.value!="undefined"&&typeof o.value!="string"&&(o=le(T({},o),{value:String(o.value)})),super(o),this.type="decl"}}return ar=t,t.default=t,ar}var lr,ii;function Ae(){if(ii)return lr;ii=1;let e=Je(),t=vt(),s=St(),{isClean:o,my:i}=Kr(),a,c,d,m;function h(l){return l.map(n=>(n.nodes&&(n.nodes=h(n.nodes)),delete n.source,n))}function r(l){if(l[o]=!1,l.proxyOf.nodes)for(let n of l.proxyOf.nodes)r(n)}class u extends s{get first(){if(this.proxyOf.nodes)return this.proxyOf.nodes[0]}get last(){if(this.proxyOf.nodes)return this.proxyOf.nodes[this.proxyOf.nodes.length-1]}append(...n){for(let p of n){let f=this.normalize(p,this.last);for(let g of f)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(),f,g;for(;this.indexes[p]<this.proxyOf.nodes.length&&(f=this.indexes[p],g=n(this.proxyOf.nodes[f],f),g!==!1);)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")?(...f)=>n[p](...f.map(g=>typeof g=="function"?(S,w)=>g(S.toProxy(),w):g)):p==="every"||p==="some"?f=>n[p]((g,...S)=>f(g.toProxy(),...S)):p==="root"?()=>n.root().toProxy():p==="nodes"?n.nodes.map(f=>f.toProxy()):p==="first"||p==="last"?n[p].toProxy():n[p]:n[p]},set(n,p,f){return n[p]===f||(n[p]=f,(p==="name"||p==="params"||p==="selector")&&n.markDirty()),!0}}}index(n){return typeof n=="number"?n:(n.proxyOf&&(n=n.proxyOf),this.proxyOf.nodes.indexOf(n))}insertAfter(n,p){let f=this.index(n),g=this.normalize(p,this.proxyOf.nodes[f]).reverse();f=this.index(n);for(let w of g)this.proxyOf.nodes.splice(f+1,0,w);let S;for(let w in this.indexes)S=this.indexes[w],f<S&&(this.indexes[w]=S+g.length);return this.markDirty(),this}insertBefore(n,p){let f=this.index(n),g=f===0?"prepend":!1,S=this.normalize(p,this.proxyOf.nodes[f],g).reverse();f=this.index(n);for(let v of S)this.proxyOf.nodes.splice(f,0,v);let w;for(let v in this.indexes)w=this.indexes[v],f<=w&&(this.indexes[v]=w+S.length);return this.markDirty(),this}normalize(n,p){if(typeof n=="string")n=h(c(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 t(n)]}else if(n.selector||n.selectors)n=[new m(n)];else if(n.name)n=[new a(n)];else if(n.text)n=[new e(n)];else throw new Error("Unknown node type in node creation");return n.map(g=>(g[i]||u.rebuild(g),g=g.proxyOf,g.parent&&g.parent.removeChild(g),g[o]&&r(g),g.raws||(g.raws={}),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 f=this.normalize(p,this.first,"prepend").reverse();for(let g of f)this.proxyOf.nodes.unshift(g);for(let g in this.indexes)this.indexes[g]=this.indexes[g]+f.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 f in this.indexes)p=this.indexes[f],p>=n&&(this.indexes[f]=p-1);return this.markDirty(),this}replaceValues(n,p,f){return f||(f=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,f))}),this.markDirty(),this}some(n){return this.nodes.some(n)}walk(n){return this.each((p,f)=>{let g;try{g=n(p,f)}catch(S){throw p.addToError(S)}return g!==!1&&p.walk&&(g=p.walk(n)),g})}walkAtRules(n,p){return p?n instanceof RegExp?this.walk((f,g)=>{if(f.type==="atrule"&&n.test(f.name))return p(f,g)}):this.walk((f,g)=>{if(f.type==="atrule"&&f.name===n)return p(f,g)}):(p=n,this.walk((f,g)=>{if(f.type==="atrule")return p(f,g)}))}walkComments(n){return this.walk((p,f)=>{if(p.type==="comment")return n(p,f)})}walkDecls(n,p){return p?n instanceof RegExp?this.walk((f,g)=>{if(f.type==="decl"&&n.test(f.prop))return p(f,g)}):this.walk((f,g)=>{if(f.type==="decl"&&f.prop===n)return p(f,g)}):(p=n,this.walk((f,g)=>{if(f.type==="decl")return p(f,g)}))}walkRules(n,p){return p?n instanceof RegExp?this.walk((f,g)=>{if(f.type==="rule"&&n.test(f.selector))return p(f,g)}):this.walk((f,g)=>{if(f.type==="rule"&&f.selector===n)return p(f,g)}):(p=n,this.walk((f,g)=>{if(f.type==="rule")return p(f,g)}))}}return u.registerParse=l=>{c=l},u.registerRule=l=>{m=l},u.registerAtRule=l=>{a=l},u.registerRoot=l=>{d=l},lr=u,u.default=u,u.rebuild=l=>{l.type==="atrule"?Object.setPrototypeOf(l,a.prototype):l.type==="rule"?Object.setPrototypeOf(l,m.prototype):l.type==="decl"?Object.setPrototypeOf(l,t.prototype):l.type==="comment"?Object.setPrototypeOf(l,e.prototype):l.type==="root"&&Object.setPrototypeOf(l,d.prototype),l[i]=!0,l.nodes&&l.nodes.forEach(n=>{u.rebuild(n)})},lr}var ur,ni;function es(){if(ni)return ur;ni=1;let e=Ae();class t extends e{constructor(o){super(o),this.type="atrule"}append(...o){return this.proxyOf.nodes||(this.nodes=[]),super.append(...o)}prepend(...o){return this.proxyOf.nodes||(this.nodes=[]),super.prepend(...o)}}return ur=t,t.default=t,e.registerAtRule(t),ur}var cr,oi;function ts(){if(oi)return cr;oi=1;let e=Ae(),t,s;class o extends e{constructor(a){super(T({type:"document"},a)),this.nodes||(this.nodes=[])}toResult(a={}){return new t(new s,this,a).stringify()}}return o.registerLazyResult=i=>{t=i},o.registerProcessor=i=>{s=i},cr=o,o.default=o,cr}var hr,ai;function ia(){if(ai)return hr;ai=1;let e="useandom-26T198340PX75pxJACKVERYMINDBUSHWOLF_GQZbfghjklqvwyzrict";return hr={nanoid:(o=21)=>{let i="",a=o|0;for(;a--;)i+=e[Math.random()*64|0];return i},customAlphabet:(o,i=21)=>(a=i)=>{let c="",d=a|0;for(;d--;)c+=o[Math.random()*o.length|0];return c}},hr}var fr,li;function an(){if(li)return fr;li=1;let{existsSync:e,readFileSync:t}=pe,{dirname:s,join:o}=pe,{SourceMapConsumer:i,SourceMapGenerator:a}=pe;function c(m){return Buffer?Buffer.from(m,"base64").toString():window.atob(m)}class d{constructor(h,r){if(r.map===!1)return;this.loadAnnotation(h),this.inline=this.startWith(this.annotation,"data:");let u=r.map?r.map.prev:void 0,l=this.loadMap(r.from,u);!this.mapFile&&r.from&&(this.mapFile=r.from),this.mapFile&&(this.root=s(this.mapFile)),l&&(this.text=l)}consumer(){return this.consumerCache||(this.consumerCache=new i(this.text)),this.consumerCache}decodeInline(h){let r=/^data:application\/json;charset=utf-?8;base64,/,u=/^data:application\/json;base64,/,l=/^data:application\/json;charset=utf-?8,/,n=/^data:application\/json,/,p=h.match(l)||h.match(n);if(p)return decodeURIComponent(h.substr(p[0].length));let f=h.match(r)||h.match(u);if(f)return c(h.substr(f[0].length));let g=h.match(/data:application\/json;([^,]+),/)[1];throw new Error("Unsupported source map encoding "+g)}getAnnotationURL(h){return h.replace(/^\/\*\s*# sourceMappingURL=/,"").trim()}isMap(h){return typeof h!="object"?!1:typeof h.mappings=="string"||typeof h._mappings=="string"||Array.isArray(h.sections)}loadAnnotation(h){let r=h.match(/\/\*\s*# sourceMappingURL=/g);if(!r)return;let u=h.lastIndexOf(r.pop()),l=h.indexOf("*/",u);u>-1&&l>-1&&(this.annotation=this.getAnnotationURL(h.substring(u,l)))}loadFile(h){if(this.root=s(h),e(h))return this.mapFile=h,t(h,"utf-8").toString().trim()}loadMap(h,r){if(r===!1)return!1;if(r){if(typeof r=="string")return r;if(typeof r=="function"){let u=r(h);if(u){let l=this.loadFile(u);if(!l)throw new Error("Unable to load previous source map: "+u.toString());return l}}else{if(r instanceof i)return a.fromSourceMap(r).toString();if(r instanceof a)return r.toString();if(this.isMap(r))return JSON.stringify(r);throw new Error("Unsupported previous source map format: "+r.toString())}}else{if(this.inline)return this.decodeInline(this.annotation);if(this.annotation){let u=this.annotation;return h&&(u=o(s(h),u)),this.loadFile(u)}}}startWith(h,r){return h?h.substr(0,r.length)===r:!1}withContent(){return!!(this.consumer().sourcesContent&&this.consumer().sourcesContent.length>0)}}return fr=d,d.default=d,fr}var pr,ui;function Ct(){if(ui)return pr;ui=1;let{nanoid:e}=ia(),{isAbsolute:t,resolve:s}=pe,{SourceMapConsumer:o,SourceMapGenerator:i}=pe,{fileURLToPath:a,pathToFileURL:c}=pe,d=Qr(),m=an(),h=pe,r=Symbol("lineToIndexCache"),u=!!(o&&i),l=!!(s&&t);function n(f){if(f[r])return f[r];let g=f.css.split(`
|
|
49
|
+
`),S=new Array(g.length),w=0;for(let v=0,x=g.length;v<x;v++)S[v]=w,w+=g[v].length+1;return f[r]=S,S}class p{get from(){return this.file||this.id}constructor(g,S={}){if(g===null||typeof g=="undefined"||typeof g=="object"&&!g.toString)throw new Error(`PostCSS received ${g} instead of CSS string`);if(this.css=g.toString(),this.css[0]==="\uFEFF"||this.css[0]==="\uFFFE"?(this.hasBOM=!0,this.css=this.css.slice(1)):this.hasBOM=!1,this.document=this.css,S.document&&(this.document=S.document.toString()),S.from&&(!l||/^\w+:\/\//.test(S.from)||t(S.from)?this.file=S.from:this.file=s(S.from)),l&&u){let w=new m(this.css,S);if(w.text){this.map=w;let v=w.consumer().file;!this.file&&v&&(this.file=this.mapResolve(v))}}this.file||(this.id="<input css "+e(6)+">"),this.map&&(this.map.file=this.from)}error(g,S,w,v={}){let x,y,b,C,R;if(S&&typeof S=="object"){let O=S,N=w;if(typeof O.offset=="number"){C=O.offset;let P=this.fromOffset(C);S=P.line,w=P.col}else S=O.line,w=O.column,C=this.fromLineAndColumn(S,w);if(typeof N.offset=="number"){b=N.offset;let P=this.fromOffset(b);y=P.line,x=P.col}else y=N.line,x=N.column,b=this.fromLineAndColumn(N.line,N.column)}else if(w)C=this.fromLineAndColumn(S,w);else{C=S;let O=this.fromOffset(C);S=O.line,w=O.col}let I=this.origin(S,w,y,x);return I?R=new d(g,I.endLine===void 0?I.line:{column:I.column,line:I.line},I.endLine===void 0?I.column:{column:I.endColumn,line:I.endLine},I.source,I.file,v.plugin):R=new d(g,y===void 0?S:{column:w,line:S},y===void 0?w:{column:x,line:y},this.css,this.file,v.plugin),R.input={column:w,endColumn:x,endLine:y,endOffset:b,line:S,offset:C,source:this.css},this.file&&(c&&(R.input.url=c(this.file).toString()),R.input.file=this.file),R}fromLineAndColumn(g,S){return n(this)[g-1]+S-1}fromOffset(g){let S=n(this),w=S[S.length-1],v=0;if(g>=w)v=S.length-1;else{let x=S.length-2,y;for(;v<x;)if(y=v+(x-v>>1),g<S[y])x=y-1;else if(g>=S[y+1])v=y+1;else{v=y;break}}return{col:g-S[v]+1,line:v+1}}mapResolve(g){return/^\w+:\/\//.test(g)?g:s(this.map.consumer().sourceRoot||this.map.root||".",g)}origin(g,S,w,v){if(!this.map)return!1;let x=this.map.consumer(),y=x.originalPositionFor({column:S,line:g});if(!y.source)return!1;let b;typeof w=="number"&&(b=x.originalPositionFor({column:v,line:w}));let C;t(y.source)?C=c(y.source):C=new URL(y.source,this.map.consumer().sourceRoot||c(this.map.mapFile));let R={column:y.column,endColumn:b&&b.column,endLine:b&&b.line,line:y.line,url:C.toString()};if(C.protocol==="file:")if(a)R.file=a(C);else throw new Error("file: protocol is not available in this PostCSS build");let I=x.sourceContentFor(y.source);return I&&(R.source=I),R}toJSON(){let g={};for(let S of["hasBOM","css","file","id"])this[S]!=null&&(g[S]=this[S]);return this.map&&(g.map=T({},this.map),g.map.consumerCache&&(g.map.consumerCache=void 0)),g}}return pr=p,p.default=p,h&&h.registerInput&&h.registerInput(p),pr}var dr,ci;function Ye(){if(ci)return dr;ci=1;let e=Ae(),t,s;class o extends e{constructor(a){super(a),this.type="root",this.nodes||(this.nodes=[])}normalize(a,c,d){let m=super.normalize(a);if(c){if(d==="prepend")this.nodes.length>1?c.raws.before=this.nodes[1].raws.before:delete c.raws.before;else if(this.first!==c)for(let h of m)h.raws.before=c.raws.before}return m}removeChild(a,c){let d=this.index(a);return!c&&d===0&&this.nodes.length>1&&(this.nodes[1].raws.before=this.nodes[d].raws.before),super.removeChild(a)}toResult(a={}){return new t(new s,this,a).stringify()}}return o.registerLazyResult=i=>{t=i},o.registerProcessor=i=>{s=i},dr=o,o.default=o,e.registerRoot(o),dr}var mr,hi;function ln(){if(hi)return mr;hi=1;let e={comma(t){return e.split(t,[","],!0)},space(t){let s=[" ",`
|
|
50
|
+
`," "];return e.split(t,s)},split(t,s,o){let i=[],a="",c=!1,d=0,m=!1,h="",r=!1;for(let u of t)r?r=!1:u==="\\"?r=!0:m?u===h&&(m=!1):u==='"'||u==="'"?(m=!0,h=u):u==="("?d+=1:u===")"?d>0&&(d-=1):d===0&&s.includes(u)&&(c=!0),c?(a!==""&&i.push(a.trim()),a="",c=!1):a+=u;return(o||a!=="")&&i.push(a.trim()),i}};return mr=e,e.default=e,mr}var gr,fi;function rs(){if(fi)return gr;fi=1;let e=Ae(),t=ln();class s extends e{get selectors(){return t.comma(this.selector)}set selectors(i){let a=this.selector?this.selector.match(/,\s*/):null,c=a?a[0]:","+this.raw("between","beforeOpen");this.selector=i.join(c)}constructor(i){super(i),this.type="rule",this.nodes||(this.nodes=[])}}return gr=s,s.default=s,e.registerRule(s),gr}var yr,pi;function na(){if(pi)return yr;pi=1;let e=es(),t=Je(),s=vt(),o=Ct(),i=an(),a=Ye(),c=rs();function d(m,h){if(Array.isArray(m))return m.map(p=>d(p));let l=m,{inputs:r}=l,u=_e(l,["inputs"]);if(r){h=[];for(let p of r){let f=le(T({},p),{__proto__:o.prototype});f.map&&(f.map=le(T({},f.map),{__proto__:i.prototype})),h.push(f)}}if(u.nodes&&(u.nodes=m.nodes.map(p=>d(p,h))),u.source){let n=u.source,{inputId:p}=n,f=_e(n,["inputId"]);u.source=f,p!=null&&(u.source.input=h[p])}if(u.type==="root")return new a(u);if(u.type==="decl")return new s(u);if(u.type==="rule")return new c(u);if(u.type==="comment")return new t(u);if(u.type==="atrule")return new e(u);throw new Error("Unknown node type: "+m.type)}return yr=d,d.default=d,yr}var wr,di;function un(){if(di)return wr;di=1;let{dirname:e,relative:t,resolve:s,sep:o}=pe,{SourceMapConsumer:i,SourceMapGenerator:a}=pe,{pathToFileURL:c}=pe,d=Ct(),m=!!(i&&a),h=!!(e&&s&&t&&o);class r{constructor(l,n,p,f){this.stringify=l,this.mapOpts=p.map||{},this.root=n,this.opts=p,this.css=f,this.originalCSS=f,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=`
|
|
51
51
|
`;this.css.includes(`\r
|
|
52
52
|
`)&&(n=`\r
|
|
53
53
|
`),this.css+=n+"/*# sourceMappingURL="+l+" */"}applyPrevMaps(){for(let l of this.previous()){let n=this.toUrl(this.path(l.file)),p=l.root||e(l.file),f;this.mapOpts.sourcesContent===!1?(f=new i(l.text),f.sourcesContent&&(f.sourcesContent=null)):f=l.consumer(),this.map.applySourceMap(f,n,this.toUrl(this.path(p)))}}clearAnnotation(){if(this.mapOpts.annotation!==!1)if(this.root){let l;for(let n=this.root.nodes.length-1;n>=0;n--)l=this.root.nodes[n],l.type==="comment"&&l.text.startsWith("# sourceMappingURL=")&&this.root.removeChild(n)}else this.css&&(this.css=this.css.replace(/\n*\/\*#[\S\s]*?\*\/$/gm,""))}generate(){if(this.clearAnnotation(),h&&m&&this.isMap())return this.generateMap();{let l="";return this.stringify(this.root,n=>{l+=n}),[l]}}generateMap(){if(this.root)this.generateString();else if(this.previous().length===1){let l=this.previous()[0].consumer();l.file=this.outputFile(),this.map=a.fromSourceMap(l,{ignoreInvalidMapping:!0})}else this.map=new a({file:this.outputFile(),ignoreInvalidMapping:!0}),this.map.addMapping({generated:{column:0,line:1},original:{column:0,line:1},source:this.opts.from?this.toUrl(this.path(this.opts.from)):"<no source>"});return this.isSourcesContent()&&this.setSourcesContent(),this.root&&this.previous().length>0&&this.applyPrevMaps(),this.isAnnotation()&&this.addAnnotation(),this.isInline()?[this.css]:[this.css,this.map]}generateString(){this.css="",this.map=new a({file:this.outputFile(),ignoreInvalidMapping:!0});let l=1,n=1,p="<no source>",f={generated:{column:0,line:0},original:{column:0,line:0},source:""},g,S;this.stringify(this.root,(w,v,x)=>{if(this.css+=w,v&&x!=="end"&&(f.generated.line=l,f.generated.column=n-1,v.source&&v.source.start?(f.source=this.sourcePath(v),f.original.line=v.source.start.line,f.original.column=v.source.start.column-1,this.map.addMapping(f)):(f.source=p,f.original.line=1,f.original.column=0,this.map.addMapping(f))),S=w.match(/\n/g),S?(l+=S.length,g=w.lastIndexOf(`
|
|
54
|
-
`),n=w.length-g):n+=w.length,v&&x!=="start"){let y=v.parent||{raws:{}};(!(v.type==="decl"||v.type==="atrule"&&!v.nodes)||v!==y.last||y.raws.semicolon)&&(v.source&&v.source.end?(f.source=this.sourcePath(v),f.original.line=v.source.end.line,f.original.column=v.source.end.column-1,f.generated.line=l,f.generated.column=n-2,this.map.addMapping(f)):(f.source=p,f.original.line=1,f.original.column=0,f.generated.line=l,f.generated.column=n-1,this.map.addMapping(f)))}})}isAnnotation(){return this.isInline()?!0:typeof this.mapOpts.annotation!="undefined"?this.mapOpts.annotation:this.previous().length?this.previous().some(l=>l.annotation):!0}isInline(){if(typeof this.mapOpts.inline!="undefined")return this.mapOpts.inline;let l=this.mapOpts.annotation;return typeof l!="undefined"&&l!==!0?!1:this.previous().length?this.previous().some(n=>n.inline):!0}isMap(){return typeof this.opts.map!="undefined"?!!this.opts.map:this.previous().length>0}isSourcesContent(){return typeof this.mapOpts.sourcesContent!="undefined"?this.mapOpts.sourcesContent:this.previous().length?this.previous().some(l=>l.withContent()):!0}outputFile(){return this.opts.to?this.path(this.opts.to):this.opts.from?this.path(this.opts.from):"to.css"}path(l){if(this.mapOpts.absolute||l.charCodeAt(0)===60||/^\w+:\/\//.test(l))return l;let n=this.memoizedPaths.get(l);if(n)return n;let p=this.opts.to?e(this.opts.to):".";typeof this.mapOpts.annotation=="string"&&(p=e(s(p,this.mapOpts.annotation)));let f=t(p,l);return this.memoizedPaths.set(l,f),f}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 d(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]=!0;let f=this.usesFileUrls?this.toFileUrl(p):this.toUrl(this.path(p));this.map.setSourceContent(f,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(c){let p=c(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;o==="\\"&&(l=l.replace(/\\/g,"/"));let p=encodeURI(l).replace(/[#?]/g,encodeURIComponent);return this.memoizedURLs.set(l,p),p}}return gr=r,gr}var yr,pi;function ln(){if(pi)return yr;pi=1;const e=39,t=34,s=92,o=47,i=10,a=32,c=12,d=9,m=13,h=91,r=93,u=40,l=41,n=123,p=125,f=59,g=42,S=58,w=64,v=/[\t\n\f\r "#'()/;[\\\]{}]/g,x=/[\t\n\f\r !"#'():;@[\\\]{}]|\/(?=\*)/g,y=/.[\r\n"'(/\\]/,b=/[\da-f]/i;return yr=function(R,I={}){let O=R.css.valueOf(),N=I.ignoreErrors,P,ee,D,M,ie,_,U,J,W,be,me=O.length,E=0,oe=[],ae=[];function Ae(){return E}function ge(X){throw R.error("Unclosed "+X,E)}function he(){return ae.length===0&&E>=me}function te(X){if(ae.length)return ae.pop();if(E>=me)return;let k=X?X.ignoreUnclosed:!1;switch(P=O.charCodeAt(E),P){case i:case a:case d:case m:case c:{M=E;do M+=1,P=O.charCodeAt(M);while(P===a||P===i||P===d||P===m||P===c);_=["space",O.slice(E,M)],E=M-1;break}case h:case r:case n:case p:case S:case f:case l:{let Y=String.fromCharCode(P);_=[Y,Y,E];break}case u:{if(be=oe.length?oe.pop()[1]:"",W=O.charCodeAt(E+1),be==="url"&&W!==e&&W!==t&&W!==a&&W!==i&&W!==d&&W!==c&&W!==m){M=E;do{if(U=!1,M=O.indexOf(")",M+1),M===-1)if(N||k){M=E;break}else ge("bracket");for(J=M;O.charCodeAt(J-1)===s;)J-=1,U=!U}while(U);_=["brackets",O.slice(E,M+1),E,M],E=M}else M=O.indexOf(")",E+1),ee=O.slice(E,M+1),M===-1||y.test(ee)?_=["(","(",E]:(_=["brackets",ee,E,M],E=M);break}case e:case t:{ie=P===e?"'":'"',M=E;do{if(U=!1,M=O.indexOf(ie,M+1),M===-1)if(N||k){M=E+1;break}else ge("string");for(J=M;O.charCodeAt(J-1)===s;)J-=1,U=!U}while(U);_=["string",O.slice(E,M+1),E,M],E=M;break}case w:{v.lastIndex=E+1,v.test(O),v.lastIndex===0?M=O.length-1:M=v.lastIndex-2,_=["at-word",O.slice(E,M+1),E,M],E=M;break}case s:{for(M=E,D=!0;O.charCodeAt(M+1)===s;)M+=1,D=!D;if(P=O.charCodeAt(M+1),D&&P!==o&&P!==a&&P!==i&&P!==d&&P!==m&&P!==c&&(M+=1,b.test(O.charAt(M)))){for(;b.test(O.charAt(M+1));)M+=1;O.charCodeAt(M+1)===a&&(M+=1)}_=["word",O.slice(E,M+1),E,M],E=M;break}default:{P===o&&O.charCodeAt(E+1)===g?(M=O.indexOf("*/",E+2)+1,M===0&&(N||k?M=O.length:ge("comment")),_=["comment",O.slice(E,M+1),E,M],E=M):(x.lastIndex=E+1,x.test(O),x.lastIndex===0?M=O.length-1:M=x.lastIndex-2,_=["word",O.slice(E,M+1),E,M],oe.push(_),E=M);break}}return E++,_}function Re(X){ae.push(X)}return{back:Re,endOfFile:he,nextToken:te,position:Ae}},yr}var wr,di;function un(){if(di)return wr;di=1;let e=Qr(),t=Ve(),s=bt(),o=Ge(),i=es(),a=ln();const c={empty:!0,space:!0};function d(h){for(let r=h.length-1;r>=0;r--){let u=h[r],l=u[3]||u[2];if(l)return l}}class m{constructor(r){this.input=r,this.root=new o,this.current=this.root,this.spaces="",this.semicolon=!1,this.createTokenizer(),this.root.source={input:r,start:{column:1,line:1,offset:0}}}atrule(r){let u=new e;u.name=r[1].slice(1),u.name===""&&this.unnamedAtrule(u,r),this.init(u,r[2]);let l,n,p,f=!1,g=!1,S=[],w=[];for(;!this.tokenizer.endOfFile();){if(r=this.tokenizer.nextToken(),l=r[0],l==="("||l==="["?w.push(l==="("?")":"]"):l==="{"&&w.length>0?w.push("}"):l===w[w.length-1]&&w.pop(),w.length===0)if(l===";"){u.source.end=this.getPosition(r[2]),u.source.end.offset++,this.semicolon=!0;break}else if(l==="{"){g=!0;break}else if(l==="}"){if(S.length>0){for(p=S.length-1,n=S[p];n&&n[0]==="space";)n=S[--p];n&&(u.source.end=this.getPosition(n[3]||n[2]),u.source.end.offset++)}this.end(r);break}else S.push(r);else S.push(r);if(this.tokenizer.endOfFile()){f=!0;break}}u.raws.between=this.spacesAndCommentsFromEnd(S),S.length?(u.raws.afterName=this.spacesAndCommentsFromStart(S),this.raw(u,"params",S),f&&(r=S[S.length-1],u.source.end=this.getPosition(r[3]||r[2]),u.source.end.offset++,this.spaces=u.raws.between,u.raws.between="")):(u.raws.afterName="",u.params=""),g&&(u.nodes=[],this.current=u)}checkMissedSemicolon(r){let u=this.colon(r);if(u===!1)return;let l=0,n;for(let p=u-1;p>=0&&(n=r[p],!(n[0]!=="space"&&(l+=1,l===2)));p--);throw this.input.error("Missed semicolon",n[0]==="word"?n[3]+1:n[2])}colon(r){let u=0,l,n,p;for(let[f,g]of r.entries()){if(n=g,p=n[0],p==="("&&(u+=1),p===")"&&(u-=1),u===0&&p===":")if(!l)this.doubleColon(n);else{if(l[0]==="word"&&l[1]==="progid")continue;return f}l=n}return!1}comment(r){let u=new t;this.init(u,r[2]),u.source.end=this.getPosition(r[3]||r[2]),u.source.end.offset++;let l=r[1].slice(2,-2);if(/^\s*$/.test(l))u.text="",u.raws.left=l,u.raws.right="";else{let n=l.match(/^(\s*)([^]*\S)(\s*)$/);u.text=n[2],u.raws.left=n[1],u.raws.right=n[3]}}createTokenizer(){this.tokenizer=a(this.input)}decl(r,u){let l=new s;this.init(l,r[0][2]);let n=r[r.length-1];for(n[0]===";"&&(this.semicolon=!0,r.pop()),l.source.end=this.getPosition(n[3]||n[2]||d(r)),l.source.end.offset++;r[0][0]!=="word";)r.length===1&&this.unknownWord(r),l.raws.before+=r.shift()[1];for(l.source.start=this.getPosition(r[0][2]),l.prop="";r.length;){let w=r[0][0];if(w===":"||w==="space"||w==="comment")break;l.prop+=r.shift()[1]}l.raws.between="";let p;for(;r.length;)if(p=r.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 f=[],g;for(;r.length&&(g=r[0][0],!(g!=="space"&&g!=="comment"));)f.push(r.shift());this.precheckMissedSemicolon(r);for(let w=r.length-1;w>=0;w--){if(p=r[w],p[1].toLowerCase()==="!important"){l.important=!0;let v=this.stringFrom(r,w);v=this.spacesFromEnd(r)+v,v!==" !important"&&(l.raws.important=v);break}else if(p[1].toLowerCase()==="important"){let v=r.slice(0),x="";for(let y=w;y>0;y--){let b=v[y][0];if(x.trim().startsWith("!")&&b!=="space")break;x=v.pop()[1]+x}x.trim().startsWith("!")&&(l.important=!0,l.raws.important=x,r=v)}if(p[0]!=="space"&&p[0]!=="comment")break}r.some(w=>w[0]!=="space"&&w[0]!=="comment")&&(l.raws.between+=f.map(w=>w[1]).join(""),f=[]),this.raw(l,"value",f.concat(r),u),l.value.includes(":")&&!u&&this.checkMissedSemicolon(r)}doubleColon(r){throw this.input.error("Double colon",{offset:r[2]},{offset:r[2]+r[1].length})}emptyRule(r){let u=new i;this.init(u,r[2]),u.selector="",u.raws.between="",this.current=u}end(r){this.current.nodes&&this.current.nodes.length&&(this.current.raws.semicolon=this.semicolon),this.semicolon=!1,this.current.raws.after=(this.current.raws.after||"")+this.spaces,this.spaces="",this.current.parent?(this.current.source.end=this.getPosition(r[2]),this.current.source.end.offset++,this.current=this.current.parent):this.unexpectedClose(r)}endFile(){this.current.parent&&this.unclosedBlock(),this.current.nodes&&this.current.nodes.length&&(this.current.raws.semicolon=this.semicolon),this.current.raws.after=(this.current.raws.after||"")+this.spaces,this.root.source.end=this.getPosition(this.tokenizer.position())}freeSemicolon(r){if(this.spaces+=r[1],this.current.nodes){let u=this.current.nodes[this.current.nodes.length-1];u&&u.type==="rule"&&!u.raws.ownSemicolon&&(u.raws.ownSemicolon=this.spaces,this.spaces="",u.source.end=this.getPosition(r[2]),u.source.end.offset+=u.raws.ownSemicolon.length)}}getPosition(r){let u=this.input.fromOffset(r);return{column:u.col,line:u.line,offset:r}}init(r,u){this.current.push(r),r.source={input:this.input,start:this.getPosition(u)},r.raws.before=this.spaces,this.spaces="",r.type!=="comment"&&(this.semicolon=!1)}other(r){let u=!1,l=null,n=!1,p=null,f=[],g=r[1].startsWith("--"),S=[],w=r;for(;w;){if(l=w[0],S.push(w),l==="("||l==="[")p||(p=w),f.push(l==="("?")":"]");else if(g&&n&&l==="{")p||(p=w),f.push("}");else if(f.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()),u=!0;break}else l===":"&&(n=!0);else l===f[f.length-1]&&(f.pop(),f.length===0&&(p=null));w=this.tokenizer.nextToken()}if(this.tokenizer.endOfFile()&&(u=!0),f.length>0&&this.unclosedBracket(p),u&&n){if(!g)for(;S.length&&(w=S[S.length-1][0],!(w!=="space"&&w!=="comment"));)this.tokenizer.back(S.pop());this.decl(S,g)}else this.unknownWord(S)}parse(){let r;for(;!this.tokenizer.endOfFile();)switch(r=this.tokenizer.nextToken(),r[0]){case"space":this.spaces+=r[1];break;case";":this.freeSemicolon(r);break;case"}":this.end(r);break;case"comment":this.comment(r);break;case"at-word":this.atrule(r);break;case"{":this.emptyRule(r);break;default:this.other(r);break}this.endFile()}precheckMissedSemicolon(){}raw(r,u,l,n){let p,f,g=l.length,S="",w=!0,v,x;for(let y=0;y<g;y+=1)p=l[y],f=p[0],f==="space"&&y===g-1&&!n?w=!1:f==="comment"?(x=l[y-1]?l[y-1][0]:"empty",v=l[y+1]?l[y+1][0]:"empty",!c[x]&&!c[v]?S.slice(-1)===","?w=!1:S+=p[1]:w=!1):S+=p[1];if(!w){let y=l.reduce((b,C)=>b+C[1],"");r.raws[u]={raw:y,value:S}}r[u]=S}rule(r){r.pop();let u=new i;this.init(u,r[0][2]),u.raws.between=this.spacesAndCommentsFromEnd(r),this.raw(u,"selector",r),this.current=u}spacesAndCommentsFromEnd(r){let u,l="";for(;r.length&&(u=r[r.length-1][0],!(u!=="space"&&u!=="comment"));)l=r.pop()[1]+l;return l}spacesAndCommentsFromStart(r){let u,l="";for(;r.length&&(u=r[0][0],!(u!=="space"&&u!=="comment"));)l+=r.shift()[1];return l}spacesFromEnd(r){let u,l="";for(;r.length&&(u=r[r.length-1][0],u==="space");)l=r.pop()[1]+l;return l}stringFrom(r,u){let l="";for(let n=u;n<r.length;n++)l+=r[n][1];return r.splice(u,r.length-u),l}unclosedBlock(){let r=this.current.source.start;throw this.input.error("Unclosed block",r.line,r.column)}unclosedBracket(r){throw this.input.error("Unclosed bracket",{offset:r[2]},{offset:r[2]+1})}unexpectedClose(r){throw this.input.error("Unexpected }",{offset:r[2]},{offset:r[2]+1})}unknownWord(r){throw this.input.error("Unknown word "+r[0][1],{offset:r[0][2]},{offset:r[0][2]+r[0][1].length})}unnamedAtrule(r,u){throw this.input.error("At-rule without name",{offset:u[2]},{offset:u[2]+u[1].length})}}return wr=m,wr}var br,mi;function ts(){if(mi)return br;mi=1;let e=Ie(),t=St(),s=un();function o(i,a){let c=new t(i,a),d=new s(c);try{d.parse()}catch(m){throw m}return d.root}return br=o,o.default=o,e.registerParse(o),br}var Sr,gi;function cn(){if(gi)return Sr;gi=1;class e{constructor(s,o={}){if(this.type="warning",this.text=s,o.node&&o.node.source){let i=o.node.rangeBy(o);this.line=i.start.line,this.column=i.start.column,this.endLine=i.end.line,this.endColumn=i.end.column}for(let i in o)this[i]=o[i]}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 Sr=e,e.default=e,Sr}var vr,yi;function rs(){if(yi)return vr;yi=1;let e=cn();class t{get content(){return this.css}constructor(o,i,a){this.processor=o,this.messages=[],this.root=i,this.opts=a,this.css="",this.map=void 0}toString(){return this.css}warn(o,i={}){i.plugin||this.lastPlugin&&this.lastPlugin.postcssPlugin&&(i.plugin=this.lastPlugin.postcssPlugin);let a=new e(o,i);return this.messages.push(a),a}warnings(){return this.messages.filter(o=>o.type==="warning")}}return vr=t,t.default=t,vr}var Cr,wi;function hn(){if(wi)return Cr;wi=1;let e={};return Cr=function(s){e[s]||(e[s]=!0,typeof console!="undefined"&&console.warn&&console.warn(s))},Cr}var xr,bi;function fn(){if(bi)return xr;bi=1;let e=Ie(),t=Kr(),s=an(),o=ts(),i=rs(),a=Ge(),c=yt(),{isClean:d,my:m}=Xr(),h=hn();const r={atrule:"AtRule",comment:"Comment",decl:"Declaration",document:"Document",root:"Root",rule:"Rule"},u={AtRule:!0,AtRuleExit:!0,Comment:!0,CommentExit:!0,Declaration:!0,DeclarationExit:!0,Document:!0,DocumentExit:!0,Once:!0,OnceExit:!0,postcssPlugin:!0,prepare:!0,Root:!0,RootExit:!0,Rule:!0,RuleExit:!0},l={Once:!0,postcssPlugin:!0,prepare:!0},n=0;function p(x){return typeof x=="object"&&typeof x.then=="function"}function f(x){let y=!1,b=r[x.type];return x.type==="decl"?y=x.prop.toLowerCase():x.type==="atrule"&&(y=x.name.toLowerCase()),y&&x.append?[b,b+"-"+y,n,b+"Exit",b+"Exit-"+y]:y?[b,b+"-"+y,b+"Exit",b+"Exit-"+y]:x.append?[b,n,b+"Exit"]:[b,b+"Exit"]}function g(x){let y;return x.type==="document"?y=["Document",n,"DocumentExit"]:x.type==="root"?y=["Root",n,"RootExit"]:y=f(x),{eventIndex:0,events:y,iterator:0,node:x,visitorIndex:0,visitors:[]}}function S(x){return x[d]=!1,x.nodes&&x.nodes.forEach(y=>S(y)),x}let w={};class v{get content(){return this.stringify().content}get css(){return this.stringify().css}get map(){return this.stringify().map}get messages(){return this.sync().messages}get opts(){return this.result.opts}get processor(){return this.result.processor}get root(){return this.sync().root}get[Symbol.toStringTag](){return"LazyResult"}constructor(y,b,C){this.stringified=!1,this.processed=!1;let R;if(typeof b=="object"&&b!==null&&(b.type==="root"||b.type==="document"))R=S(b);else if(b instanceof v||b instanceof i)R=S(b.root),b.map&&(typeof C.map=="undefined"&&(C.map={}),C.map.inline||(C.map.inline=!1),C.map.prev=b.map);else{let I=o;C.syntax&&(I=C.syntax.parse),C.parser&&(I=C.parser),I.parse&&(I=I.parse);try{R=I(b,C)}catch(O){this.processed=!0,this.error=O}R&&!R[m]&&e.rebuild(R)}this.result=new i(y,R,C),this.helpers=le(T({},w),{postcss:w,result:this.result}),this.plugins=this.processor.plugins.map(I=>typeof I=="object"&&I.prepare?T(T({},I),I.prepare(this.result)):I)}async(){return this.error?Promise.reject(this.error):this.processed?Promise.resolve(this.result):(this.processing||(this.processing=this.runAsync()),this.processing)}catch(y){return this.async().catch(y)}finally(y){return this.async().then(y,y)}getAsyncError(){throw new Error("Use process(css).then(cb) to work with async plugins")}handleError(y,b){let C=this.result.lastPlugin;try{b&&b.addToError(y),this.error=y,y.name==="CssSyntaxError"&&!y.plugin?(y.plugin=C.postcssPlugin,y.setMessage()):C.postcssVersion}catch(R){console&&console.error&&console.error(R)}return y}prepareVisitors(){this.listeners={};let y=(b,C,R)=>{this.listeners[C]||(this.listeners[C]=[]),this.listeners[C].push([b,R])};for(let b of this.plugins)if(typeof b=="object")for(let C in b){if(!u[C]&&/^[A-Z]/.test(C))throw new Error(`Unknown event ${C} in ${b.postcssPlugin}. Try to update PostCSS (${this.processor.version} now).`);if(!l[C])if(typeof b[C]=="object")for(let R in b[C])R==="*"?y(b,C,b[C][R]):y(b,C+"-"+R.toLowerCase(),b[C][R]);else typeof b[C]=="function"&&y(b,C,b[C])}this.hasListener=Object.keys(this.listeners).length>0}async runAsync(){this.plugin=0;for(let y=0;y<this.plugins.length;y++){let b=this.plugins[y],C=this.runOnRoot(b);if(p(C))try{await C}catch(R){throw this.handleError(R)}}if(this.prepareVisitors(),this.hasListener){let y=this.result.root;for(;!y[d];){y[d]=!0;let b=[g(y)];for(;b.length>0;){let C=this.visitTick(b);if(p(C))try{await C}catch(R){let I=b[b.length-1].node;throw this.handleError(R,I)}}}if(this.listeners.OnceExit)for(let[b,C]of this.listeners.OnceExit){this.result.lastPlugin=b;try{if(y.type==="document"){let R=y.nodes.map(I=>C(I,this.helpers));await Promise.all(R)}else await C(y,this.helpers)}catch(R){throw this.handleError(R)}}}return this.processed=!0,this.stringify()}runOnRoot(y){this.result.lastPlugin=y;try{if(typeof y=="object"&&y.Once){if(this.result.root.type==="document"){let b=this.result.root.nodes.map(C=>y.Once(C,this.helpers));return p(b[0])?Promise.all(b):b}return y.Once(this.result.root,this.helpers)}else if(typeof y=="function")return y(this.result.root,this.result)}catch(b){throw this.handleError(b)}}stringify(){if(this.error)throw this.error;if(this.stringified)return this.result;this.stringified=!0,this.sync();let y=this.result.opts,b=c;y.syntax&&(b=y.syntax.stringify),y.stringifier&&(b=y.stringifier),b.stringify&&(b=b.stringify);let R=new s(b,this.result.root,this.result.opts).generate();return this.result.css=R[0],this.result.map=R[1],this.result}sync(){if(this.error)throw this.error;if(this.processed)return this.result;if(this.processed=!0,this.processing)throw this.getAsyncError();for(let y of this.plugins){let b=this.runOnRoot(y);if(p(b))throw this.getAsyncError()}if(this.prepareVisitors(),this.hasListener){let y=this.result.root;for(;!y[d];)y[d]=!0,this.walkSync(y);if(this.listeners.OnceExit)if(y.type==="document")for(let b of y.nodes)this.visitSync(this.listeners.OnceExit,b);else this.visitSync(this.listeners.OnceExit,y)}return this.result}then(y,b){return this.async().then(y,b)}toString(){return this.css}visitSync(y,b){for(let[C,R]of y){this.result.lastPlugin=C;let I;try{I=R(b,this.helpers)}catch(O){throw this.handleError(O,b.proxyOf)}if(b.type!=="root"&&b.type!=="document"&&!b.parent)return!0;if(p(I))throw this.getAsyncError()}}visitTick(y){let b=y[y.length-1],{node:C,visitors:R}=b;if(C.type!=="root"&&C.type!=="document"&&!C.parent){y.pop();return}if(R.length>0&&b.visitorIndex<R.length){let[O,N]=R[b.visitorIndex];b.visitorIndex+=1,b.visitorIndex===R.length&&(b.visitors=[],b.visitorIndex=0),this.result.lastPlugin=O;try{return N(C.toProxy(),this.helpers)}catch(P){throw this.handleError(P,C)}}if(b.iterator!==0){let O=b.iterator,N;for(;N=C.nodes[C.indexes[O]];)if(C.indexes[O]+=1,!N[d]){N[d]=!0,y.push(g(N));return}b.iterator=0,delete C.indexes[O]}let I=b.events;for(;b.eventIndex<I.length;){let O=I[b.eventIndex];if(b.eventIndex+=1,O===n){C.nodes&&C.nodes.length&&(C[d]=!0,b.iterator=C.getIterator());return}else if(this.listeners[O]){b.visitors=this.listeners[O];return}}y.pop()}walkSync(y){y[d]=!0;let b=f(y);for(let C of b)if(C===n)y.nodes&&y.each(R=>{R[d]||this.walkSync(R)});else{let R=this.listeners[C];if(R&&this.visitSync(R,y.toProxy()))return}}warnings(){return this.sync().warnings()}}return v.registerPostcss=x=>{w=x},xr=v,v.default=v,a.registerLazyResult(v),t.registerLazyResult(v),xr}var Rr,Si;function ia(){if(Si)return Rr;Si=1;let e=an(),t=ts();const s=rs();let o=yt(),i=hn();class a{get content(){return this.result.css}get css(){return this.result.css}get map(){return this.result.map}get messages(){return[]}get opts(){return this.result.opts}get processor(){return this.result.processor}get root(){if(this._root)return this._root;let d,m=t;try{d=m(this._css,this._opts)}catch(h){this.error=h}if(this.error)throw this.error;return this._root=d,d}get[Symbol.toStringTag](){return"NoWorkResult"}constructor(d,m,h){m=m.toString(),this.stringified=!1,this._processor=d,this._css=m,this._opts=h,this._map=void 0;let r,u=o;this.result=new s(this._processor,r,this._opts),this.result.css=m;let l=this;Object.defineProperty(this.result,"root",{get(){return l.root}});let n=new e(u,r,this._opts,m);if(n.isMap()){let[p,f]=n.generate();p&&(this.result.css=p),f&&(this.result.map=f)}else n.clearAnnotation(),this.result.css=n.css}async(){return this.error?Promise.reject(this.error):Promise.resolve(this.result)}catch(d){return this.async().catch(d)}finally(d){return this.async().then(d,d)}sync(){if(this.error)throw this.error;return this.result}then(d,m){return this.async().then(d,m)}toString(){return this._css}warnings(){return[]}}return Rr=a,a.default=a,Rr}var Or,vi;function na(){if(vi)return Or;vi=1;let e=Kr(),t=fn(),s=ia(),o=Ge();class i{constructor(c=[]){this.version="8.5.6",this.plugins=this.normalize(c)}normalize(c){let d=[];for(let m of c)if(m.postcss===!0?m=m():m.postcss&&(m=m.postcss),typeof m=="object"&&Array.isArray(m.plugins))d=d.concat(m.plugins);else if(typeof m=="object"&&m.postcssPlugin)d.push(m);else if(typeof m=="function")d.push(m);else if(!(typeof m=="object"&&(m.parse||m.stringify)))throw new Error(m+" is not a PostCSS plugin");return d}process(c,d={}){return!this.plugins.length&&!d.parser&&!d.stringifier&&!d.syntax?new s(this,c,d):new t(this,c,d)}use(c){return this.plugins=this.plugins.concat(this.normalize([c])),this}}return Or=i,i.default=i,o.registerProcessor(i),e.registerProcessor(i),Or}var Mr,Ci;function pn(){if(Ci)return Mr;Ci=1;let e=Qr(),t=Ve(),s=Ie(),o=Zr(),i=bt(),a=Kr(),c=sa(),d=St(),m=fn(),h=on(),r=wt(),u=ts(),l=na(),n=rs(),p=Ge(),f=es(),g=yt(),S=cn();function w(...v){return v.length===1&&Array.isArray(v[0])&&(v=v[0]),new l(v)}return w.plugin=function(x,y){let b=!1;function C(...I){console&&console.warn&&!b&&(b=!0,console.warn(x+`: postcss.plugin was deprecated. Migration guide:
|
|
54
|
+
`),n=w.length-g):n+=w.length,v&&x!=="start"){let y=v.parent||{raws:{}};(!(v.type==="decl"||v.type==="atrule"&&!v.nodes)||v!==y.last||y.raws.semicolon)&&(v.source&&v.source.end?(f.source=this.sourcePath(v),f.original.line=v.source.end.line,f.original.column=v.source.end.column-1,f.generated.line=l,f.generated.column=n-2,this.map.addMapping(f)):(f.source=p,f.original.line=1,f.original.column=0,f.generated.line=l,f.generated.column=n-1,this.map.addMapping(f)))}})}isAnnotation(){return this.isInline()?!0:typeof this.mapOpts.annotation!="undefined"?this.mapOpts.annotation:this.previous().length?this.previous().some(l=>l.annotation):!0}isInline(){if(typeof this.mapOpts.inline!="undefined")return this.mapOpts.inline;let l=this.mapOpts.annotation;return typeof l!="undefined"&&l!==!0?!1:this.previous().length?this.previous().some(n=>n.inline):!0}isMap(){return typeof this.opts.map!="undefined"?!!this.opts.map:this.previous().length>0}isSourcesContent(){return typeof this.mapOpts.sourcesContent!="undefined"?this.mapOpts.sourcesContent:this.previous().length?this.previous().some(l=>l.withContent()):!0}outputFile(){return this.opts.to?this.path(this.opts.to):this.opts.from?this.path(this.opts.from):"to.css"}path(l){if(this.mapOpts.absolute||l.charCodeAt(0)===60||/^\w+:\/\//.test(l))return l;let n=this.memoizedPaths.get(l);if(n)return n;let p=this.opts.to?e(this.opts.to):".";typeof this.mapOpts.annotation=="string"&&(p=e(s(p,this.mapOpts.annotation)));let f=t(p,l);return this.memoizedPaths.set(l,f),f}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 d(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]=!0;let f=this.usesFileUrls?this.toFileUrl(p):this.toUrl(this.path(p));this.map.setSourceContent(f,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(c){let p=c(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;o==="\\"&&(l=l.replace(/\\/g,"/"));let p=encodeURI(l).replace(/[#?]/g,encodeURIComponent);return this.memoizedURLs.set(l,p),p}}return wr=r,wr}var br,mi;function cn(){if(mi)return br;mi=1;const e=39,t=34,s=92,o=47,i=10,a=32,c=12,d=9,m=13,h=91,r=93,u=40,l=41,n=123,p=125,f=59,g=42,S=58,w=64,v=/[\t\n\f\r "#'()/;[\\\]{}]/g,x=/[\t\n\f\r !"#'():;@[\\\]{}]|\/(?=\*)/g,y=/.[\r\n"'(/\\]/,b=/[\da-f]/i;return br=function(R,I={}){let O=R.css.valueOf(),N=I.ignoreErrors,P,ee,D,M,se,_,W,Z,z,ve,ye=O.length,E=0,we=[],oe=[];function Ce(){return E}function de(H){throw R.error("Unclosed "+H,E)}function Ne(){return oe.length===0&&E>=ye}function Ue(H){if(oe.length)return oe.pop();if(E>=ye)return;let he=H?H.ignoreUnclosed:!1;switch(P=O.charCodeAt(E),P){case i:case a:case d:case m:case c:{M=E;do M+=1,P=O.charCodeAt(M);while(P===a||P===i||P===d||P===m||P===c);_=["space",O.slice(E,M)],E=M-1;break}case h:case r:case n:case p:case S:case f:case l:{let me=String.fromCharCode(P);_=[me,me,E];break}case u:{if(ve=we.length?we.pop()[1]:"",z=O.charCodeAt(E+1),ve==="url"&&z!==e&&z!==t&&z!==a&&z!==i&&z!==d&&z!==c&&z!==m){M=E;do{if(W=!1,M=O.indexOf(")",M+1),M===-1)if(N||he){M=E;break}else de("bracket");for(Z=M;O.charCodeAt(Z-1)===s;)Z-=1,W=!W}while(W);_=["brackets",O.slice(E,M+1),E,M],E=M}else M=O.indexOf(")",E+1),ee=O.slice(E,M+1),M===-1||y.test(ee)?_=["(","(",E]:(_=["brackets",ee,E,M],E=M);break}case e:case t:{se=P===e?"'":'"',M=E;do{if(W=!1,M=O.indexOf(se,M+1),M===-1)if(N||he){M=E+1;break}else de("string");for(Z=M;O.charCodeAt(Z-1)===s;)Z-=1,W=!W}while(W);_=["string",O.slice(E,M+1),E,M],E=M;break}case w:{v.lastIndex=E+1,v.test(O),v.lastIndex===0?M=O.length-1:M=v.lastIndex-2,_=["at-word",O.slice(E,M+1),E,M],E=M;break}case s:{for(M=E,D=!0;O.charCodeAt(M+1)===s;)M+=1,D=!D;if(P=O.charCodeAt(M+1),D&&P!==o&&P!==a&&P!==i&&P!==d&&P!==m&&P!==c&&(M+=1,b.test(O.charAt(M)))){for(;b.test(O.charAt(M+1));)M+=1;O.charCodeAt(M+1)===a&&(M+=1)}_=["word",O.slice(E,M+1),E,M],E=M;break}default:{P===o&&O.charCodeAt(E+1)===g?(M=O.indexOf("*/",E+2)+1,M===0&&(N||he?M=O.length:de("comment")),_=["comment",O.slice(E,M+1),E,M],E=M):(x.lastIndex=E+1,x.test(O),x.lastIndex===0?M=O.length-1:M=x.lastIndex-2,_=["word",O.slice(E,M+1),E,M],we.push(_),E=M);break}}return E++,_}function ce(H){oe.push(H)}return{back:ce,endOfFile:Ne,nextToken:Ue,position:Ce}},br}var Sr,gi;function hn(){if(gi)return Sr;gi=1;let e=es(),t=Je(),s=vt(),o=Ye(),i=rs(),a=cn();const c={empty:!0,space:!0};function d(h){for(let r=h.length-1;r>=0;r--){let u=h[r],l=u[3]||u[2];if(l)return l}}class m{constructor(r){this.input=r,this.root=new o,this.current=this.root,this.spaces="",this.semicolon=!1,this.createTokenizer(),this.root.source={input:r,start:{column:1,line:1,offset:0}}}atrule(r){let u=new e;u.name=r[1].slice(1),u.name===""&&this.unnamedAtrule(u,r),this.init(u,r[2]);let l,n,p,f=!1,g=!1,S=[],w=[];for(;!this.tokenizer.endOfFile();){if(r=this.tokenizer.nextToken(),l=r[0],l==="("||l==="["?w.push(l==="("?")":"]"):l==="{"&&w.length>0?w.push("}"):l===w[w.length-1]&&w.pop(),w.length===0)if(l===";"){u.source.end=this.getPosition(r[2]),u.source.end.offset++,this.semicolon=!0;break}else if(l==="{"){g=!0;break}else if(l==="}"){if(S.length>0){for(p=S.length-1,n=S[p];n&&n[0]==="space";)n=S[--p];n&&(u.source.end=this.getPosition(n[3]||n[2]),u.source.end.offset++)}this.end(r);break}else S.push(r);else S.push(r);if(this.tokenizer.endOfFile()){f=!0;break}}u.raws.between=this.spacesAndCommentsFromEnd(S),S.length?(u.raws.afterName=this.spacesAndCommentsFromStart(S),this.raw(u,"params",S),f&&(r=S[S.length-1],u.source.end=this.getPosition(r[3]||r[2]),u.source.end.offset++,this.spaces=u.raws.between,u.raws.between="")):(u.raws.afterName="",u.params=""),g&&(u.nodes=[],this.current=u)}checkMissedSemicolon(r){let u=this.colon(r);if(u===!1)return;let l=0,n;for(let p=u-1;p>=0&&(n=r[p],!(n[0]!=="space"&&(l+=1,l===2)));p--);throw this.input.error("Missed semicolon",n[0]==="word"?n[3]+1:n[2])}colon(r){let u=0,l,n,p;for(let[f,g]of r.entries()){if(n=g,p=n[0],p==="("&&(u+=1),p===")"&&(u-=1),u===0&&p===":")if(!l)this.doubleColon(n);else{if(l[0]==="word"&&l[1]==="progid")continue;return f}l=n}return!1}comment(r){let u=new t;this.init(u,r[2]),u.source.end=this.getPosition(r[3]||r[2]),u.source.end.offset++;let l=r[1].slice(2,-2);if(/^\s*$/.test(l))u.text="",u.raws.left=l,u.raws.right="";else{let n=l.match(/^(\s*)([^]*\S)(\s*)$/);u.text=n[2],u.raws.left=n[1],u.raws.right=n[3]}}createTokenizer(){this.tokenizer=a(this.input)}decl(r,u){let l=new s;this.init(l,r[0][2]);let n=r[r.length-1];for(n[0]===";"&&(this.semicolon=!0,r.pop()),l.source.end=this.getPosition(n[3]||n[2]||d(r)),l.source.end.offset++;r[0][0]!=="word";)r.length===1&&this.unknownWord(r),l.raws.before+=r.shift()[1];for(l.source.start=this.getPosition(r[0][2]),l.prop="";r.length;){let w=r[0][0];if(w===":"||w==="space"||w==="comment")break;l.prop+=r.shift()[1]}l.raws.between="";let p;for(;r.length;)if(p=r.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 f=[],g;for(;r.length&&(g=r[0][0],!(g!=="space"&&g!=="comment"));)f.push(r.shift());this.precheckMissedSemicolon(r);for(let w=r.length-1;w>=0;w--){if(p=r[w],p[1].toLowerCase()==="!important"){l.important=!0;let v=this.stringFrom(r,w);v=this.spacesFromEnd(r)+v,v!==" !important"&&(l.raws.important=v);break}else if(p[1].toLowerCase()==="important"){let v=r.slice(0),x="";for(let y=w;y>0;y--){let b=v[y][0];if(x.trim().startsWith("!")&&b!=="space")break;x=v.pop()[1]+x}x.trim().startsWith("!")&&(l.important=!0,l.raws.important=x,r=v)}if(p[0]!=="space"&&p[0]!=="comment")break}r.some(w=>w[0]!=="space"&&w[0]!=="comment")&&(l.raws.between+=f.map(w=>w[1]).join(""),f=[]),this.raw(l,"value",f.concat(r),u),l.value.includes(":")&&!u&&this.checkMissedSemicolon(r)}doubleColon(r){throw this.input.error("Double colon",{offset:r[2]},{offset:r[2]+r[1].length})}emptyRule(r){let u=new i;this.init(u,r[2]),u.selector="",u.raws.between="",this.current=u}end(r){this.current.nodes&&this.current.nodes.length&&(this.current.raws.semicolon=this.semicolon),this.semicolon=!1,this.current.raws.after=(this.current.raws.after||"")+this.spaces,this.spaces="",this.current.parent?(this.current.source.end=this.getPosition(r[2]),this.current.source.end.offset++,this.current=this.current.parent):this.unexpectedClose(r)}endFile(){this.current.parent&&this.unclosedBlock(),this.current.nodes&&this.current.nodes.length&&(this.current.raws.semicolon=this.semicolon),this.current.raws.after=(this.current.raws.after||"")+this.spaces,this.root.source.end=this.getPosition(this.tokenizer.position())}freeSemicolon(r){if(this.spaces+=r[1],this.current.nodes){let u=this.current.nodes[this.current.nodes.length-1];u&&u.type==="rule"&&!u.raws.ownSemicolon&&(u.raws.ownSemicolon=this.spaces,this.spaces="",u.source.end=this.getPosition(r[2]),u.source.end.offset+=u.raws.ownSemicolon.length)}}getPosition(r){let u=this.input.fromOffset(r);return{column:u.col,line:u.line,offset:r}}init(r,u){this.current.push(r),r.source={input:this.input,start:this.getPosition(u)},r.raws.before=this.spaces,this.spaces="",r.type!=="comment"&&(this.semicolon=!1)}other(r){let u=!1,l=null,n=!1,p=null,f=[],g=r[1].startsWith("--"),S=[],w=r;for(;w;){if(l=w[0],S.push(w),l==="("||l==="[")p||(p=w),f.push(l==="("?")":"]");else if(g&&n&&l==="{")p||(p=w),f.push("}");else if(f.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()),u=!0;break}else l===":"&&(n=!0);else l===f[f.length-1]&&(f.pop(),f.length===0&&(p=null));w=this.tokenizer.nextToken()}if(this.tokenizer.endOfFile()&&(u=!0),f.length>0&&this.unclosedBracket(p),u&&n){if(!g)for(;S.length&&(w=S[S.length-1][0],!(w!=="space"&&w!=="comment"));)this.tokenizer.back(S.pop());this.decl(S,g)}else this.unknownWord(S)}parse(){let r;for(;!this.tokenizer.endOfFile();)switch(r=this.tokenizer.nextToken(),r[0]){case"space":this.spaces+=r[1];break;case";":this.freeSemicolon(r);break;case"}":this.end(r);break;case"comment":this.comment(r);break;case"at-word":this.atrule(r);break;case"{":this.emptyRule(r);break;default:this.other(r);break}this.endFile()}precheckMissedSemicolon(){}raw(r,u,l,n){let p,f,g=l.length,S="",w=!0,v,x;for(let y=0;y<g;y+=1)p=l[y],f=p[0],f==="space"&&y===g-1&&!n?w=!1:f==="comment"?(x=l[y-1]?l[y-1][0]:"empty",v=l[y+1]?l[y+1][0]:"empty",!c[x]&&!c[v]?S.slice(-1)===","?w=!1:S+=p[1]:w=!1):S+=p[1];if(!w){let y=l.reduce((b,C)=>b+C[1],"");r.raws[u]={raw:y,value:S}}r[u]=S}rule(r){r.pop();let u=new i;this.init(u,r[0][2]),u.raws.between=this.spacesAndCommentsFromEnd(r),this.raw(u,"selector",r),this.current=u}spacesAndCommentsFromEnd(r){let u,l="";for(;r.length&&(u=r[r.length-1][0],!(u!=="space"&&u!=="comment"));)l=r.pop()[1]+l;return l}spacesAndCommentsFromStart(r){let u,l="";for(;r.length&&(u=r[0][0],!(u!=="space"&&u!=="comment"));)l+=r.shift()[1];return l}spacesFromEnd(r){let u,l="";for(;r.length&&(u=r[r.length-1][0],u==="space");)l=r.pop()[1]+l;return l}stringFrom(r,u){let l="";for(let n=u;n<r.length;n++)l+=r[n][1];return r.splice(u,r.length-u),l}unclosedBlock(){let r=this.current.source.start;throw this.input.error("Unclosed block",r.line,r.column)}unclosedBracket(r){throw this.input.error("Unclosed bracket",{offset:r[2]},{offset:r[2]+1})}unexpectedClose(r){throw this.input.error("Unexpected }",{offset:r[2]},{offset:r[2]+1})}unknownWord(r){throw this.input.error("Unknown word "+r[0][1],{offset:r[0][2]},{offset:r[0][2]+r[0][1].length})}unnamedAtrule(r,u){throw this.input.error("At-rule without name",{offset:u[2]},{offset:u[2]+u[1].length})}}return Sr=m,Sr}var vr,yi;function ss(){if(yi)return vr;yi=1;let e=Ae(),t=Ct(),s=hn();function o(i,a){let c=new t(i,a),d=new s(c);try{d.parse()}catch(m){throw m}return d.root}return vr=o,o.default=o,e.registerParse(o),vr}var Cr,wi;function fn(){if(wi)return Cr;wi=1;class e{constructor(s,o={}){if(this.type="warning",this.text=s,o.node&&o.node.source){let i=o.node.rangeBy(o);this.line=i.start.line,this.column=i.start.column,this.endLine=i.end.line,this.endColumn=i.end.column}for(let i in o)this[i]=o[i]}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 xr,bi;function is(){if(bi)return xr;bi=1;let e=fn();class t{get content(){return this.css}constructor(o,i,a){this.processor=o,this.messages=[],this.root=i,this.opts=a,this.css="",this.map=void 0}toString(){return this.css}warn(o,i={}){i.plugin||this.lastPlugin&&this.lastPlugin.postcssPlugin&&(i.plugin=this.lastPlugin.postcssPlugin);let a=new e(o,i);return this.messages.push(a),a}warnings(){return this.messages.filter(o=>o.type==="warning")}}return xr=t,t.default=t,xr}var Rr,Si;function pn(){if(Si)return Rr;Si=1;let e={};return Rr=function(s){e[s]||(e[s]=!0,typeof console!="undefined"&&console.warn&&console.warn(s))},Rr}var Or,vi;function dn(){if(vi)return Or;vi=1;let e=Ae(),t=ts(),s=un(),o=ss(),i=is(),a=Ye(),c=bt(),{isClean:d,my:m}=Kr(),h=pn();const r={atrule:"AtRule",comment:"Comment",decl:"Declaration",document:"Document",root:"Root",rule:"Rule"},u={AtRule:!0,AtRuleExit:!0,Comment:!0,CommentExit:!0,Declaration:!0,DeclarationExit:!0,Document:!0,DocumentExit:!0,Once:!0,OnceExit:!0,postcssPlugin:!0,prepare:!0,Root:!0,RootExit:!0,Rule:!0,RuleExit:!0},l={Once:!0,postcssPlugin:!0,prepare:!0},n=0;function p(x){return typeof x=="object"&&typeof x.then=="function"}function f(x){let y=!1,b=r[x.type];return x.type==="decl"?y=x.prop.toLowerCase():x.type==="atrule"&&(y=x.name.toLowerCase()),y&&x.append?[b,b+"-"+y,n,b+"Exit",b+"Exit-"+y]:y?[b,b+"-"+y,b+"Exit",b+"Exit-"+y]:x.append?[b,n,b+"Exit"]:[b,b+"Exit"]}function g(x){let y;return x.type==="document"?y=["Document",n,"DocumentExit"]:x.type==="root"?y=["Root",n,"RootExit"]:y=f(x),{eventIndex:0,events:y,iterator:0,node:x,visitorIndex:0,visitors:[]}}function S(x){return x[d]=!1,x.nodes&&x.nodes.forEach(y=>S(y)),x}let w={};class v{get content(){return this.stringify().content}get css(){return this.stringify().css}get map(){return this.stringify().map}get messages(){return this.sync().messages}get opts(){return this.result.opts}get processor(){return this.result.processor}get root(){return this.sync().root}get[Symbol.toStringTag](){return"LazyResult"}constructor(y,b,C){this.stringified=!1,this.processed=!1;let R;if(typeof b=="object"&&b!==null&&(b.type==="root"||b.type==="document"))R=S(b);else if(b instanceof v||b instanceof i)R=S(b.root),b.map&&(typeof C.map=="undefined"&&(C.map={}),C.map.inline||(C.map.inline=!1),C.map.prev=b.map);else{let I=o;C.syntax&&(I=C.syntax.parse),C.parser&&(I=C.parser),I.parse&&(I=I.parse);try{R=I(b,C)}catch(O){this.processed=!0,this.error=O}R&&!R[m]&&e.rebuild(R)}this.result=new i(y,R,C),this.helpers=le(T({},w),{postcss:w,result:this.result}),this.plugins=this.processor.plugins.map(I=>typeof I=="object"&&I.prepare?T(T({},I),I.prepare(this.result)):I)}async(){return this.error?Promise.reject(this.error):this.processed?Promise.resolve(this.result):(this.processing||(this.processing=this.runAsync()),this.processing)}catch(y){return this.async().catch(y)}finally(y){return this.async().then(y,y)}getAsyncError(){throw new Error("Use process(css).then(cb) to work with async plugins")}handleError(y,b){let C=this.result.lastPlugin;try{b&&b.addToError(y),this.error=y,y.name==="CssSyntaxError"&&!y.plugin?(y.plugin=C.postcssPlugin,y.setMessage()):C.postcssVersion}catch(R){console&&console.error&&console.error(R)}return y}prepareVisitors(){this.listeners={};let y=(b,C,R)=>{this.listeners[C]||(this.listeners[C]=[]),this.listeners[C].push([b,R])};for(let b of this.plugins)if(typeof b=="object")for(let C in b){if(!u[C]&&/^[A-Z]/.test(C))throw new Error(`Unknown event ${C} in ${b.postcssPlugin}. Try to update PostCSS (${this.processor.version} now).`);if(!l[C])if(typeof b[C]=="object")for(let R in b[C])R==="*"?y(b,C,b[C][R]):y(b,C+"-"+R.toLowerCase(),b[C][R]);else typeof b[C]=="function"&&y(b,C,b[C])}this.hasListener=Object.keys(this.listeners).length>0}async runAsync(){this.plugin=0;for(let y=0;y<this.plugins.length;y++){let b=this.plugins[y],C=this.runOnRoot(b);if(p(C))try{await C}catch(R){throw this.handleError(R)}}if(this.prepareVisitors(),this.hasListener){let y=this.result.root;for(;!y[d];){y[d]=!0;let b=[g(y)];for(;b.length>0;){let C=this.visitTick(b);if(p(C))try{await C}catch(R){let I=b[b.length-1].node;throw this.handleError(R,I)}}}if(this.listeners.OnceExit)for(let[b,C]of this.listeners.OnceExit){this.result.lastPlugin=b;try{if(y.type==="document"){let R=y.nodes.map(I=>C(I,this.helpers));await Promise.all(R)}else await C(y,this.helpers)}catch(R){throw this.handleError(R)}}}return this.processed=!0,this.stringify()}runOnRoot(y){this.result.lastPlugin=y;try{if(typeof y=="object"&&y.Once){if(this.result.root.type==="document"){let b=this.result.root.nodes.map(C=>y.Once(C,this.helpers));return p(b[0])?Promise.all(b):b}return y.Once(this.result.root,this.helpers)}else if(typeof y=="function")return y(this.result.root,this.result)}catch(b){throw this.handleError(b)}}stringify(){if(this.error)throw this.error;if(this.stringified)return this.result;this.stringified=!0,this.sync();let y=this.result.opts,b=c;y.syntax&&(b=y.syntax.stringify),y.stringifier&&(b=y.stringifier),b.stringify&&(b=b.stringify);let R=new s(b,this.result.root,this.result.opts).generate();return this.result.css=R[0],this.result.map=R[1],this.result}sync(){if(this.error)throw this.error;if(this.processed)return this.result;if(this.processed=!0,this.processing)throw this.getAsyncError();for(let y of this.plugins){let b=this.runOnRoot(y);if(p(b))throw this.getAsyncError()}if(this.prepareVisitors(),this.hasListener){let y=this.result.root;for(;!y[d];)y[d]=!0,this.walkSync(y);if(this.listeners.OnceExit)if(y.type==="document")for(let b of y.nodes)this.visitSync(this.listeners.OnceExit,b);else this.visitSync(this.listeners.OnceExit,y)}return this.result}then(y,b){return this.async().then(y,b)}toString(){return this.css}visitSync(y,b){for(let[C,R]of y){this.result.lastPlugin=C;let I;try{I=R(b,this.helpers)}catch(O){throw this.handleError(O,b.proxyOf)}if(b.type!=="root"&&b.type!=="document"&&!b.parent)return!0;if(p(I))throw this.getAsyncError()}}visitTick(y){let b=y[y.length-1],{node:C,visitors:R}=b;if(C.type!=="root"&&C.type!=="document"&&!C.parent){y.pop();return}if(R.length>0&&b.visitorIndex<R.length){let[O,N]=R[b.visitorIndex];b.visitorIndex+=1,b.visitorIndex===R.length&&(b.visitors=[],b.visitorIndex=0),this.result.lastPlugin=O;try{return N(C.toProxy(),this.helpers)}catch(P){throw this.handleError(P,C)}}if(b.iterator!==0){let O=b.iterator,N;for(;N=C.nodes[C.indexes[O]];)if(C.indexes[O]+=1,!N[d]){N[d]=!0,y.push(g(N));return}b.iterator=0,delete C.indexes[O]}let I=b.events;for(;b.eventIndex<I.length;){let O=I[b.eventIndex];if(b.eventIndex+=1,O===n){C.nodes&&C.nodes.length&&(C[d]=!0,b.iterator=C.getIterator());return}else if(this.listeners[O]){b.visitors=this.listeners[O];return}}y.pop()}walkSync(y){y[d]=!0;let b=f(y);for(let C of b)if(C===n)y.nodes&&y.each(R=>{R[d]||this.walkSync(R)});else{let R=this.listeners[C];if(R&&this.visitSync(R,y.toProxy()))return}}warnings(){return this.sync().warnings()}}return v.registerPostcss=x=>{w=x},Or=v,v.default=v,a.registerLazyResult(v),t.registerLazyResult(v),Or}var Mr,Ci;function oa(){if(Ci)return Mr;Ci=1;let e=un(),t=ss();const s=is();let o=bt(),i=pn();class a{get content(){return this.result.css}get css(){return this.result.css}get map(){return this.result.map}get messages(){return[]}get opts(){return this.result.opts}get processor(){return this.result.processor}get root(){if(this._root)return this._root;let d,m=t;try{d=m(this._css,this._opts)}catch(h){this.error=h}if(this.error)throw this.error;return this._root=d,d}get[Symbol.toStringTag](){return"NoWorkResult"}constructor(d,m,h){m=m.toString(),this.stringified=!1,this._processor=d,this._css=m,this._opts=h,this._map=void 0;let r,u=o;this.result=new s(this._processor,r,this._opts),this.result.css=m;let l=this;Object.defineProperty(this.result,"root",{get(){return l.root}});let n=new e(u,r,this._opts,m);if(n.isMap()){let[p,f]=n.generate();p&&(this.result.css=p),f&&(this.result.map=f)}else n.clearAnnotation(),this.result.css=n.css}async(){return this.error?Promise.reject(this.error):Promise.resolve(this.result)}catch(d){return this.async().catch(d)}finally(d){return this.async().then(d,d)}sync(){if(this.error)throw this.error;return this.result}then(d,m){return this.async().then(d,m)}toString(){return this._css}warnings(){return[]}}return Mr=a,a.default=a,Mr}var Ir,xi;function aa(){if(xi)return Ir;xi=1;let e=ts(),t=dn(),s=oa(),o=Ye();class i{constructor(c=[]){this.version="8.5.6",this.plugins=this.normalize(c)}normalize(c){let d=[];for(let m of c)if(m.postcss===!0?m=m():m.postcss&&(m=m.postcss),typeof m=="object"&&Array.isArray(m.plugins))d=d.concat(m.plugins);else if(typeof m=="object"&&m.postcssPlugin)d.push(m);else if(typeof m=="function")d.push(m);else if(!(typeof m=="object"&&(m.parse||m.stringify)))throw new Error(m+" is not a PostCSS plugin");return d}process(c,d={}){return!this.plugins.length&&!d.parser&&!d.stringifier&&!d.syntax?new s(this,c,d):new t(this,c,d)}use(c){return this.plugins=this.plugins.concat(this.normalize([c])),this}}return Ir=i,i.default=i,o.registerProcessor(i),e.registerProcessor(i),Ir}var Er,Ri;function mn(){if(Ri)return Er;Ri=1;let e=es(),t=Je(),s=Ae(),o=Qr(),i=vt(),a=ts(),c=na(),d=Ct(),m=dn(),h=ln(),r=St(),u=ss(),l=aa(),n=is(),p=Ye(),f=rs(),g=bt(),S=fn();function w(...v){return v.length===1&&Array.isArray(v[0])&&(v=v[0]),new l(v)}return w.plugin=function(x,y){let b=!1;function C(...I){console&&console.warn&&!b&&(b=!0,console.warn(x+`: postcss.plugin was deprecated. Migration guide:
|
|
55
55
|
https://evilmartians.com/chronicles/postcss-8-plugin-migration`),process.env.LANG&&process.env.LANG.startsWith("cn")&&console.warn(x+`: \u91CC\u9762 postcss.plugin \u88AB\u5F03\u7528. \u8FC1\u79FB\u6307\u5357:
|
|
56
|
-
https://www.w3ctech.com/topic/2226`));let O=y(...I);return O.postcssPlugin=x,O.postcssVersion=new l().version,O}let R;return Object.defineProperty(C,"postcss",{get(){return R||(R=C()),R}}),C.process=function(I,O,N){return w([C(N)]).process(I,O)},C},w.stringify=g,w.parse=u,w.fromJSON=c,w.list=h,w.comment=v=>new t(v),w.atRule=v=>new e(v),w.decl=v=>new i(v),w.rule=v=>new f(v),w.root=v=>new p(v),w.document=v=>new a(v),w.CssSyntaxError=o,w.Declaration=i,w.Container=s,w.Processor=l,w.Document=a,w.Comment=t,w.Warning=S,w.AtRule=e,w.Result=n,w.Input=d,w.Rule=f,w.Root=p,w.Node=r,m.registerPostcss(w),
|
|
56
|
+
https://www.w3ctech.com/topic/2226`));let O=y(...I);return O.postcssPlugin=x,O.postcssVersion=new l().version,O}let R;return Object.defineProperty(C,"postcss",{get(){return R||(R=C()),R}}),C.process=function(I,O,N){return w([C(N)]).process(I,O)},C},w.stringify=g,w.parse=u,w.fromJSON=c,w.list=h,w.comment=v=>new t(v),w.atRule=v=>new e(v),w.decl=v=>new i(v),w.rule=v=>new f(v),w.root=v=>new p(v),w.document=v=>new a(v),w.CssSyntaxError=o,w.Declaration=i,w.Container=s,w.Processor=l,w.Document=a,w.Comment=t,w.Warning=S,w.AtRule=e,w.Result=n,w.Input=d,w.Rule=f,w.Root=p,w.Node=r,m.registerPostcss(w),Er=w,w.default=w,Er}var Ar,Oi;function la(){if(Oi)return Ar;Oi=1;let e=Je(),t=hn(),s=cn();class o extends t{checkMissedSemicolon(){}comment(a){let c=new e;this.init(c,a[2]);let d=this.input.fromOffset(a[3])||this.input.fromOffset(this.input.css.length-1);c.source.end={column:d.col,line:d.line,offset:a[3]+1};let m=a[1].slice(2);if(m.slice(-2)==="*/"&&(m=m.slice(0,-2)),/^\s*$/.test(m))c.text="",c.raws.left=m,c.raws.right="";else{let h=m.match(/^(\s*)([^]*\S)(\s*)$/);c.text=h[2],c.raws.left=h[1],c.raws.right=h[3]}}createTokenizer(){this.tokenizer=s(this.input,{ignoreErrors:!0})}decl(a){a.length>1&&a.some(c=>c[0]==="word")&&super.decl(a)}doubleColon(){}endFile(){for(this.current.nodes&&this.current.nodes.length&&(this.current.raws.semicolon=this.semicolon),this.current.raws.after=(this.current.raws.after||"")+this.spaces;this.current.parent;)this.current=this.current.parent,this.current.raws.after="";this.root.source.end=this.getPosition(this.tokenizer.position())}precheckMissedSemicolon(a){let c=this.colon(a);if(c===!1)return;let d,m;for(d=c-1;d>=0&&a[d][0]!=="word";d--);if(d===0||d<0)return;for(m=d-1;m>=0;m--)if(a[m][0]!=="space"){m+=1;break}let h=a.slice(d),r=a.slice(m,d);a.splice(m,a.length-m),this.spaces=r.map(u=>u[1]).join(""),this.decl(h)}unclosedBracket(){}unexpectedClose(){this.current.raws.after+="}"}unknownWord(a){this.spaces+=a.map(c=>c[1]).join("")}unnamedAtrule(a){a.name=""}}return Ar=o,Ar}var Pr,Mi;function ua(){if(Mi)return Pr;Mi=1;let{Input:e}=mn(),t=la();return Pr=function(o,i){let a=new e(o,i),c=new t(a);return c.parse(),c.root},Pr}ua();var ca=mn();const J=Ko(ca);J.stringify;J.fromJSON;J.plugin;J.parse;J.list;J.document;J.comment;J.atRule;J.rule;J.decl;J.root;J.CssSyntaxError;J.Declaration;J.Container;J.Processor;J.Document;J.Comment;J.Warning;J.AtRule;J.Result;J.Input;J.Rule;J.Root;J.Node;class ns{constructor(...t){ue(this,"parentElement",null),ue(this,"parentNode",null),ue(this,"ownerDocument"),ue(this,"firstChild",null),ue(this,"lastChild",null),ue(this,"previousSibling",null),ue(this,"nextSibling",null),ue(this,"ELEMENT_NODE",1),ue(this,"TEXT_NODE",3),ue(this,"nodeType"),ue(this,"nodeName"),ue(this,"RRNodeType")}get childNodes(){const t=[];let s=this.firstChild;for(;s;)t.push(s),s=s.nextSibling;return t}contains(t){if(t instanceof ns){if(t.ownerDocument!==this.ownerDocument)return!1;if(t===this)return!0}else return!1;for(;t.parentNode;){if(t.parentNode===this)return!0;t=t.parentNode}return!1}appendChild(t){throw new Error("RRDomException: Failed to execute 'appendChild' on 'RRNode': This RRNode type does not support this method.")}insertBefore(t,s){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"}}const Ii={Node:["childNodes","parentNode","parentElement","textContent"],ShadowRoot:["host","styleSheets"],Element:["shadowRoot","querySelector","querySelectorAll"],MutationObserver:[]},Ei={Node:["contains","getRootNode"],ShadowRoot:["getSelection"],Element:[],MutationObserver:["constructor"]},st={};function ha(e){var t,s;const o=(s=(t=globalThis==null?void 0:globalThis.Zone)==null?void 0:t.__symbol__)==null?void 0:s.call(t,e);if(o&&globalThis[o])return globalThis[o]}function os(e){if(st[e])return st[e];const t=ha(e)||globalThis[e],s=t.prototype,o=e in Ii?Ii[e]:void 0,i=!!(o&&o.every(d=>{var m,h;return!!((h=(m=Object.getOwnPropertyDescriptor(s,d))==null?void 0:m.get)!=null&&h.toString().includes("[native code]"))})),a=e in Ei?Ei[e]:void 0,c=!!(a&&a.every(d=>{var m;return typeof s[d]=="function"&&((m=s[d])==null?void 0:m.toString().includes("[native code]"))}));if(i&&c)return st[e]=t.prototype,t.prototype;try{const d=document.createElement("iframe");document.body.appendChild(d);const m=d.contentWindow;if(!m)return t.prototype;const h=m[e].prototype;return document.body.removeChild(d),h?st[e]=h:s}catch(d){return s}}const Nr={};function Oe(e,t,s){var o;const i=`${e}.${String(s)}`;if(Nr[i])return Nr[i].call(t);const a=os(e),c=(o=Object.getOwnPropertyDescriptor(a,s))==null?void 0:o.get;return c?(Nr[i]=c,c.call(t)):t[s]}const _r={};function gn(e,t,s){const o=`${e}.${String(s)}`;if(_r[o])return _r[o].bind(t);const a=os(e)[s];return typeof a!="function"?t[s]:(_r[o]=a,a.bind(t))}function fa(e){return Oe("Node",e,"childNodes")}function pa(e){return Oe("Node",e,"parentNode")}function da(e){return Oe("Node",e,"parentElement")}function ma(e){return Oe("Node",e,"textContent")}function ga(e,t){return gn("Node",e,"contains")(t)}function ya(e){return gn("Node",e,"getRootNode")()}function wa(e){return!e||!("host"in e)?null:Oe("ShadowRoot",e,"host")}function ba(e){return e.styleSheets}function Sa(e){return!e||!("shadowRoot"in e)?null:Oe("Element",e,"shadowRoot")}function va(e,t){return Oe("Element",e,"querySelector")(t)}function Ca(e,t){return Oe("Element",e,"querySelectorAll")(t)}function yn(){return os("MutationObserver").constructor}function Pe(e,t,s){try{if(!(t in e))return()=>{};const o=e[t],i=s(o);return typeof i=="function"&&(i.prototype=i.prototype||{},Object.defineProperties(i,{__rrweb_original__:{enumerable:!1,value:o}})),e[t]=i,()=>{e[t]=o}}catch(o){return()=>{}}}const L={childNodes:fa,parentNode:pa,parentElement:da,textContent:ma,contains:ga,getRootNode:ya,host:wa,styleSheets:ba,shadowRoot:Sa,querySelector:va,querySelectorAll:Ca,mutationObserver:yn,patch:Pe};function te(e,t,s=document){const o={capture:!0,passive:!0};return s.addEventListener(e,t,o),()=>s.removeEventListener(e,t,o)}const De=`Please stop import mirror directly. Instead of that,\r
|
|
57
57
|
now you can use replayer.getMirror() to access the mirror instance of a replayer,\r
|
|
58
|
-
or you can use record.mirror to access the mirror instance during recording.`;let Ii={map:{},getId(){return console.error(ke),-1},getNode(){return console.error(ke),null},removeNodeFromMap(){console.error(ke)},has(){return console.error(ke),!1},reset(){console.error(ke)}};typeof window!="undefined"&&window.Proxy&&window.Reflect&&(Ii=new Proxy(Ii,{get(e,t,s){return t==="map"&&console.error(ke),Reflect.get(e,t,s)}}));function qe(e,t,s={}){let o=null,i=0;return function(...a){const c=Date.now();!i&&s.leading===!1&&(i=c);const d=t-(c-i),m=this;d<=0||d>t?(o&&(clearTimeout(o),o=null),i=c,e.apply(m,a)):!o&&s.trailing!==!1&&(o=setTimeout(()=>{i=s.leading===!1?0:Date.now(),o=null,e.apply(m,a)},d))}}function vt(e,t,s,o,i=window){const a=i.Object.getOwnPropertyDescriptor(e,t);return i.Object.defineProperty(e,t,o?s:{set(c){setTimeout(()=>{s.set.call(this,c)},0),a&&a.set&&a.set.call(this,c)}}),()=>vt(e,t,a||{},!0)}let ct=Date.now;/[1-9][0-9]{12}/.test(Date.now().toString())||(ct=()=>new Date().getTime());function gn(e){var t,s,o,i;const a=e.document;return{left:a.scrollingElement?a.scrollingElement.scrollLeft:e.pageXOffset!==void 0?e.pageXOffset:a.documentElement.scrollLeft||(a==null?void 0:a.body)&&((t=L.parentElement(a.body))==null?void 0:t.scrollLeft)||((s=a==null?void 0:a.body)==null?void 0:s.scrollLeft)||0,top:a.scrollingElement?a.scrollingElement.scrollTop:e.pageYOffset!==void 0?e.pageYOffset:(a==null?void 0:a.documentElement.scrollTop)||(a==null?void 0:a.body)&&((o=L.parentElement(a.body))==null?void 0:o.scrollTop)||((i=a==null?void 0:a.body)==null?void 0:i.scrollTop)||0}}function yn(){return window.innerHeight||document.documentElement&&document.documentElement.clientHeight||document.body&&document.body.clientHeight}function wn(){return window.innerWidth||document.documentElement&&document.documentElement.clientWidth||document.body&&document.body.clientWidth}function bn(e){return e?e.nodeType===e.ELEMENT_NODE?e:L.parentElement(e):null}function se(e,t,s,o){if(!e)return!1;const i=bn(e);if(!i)return!1;try{if(typeof t=="string"){if(i.classList.contains(t)||o&&i.closest("."+t)!==null)return!0}else if(ut(i,t,o))return!0}catch(a){}return!!(s&&(i.matches(s)||o&&i.closest(s)!==null))}function va(e,t){return t.getId(e)!==-1}function Nr(e,t,s){return e.tagName==="TITLE"&&s.headTitleMutations?!0:t.getId(e)===ze}function Sn(e,t){if(Be(e))return!1;const s=t.getId(e);if(!t.has(s))return!0;const o=L.parentNode(e);return o&&o.nodeType===e.DOCUMENT_NODE?!1:o?Sn(o,t):!0}function Dr(e){return!!e.changedTouches}function Ca(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 vn(e,t){return!!(e.nodeName==="IFRAME"&&t.getMeta(e))}function Cn(e,t){return!!(e.nodeName==="LINK"&&e.nodeType===e.ELEMENT_NODE&&e.getAttribute&&e.getAttribute("rel")==="stylesheet"&&t.getMeta(e))}function Lr(e){return e?e instanceof ss&&"shadowRoot"in e?!!e.shadowRoot:!!L.shadowRoot(e):!1}class xa{constructor(){A(this,"id",1),A(this,"styleIDMap",new WeakMap),A(this,"idStyleMap",new Map)}getId(t){var s;return(s=this.styleIDMap.get(t))!=null?s:-1}has(t){return this.styleIDMap.has(t)}add(t,s){if(this.has(t))return this.getId(t);let o;return s===void 0?o=this.id++:o=s,this.styleIDMap.set(t,o),this.idStyleMap.set(o,t),o}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 xn(e){var t;let s=null;return"getRootNode"in e&&((t=L.getRootNode(e))==null?void 0:t.nodeType)===Node.DOCUMENT_FRAGMENT_NODE&&L.host(L.getRootNode(e))&&(s=L.host(L.getRootNode(e))),s}function Ra(e){let t=e,s;for(;s=xn(t);)t=s;return t}function Oa(e){const t=e.ownerDocument;if(!t)return!1;const s=Ra(e);return L.contains(t,s)}function Rn(e){const t=e.ownerDocument;return t?L.contains(t,e)||Oa(e):!1}var B=(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))(B||{}),F=(e=>(e[e.Mutation=0]="Mutation",e[e.MouseMove=1]="MouseMove",e[e.MouseInteraction=2]="MouseInteraction",e[e.Scroll=3]="Scroll",e[e.ViewportResize=4]="ViewportResize",e[e.Input=5]="Input",e[e.TouchMove=6]="TouchMove",e[e.MediaInteraction=7]="MediaInteraction",e[e.StyleSheetRule=8]="StyleSheetRule",e[e.CanvasMutation=9]="CanvasMutation",e[e.Font=10]="Font",e[e.Log=11]="Log",e[e.Drag=12]="Drag",e[e.StyleDeclaration=13]="StyleDeclaration",e[e.Selection=14]="Selection",e[e.AdoptedStyleSheet=15]="AdoptedStyleSheet",e[e.CustomElement=16]="CustomElement",e))(F||{}),ne=(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))(ne||{}),ye=(e=>(e[e.Mouse=0]="Mouse",e[e.Pen=1]="Pen",e[e.Touch=2]="Touch",e))(ye||{}),$e=(e=>(e[e["2D"]=0]="2D",e[e.WebGL=1]="WebGL",e[e.WebGL2=2]="WebGL2",e))($e||{}),De=(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))(De||{}),On=(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))(On||{});function Ei(e){return"__ln"in e}class Ma{constructor(){A(this,"length",0),A(this,"head",null),A(this,"tail",null)}get(t){if(t>=this.length)throw new Error("Position outside of list range");let s=this.head;for(let o=0;o<t;o++)s=(s==null?void 0:s.next)||null;return s}addNode(t){const s={value:t,previous:null,next:null};if(t.__ln=s,t.previousSibling&&Ei(t.previousSibling)){const o=t.previousSibling.__ln.next;s.next=o,s.previous=t.previousSibling.__ln,t.previousSibling.__ln.next=s,o&&(o.previous=s)}else if(t.nextSibling&&Ei(t.nextSibling)&&t.nextSibling.__ln.previous){const o=t.nextSibling.__ln.previous;s.previous=o,s.next=t.nextSibling.__ln,t.nextSibling.__ln.previous=s,o&&(o.next=s)}else this.head&&(this.head.previous=s),s.next=this.head,this.head=s;s.next===null&&(this.tail=s),this.length++}removeNode(t){const s=t.__ln;this.head&&(s.previous?(s.previous.next=s.next,s.next?s.next.previous=s.previous:this.tail=s.previous):(this.head=s.next,this.head?this.head.previous=null:this.tail=null),t.__ln&&delete t.__ln,this.length--)}}const Ai=(e,t)=>`${e}@${t}`;class Ia{constructor(){A(this,"frozen",!1),A(this,"locked",!1),A(this,"texts",[]),A(this,"attributes",[]),A(this,"attributeMap",new WeakMap),A(this,"removes",[]),A(this,"mapRemoves",[]),A(this,"movedMap",{}),A(this,"addedSet",new Set),A(this,"movedSet",new Set),A(this,"droppedSet",new Set),A(this,"removesSubTreeCache",new Set),A(this,"mutationCb"),A(this,"blockClass"),A(this,"blockSelector"),A(this,"maskTextClass"),A(this,"maskTextSelector"),A(this,"inlineStylesheet"),A(this,"maskInputOptions"),A(this,"maskTextFn"),A(this,"maskInputFn"),A(this,"keepIframeSrcFn"),A(this,"recordCanvas"),A(this,"inlineImages"),A(this,"slimDOMOptions"),A(this,"dataURLOptions"),A(this,"doc"),A(this,"mirror"),A(this,"iframeManager"),A(this,"stylesheetManager"),A(this,"shadowDomManager"),A(this,"canvasManager"),A(this,"processedNodeManager"),A(this,"unattachedDoc"),A(this,"processMutations",t=>{t.forEach(this.processMutation),this.emit()}),A(this,"emit",()=>{if(this.frozen||this.locked)return;const t=[],s=new Set,o=new Ma,i=m=>{let h=m,r=ze;for(;r===ze;)h=h&&h.nextSibling,r=h&&this.mirror.getId(h);return r},a=m=>{const h=L.parentNode(m);if(!h||!Rn(m)||h.tagName==="TEXTAREA")return;const r=Be(h)?this.mirror.getId(xn(m)):this.mirror.getId(h),u=i(m);if(r===-1||u===-1)return o.addNode(m);const l=Te(m,{doc:this.doc,mirror:this.mirror,blockClass:this.blockClass,blockSelector:this.blockSelector,maskTextClass:this.maskTextClass,maskTextSelector:this.maskTextSelector,skipChild:!0,newlyAddedElement:!0,inlineStylesheet:this.inlineStylesheet,maskInputOptions:this.maskInputOptions,maskTextFn:this.maskTextFn,maskInputFn:this.maskInputFn,slimDOMOptions:this.slimDOMOptions,dataURLOptions:this.dataURLOptions,recordCanvas:this.recordCanvas,inlineImages:this.inlineImages,onSerialize:n=>{vn(n,this.mirror)&&this.iframeManager.addIframe(n),Cn(n,this.mirror)&&this.stylesheetManager.trackLinkElement(n),Lr(m)&&this.shadowDomManager.addShadowRoot(L.shadowRoot(m),this.doc)},onIframeLoad:(n,p)=>{this.iframeManager.attachIframe(n,p),this.shadowDomManager.observeAttachShadow(n)},onStylesheetLoad:(n,p)=>{this.stylesheetManager.attachLinkElement(n,p)}});l&&(t.push({parentId:r,nextId:u,node:l}),s.add(l.id))};for(;this.mapRemoves.length;)this.mirror.removeNodeFromMap(this.mapRemoves.shift());for(const m of this.movedSet)Pi(this.removesSubTreeCache,m,this.mirror)&&!this.movedSet.has(L.parentNode(m))||a(m);for(const m of this.addedSet)!Ni(this.droppedSet,m)&&!Pi(this.removesSubTreeCache,m,this.mirror)||Ni(this.movedSet,m)?a(m):this.droppedSet.add(m);let c=null;for(;o.length;){let m=null;if(c){const h=this.mirror.getId(L.parentNode(c.value)),r=i(c.value);h!==-1&&r!==-1&&(m=c)}if(!m){let h=o.tail;for(;h;){const r=h;if(h=h.previous,r){const u=this.mirror.getId(L.parentNode(r.value));if(i(r.value)===-1)continue;if(u!==-1){m=r;break}else{const n=r.value,p=L.parentNode(n);if(p&&p.nodeType===Node.DOCUMENT_FRAGMENT_NODE){const f=L.host(p);if(this.mirror.getId(f)!==-1){m=r;break}}}}}}if(!m){for(;o.head;)o.removeNode(o.head.value);break}c=m.previous,o.removeNode(m.value),a(m.value)}const d={texts:this.texts.map(m=>{const h=m.node,r=L.parentNode(h);return r&&r.tagName==="TEXTAREA"&&this.genTextAreaValueMutation(r),{id:this.mirror.getId(h),value:m.value}}).filter(m=>!s.has(m.id)).filter(m=>this.mirror.has(m.id)),attributes:this.attributes.map(m=>{const{attributes:h}=m;if(typeof h.style=="string"){const r=JSON.stringify(m.styleDiff),u=JSON.stringify(m._unchangedStyles);r.length<h.style.length&&(r+u).split("var(").length===h.style.split("var(").length&&(h.style=m.styleDiff)}return{id:this.mirror.getId(m.node),attributes:h}}).filter(m=>!s.has(m.id)).filter(m=>this.mirror.has(m.id)),removes:this.removes,adds:t};!d.texts.length&&!d.attributes.length&&!d.removes.length&&!d.adds.length||(this.texts=[],this.attributes=[],this.attributeMap=new WeakMap,this.removes=[],this.addedSet=new Set,this.movedSet=new Set,this.droppedSet=new Set,this.removesSubTreeCache=new Set,this.movedMap={},this.mutationCb(d))}),A(this,"genTextAreaValueMutation",t=>{let s=this.attributeMap.get(t);s||(s={node:t,attributes:{},styleDiff:{},_unchangedStyles:{}},this.attributes.push(s),this.attributeMap.set(t,s)),s.attributes.value=Array.from(L.childNodes(t),o=>L.textContent(o)||"").join("")}),A(this,"processMutation",t=>{if(!Nr(t.target,this.mirror,this.slimDOMOptions))switch(t.type){case"characterData":{const s=L.textContent(t.target);!se(t.target,this.blockClass,this.blockSelector,!1)&&s!==t.oldValue&&this.texts.push({value:Vi(t.target,this.maskTextClass,this.maskTextSelector,!0)&&s?this.maskTextFn?this.maskTextFn(s,bn(t.target)):s.replace(/[\S]/g,"*"):s,node:t.target});break}case"attributes":{const s=t.target;let o=t.attributeName,i=t.target.getAttribute(o);if(o==="value"){const c=Ur(s);i=Br({element:s,maskInputOptions:this.maskInputOptions,tagName:s.tagName,type:c,value:i,maskInputFn:this.maskInputFn})}if(se(t.target,this.blockClass,this.blockSelector,!1)||i===t.oldValue)return;let a=this.attributeMap.get(t.target);if(s.tagName==="IFRAME"&&o==="src"&&!this.keepIframeSrcFn(i))if(!s.contentDocument)o="rr_src";else return;if(a||(a={node:t.target,attributes:{},styleDiff:{},_unchangedStyles:{}},this.attributes.push(a),this.attributeMap.set(t.target,a)),o==="type"&&s.tagName==="INPUT"&&(t.oldValue||"").toLowerCase()==="password"&&s.setAttribute("data-rr-is-password","true"),!Hi(s.tagName,o))if(a.attributes[o]=ji(this.doc,Oe(s.tagName),Oe(o),i,s,this.dataURLOptions),o==="style"){if(!this.unattachedDoc)try{this.unattachedDoc=document.implementation.createHTMLDocument()}catch(d){this.unattachedDoc=this.doc}const c=this.unattachedDoc.createElement("span");t.oldValue&&c.setAttribute("style",t.oldValue);for(const d of Array.from(s.style)){const m=s.style.getPropertyValue(d),h=s.style.getPropertyPriority(d);m!==c.style.getPropertyValue(d)||h!==c.style.getPropertyPriority(d)?h===""?a.styleDiff[d]=m:a.styleDiff[d]=[m,h]:a._unchangedStyles[d]=[m,h]}for(const d of Array.from(c.style))s.style.getPropertyValue(d)===""&&(a.styleDiff[d]=!1)}else o==="open"&&s.tagName==="DIALOG"&&(s.matches("dialog:modal")?a.attributes.rr_open_mode="modal":a.attributes.rr_open_mode="non-modal");break}case"childList":{if(se(t.target,this.blockClass,this.blockSelector,!0))return;if(t.target.tagName==="TEXTAREA"){this.genTextAreaValueMutation(t.target);return}t.addedNodes.forEach(s=>this.genAdds(s,t.target)),t.removedNodes.forEach(s=>{const o=this.mirror.getId(s),i=Be(t.target)?this.mirror.getId(L.host(t.target)):this.mirror.getId(t.target);se(t.target,this.blockClass,this.blockSelector,!1)||Nr(s,this.mirror,this.slimDOMOptions)||!va(s,this.mirror)||(this.addedSet.has(s)?(Tr(this.addedSet,s),this.droppedSet.add(s)):this.addedSet.has(t.target)&&o===-1||Sn(t.target,this.mirror)||(this.movedSet.has(s)&&this.movedMap[Ai(o,i)]?Tr(this.movedSet,s):(this.removes.push({parentId:i,id:o,isShadow:Be(t.target)&&Ue(t.target)?!0:void 0}),Ea(s,this.removesSubTreeCache))),this.mapRemoves.push(s))});break}}}),A(this,"genAdds",(t,s)=>{if(!this.processedNodeManager.inOtherBuffer(t,this)&&!(this.addedSet.has(t)||this.movedSet.has(t))){if(this.mirror.hasNode(t)){if(Nr(t,this.mirror,this.slimDOMOptions))return;this.movedSet.add(t);let o=null;s&&this.mirror.hasNode(s)&&(o=this.mirror.getId(s)),o&&o!==-1&&(this.movedMap[Ai(this.mirror.getId(t),o)]=!0)}else this.addedSet.add(t),this.droppedSet.delete(t);se(t,this.blockClass,this.blockSelector,!1)||(L.childNodes(t).forEach(o=>this.genAdds(o)),Lr(t)&&L.childNodes(L.shadowRoot(t)).forEach(o=>{this.processedNodeManager.add(o,this),this.genAdds(o,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(s=>{this[s]=t[s]})}freeze(){this.frozen=!0,this.canvasManager.freeze()}unfreeze(){this.frozen=!1,this.canvasManager.unfreeze(),this.emit()}isFrozen(){return this.frozen}lock(){this.locked=!0,this.canvasManager.lock()}unlock(){this.locked=!1,this.canvasManager.unlock(),this.emit()}reset(){this.shadowDomManager.reset(),this.canvasManager.reset()}destroy(){for(;this.mapRemoves.length;)this.mirror.removeNodeFromMap(this.mapRemoves.shift())}}function Tr(e,t){e.delete(t),L.childNodes(t).forEach(s=>Tr(e,s))}function Ea(e,t){const s=[e];for(;s.length;){const o=s.pop();t.has(o)||(t.add(o),L.childNodes(o).forEach(i=>s.push(i)))}}function Pi(e,t,s){return e.size===0?!1:Aa(e,t)}function Aa(e,t,s){const o=L.parentNode(t);return o?e.has(o):!1}function Ni(e,t){return e.size===0?!1:Mn(e,t)}function Mn(e,t){const s=L.parentNode(t);return s?e.has(s)?!0:Mn(e,s):!1}let We;function Pa(e){We=e}function Na(){We=void 0}const $=e=>We?(...s)=>{try{return e(...s)}catch(o){if(We&&We(o)===!0)return;throw o}}:e,we=[];function Je(e){try{if("composedPath"in e){const t=e.composedPath();if(t.length)return t[0]}else if("path"in e&&e.path.length)return e.path[0]}catch(t){}return e&&e.target}function In(e,t){const s=new Ia;we.push(s),s.init(e);const o=new(mn())($(s.processMutations.bind(s)));return o.observe(t,{attributes:!0,attributeOldValue:!0,characterData:!0,characterDataOldValue:!0,childList:!0,subtree:!0}),o}function _a({mousemoveCb:e,sampling:t,doc:s,mirror:o}){if(t.mousemove===!1)return()=>{};const i=typeof t.mousemove=="number"?t.mousemove:50,a=typeof t.mousemoveCallback=="number"?t.mousemoveCallback:500;let c=[],d;const m=qe($(u=>{const l=Date.now()-d;e(c.map(n=>(n.timeOffset-=l,n)),u),c=[],d=null}),a),h=$(qe($(u=>{const l=Je(u),{clientX:n,clientY:p}=Dr(u)?u.changedTouches[0]:u;d||(d=ct()),c.push({x:n,y:p,id:o.getId(l),timeOffset:ct()-d}),m(typeof DragEvent!="undefined"&&u instanceof DragEvent?F.Drag:u instanceof MouseEvent?F.MouseMove:F.TouchMove)}),i,{trailing:!1})),r=[re("mousemove",h,s),re("touchmove",h,s),re("drag",h,s)];return $(()=>{r.forEach(u=>u())})}function ka({mouseInteractionCb:e,doc:t,mirror:s,blockClass:o,blockSelector:i,sampling:a}){if(a.mouseInteraction===!1)return()=>{};const c=a.mouseInteraction===!0||a.mouseInteraction===void 0?{}:a.mouseInteraction,d=[];let m=null;const h=r=>u=>{const l=Je(u);if(se(l,o,i,!0))return;let n=null,p=r;if("pointerType"in u){switch(u.pointerType){case"mouse":n=ye.Mouse;break;case"touch":n=ye.Touch;break;case"pen":n=ye.Pen;break}n===ye.Touch?ne[r]===ne.MouseDown?p="TouchStart":ne[r]===ne.MouseUp&&(p="TouchEnd"):ye.Pen}else Dr(u)&&(n=ye.Touch);n!==null?(m=n,(p.startsWith("Touch")&&n===ye.Touch||p.startsWith("Mouse")&&n===ye.Mouse)&&(n=null)):ne[r]===ne.Click&&(n=m,m=null);const f=Dr(u)?u.changedTouches[0]:u;if(!f)return;const g=s.getId(l),{clientX:S,clientY:w}=f;$(e)(T({type:ne[p],id:g,x:S,y:w},n!==null&&{pointerType:n}))};return Object.keys(ne).filter(r=>Number.isNaN(Number(r))&&!r.endsWith("_Departed")&&c[r]!==!1).forEach(r=>{let u=Oe(r);const l=h(r);if(window.PointerEvent)switch(ne[r]){case ne.MouseDown:case ne.MouseUp:u=u.replace("mouse","pointer");break;case ne.TouchStart:case ne.TouchEnd:return}d.push(re(u,l,t))}),$(()=>{d.forEach(r=>r())})}function En({scrollCb:e,doc:t,mirror:s,blockClass:o,blockSelector:i,sampling:a}){const c=$(qe($(d=>{const m=Je(d);if(!m||se(m,o,i,!0))return;const h=s.getId(m);if(m===t&&t.defaultView){const r=gn(t.defaultView);e({id:h,x:r.left,y:r.top})}else e({id:h,x:m.scrollLeft,y:m.scrollTop})}),a.scroll||100));return re("scroll",c,t)}function Da({viewportResizeCb:e},{win:t}){let s=-1,o=-1;const i=$(qe($(()=>{const a=yn(),c=wn();(s!==a||o!==c)&&(e({width:Number(c),height:Number(a)}),s=a,o=c)}),200));return re("resize",i,t)}const La=["INPUT","TEXTAREA","SELECT"],_i=new WeakMap;function Ta({inputCb:e,doc:t,mirror:s,blockClass:o,blockSelector:i,ignoreClass:a,ignoreSelector:c,maskInputOptions:d,maskInputFn:m,sampling:h,userTriggeredOnInput:r}){function u(w){let v=Je(w);const x=w.isTrusted,y=v&&v.tagName;if(v&&y==="OPTION"&&(v=L.parentElement(v)),!v||!y||La.indexOf(y)<0||se(v,o,i,!0)||v.classList.contains(a)||c&&v.matches(c))return;let b=v.value,C=!1;const R=Ur(v)||"";R==="radio"||R==="checkbox"?C=v.checked:(d[y.toLowerCase()]||d[R])&&(b=Br({element:v,maskInputOptions:d,tagName:y,type:R,value:b,maskInputFn:m})),l(v,r?{text:b,isChecked:C,userTriggered:x}:{text:b,isChecked:C});const I=v.name;R==="radio"&&I&&C&&t.querySelectorAll(`input[type="radio"][name="${I}"]`).forEach(O=>{if(O!==v){const N=O.value;l(O,r?{text:N,isChecked:!C,userTriggered:!1}:{text:N,isChecked:!C})}})}function l(w,v){const x=_i.get(w);if(!x||x.text!==v.text||x.isChecked!==v.isChecked){_i.set(w,v);const y=s.getId(w);$(e)(le(T({},v),{id:y}))}}const p=(h.input==="last"?["change"]:["input","change"]).map(w=>re(w,$(u),t)),f=t.defaultView;if(!f)return()=>{p.forEach(w=>w())};const g=f.Object.getOwnPropertyDescriptor(f.HTMLInputElement.prototype,"value"),S=[[f.HTMLInputElement.prototype,"value"],[f.HTMLInputElement.prototype,"checked"],[f.HTMLSelectElement.prototype,"value"],[f.HTMLTextAreaElement.prototype,"value"],[f.HTMLSelectElement.prototype,"selectedIndex"],[f.HTMLOptionElement.prototype,"selected"]];return g&&g.set&&p.push(...S.map(w=>vt(w[0],w[1],{set(){$(u)({target:this,isTrusted:!1})}},!1,f))),$(()=>{p.forEach(w=>w())})}function ht(e){const t=[];function s(o,i){if(rt("CSSGroupingRule")&&o.parentRule instanceof CSSGroupingRule||rt("CSSMediaRule")&&o.parentRule instanceof CSSMediaRule||rt("CSSSupportsRule")&&o.parentRule instanceof CSSSupportsRule||rt("CSSConditionRule")&&o.parentRule instanceof CSSConditionRule){const c=Array.from(o.parentRule.cssRules).indexOf(o);i.unshift(c)}else if(o.parentStyleSheet){const c=Array.from(o.parentStyleSheet.cssRules).indexOf(o);i.unshift(c)}return i}return s(e,t)}function Se(e,t,s){let o,i;return e?(e.ownerNode?o=t.getId(e.ownerNode):i=s.getId(e),{styleId:i,id:o}):{}}function Fa({styleSheetRuleCb:e,mirror:t,stylesheetManager:s},{win:o}){if(!o.CSSStyleSheet||!o.CSSStyleSheet.prototype)return()=>{};const i=o.CSSStyleSheet.prototype.insertRule;o.CSSStyleSheet.prototype.insertRule=new Proxy(i,{apply:$((r,u,l)=>{const[n,p]=l,{id:f,styleId:g}=Se(u,t,s.styleMirror);return(f&&f!==-1||g&&g!==-1)&&e({id:f,styleId:g,adds:[{rule:n,index:p}]}),r.apply(u,l)})}),o.CSSStyleSheet.prototype.addRule=function(r,u,l=this.cssRules.length){const n=`${r} { ${u} }`;return o.CSSStyleSheet.prototype.insertRule.apply(this,[n,l])};const a=o.CSSStyleSheet.prototype.deleteRule;o.CSSStyleSheet.prototype.deleteRule=new Proxy(a,{apply:$((r,u,l)=>{const[n]=l,{id:p,styleId:f}=Se(u,t,s.styleMirror);return(p&&p!==-1||f&&f!==-1)&&e({id:p,styleId:f,removes:[{index:n}]}),r.apply(u,l)})}),o.CSSStyleSheet.prototype.removeRule=function(r){return o.CSSStyleSheet.prototype.deleteRule.apply(this,[r])};let c;o.CSSStyleSheet.prototype.replace&&(c=o.CSSStyleSheet.prototype.replace,o.CSSStyleSheet.prototype.replace=new Proxy(c,{apply:$((r,u,l)=>{const[n]=l,{id:p,styleId:f}=Se(u,t,s.styleMirror);return(p&&p!==-1||f&&f!==-1)&&e({id:p,styleId:f,replace:n}),r.apply(u,l)})}));let d;o.CSSStyleSheet.prototype.replaceSync&&(d=o.CSSStyleSheet.prototype.replaceSync,o.CSSStyleSheet.prototype.replaceSync=new Proxy(d,{apply:$((r,u,l)=>{const[n]=l,{id:p,styleId:f}=Se(u,t,s.styleMirror);return(p&&p!==-1||f&&f!==-1)&&e({id:p,styleId:f,replaceSync:n}),r.apply(u,l)})}));const m={};st("CSSGroupingRule")?m.CSSGroupingRule=o.CSSGroupingRule:(st("CSSMediaRule")&&(m.CSSMediaRule=o.CSSMediaRule),st("CSSConditionRule")&&(m.CSSConditionRule=o.CSSConditionRule),st("CSSSupportsRule")&&(m.CSSSupportsRule=o.CSSSupportsRule));const h={};return Object.entries(m).forEach(([r,u])=>{h[r]={insertRule:u.prototype.insertRule,deleteRule:u.prototype.deleteRule},u.prototype.insertRule=new Proxy(h[r].insertRule,{apply:$((l,n,p)=>{const[f,g]=p,{id:S,styleId:w}=Se(n.parentStyleSheet,t,s.styleMirror);return(S&&S!==-1||w&&w!==-1)&&e({id:S,styleId:w,adds:[{rule:f,index:[...ht(n),g||0]}]}),l.apply(n,p)})}),u.prototype.deleteRule=new Proxy(h[r].deleteRule,{apply:$((l,n,p)=>{const[f]=p,{id:g,styleId:S}=Se(n.parentStyleSheet,t,s.styleMirror);return(g&&g!==-1||S&&S!==-1)&&e({id:g,styleId:S,removes:[{index:[...ht(n),f]}]}),l.apply(n,p)})})}),$(()=>{o.CSSStyleSheet.prototype.insertRule=i,o.CSSStyleSheet.prototype.deleteRule=a,c&&(o.CSSStyleSheet.prototype.replace=c),d&&(o.CSSStyleSheet.prototype.replaceSync=d),Object.entries(m).forEach(([r,u])=>{u.prototype.insertRule=h[r].insertRule,u.prototype.deleteRule=h[r].deleteRule})})}function An({mirror:e,stylesheetManager:t},s){var o,i,a;let c=null;s.nodeName==="#document"?c=e.getId(s):c=e.getId(L.host(s));const d=s.nodeName==="#document"?(o=s.defaultView)==null?void 0:o.Document:(a=(i=s.ownerDocument)==null?void 0:i.defaultView)==null?void 0:a.ShadowRoot,m=d!=null&&d.prototype?Object.getOwnPropertyDescriptor(d==null?void 0:d.prototype,"adoptedStyleSheets"):void 0;return c===null||c===-1||!d||!m?()=>{}:(Object.defineProperty(s,"adoptedStyleSheets",{configurable:m.configurable,enumerable:m.enumerable,get(){var h;return(h=m.get)==null?void 0:h.call(this)},set(h){var r;const u=(r=m.set)==null?void 0:r.call(this,h);if(c!==null&&c!==-1)try{t.adoptStyleSheets(h,c)}catch(l){}return u}}),$(()=>{Object.defineProperty(s,"adoptedStyleSheets",{configurable:m.configurable,enumerable:m.enumerable,get:m.get,set:m.set})}))}function $a({styleDeclarationCb:e,mirror:t,ignoreCSSAttributes:s,stylesheetManager:o},{win:i}){const a=i.CSSStyleDeclaration.prototype.setProperty;i.CSSStyleDeclaration.prototype.setProperty=new Proxy(a,{apply:$((d,m,h)=>{var r;const[u,l,n]=h;if(s.has(u))return a.apply(m,[u,l,n]);const{id:p,styleId:f}=Se((r=m.parentRule)==null?void 0:r.parentStyleSheet,t,o.styleMirror);return(p&&p!==-1||f&&f!==-1)&&e({id:p,styleId:f,set:{property:u,value:l,priority:n},index:ht(m.parentRule)}),d.apply(m,h)})});const c=i.CSSStyleDeclaration.prototype.removeProperty;return i.CSSStyleDeclaration.prototype.removeProperty=new Proxy(c,{apply:$((d,m,h)=>{var r;const[u]=h;if(s.has(u))return c.apply(m,[u]);const{id:l,styleId:n}=Se((r=m.parentRule)==null?void 0:r.parentStyleSheet,t,o.styleMirror);return(l&&l!==-1||n&&n!==-1)&&e({id:l,styleId:n,remove:{property:u},index:ht(m.parentRule)}),d.apply(m,h)})}),$(()=>{i.CSSStyleDeclaration.prototype.setProperty=a,i.CSSStyleDeclaration.prototype.removeProperty=c})}function Ba({mediaInteractionCb:e,blockClass:t,blockSelector:s,mirror:o,sampling:i,doc:a}){const c=$(m=>qe($(h=>{const r=Je(h);if(!r||se(r,t,s,!0))return;const{currentTime:u,volume:l,muted:n,playbackRate:p,loop:f}=r;e({type:m,id:o.getId(r),currentTime:u,volume:l,muted:n,playbackRate:p,loop:f})}),i.media||500)),d=[re("play",c(De.Play),a),re("pause",c(De.Pause),a),re("seeked",c(De.Seeked),a),re("volumechange",c(De.VolumeChange),a),re("ratechange",c(De.RateChange),a)];return $(()=>{d.forEach(m=>m())})}function Ua({fontCb:e,doc:t}){const s=t.defaultView;if(!s)return()=>{};const o=[],i=new WeakMap,a=s.FontFace;s.FontFace=function(m,h,r){const u=new a(m,h,r);return i.set(u,{family:m,buffer:typeof h!="string",descriptors:r,fontSource:typeof h=="string"?h:JSON.stringify(Array.from(new Uint8Array(h)))}),u};const c=Ee(t.fonts,"add",function(d){return function(m){return setTimeout($(()=>{const h=i.get(m);h&&(e(h),i.delete(m))}),0),d.apply(this,[m])}});return o.push(()=>{s.FontFace=a}),o.push(c),$(()=>{o.forEach(d=>d())})}function Wa(e){const{doc:t,mirror:s,blockClass:o,blockSelector:i,selectionCb:a}=e;let c=!0;const d=$(()=>{const m=t.getSelection();if(!m||c&&(m!=null&&m.isCollapsed))return;c=m.isCollapsed||!1;const h=[],r=m.rangeCount||0;for(let u=0;u<r;u++){const l=m.getRangeAt(u),{startContainer:n,startOffset:p,endContainer:f,endOffset:g}=l;se(n,o,i,!0)||se(f,o,i,!0)||h.push({start:s.getId(n),startOffset:p,end:s.getId(f),endOffset:g})}a({ranges:h})});return d(),re("selectionchange",d)}function za({doc:e,customElementCb:t}){const s=e.defaultView;return!s||!s.customElements?()=>{}:Ee(s.customElements,"define",function(i){return function(a,c,d){try{t({define:{name:a}})}catch(m){console.warn(`Custom element callback failed for ${a}`)}return i.apply(this,[a,c,d])}})}function qa(e,t){const{mutationCb:s,mousemoveCb:o,mouseInteractionCb:i,scrollCb:a,viewportResizeCb:c,inputCb:d,mediaInteractionCb:m,styleSheetRuleCb:h,styleDeclarationCb:r,canvasMutationCb:u,fontCb:l,selectionCb:n,customElementCb:p}=e;e.mutationCb=(...f)=>{t.mutation&&t.mutation(...f),s(...f)},e.mousemoveCb=(...f)=>{t.mousemove&&t.mousemove(...f),o(...f)},e.mouseInteractionCb=(...f)=>{t.mouseInteraction&&t.mouseInteraction(...f),i(...f)},e.scrollCb=(...f)=>{t.scroll&&t.scroll(...f),a(...f)},e.viewportResizeCb=(...f)=>{t.viewportResize&&t.viewportResize(...f),c(...f)},e.inputCb=(...f)=>{t.input&&t.input(...f),d(...f)},e.mediaInteractionCb=(...f)=>{t.mediaInteaction&&t.mediaInteaction(...f),m(...f)},e.styleSheetRuleCb=(...f)=>{t.styleSheetRule&&t.styleSheetRule(...f),h(...f)},e.styleDeclarationCb=(...f)=>{t.styleDeclaration&&t.styleDeclaration(...f),r(...f)},e.canvasMutationCb=(...f)=>{t.canvasMutation&&t.canvasMutation(...f),u(...f)},e.fontCb=(...f)=>{t.font&&t.font(...f),l(...f)},e.selectionCb=(...f)=>{t.selection&&t.selection(...f),n(...f)},e.customElementCb=(...f)=>{t.customElement&&t.customElement(...f),p(...f)}}function ja(e,t={}){const s=e.doc.defaultView;if(!s)return()=>{};qa(e,t);let o;e.recordDOM&&(o=In(e,e.doc));const i=_a(e),a=ka(e),c=En(e),d=Da(e,{win:s}),m=Ta(e),h=Ba(e);let r=()=>{},u=()=>{},l=()=>{},n=()=>{};e.recordDOM&&(r=Fa(e,{win:s}),u=An(e,e.doc),l=$a(e,{win:s}),e.collectFonts&&(n=Ua(e)));const p=Wa(e),f=za(e),g=[];for(const S of e.plugins)g.push(S.observer(S.callback,s,S.options));return $(()=>{we.forEach(S=>S.destroy()),we.forEach(S=>S.reset()),o==null||o.disconnect(),i(),a(),c(),d(),m(),h(),r(),u(),l(),n(),p(),f(),g.forEach(S=>S()),we.length=0})}function rt(e){return typeof window[e]!="undefined"}function st(e){return!!(typeof window[e]!="undefined"&&window[e].prototype&&"insertRule"in window[e].prototype&&"deleteRule"in window[e].prototype)}class ki{constructor(t){A(this,"iframeIdToRemoteIdMap",new WeakMap),A(this,"iframeRemoteIdToIdMap",new WeakMap),this.generateIdFn=t}getId(t,s,o,i){const a=o||this.getIdToRemoteIdMap(t),c=i||this.getRemoteIdToIdMap(t);let d=a.get(s);return d||(d=this.generateIdFn(),a.set(s,d),c.set(d,s)),d}getIds(t,s){const o=this.getIdToRemoteIdMap(t),i=this.getRemoteIdToIdMap(t);return s.map(a=>this.getId(t,a,o,i))}getRemoteId(t,s,o){const i=o||this.getRemoteIdToIdMap(t);if(typeof s!="number")return s;const a=i.get(s);return a||-1}getRemoteIds(t,s){const o=this.getRemoteIdToIdMap(t);return s.map(i=>this.getRemoteId(t,i,o))}reset(t){if(!t){this.iframeIdToRemoteIdMap=new WeakMap,this.iframeRemoteIdToIdMap=new WeakMap;return}this.iframeIdToRemoteIdMap.delete(t),this.iframeRemoteIdToIdMap.delete(t)}getIdToRemoteIdMap(t){let s=this.iframeIdToRemoteIdMap.get(t);return s||(s=new Map,this.iframeIdToRemoteIdMap.set(t,s)),s}getRemoteIdToIdMap(t){let s=this.iframeRemoteIdToIdMap.get(t);return s||(s=new Map,this.iframeRemoteIdToIdMap.set(t,s)),s}}class Ha{constructor(t){A(this,"iframes",new WeakMap),A(this,"crossOriginIframeMap",new WeakMap),A(this,"crossOriginIframeMirror",new ki(qi)),A(this,"crossOriginIframeStyleMirror"),A(this,"crossOriginIframeRootIdMap",new WeakMap),A(this,"mirror"),A(this,"mutationCb"),A(this,"wrappedEmit"),A(this,"loadListener"),A(this,"stylesheetManager"),A(this,"recordCrossOriginIframes"),A(this,"messageHandler"),A(this,"nestedIframeListeners",new Map),A(this,"attachedIframes",new Map),this.mutationCb=t.mutationCb,this.wrappedEmit=t.wrappedEmit,this.stylesheetManager=t.stylesheetManager,this.recordCrossOriginIframes=t.recordCrossOriginIframes,this.crossOriginIframeStyleMirror=new ki(this.stylesheetManager.styleMirror.generateId.bind(this.stylesheetManager.styleMirror)),this.mirror=t.mirror,this.messageHandler=this.handleMessage.bind(this),this.recordCrossOriginIframes&&window.addEventListener("message",this.messageHandler)}addIframe(t){this.iframes.set(t,!0),t.contentWindow&&this.crossOriginIframeMap.set(t.contentWindow,t)}addLoadListener(t){this.loadListener=t}removeLoadListener(){this.loadListener=void 0}trackIframeContent(t,s){const o=this.mirror.getId(t);return this.attachedIframes.set(o,{element:t,content:s}),o}attachIframe(t,s){var o;const i=this.trackIframeContent(t,s);this.mutationCb({adds:[{parentId:i,nextId:null,node:s}],removes:[],texts:[],attributes:[],isAttachIframe:!0});const a=t.contentWindow;if(this.recordCrossOriginIframes&&a&&!this.nestedIframeListeners.has(a)){const c=this.handleMessage.bind(this);this.nestedIframeListeners.set(a,c),a.addEventListener("message",c)}(o=this.loadListener)==null||o.call(this,t),t.contentDocument&&t.contentDocument.adoptedStyleSheets&&t.contentDocument.adoptedStyleSheets.length>0&&this.stylesheetManager.adoptStyleSheets(t.contentDocument.adoptedStyleSheets,this.mirror.getId(t.contentDocument))}handleMessage(t){const s=t;if(s.data.type!=="rrweb"||s.origin!==s.data.origin||!t.source)return;const i=this.crossOriginIframeMap.get(t.source);if(!i)return;const a=this.transformCrossOriginEvent(i,s.data.event);a&&this.wrappedEmit(a,s.data.isCheckout)}transformCrossOriginEvent(t,s){var o;switch(s.type){case B.FullSnapshot:{this.crossOriginIframeMirror.reset(t),this.crossOriginIframeStyleMirror.reset(t),this.replaceIdOnNode(s.data.node,t);const i=s.data.node.id;return this.crossOriginIframeRootIdMap.set(t,i),this.patchRootIdOnNode(s.data.node,i),this.trackIframeContent(t,s.data.node),{timestamp:s.timestamp,type:B.IncrementalSnapshot,data:{source:F.Mutation,adds:[{parentId:this.mirror.getId(t),nextId:null,node:s.data.node}],removes:[],texts:[],attributes:[],isAttachIframe:!0}}}case B.Meta:case B.Load:case B.DomContentLoaded:return!1;case B.Plugin:return s;case B.Custom:return this.replaceIds(s.data.payload,t,["id","parentId","previousId","nextId"]),s;case B.IncrementalSnapshot:switch(s.data.source){case F.Mutation:return s.data.adds.forEach(i=>{this.replaceIds(i,t,["parentId","nextId","previousId"]),this.replaceIdOnNode(i.node,t);const a=this.crossOriginIframeRootIdMap.get(t);a&&this.patchRootIdOnNode(i.node,a)}),s.data.removes.forEach(i=>{this.replaceIds(i,t,["parentId","id"])}),s.data.attributes.forEach(i=>{this.replaceIds(i,t,["id"])}),s.data.texts.forEach(i=>{this.replaceIds(i,t,["id"])}),s;case F.Drag:case F.TouchMove:case F.MouseMove:return s.data.positions.forEach(i=>{this.replaceIds(i,t,["id"])}),s;case F.ViewportResize:return!1;case F.MediaInteraction:case F.MouseInteraction:case F.Scroll:case F.CanvasMutation:case F.Input:return this.replaceIds(s.data,t,["id"]),s;case F.StyleSheetRule:case F.StyleDeclaration:return this.replaceIds(s.data,t,["id"]),this.replaceStyleIds(s.data,t,["styleId"]),s;case F.Font:return s;case F.Selection:return s.data.ranges.forEach(i=>{this.replaceIds(i,t,["start","end"])}),s;case F.AdoptedStyleSheet:return this.replaceIds(s.data,t,["id"]),this.replaceStyleIds(s.data,t,["styleIds"]),(o=s.data.styles)==null||o.forEach(i=>{this.replaceStyleIds(i,t,["styleId"])}),s}}return!1}replace(t,s,o,i){for(const a of i)!Array.isArray(s[a])&&typeof s[a]!="number"||(Array.isArray(s[a])?s[a]=t.getIds(o,s[a]):s[a]=t.getId(o,s[a]));return s}replaceIds(t,s,o){return this.replace(this.crossOriginIframeMirror,t,s,o)}replaceStyleIds(t,s,o){return this.replace(this.crossOriginIframeStyleMirror,t,s,o)}replaceIdOnNode(t,s){this.replaceIds(t,s,["id","rootId"]),"childNodes"in t&&t.childNodes.forEach(o=>{this.replaceIdOnNode(o,s)})}patchRootIdOnNode(t,s){t.type!==On.Document&&!t.rootId&&(t.rootId=s),"childNodes"in t&&t.childNodes.forEach(o=>{this.patchRootIdOnNode(o,s)})}removeIframeById(t){const s=this.attachedIframes.get(t),o=(s==null?void 0:s.element)||this.mirror.getNode(t);if(o){const i=o.contentWindow;if(i&&this.nestedIframeListeners.has(i)){const a=this.nestedIframeListeners.get(i);i.removeEventListener("message",a),this.nestedIframeListeners.delete(i)}i&&this.crossOriginIframeMap.delete(i),this.iframes.delete(o)}s&&this.attachedIframes.delete(t)}reattachIframes(){this.attachedIframes.forEach(({content:t},s)=>{if(!this.mirror.has(s)){this.attachedIframes.delete(s);return}this.mutationCb({adds:[{parentId:s,nextId:null,node:t}],removes:[],texts:[],attributes:[],isAttachIframe:!0})})}destroy(){this.recordCrossOriginIframes&&window.removeEventListener("message",this.messageHandler),this.nestedIframeListeners.forEach((t,s)=>{s.removeEventListener("message",t)}),this.nestedIframeListeners.clear(),this.crossOriginIframeMirror.reset(),this.crossOriginIframeStyleMirror.reset(),this.attachedIframes.clear(),this.crossOriginIframeMap=new WeakMap,this.iframes=new WeakMap,this.crossOriginIframeRootIdMap=new WeakMap}}class Va{constructor(t){A(this,"shadowDoms",new WeakSet),A(this,"mutationCb"),A(this,"scrollCb"),A(this,"bypassOptions"),A(this,"mirror"),A(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,s){if(!Ue(t)||this.shadowDoms.has(t))return;this.shadowDoms.add(t);const o=In(le(T({},this.bypassOptions),{doc:s,mutationCb:this.mutationCb,mirror:this.mirror,shadowDomManager:this}),t);this.restoreHandlers.push(()=>o.disconnect()),this.restoreHandlers.push(En(le(T({},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(L.host(t))),this.restoreHandlers.push(An({mirror:this.mirror,stylesheetManager:this.bypassOptions.stylesheetManager},t))},0)}observeAttachShadow(t){!t.contentWindow||!t.contentDocument||this.patchAttachShadow(t.contentWindow.Element,t.contentDocument)}patchAttachShadow(t,s){const o=this;this.restoreHandlers.push(Ee(t.prototype,"attachShadow",function(i){return function(a){const c=i.call(this,a),d=L.shadowRoot(this);return d&&Rn(this)&&o.addShadowRoot(d,s),c}}))}reset(){this.restoreHandlers.forEach(t=>{try{t()}catch(s){}}),this.restoreHandlers=[],this.shadowDoms=new WeakSet}}var Fe="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",Ga=typeof Uint8Array=="undefined"?[]:new Uint8Array(256);for(var it=0;it<Fe.length;it++)Ga[Fe.charCodeAt(it)]=it;var Ja=function(e){var t=new Uint8Array(e),s,o=t.length,i="";for(s=0;s<o;s+=3)i+=Fe[t[s]>>2],i+=Fe[(t[s]&3)<<4|t[s+1]>>4],i+=Fe[(t[s+1]&15)<<2|t[s+2]>>6],i+=Fe[t[s+2]&63];return o%3===2?i=i.substring(0,i.length-1)+"=":o%3===1&&(i=i.substring(0,i.length-2)+"=="),i};const Di=new Map;function Ya(e,t){let s=Di.get(e);return s||(s=new Map,Di.set(e,s)),s.has(t)||s.set(t,[]),s.get(t)}const Pn=(e,t,s)=>{if(!e||!(_n(e,t)||typeof e=="object"))return;const o=e.constructor.name,i=Ya(s,o);let a=i.indexOf(e);return a===-1&&(a=i.length,i.push(e)),a};function nt(e,t,s,o){if(e instanceof Array)return e.map(i=>nt(i,t,s,o));if(e===null)return e;if(e instanceof Float32Array||e instanceof Float64Array||e instanceof Int32Array||e instanceof Uint32Array||e instanceof Uint8Array||e instanceof Uint16Array||e instanceof Int16Array||e instanceof Int8Array||e instanceof Uint8ClampedArray)return{rr_type:e.constructor.name,args:[Object.values(e)]};if(e instanceof ArrayBuffer){const i=e.constructor.name,a=Ja(e);return{rr_type:i,base64:a}}else{if(e instanceof DataView)return{rr_type:e.constructor.name,args:[nt(e.buffer,t,s,o),e.byteOffset,e.byteLength]};if(e instanceof HTMLImageElement){const i=e.constructor.name,{src:a}=e;return{rr_type:i,src:a}}else if(e instanceof HTMLCanvasElement){const i="HTMLImageElement",a=e.toDataURL(o.type,o.quality);return{rr_type:i,src:a}}else{if(e instanceof ImageData)return{rr_type:e.constructor.name,args:[nt(e.data,t,s,o),e.width,e.height]};if(_n(e,t)||typeof e=="object"){const i=e.constructor.name,a=Pn(e,t,s);return{rr_type:i,index:a}}}}return e}const Nn=(e,t,s,o)=>e.map(i=>nt(i,t,s,o)),_n=(e,t)=>!!["WebGLActiveInfo","WebGLBuffer","WebGLFramebuffer","WebGLProgram","WebGLRenderbuffer","WebGLShader","WebGLShaderPrecisionFormat","WebGLTexture","WebGLUniformLocation","WebGLVertexArrayObject","WebGLVertexArrayObjectOES"].filter(i=>typeof t[i]=="function").find(i=>e instanceof t[i]);function Za(e,t,s,o,i){const a=[],c=Object.getOwnPropertyNames(t.CanvasRenderingContext2D.prototype);for(const d of c)try{if(typeof t.CanvasRenderingContext2D.prototype[d]!="function")continue;const m=Ee(t.CanvasRenderingContext2D.prototype,d,function(h){return function(...r){return se(this.canvas,s,o,!0)||setTimeout(()=>{const u=Nn(r,t,this,i);e(this.canvas,{type:$e["2D"],property:d,args:u})},0),h.apply(this,r)}});a.push(m)}catch(m){const h=vt(t.CanvasRenderingContext2D.prototype,d,{set(r){e(this.canvas,{type:$e["2D"],property:d,args:[r],setter:!0})}});a.push(h)}return()=>{a.forEach(d=>d())}}function Xa(e){return e==="experimental-webgl"?"webgl":e}function Li(e,t,s,o){const i=[];try{const a=Ee(e.HTMLCanvasElement.prototype,"getContext",function(c){return function(d,...m){if(!se(this,t,s,!0)){const h=Xa(d);if("__context"in this||(this.__context=h),o&&["webgl","webgl2"].includes(h))if(m[0]&&typeof m[0]=="object"){const r=m[0];r.preserveDrawingBuffer||(r.preserveDrawingBuffer=!0)}else m.splice(0,1,{preserveDrawingBuffer:!0})}return c.apply(this,[d,...m])}});i.push(a)}catch(a){console.error("failed to patch HTMLCanvasElement.prototype.getContext")}return()=>{i.forEach(a=>a())}}function Ti(e,t,s,o,i,a,c){const d=[],m=Object.getOwnPropertyNames(e);for(const h of m)if(!["isContextLost","canvas","drawingBufferWidth","drawingBufferHeight"].includes(h))try{if(typeof e[h]!="function")continue;const r=Ee(e,h,function(u){return function(...l){const n=u.apply(this,l);if(Pn(n,a,this),"tagName"in this.canvas&&!se(this.canvas,o,i,!0)){const p=Nn(l,a,this,c),f={type:t,property:h,args:p};s(this.canvas,f)}return n}});d.push(r)}catch(r){const u=vt(e,h,{set(l){s(this.canvas,{type:t,property:h,args:[l],setter:!0})}});d.push(u)}return d}function Qa(e,t,s,o,i){const a=[];return a.push(...Ti(t.WebGLRenderingContext.prototype,$e.WebGL,e,s,o,t,i)),typeof t.WebGL2RenderingContext!="undefined"&&a.push(...Ti(t.WebGL2RenderingContext.prototype,$e.WebGL2,e,s,o,t,i)),()=>{a.forEach(c=>c())}}const kn=`(function() {
|
|
58
|
+
or you can use record.mirror to access the mirror instance during recording.`;let Ai={map:{},getId(){return console.error(De),-1},getNode(){return console.error(De),null},removeNodeFromMap(){console.error(De)},has(){return console.error(De),!1},reset(){console.error(De)}};typeof window!="undefined"&&window.Proxy&&window.Reflect&&(Ai=new Proxy(Ai,{get(e,t,s){return t==="map"&&console.error(De),Reflect.get(e,t,s)}}));function He(e,t,s={}){let o=null,i=0;return function(...a){const c=Date.now();!i&&s.leading===!1&&(i=c);const d=t-(c-i),m=this;d<=0||d>t?(o&&(clearTimeout(o),o=null),i=c,e.apply(m,a)):!o&&s.trailing!==!1&&(o=setTimeout(()=>{i=s.leading===!1?0:Date.now(),o=null,e.apply(m,a)},d))}}function xt(e,t,s,o,i=window){const a=i.Object.getOwnPropertyDescriptor(e,t);return i.Object.defineProperty(e,t,o?s:{set(c){setTimeout(()=>{s.set.call(this,c)},0),a&&a.set&&a.set.call(this,c)}}),()=>xt(e,t,a||{},!0)}let ft=Date.now;/[1-9][0-9]{12}/.test(Date.now().toString())||(ft=()=>new Date().getTime());function wn(e){var t,s,o,i;const a=e.document;return{left:a.scrollingElement?a.scrollingElement.scrollLeft:e.pageXOffset!==void 0?e.pageXOffset:a.documentElement.scrollLeft||(a==null?void 0:a.body)&&((t=L.parentElement(a.body))==null?void 0:t.scrollLeft)||((s=a==null?void 0:a.body)==null?void 0:s.scrollLeft)||0,top:a.scrollingElement?a.scrollingElement.scrollTop:e.pageYOffset!==void 0?e.pageYOffset:(a==null?void 0:a.documentElement.scrollTop)||(a==null?void 0:a.body)&&((o=L.parentElement(a.body))==null?void 0:o.scrollTop)||((i=a==null?void 0:a.body)==null?void 0:i.scrollTop)||0}}function bn(){return window.innerHeight||document.documentElement&&document.documentElement.clientHeight||document.body&&document.body.clientHeight}function Sn(){return window.innerWidth||document.documentElement&&document.documentElement.clientWidth||document.body&&document.body.clientWidth}function vn(e){return e?e.nodeType===e.ELEMENT_NODE?e:L.parentElement(e):null}function re(e,t,s,o){if(!e)return!1;const i=vn(e);if(!i)return!1;try{if(typeof t=="string"){if(i.classList.contains(t)||o&&i.closest("."+t)!==null)return!0}else if(ht(i,t,o))return!0}catch(a){}return!!(s&&(i.matches(s)||o&&i.closest(s)!==null))}function xa(e,t){return t.getId(e)!==-1}function kr(e,t,s){return e.tagName==="TITLE"&&s.headTitleMutations?!0:t.getId(e)===je}function Cn(e,t){if(We(e))return!1;const s=t.getId(e);if(!t.has(s))return!0;const o=L.parentNode(e);return o&&o.nodeType===e.DOCUMENT_NODE?!1:o?Cn(o,t):!0}function Tr(e){return!!e.changedTouches}function Ra(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 xn(e,t){return!!(e.nodeName==="IFRAME"&&t.getMeta(e))}function Rn(e,t){return!!(e.nodeName==="LINK"&&e.nodeType===e.ELEMENT_NODE&&e.getAttribute&&e.getAttribute("rel")==="stylesheet"&&t.getMeta(e))}function Fr(e){return e?e instanceof ns&&"shadowRoot"in e?!!e.shadowRoot:!!L.shadowRoot(e):!1}class Oa{constructor(){A(this,"id",1),A(this,"styleIDMap",new WeakMap),A(this,"idStyleMap",new Map)}getId(t){var s;return(s=this.styleIDMap.get(t))!=null?s:-1}has(t){return this.styleIDMap.has(t)}add(t,s){if(this.has(t))return this.getId(t);let o;return s===void 0?o=this.id++:o=s,this.styleIDMap.set(t,o),this.idStyleMap.set(o,t),o}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 On(e){var t;let s=null;return"getRootNode"in e&&((t=L.getRootNode(e))==null?void 0:t.nodeType)===Node.DOCUMENT_FRAGMENT_NODE&&L.host(L.getRootNode(e))&&(s=L.host(L.getRootNode(e))),s}function Ma(e){let t=e,s;for(;s=On(t);)t=s;return t}function Ia(e){const t=e.ownerDocument;if(!t)return!1;const s=Ma(e);return L.contains(t,s)}function Mn(e){const t=e.ownerDocument;return t?L.contains(t,e)||Ia(e):!1}var B=(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))(B||{}),F=(e=>(e[e.Mutation=0]="Mutation",e[e.MouseMove=1]="MouseMove",e[e.MouseInteraction=2]="MouseInteraction",e[e.Scroll=3]="Scroll",e[e.ViewportResize=4]="ViewportResize",e[e.Input=5]="Input",e[e.TouchMove=6]="TouchMove",e[e.MediaInteraction=7]="MediaInteraction",e[e.StyleSheetRule=8]="StyleSheetRule",e[e.CanvasMutation=9]="CanvasMutation",e[e.Font=10]="Font",e[e.Log=11]="Log",e[e.Drag=12]="Drag",e[e.StyleDeclaration=13]="StyleDeclaration",e[e.Selection=14]="Selection",e[e.AdoptedStyleSheet=15]="AdoptedStyleSheet",e[e.CustomElement=16]="CustomElement",e))(F||{}),ie=(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))(ie||{}),Se=(e=>(e[e.Mouse=0]="Mouse",e[e.Pen=1]="Pen",e[e.Touch=2]="Touch",e))(Se||{}),Be=(e=>(e[e["2D"]=0]="2D",e[e.WebGL=1]="WebGL",e[e.WebGL2=2]="WebGL2",e))(Be||{}),Le=(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))(Le||{}),In=(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))(In||{});function Pi(e){return"__ln"in e}class Ea{constructor(){A(this,"length",0),A(this,"head",null),A(this,"tail",null)}get(t){if(t>=this.length)throw new Error("Position outside of list range");let s=this.head;for(let o=0;o<t;o++)s=(s==null?void 0:s.next)||null;return s}addNode(t){const s={value:t,previous:null,next:null};if(t.__ln=s,t.previousSibling&&Pi(t.previousSibling)){const o=t.previousSibling.__ln.next;s.next=o,s.previous=t.previousSibling.__ln,t.previousSibling.__ln.next=s,o&&(o.previous=s)}else if(t.nextSibling&&Pi(t.nextSibling)&&t.nextSibling.__ln.previous){const o=t.nextSibling.__ln.previous;s.previous=o,s.next=t.nextSibling.__ln,t.nextSibling.__ln.previous=s,o&&(o.next=s)}else this.head&&(this.head.previous=s),s.next=this.head,this.head=s;s.next===null&&(this.tail=s),this.length++}removeNode(t){const s=t.__ln;this.head&&(s.previous?(s.previous.next=s.next,s.next?s.next.previous=s.previous:this.tail=s.previous):(this.head=s.next,this.head?this.head.previous=null:this.tail=null),t.__ln&&delete t.__ln,this.length--)}}const Ni=(e,t)=>`${e}@${t}`;class Aa{constructor(){A(this,"frozen",!1),A(this,"locked",!1),A(this,"texts",[]),A(this,"attributes",[]),A(this,"attributeMap",new WeakMap),A(this,"removes",[]),A(this,"mapRemoves",[]),A(this,"movedMap",{}),A(this,"addedSet",new Set),A(this,"movedSet",new Set),A(this,"droppedSet",new Set),A(this,"removesSubTreeCache",new Set),A(this,"mutationCb"),A(this,"blockClass"),A(this,"blockSelector"),A(this,"maskTextClass"),A(this,"maskTextSelector"),A(this,"inlineStylesheet"),A(this,"maskInputOptions"),A(this,"maskTextFn"),A(this,"maskInputFn"),A(this,"keepIframeSrcFn"),A(this,"recordCanvas"),A(this,"inlineImages"),A(this,"slimDOMOptions"),A(this,"dataURLOptions"),A(this,"doc"),A(this,"mirror"),A(this,"iframeManager"),A(this,"stylesheetManager"),A(this,"shadowDomManager"),A(this,"canvasManager"),A(this,"processedNodeManager"),A(this,"unattachedDoc"),A(this,"processMutations",t=>{t.forEach(this.processMutation),this.emit()}),A(this,"emit",()=>{if(this.frozen||this.locked)return;const t=[],s=new Set,o=new Ea,i=m=>{let h=m,r=je;for(;r===je;)h=h&&h.nextSibling,r=h&&this.mirror.getId(h);return r},a=m=>{const h=L.parentNode(m);if(!h||!Mn(m)||h.tagName==="TEXTAREA")return;const r=We(h)?this.mirror.getId(On(m)):this.mirror.getId(h),u=i(m);if(r===-1||u===-1)return o.addNode(m);const l=Fe(m,{doc:this.doc,mirror:this.mirror,blockClass:this.blockClass,blockSelector:this.blockSelector,maskTextClass:this.maskTextClass,maskTextSelector:this.maskTextSelector,skipChild:!0,newlyAddedElement:!0,inlineStylesheet:this.inlineStylesheet,maskInputOptions:this.maskInputOptions,maskTextFn:this.maskTextFn,maskInputFn:this.maskInputFn,slimDOMOptions:this.slimDOMOptions,dataURLOptions:this.dataURLOptions,recordCanvas:this.recordCanvas,inlineImages:this.inlineImages,onSerialize:n=>{xn(n,this.mirror)&&this.iframeManager.addIframe(n),Rn(n,this.mirror)&&this.stylesheetManager.trackLinkElement(n),Fr(m)&&this.shadowDomManager.addShadowRoot(L.shadowRoot(m),this.doc)},onIframeLoad:(n,p)=>{this.iframeManager.attachIframe(n,p),this.shadowDomManager.observeAttachShadow(n)},onStylesheetLoad:(n,p)=>{this.stylesheetManager.attachLinkElement(n,p)}});l&&(t.push({parentId:r,nextId:u,node:l}),s.add(l.id))};for(;this.mapRemoves.length;)this.mirror.removeNodeFromMap(this.mapRemoves.shift());for(const m of this.movedSet)_i(this.removesSubTreeCache,m,this.mirror)&&!this.movedSet.has(L.parentNode(m))||a(m);for(const m of this.addedSet)!ki(this.droppedSet,m)&&!_i(this.removesSubTreeCache,m,this.mirror)||ki(this.movedSet,m)?a(m):this.droppedSet.add(m);let c=null;for(;o.length;){let m=null;if(c){const h=this.mirror.getId(L.parentNode(c.value)),r=i(c.value);h!==-1&&r!==-1&&(m=c)}if(!m){let h=o.tail;for(;h;){const r=h;if(h=h.previous,r){const u=this.mirror.getId(L.parentNode(r.value));if(i(r.value)===-1)continue;if(u!==-1){m=r;break}else{const n=r.value,p=L.parentNode(n);if(p&&p.nodeType===Node.DOCUMENT_FRAGMENT_NODE){const f=L.host(p);if(this.mirror.getId(f)!==-1){m=r;break}}}}}}if(!m){for(;o.head;)o.removeNode(o.head.value);break}c=m.previous,o.removeNode(m.value),a(m.value)}const d={texts:this.texts.map(m=>{const h=m.node,r=L.parentNode(h);return r&&r.tagName==="TEXTAREA"&&this.genTextAreaValueMutation(r),{id:this.mirror.getId(h),value:m.value}}).filter(m=>!s.has(m.id)).filter(m=>this.mirror.has(m.id)),attributes:this.attributes.map(m=>{const{attributes:h}=m;if(typeof h.style=="string"){const r=JSON.stringify(m.styleDiff),u=JSON.stringify(m._unchangedStyles);r.length<h.style.length&&(r+u).split("var(").length===h.style.split("var(").length&&(h.style=m.styleDiff)}return{id:this.mirror.getId(m.node),attributes:h}}).filter(m=>!s.has(m.id)).filter(m=>this.mirror.has(m.id)),removes:this.removes,adds:t};!d.texts.length&&!d.attributes.length&&!d.removes.length&&!d.adds.length||(this.texts=[],this.attributes=[],this.attributeMap=new WeakMap,this.removes=[],this.addedSet=new Set,this.movedSet=new Set,this.droppedSet=new Set,this.removesSubTreeCache=new Set,this.movedMap={},this.mutationCb(d))}),A(this,"genTextAreaValueMutation",t=>{let s=this.attributeMap.get(t);s||(s={node:t,attributes:{},styleDiff:{},_unchangedStyles:{}},this.attributes.push(s),this.attributeMap.set(t,s)),s.attributes.value=Array.from(L.childNodes(t),o=>L.textContent(o)||"").join("")}),A(this,"processMutation",t=>{if(!kr(t.target,this.mirror,this.slimDOMOptions))switch(t.type){case"characterData":{const s=L.textContent(t.target);!re(t.target,this.blockClass,this.blockSelector,!1)&&s!==t.oldValue&&this.texts.push({value:Ji(t.target,this.maskTextClass,this.maskTextSelector,!0)&&s?this.maskTextFn?this.maskTextFn(s,vn(t.target)):s.replace(/[\S]/g,"*"):s,node:t.target});break}case"attributes":{const s=t.target;let o=t.attributeName,i=t.target.getAttribute(o);if(o==="value"){const c=zr(s);i=Wr({element:s,maskInputOptions:this.maskInputOptions,tagName:s.tagName,type:c,value:i,maskInputFn:this.maskInputFn})}if(re(t.target,this.blockClass,this.blockSelector,!1)||i===t.oldValue)return;let a=this.attributeMap.get(t.target);if(s.tagName==="IFRAME"&&o==="src"&&!this.keepIframeSrcFn(i))if(!s.contentDocument)o="rr_src";else return;if(a||(a={node:t.target,attributes:{},styleDiff:{},_unchangedStyles:{}},this.attributes.push(a),this.attributeMap.set(t.target,a)),o==="type"&&s.tagName==="INPUT"&&(t.oldValue||"").toLowerCase()==="password"&&s.setAttribute("data-rr-is-password","true"),!Gi(s.tagName,o))if(a.attributes[o]=Vi(this.doc,Ie(s.tagName),Ie(o),i,s,this.dataURLOptions),o==="style"){if(!this.unattachedDoc)try{this.unattachedDoc=document.implementation.createHTMLDocument()}catch(d){this.unattachedDoc=this.doc}const c=this.unattachedDoc.createElement("span");t.oldValue&&c.setAttribute("style",t.oldValue);for(const d of Array.from(s.style)){const m=s.style.getPropertyValue(d),h=s.style.getPropertyPriority(d);m!==c.style.getPropertyValue(d)||h!==c.style.getPropertyPriority(d)?h===""?a.styleDiff[d]=m:a.styleDiff[d]=[m,h]:a._unchangedStyles[d]=[m,h]}for(const d of Array.from(c.style))s.style.getPropertyValue(d)===""&&(a.styleDiff[d]=!1)}else o==="open"&&s.tagName==="DIALOG"&&(s.matches("dialog:modal")?a.attributes.rr_open_mode="modal":a.attributes.rr_open_mode="non-modal");break}case"childList":{if(re(t.target,this.blockClass,this.blockSelector,!0))return;if(t.target.tagName==="TEXTAREA"){this.genTextAreaValueMutation(t.target);return}t.addedNodes.forEach(s=>this.genAdds(s,t.target)),t.removedNodes.forEach(s=>{const o=this.mirror.getId(s),i=We(t.target)?this.mirror.getId(L.host(t.target)):this.mirror.getId(t.target);re(t.target,this.blockClass,this.blockSelector,!1)||kr(s,this.mirror,this.slimDOMOptions)||!xa(s,this.mirror)||(this.addedSet.has(s)?($r(this.addedSet,s),this.droppedSet.add(s)):this.addedSet.has(t.target)&&o===-1||Cn(t.target,this.mirror)||(this.movedSet.has(s)&&this.movedMap[Ni(o,i)]?$r(this.movedSet,s):(this.removes.push({parentId:i,id:o,isShadow:We(t.target)&&ze(t.target)?!0:void 0}),Pa(s,this.removesSubTreeCache))),this.mapRemoves.push(s))});break}}}),A(this,"genAdds",(t,s)=>{if(!this.processedNodeManager.inOtherBuffer(t,this)&&!(this.addedSet.has(t)||this.movedSet.has(t))){if(this.mirror.hasNode(t)){if(kr(t,this.mirror,this.slimDOMOptions))return;this.movedSet.add(t);let o=null;s&&this.mirror.hasNode(s)&&(o=this.mirror.getId(s)),o&&o!==-1&&(this.movedMap[Ni(this.mirror.getId(t),o)]=!0)}else this.addedSet.add(t),this.droppedSet.delete(t);re(t,this.blockClass,this.blockSelector,!1)||(L.childNodes(t).forEach(o=>this.genAdds(o)),Fr(t)&&L.childNodes(L.shadowRoot(t)).forEach(o=>{this.processedNodeManager.add(o,this),this.genAdds(o,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(s=>{this[s]=t[s]})}freeze(){this.frozen=!0,this.canvasManager.freeze()}unfreeze(){this.frozen=!1,this.canvasManager.unfreeze(),this.emit()}isFrozen(){return this.frozen}lock(){this.locked=!0,this.canvasManager.lock()}unlock(){this.locked=!1,this.canvasManager.unlock(),this.emit()}reset(){this.shadowDomManager.reset(),this.canvasManager.reset()}destroy(){for(;this.mapRemoves.length;)this.mirror.removeNodeFromMap(this.mapRemoves.shift())}}function $r(e,t){e.delete(t),L.childNodes(t).forEach(s=>$r(e,s))}function Pa(e,t){const s=[e];for(;s.length;){const o=s.pop();t.has(o)||(t.add(o),L.childNodes(o).forEach(i=>s.push(i)))}}function _i(e,t,s){return e.size===0?!1:Na(e,t)}function Na(e,t,s){const o=L.parentNode(t);return o?e.has(o):!1}function ki(e,t){return e.size===0?!1:En(e,t)}function En(e,t){const s=L.parentNode(t);return s?e.has(s)?!0:En(e,s):!1}let qe;function _a(e){qe=e}function ka(){qe=void 0}const $=e=>qe?(...s)=>{try{return e(...s)}catch(o){if(qe&&qe(o)===!0)return;throw o}}:e,ge=[];function Ze(e){try{if("composedPath"in e){const t=e.composedPath();if(t.length)return t[0]}else if("path"in e&&e.path.length)return e.path[0]}catch(t){}return e&&e.target}function An(e,t){const s=new Aa;ge.push(s),s.init(e);const o=new(yn())($(s.processMutations.bind(s)));return o.observe(t,{attributes:!0,attributeOldValue:!0,characterData:!0,characterDataOldValue:!0,childList:!0,subtree:!0}),{observer:o,buffer:s}}function Da({mousemoveCb:e,sampling:t,doc:s,mirror:o}){if(t.mousemove===!1)return()=>{};const i=typeof t.mousemove=="number"?t.mousemove:50,a=typeof t.mousemoveCallback=="number"?t.mousemoveCallback:500;let c=[],d;const m=He($(u=>{const l=Date.now()-d;e(c.map(n=>(n.timeOffset-=l,n)),u),c=[],d=null}),a),h=$(He($(u=>{const l=Ze(u),{clientX:n,clientY:p}=Tr(u)?u.changedTouches[0]:u;d||(d=ft()),c.push({x:n,y:p,id:o.getId(l),timeOffset:ft()-d}),m(typeof DragEvent!="undefined"&&u instanceof DragEvent?F.Drag:u instanceof MouseEvent?F.MouseMove:F.TouchMove)}),i,{trailing:!1})),r=[te("mousemove",h,s),te("touchmove",h,s),te("drag",h,s)];return $(()=>{r.forEach(u=>u())})}function La({mouseInteractionCb:e,doc:t,mirror:s,blockClass:o,blockSelector:i,sampling:a}){if(a.mouseInteraction===!1)return()=>{};const c=a.mouseInteraction===!0||a.mouseInteraction===void 0?{}:a.mouseInteraction,d=[];let m=null;const h=r=>u=>{const l=Ze(u);if(re(l,o,i,!0))return;let n=null,p=r;if("pointerType"in u){switch(u.pointerType){case"mouse":n=Se.Mouse;break;case"touch":n=Se.Touch;break;case"pen":n=Se.Pen;break}n===Se.Touch?ie[r]===ie.MouseDown?p="TouchStart":ie[r]===ie.MouseUp&&(p="TouchEnd"):Se.Pen}else Tr(u)&&(n=Se.Touch);n!==null?(m=n,(p.startsWith("Touch")&&n===Se.Touch||p.startsWith("Mouse")&&n===Se.Mouse)&&(n=null)):ie[r]===ie.Click&&(n=m,m=null);const f=Tr(u)?u.changedTouches[0]:u;if(!f)return;const g=s.getId(l),{clientX:S,clientY:w}=f;$(e)(T({type:ie[p],id:g,x:S,y:w},n!==null&&{pointerType:n}))};return Object.keys(ie).filter(r=>Number.isNaN(Number(r))&&!r.endsWith("_Departed")&&c[r]!==!1).forEach(r=>{let u=Ie(r);const l=h(r);if(window.PointerEvent)switch(ie[r]){case ie.MouseDown:case ie.MouseUp:u=u.replace("mouse","pointer");break;case ie.TouchStart:case ie.TouchEnd:return}d.push(te(u,l,t))}),$(()=>{d.forEach(r=>r())})}function Pn({scrollCb:e,doc:t,mirror:s,blockClass:o,blockSelector:i,sampling:a}){const c=$(He($(d=>{const m=Ze(d);if(!m||re(m,o,i,!0))return;const h=s.getId(m);if(m===t&&t.defaultView){const r=wn(t.defaultView);e({id:h,x:r.left,y:r.top})}else e({id:h,x:m.scrollLeft,y:m.scrollTop})}),a.scroll||100));return te("scroll",c,t)}function Ta({viewportResizeCb:e},{win:t}){let s=-1,o=-1;const i=$(He($(()=>{const a=bn(),c=Sn();(s!==a||o!==c)&&(e({width:Number(c),height:Number(a)}),s=a,o=c)}),200));return te("resize",i,t)}const Fa=["INPUT","TEXTAREA","SELECT"],Di=new WeakMap;function $a({inputCb:e,doc:t,mirror:s,blockClass:o,blockSelector:i,ignoreClass:a,ignoreSelector:c,maskInputOptions:d,maskInputFn:m,sampling:h,userTriggeredOnInput:r}){function u(w){let v=Ze(w);const x=w.isTrusted,y=v&&v.tagName;if(v&&y==="OPTION"&&(v=L.parentElement(v)),!v||!y||Fa.indexOf(y)<0||re(v,o,i,!0)||v.classList.contains(a)||c&&v.matches(c))return;let b=v.value,C=!1;const R=zr(v)||"";R==="radio"||R==="checkbox"?C=v.checked:(d[y.toLowerCase()]||d[R])&&(b=Wr({element:v,maskInputOptions:d,tagName:y,type:R,value:b,maskInputFn:m})),l(v,r?{text:b,isChecked:C,userTriggered:x}:{text:b,isChecked:C});const I=v.name;R==="radio"&&I&&C&&t.querySelectorAll(`input[type="radio"][name="${I}"]`).forEach(O=>{if(O!==v){const N=O.value;l(O,r?{text:N,isChecked:!C,userTriggered:!1}:{text:N,isChecked:!C})}})}function l(w,v){const x=Di.get(w);if(!x||x.text!==v.text||x.isChecked!==v.isChecked){Di.set(w,v);const y=s.getId(w);$(e)(le(T({},v),{id:y}))}}const p=(h.input==="last"?["change"]:["input","change"]).map(w=>te(w,$(u),t)),f=t.defaultView;if(!f)return()=>{p.forEach(w=>w())};const g=f.Object.getOwnPropertyDescriptor(f.HTMLInputElement.prototype,"value"),S=[[f.HTMLInputElement.prototype,"value"],[f.HTMLInputElement.prototype,"checked"],[f.HTMLSelectElement.prototype,"value"],[f.HTMLTextAreaElement.prototype,"value"],[f.HTMLSelectElement.prototype,"selectedIndex"],[f.HTMLOptionElement.prototype,"selected"]];return g&&g.set&&p.push(...S.map(w=>xt(w[0],w[1],{set(){$(u)({target:this,isTrusted:!1})}},!1,f))),$(()=>{p.forEach(w=>w())})}function pt(e){const t=[];function s(o,i){if(it("CSSGroupingRule")&&o.parentRule instanceof CSSGroupingRule||it("CSSMediaRule")&&o.parentRule instanceof CSSMediaRule||it("CSSSupportsRule")&&o.parentRule instanceof CSSSupportsRule||it("CSSConditionRule")&&o.parentRule instanceof CSSConditionRule){const c=Array.from(o.parentRule.cssRules).indexOf(o);i.unshift(c)}else if(o.parentStyleSheet){const c=Array.from(o.parentStyleSheet.cssRules).indexOf(o);i.unshift(c)}return i}return s(e,t)}function xe(e,t,s){let o,i;return e?(e.ownerNode?o=t.getId(e.ownerNode):i=s.getId(e),{styleId:i,id:o}):{}}function Ba({styleSheetRuleCb:e,mirror:t,stylesheetManager:s},{win:o}){if(!o.CSSStyleSheet||!o.CSSStyleSheet.prototype)return()=>{};const i=o.CSSStyleSheet.prototype.insertRule;o.CSSStyleSheet.prototype.insertRule=new Proxy(i,{apply:$((r,u,l)=>{const[n,p]=l,{id:f,styleId:g}=xe(u,t,s.styleMirror);return(f&&f!==-1||g&&g!==-1)&&e({id:f,styleId:g,adds:[{rule:n,index:p}]}),r.apply(u,l)})}),o.CSSStyleSheet.prototype.addRule=function(r,u,l=this.cssRules.length){const n=`${r} { ${u} }`;return o.CSSStyleSheet.prototype.insertRule.apply(this,[n,l])};const a=o.CSSStyleSheet.prototype.deleteRule;o.CSSStyleSheet.prototype.deleteRule=new Proxy(a,{apply:$((r,u,l)=>{const[n]=l,{id:p,styleId:f}=xe(u,t,s.styleMirror);return(p&&p!==-1||f&&f!==-1)&&e({id:p,styleId:f,removes:[{index:n}]}),r.apply(u,l)})}),o.CSSStyleSheet.prototype.removeRule=function(r){return o.CSSStyleSheet.prototype.deleteRule.apply(this,[r])};let c;o.CSSStyleSheet.prototype.replace&&(c=o.CSSStyleSheet.prototype.replace,o.CSSStyleSheet.prototype.replace=new Proxy(c,{apply:$((r,u,l)=>{const[n]=l,{id:p,styleId:f}=xe(u,t,s.styleMirror);return(p&&p!==-1||f&&f!==-1)&&e({id:p,styleId:f,replace:n}),r.apply(u,l)})}));let d;o.CSSStyleSheet.prototype.replaceSync&&(d=o.CSSStyleSheet.prototype.replaceSync,o.CSSStyleSheet.prototype.replaceSync=new Proxy(d,{apply:$((r,u,l)=>{const[n]=l,{id:p,styleId:f}=xe(u,t,s.styleMirror);return(p&&p!==-1||f&&f!==-1)&&e({id:p,styleId:f,replaceSync:n}),r.apply(u,l)})}));const m={};nt("CSSGroupingRule")?m.CSSGroupingRule=o.CSSGroupingRule:(nt("CSSMediaRule")&&(m.CSSMediaRule=o.CSSMediaRule),nt("CSSConditionRule")&&(m.CSSConditionRule=o.CSSConditionRule),nt("CSSSupportsRule")&&(m.CSSSupportsRule=o.CSSSupportsRule));const h={};return Object.entries(m).forEach(([r,u])=>{h[r]={insertRule:u.prototype.insertRule,deleteRule:u.prototype.deleteRule},u.prototype.insertRule=new Proxy(h[r].insertRule,{apply:$((l,n,p)=>{const[f,g]=p,{id:S,styleId:w}=xe(n.parentStyleSheet,t,s.styleMirror);return(S&&S!==-1||w&&w!==-1)&&e({id:S,styleId:w,adds:[{rule:f,index:[...pt(n),g||0]}]}),l.apply(n,p)})}),u.prototype.deleteRule=new Proxy(h[r].deleteRule,{apply:$((l,n,p)=>{const[f]=p,{id:g,styleId:S}=xe(n.parentStyleSheet,t,s.styleMirror);return(g&&g!==-1||S&&S!==-1)&&e({id:g,styleId:S,removes:[{index:[...pt(n),f]}]}),l.apply(n,p)})})}),$(()=>{o.CSSStyleSheet.prototype.insertRule=i,o.CSSStyleSheet.prototype.deleteRule=a,c&&(o.CSSStyleSheet.prototype.replace=c),d&&(o.CSSStyleSheet.prototype.replaceSync=d),Object.entries(m).forEach(([r,u])=>{u.prototype.insertRule=h[r].insertRule,u.prototype.deleteRule=h[r].deleteRule})})}function Nn({mirror:e,stylesheetManager:t},s){var o,i,a;let c=null;s.nodeName==="#document"?c=e.getId(s):c=e.getId(L.host(s));const d=s.nodeName==="#document"?(o=s.defaultView)==null?void 0:o.Document:(a=(i=s.ownerDocument)==null?void 0:i.defaultView)==null?void 0:a.ShadowRoot,m=d!=null&&d.prototype?Object.getOwnPropertyDescriptor(d==null?void 0:d.prototype,"adoptedStyleSheets"):void 0;return c===null||c===-1||!d||!m?()=>{}:(Object.defineProperty(s,"adoptedStyleSheets",{configurable:m.configurable,enumerable:m.enumerable,get(){var h;return(h=m.get)==null?void 0:h.call(this)},set(h){var r;const u=(r=m.set)==null?void 0:r.call(this,h);if(c!==null&&c!==-1)try{t.adoptStyleSheets(h,c)}catch(l){}return u}}),$(()=>{Object.defineProperty(s,"adoptedStyleSheets",{configurable:m.configurable,enumerable:m.enumerable,get:m.get,set:m.set})}))}function Ua({styleDeclarationCb:e,mirror:t,ignoreCSSAttributes:s,stylesheetManager:o},{win:i}){const a=i.CSSStyleDeclaration.prototype.setProperty;i.CSSStyleDeclaration.prototype.setProperty=new Proxy(a,{apply:$((d,m,h)=>{var r;const[u,l,n]=h;if(s.has(u))return a.apply(m,[u,l,n]);const{id:p,styleId:f}=xe((r=m.parentRule)==null?void 0:r.parentStyleSheet,t,o.styleMirror);return(p&&p!==-1||f&&f!==-1)&&e({id:p,styleId:f,set:{property:u,value:l,priority:n},index:pt(m.parentRule)}),d.apply(m,h)})});const c=i.CSSStyleDeclaration.prototype.removeProperty;return i.CSSStyleDeclaration.prototype.removeProperty=new Proxy(c,{apply:$((d,m,h)=>{var r;const[u]=h;if(s.has(u))return c.apply(m,[u]);const{id:l,styleId:n}=xe((r=m.parentRule)==null?void 0:r.parentStyleSheet,t,o.styleMirror);return(l&&l!==-1||n&&n!==-1)&&e({id:l,styleId:n,remove:{property:u},index:pt(m.parentRule)}),d.apply(m,h)})}),$(()=>{i.CSSStyleDeclaration.prototype.setProperty=a,i.CSSStyleDeclaration.prototype.removeProperty=c})}function Wa({mediaInteractionCb:e,blockClass:t,blockSelector:s,mirror:o,sampling:i,doc:a}){const c=$(m=>He($(h=>{const r=Ze(h);if(!r||re(r,t,s,!0))return;const{currentTime:u,volume:l,muted:n,playbackRate:p,loop:f}=r;e({type:m,id:o.getId(r),currentTime:u,volume:l,muted:n,playbackRate:p,loop:f})}),i.media||500)),d=[te("play",c(Le.Play),a),te("pause",c(Le.Pause),a),te("seeked",c(Le.Seeked),a),te("volumechange",c(Le.VolumeChange),a),te("ratechange",c(Le.RateChange),a)];return $(()=>{d.forEach(m=>m())})}function za({fontCb:e,doc:t}){const s=t.defaultView;if(!s)return()=>{};const o=[],i=new WeakMap,a=s.FontFace;s.FontFace=function(m,h,r){const u=new a(m,h,r);return i.set(u,{family:m,buffer:typeof h!="string",descriptors:r,fontSource:typeof h=="string"?h:JSON.stringify(Array.from(new Uint8Array(h)))}),u};const c=Pe(t.fonts,"add",function(d){return function(m){return setTimeout($(()=>{const h=i.get(m);h&&(e(h),i.delete(m))}),0),d.apply(this,[m])}});return o.push(()=>{s.FontFace=a}),o.push(c),$(()=>{o.forEach(d=>d())})}function qa(e){const{doc:t,mirror:s,blockClass:o,blockSelector:i,selectionCb:a}=e;let c=!0;const d=$(()=>{const m=t.getSelection();if(!m||c&&(m!=null&&m.isCollapsed))return;c=m.isCollapsed||!1;const h=[],r=m.rangeCount||0;for(let u=0;u<r;u++){const l=m.getRangeAt(u),{startContainer:n,startOffset:p,endContainer:f,endOffset:g}=l;re(n,o,i,!0)||re(f,o,i,!0)||h.push({start:s.getId(n),startOffset:p,end:s.getId(f),endOffset:g})}a({ranges:h})});return d(),te("selectionchange",d)}function ja({doc:e,customElementCb:t}){const s=e.defaultView;return!s||!s.customElements?()=>{}:Pe(s.customElements,"define",function(i){return function(a,c,d){try{t({define:{name:a}})}catch(m){console.warn(`Custom element callback failed for ${a}`)}return i.apply(this,[a,c,d])}})}function Ha(e,t){const{mutationCb:s,mousemoveCb:o,mouseInteractionCb:i,scrollCb:a,viewportResizeCb:c,inputCb:d,mediaInteractionCb:m,styleSheetRuleCb:h,styleDeclarationCb:r,canvasMutationCb:u,fontCb:l,selectionCb:n,customElementCb:p}=e;e.mutationCb=(...f)=>{t.mutation&&t.mutation(...f),s(...f)},e.mousemoveCb=(...f)=>{t.mousemove&&t.mousemove(...f),o(...f)},e.mouseInteractionCb=(...f)=>{t.mouseInteraction&&t.mouseInteraction(...f),i(...f)},e.scrollCb=(...f)=>{t.scroll&&t.scroll(...f),a(...f)},e.viewportResizeCb=(...f)=>{t.viewportResize&&t.viewportResize(...f),c(...f)},e.inputCb=(...f)=>{t.input&&t.input(...f),d(...f)},e.mediaInteractionCb=(...f)=>{t.mediaInteaction&&t.mediaInteaction(...f),m(...f)},e.styleSheetRuleCb=(...f)=>{t.styleSheetRule&&t.styleSheetRule(...f),h(...f)},e.styleDeclarationCb=(...f)=>{t.styleDeclaration&&t.styleDeclaration(...f),r(...f)},e.canvasMutationCb=(...f)=>{t.canvasMutation&&t.canvasMutation(...f),u(...f)},e.fontCb=(...f)=>{t.font&&t.font(...f),l(...f)},e.selectionCb=(...f)=>{t.selection&&t.selection(...f),n(...f)},e.customElementCb=(...f)=>{t.customElement&&t.customElement(...f),p(...f)}}function Va(e,t={}){const s=e.doc.defaultView;if(!s)return()=>{};Ha(e,t);let o,i;if(e.recordDOM){const w=An(e,e.doc);o=w.observer,i=w.buffer}const a=Da(e),c=La(e),d=Pn(e),m=Ta(e,{win:s}),h=$a(e),r=Wa(e);let u=()=>{},l=()=>{},n=()=>{},p=()=>{};e.recordDOM&&(u=Ba(e,{win:s}),l=Nn(e,e.doc),n=Ua(e,{win:s}),e.collectFonts&&(p=za(e)));const f=qa(e),g=ja(e),S=[];for(const w of e.plugins)S.push(w.observer(w.callback,s,w.options));return $(()=>{if(i){i.destroy(),i.reset();const w=ge.indexOf(i);w!==-1&&ge.splice(w,1)}o==null||o.disconnect(),a(),c(),d(),m(),h(),r(),u(),l(),n(),p(),f(),g(),S.forEach(w=>w())})}function it(e){return typeof window[e]!="undefined"}function nt(e){return!!(typeof window[e]!="undefined"&&window[e].prototype&&"insertRule"in window[e].prototype&&"deleteRule"in window[e].prototype)}class Li{constructor(t){A(this,"iframeIdToRemoteIdMap",new WeakMap),A(this,"iframeRemoteIdToIdMap",new WeakMap),this.generateIdFn=t}getId(t,s,o,i){const a=o||this.getIdToRemoteIdMap(t),c=i||this.getRemoteIdToIdMap(t);let d=a.get(s);return d||(d=this.generateIdFn(),a.set(s,d),c.set(d,s)),d}getIds(t,s){const o=this.getIdToRemoteIdMap(t),i=this.getRemoteIdToIdMap(t);return s.map(a=>this.getId(t,a,o,i))}getRemoteId(t,s,o){const i=o||this.getRemoteIdToIdMap(t);if(typeof s!="number")return s;const a=i.get(s);return a||-1}getRemoteIds(t,s){const o=this.getRemoteIdToIdMap(t);return s.map(i=>this.getRemoteId(t,i,o))}reset(t){if(!t){this.iframeIdToRemoteIdMap=new WeakMap,this.iframeRemoteIdToIdMap=new WeakMap;return}this.iframeIdToRemoteIdMap.delete(t),this.iframeRemoteIdToIdMap.delete(t)}getIdToRemoteIdMap(t){let s=this.iframeIdToRemoteIdMap.get(t);return s||(s=new Map,this.iframeIdToRemoteIdMap.set(t,s)),s}getRemoteIdToIdMap(t){let s=this.iframeRemoteIdToIdMap.get(t);return s||(s=new Map,this.iframeRemoteIdToIdMap.set(t,s)),s}}class Ga{constructor(t){A(this,"iframes",new WeakMap),A(this,"crossOriginIframeMap",new WeakMap),A(this,"crossOriginIframeMirror",new Li(Hi)),A(this,"crossOriginIframeStyleMirror"),A(this,"crossOriginIframeRootIdMap",new WeakMap),A(this,"mirror"),A(this,"mutationCb"),A(this,"wrappedEmit"),A(this,"loadListener"),A(this,"stylesheetManager"),A(this,"recordCrossOriginIframes"),A(this,"messageHandler"),A(this,"nestedIframeListeners",new Map),A(this,"attachedIframes",new Map),this.mutationCb=t.mutationCb,this.wrappedEmit=t.wrappedEmit,this.stylesheetManager=t.stylesheetManager,this.recordCrossOriginIframes=t.recordCrossOriginIframes,this.crossOriginIframeStyleMirror=new Li(this.stylesheetManager.styleMirror.generateId.bind(this.stylesheetManager.styleMirror)),this.mirror=t.mirror,this.messageHandler=this.handleMessage.bind(this),this.recordCrossOriginIframes&&window.addEventListener("message",this.messageHandler)}addIframe(t){this.iframes.set(t,!0),t.contentWindow&&this.crossOriginIframeMap.set(t.contentWindow,t)}addLoadListener(t){this.loadListener=t}removeLoadListener(){this.loadListener=void 0}trackIframeContent(t,s){const o=this.mirror.getId(t);return this.attachedIframes.set(o,{element:t,content:s}),o}attachIframe(t,s){var o;const i=this.trackIframeContent(t,s);this.mutationCb({adds:[{parentId:i,nextId:null,node:s}],removes:[],texts:[],attributes:[],isAttachIframe:!0});const a=t.contentWindow;if(this.recordCrossOriginIframes&&a&&!this.nestedIframeListeners.has(a)){const c=this.handleMessage.bind(this);this.nestedIframeListeners.set(a,c),a.addEventListener("message",c)}(o=this.loadListener)==null||o.call(this,t),t.contentDocument&&t.contentDocument.adoptedStyleSheets&&t.contentDocument.adoptedStyleSheets.length>0&&this.stylesheetManager.adoptStyleSheets(t.contentDocument.adoptedStyleSheets,this.mirror.getId(t.contentDocument))}handleMessage(t){const s=t;if(s.data.type!=="rrweb"||s.origin!==s.data.origin||!t.source)return;const i=this.crossOriginIframeMap.get(t.source);if(!i)return;const a=this.transformCrossOriginEvent(i,s.data.event);a&&this.wrappedEmit(a,s.data.isCheckout)}transformCrossOriginEvent(t,s){var o;switch(s.type){case B.FullSnapshot:{this.crossOriginIframeMirror.reset(t),this.crossOriginIframeStyleMirror.reset(t),this.replaceIdOnNode(s.data.node,t);const i=s.data.node.id;return this.crossOriginIframeRootIdMap.set(t,i),this.patchRootIdOnNode(s.data.node,i),this.trackIframeContent(t,s.data.node),{timestamp:s.timestamp,type:B.IncrementalSnapshot,data:{source:F.Mutation,adds:[{parentId:this.mirror.getId(t),nextId:null,node:s.data.node}],removes:[],texts:[],attributes:[],isAttachIframe:!0}}}case B.Meta:case B.Load:case B.DomContentLoaded:return!1;case B.Plugin:return s;case B.Custom:return this.replaceIds(s.data.payload,t,["id","parentId","previousId","nextId"]),s;case B.IncrementalSnapshot:switch(s.data.source){case F.Mutation:return s.data.adds.forEach(i=>{this.replaceIds(i,t,["parentId","nextId","previousId"]),this.replaceIdOnNode(i.node,t);const a=this.crossOriginIframeRootIdMap.get(t);a&&this.patchRootIdOnNode(i.node,a)}),s.data.removes.forEach(i=>{this.replaceIds(i,t,["parentId","id"])}),s.data.attributes.forEach(i=>{this.replaceIds(i,t,["id"])}),s.data.texts.forEach(i=>{this.replaceIds(i,t,["id"])}),s;case F.Drag:case F.TouchMove:case F.MouseMove:return s.data.positions.forEach(i=>{this.replaceIds(i,t,["id"])}),s;case F.ViewportResize:return!1;case F.MediaInteraction:case F.MouseInteraction:case F.Scroll:case F.CanvasMutation:case F.Input:return this.replaceIds(s.data,t,["id"]),s;case F.StyleSheetRule:case F.StyleDeclaration:return this.replaceIds(s.data,t,["id"]),this.replaceStyleIds(s.data,t,["styleId"]),s;case F.Font:return s;case F.Selection:return s.data.ranges.forEach(i=>{this.replaceIds(i,t,["start","end"])}),s;case F.AdoptedStyleSheet:return this.replaceIds(s.data,t,["id"]),this.replaceStyleIds(s.data,t,["styleIds"]),(o=s.data.styles)==null||o.forEach(i=>{this.replaceStyleIds(i,t,["styleId"])}),s}}return!1}replace(t,s,o,i){for(const a of i)!Array.isArray(s[a])&&typeof s[a]!="number"||(Array.isArray(s[a])?s[a]=t.getIds(o,s[a]):s[a]=t.getId(o,s[a]));return s}replaceIds(t,s,o){return this.replace(this.crossOriginIframeMirror,t,s,o)}replaceStyleIds(t,s,o){return this.replace(this.crossOriginIframeStyleMirror,t,s,o)}replaceIdOnNode(t,s){this.replaceIds(t,s,["id","rootId"]),"childNodes"in t&&t.childNodes.forEach(o=>{this.replaceIdOnNode(o,s)})}patchRootIdOnNode(t,s){t.type!==In.Document&&!t.rootId&&(t.rootId=s),"childNodes"in t&&t.childNodes.forEach(o=>{this.patchRootIdOnNode(o,s)})}removeIframeById(t){const s=this.attachedIframes.get(t),o=(s==null?void 0:s.element)||this.mirror.getNode(t);if(o){const i=o.contentWindow;if(i&&this.nestedIframeListeners.has(i)){const a=this.nestedIframeListeners.get(i);i.removeEventListener("message",a),this.nestedIframeListeners.delete(i)}i&&this.crossOriginIframeMap.delete(i),this.iframes.delete(o)}s&&this.attachedIframes.delete(t)}reattachIframes(){this.attachedIframes.forEach(({content:t},s)=>{if(!this.mirror.has(s)){this.attachedIframes.delete(s);return}this.mutationCb({adds:[{parentId:s,nextId:null,node:t}],removes:[],texts:[],attributes:[],isAttachIframe:!0})})}destroy(){this.recordCrossOriginIframes&&window.removeEventListener("message",this.messageHandler),this.nestedIframeListeners.forEach((t,s)=>{s.removeEventListener("message",t)}),this.nestedIframeListeners.clear(),this.crossOriginIframeMirror.reset(),this.crossOriginIframeStyleMirror.reset(),this.attachedIframes.clear(),this.crossOriginIframeMap=new WeakMap,this.iframes=new WeakMap,this.crossOriginIframeRootIdMap=new WeakMap}}class Ja{constructor(t){A(this,"shadowDoms",new WeakSet),A(this,"mutationCb"),A(this,"scrollCb"),A(this,"bypassOptions"),A(this,"mirror"),A(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,s){if(!ze(t)||this.shadowDoms.has(t))return;this.shadowDoms.add(t);const{observer:o,buffer:i}=An(le(T({},this.bypassOptions),{doc:s,mutationCb:this.mutationCb,mirror:this.mirror,shadowDomManager:this}),t);this.restoreHandlers.push(()=>{o.disconnect(),i.destroy(),i.reset();const a=ge.indexOf(i);a!==-1&&ge.splice(a,1)}),this.restoreHandlers.push(Pn(le(T({},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(L.host(t))),this.restoreHandlers.push(Nn({mirror:this.mirror,stylesheetManager:this.bypassOptions.stylesheetManager},t))},0)}observeAttachShadow(t){!t.contentWindow||!t.contentDocument||this.patchAttachShadow(t.contentWindow.Element,t.contentDocument)}patchAttachShadow(t,s){const o=this;this.restoreHandlers.push(Pe(t.prototype,"attachShadow",function(i){return function(a){const c=i.call(this,a),d=L.shadowRoot(this);return d&&Mn(this)&&o.addShadowRoot(d,s),c}}))}reset(){this.restoreHandlers.forEach(t=>{try{t()}catch(s){}}),this.restoreHandlers=[],this.shadowDoms=new WeakSet}}var $e="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",Ya=typeof Uint8Array=="undefined"?[]:new Uint8Array(256);for(var ot=0;ot<$e.length;ot++)Ya[$e.charCodeAt(ot)]=ot;var Za=function(e){var t=new Uint8Array(e),s,o=t.length,i="";for(s=0;s<o;s+=3)i+=$e[t[s]>>2],i+=$e[(t[s]&3)<<4|t[s+1]>>4],i+=$e[(t[s+1]&15)<<2|t[s+2]>>6],i+=$e[t[s+2]&63];return o%3===2?i=i.substring(0,i.length-1)+"=":o%3===1&&(i=i.substring(0,i.length-2)+"=="),i};const Ti=new Map;function Xa(e,t){let s=Ti.get(e);return s||(s=new Map,Ti.set(e,s)),s.has(t)||s.set(t,[]),s.get(t)}const _n=(e,t,s)=>{if(!e||!(Dn(e,t)||typeof e=="object"))return;const o=e.constructor.name,i=Xa(s,o);let a=i.indexOf(e);return a===-1&&(a=i.length,i.push(e)),a};function at(e,t,s,o){if(e instanceof Array)return e.map(i=>at(i,t,s,o));if(e===null)return e;if(e instanceof Float32Array||e instanceof Float64Array||e instanceof Int32Array||e instanceof Uint32Array||e instanceof Uint8Array||e instanceof Uint16Array||e instanceof Int16Array||e instanceof Int8Array||e instanceof Uint8ClampedArray)return{rr_type:e.constructor.name,args:[Object.values(e)]};if(e instanceof ArrayBuffer){const i=e.constructor.name,a=Za(e);return{rr_type:i,base64:a}}else{if(e instanceof DataView)return{rr_type:e.constructor.name,args:[at(e.buffer,t,s,o),e.byteOffset,e.byteLength]};if(e instanceof HTMLImageElement){const i=e.constructor.name,{src:a}=e;return{rr_type:i,src:a}}else if(e instanceof HTMLCanvasElement){const i="HTMLImageElement",a=e.toDataURL(o.type,o.quality);return{rr_type:i,src:a}}else{if(e instanceof ImageData)return{rr_type:e.constructor.name,args:[at(e.data,t,s,o),e.width,e.height]};if(Dn(e,t)||typeof e=="object"){const i=e.constructor.name,a=_n(e,t,s);return{rr_type:i,index:a}}}}return e}const kn=(e,t,s,o)=>e.map(i=>at(i,t,s,o)),Dn=(e,t)=>!!["WebGLActiveInfo","WebGLBuffer","WebGLFramebuffer","WebGLProgram","WebGLRenderbuffer","WebGLShader","WebGLShaderPrecisionFormat","WebGLTexture","WebGLUniformLocation","WebGLVertexArrayObject","WebGLVertexArrayObjectOES"].filter(i=>typeof t[i]=="function").find(i=>e instanceof t[i]);function Qa(e,t,s,o,i){const a=[],c=Object.getOwnPropertyNames(t.CanvasRenderingContext2D.prototype);for(const d of c)try{if(typeof t.CanvasRenderingContext2D.prototype[d]!="function")continue;const m=Pe(t.CanvasRenderingContext2D.prototype,d,function(h){return function(...r){return re(this.canvas,s,o,!0)||setTimeout(()=>{const u=kn(r,t,this,i);e(this.canvas,{type:Be["2D"],property:d,args:u})},0),h.apply(this,r)}});a.push(m)}catch(m){const h=xt(t.CanvasRenderingContext2D.prototype,d,{set(r){e(this.canvas,{type:Be["2D"],property:d,args:[r],setter:!0})}});a.push(h)}return()=>{a.forEach(d=>d())}}function Ka(e){return e==="experimental-webgl"?"webgl":e}function Fi(e,t,s,o){const i=[];try{const a=Pe(e.HTMLCanvasElement.prototype,"getContext",function(c){return function(d,...m){if(!re(this,t,s,!0)){const h=Ka(d);if("__context"in this||(this.__context=h),o&&["webgl","webgl2"].includes(h))if(m[0]&&typeof m[0]=="object"){const r=m[0];r.preserveDrawingBuffer||(r.preserveDrawingBuffer=!0)}else m.splice(0,1,{preserveDrawingBuffer:!0})}return c.apply(this,[d,...m])}});i.push(a)}catch(a){console.error("failed to patch HTMLCanvasElement.prototype.getContext")}return()=>{i.forEach(a=>a())}}function $i(e,t,s,o,i,a,c){const d=[],m=Object.getOwnPropertyNames(e);for(const h of m)if(!["isContextLost","canvas","drawingBufferWidth","drawingBufferHeight"].includes(h))try{if(typeof e[h]!="function")continue;const r=Pe(e,h,function(u){return function(...l){const n=u.apply(this,l);if(_n(n,a,this),"tagName"in this.canvas&&!re(this.canvas,o,i,!0)){const p=kn(l,a,this,c),f={type:t,property:h,args:p};s(this.canvas,f)}return n}});d.push(r)}catch(r){const u=xt(e,h,{set(l){s(this.canvas,{type:t,property:h,args:[l],setter:!0})}});d.push(u)}return d}function el(e,t,s,o,i){const a=[];return a.push(...$i(t.WebGLRenderingContext.prototype,Be.WebGL,e,s,o,t,i)),typeof t.WebGL2RenderingContext!="undefined"&&a.push(...$i(t.WebGL2RenderingContext.prototype,Be.WebGL2,e,s,o,t,i)),()=>{a.forEach(c=>c())}}const Ln=`(function() {
|
|
59
59
|
"use strict";
|
|
60
60
|
var chars = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/";
|
|
61
61
|
var lookup = typeof Uint8Array === "undefined" ? [] : new Uint8Array(256);
|
|
@@ -147,7 +147,7 @@ or you can use record.mirror to access the mirror instance during recording.`;le
|
|
|
147
147
|
};
|
|
148
148
|
})();
|
|
149
149
|
//# sourceMappingURL=image-bitmap-data-url-worker-B8-18rdG.js.map
|
|
150
|
-
`,Fi=typeof self!="undefined"&&self.Blob&&new Blob([kn],{type:"text/javascript;charset=utf-8"});function Ka(e){let t;try{if(t=Fi&&(self.URL||self.webkitURL).createObjectURL(Fi),!t)throw"";const s=new Worker(t,{name:e==null?void 0:e.name});return s.addEventListener("error",()=>{(self.URL||self.webkitURL).revokeObjectURL(t)}),s}catch(s){return new Worker("data:text/javascript;charset=utf-8,"+encodeURIComponent(kn),{name:e==null?void 0:e.name})}finally{t&&(self.URL||self.webkitURL).revokeObjectURL(t)}}class el{constructor(t){A(this,"pendingCanvasMutations",new Map),A(this,"rafStamps",{latestId:0,invokeId:null}),A(this,"mirror"),A(this,"mutationCb"),A(this,"resetObservers"),A(this,"frozen",!1),A(this,"locked",!1),A(this,"rafIdTimestamp",null),A(this,"rafIdFlush",null),A(this,"processMutation",(m,h)=>{(this.rafStamps.invokeId&&this.rafStamps.latestId!==this.rafStamps.invokeId||!this.rafStamps.invokeId)&&(this.rafStamps.invokeId=this.rafStamps.latestId),this.pendingCanvasMutations.has(m)||this.pendingCanvasMutations.set(m,[]),this.pendingCanvasMutations.get(m).push(h)});const{sampling:s="all",win:o,blockClass:i,blockSelector:a,recordCanvas:c,dataURLOptions:d}=t;this.mutationCb=t.mutationCb,this.mirror=t.mirror,c&&s==="all"&&this.initCanvasMutationObserver(o,i,a,d),c&&typeof s=="number"&&this.initCanvasFPSObserver(s,o,i,a,{dataURLOptions:d})}reset(){this.pendingCanvasMutations.clear(),this.resetObservers&&this.resetObservers(),this.rafIdTimestamp!==null&&(cancelAnimationFrame(this.rafIdTimestamp),this.rafIdTimestamp=null),this.rafIdFlush!==null&&(cancelAnimationFrame(this.rafIdFlush),this.rafIdFlush=null)}freeze(){this.frozen=!0}unfreeze(){this.frozen=!1}lock(){this.locked=!0}unlock(){this.locked=!1}initCanvasFPSObserver(t,s,o,i,a){if(!("OffscreenCanvas"in s))return;const c=Li(s,o,i,!0),d=new Map,m=new Ka;m.onmessage=p=>{const{id:f}=p.data;if(d.set(f,!1),!("base64"in p.data))return;const{base64:g,type:S,width:w,height:v}=p.data;this.mutationCb({id:f,type:$e["2D"],commands:[{property:"clearRect",args:[0,0,w,v]},{property:"drawImage",args:[{rr_type:"ImageBitmap",args:[{rr_type:"Blob",data:[{rr_type:"ArrayBuffer",base64:g}],type:S}]},0,0]}],displayWidth:w,displayHeight:v})};const h=1e3/t;let r=0,u;const l=()=>{const p=[],f=g=>{g.querySelectorAll("canvas").forEach(S=>{se(S,o,i,!0)||p.push(S)}),g.querySelectorAll("*").forEach(S=>{S.shadowRoot&&f(S.shadowRoot)})};return f(s.document),p},n=p=>{if(r&&p-r<h){u=requestAnimationFrame(n);return}r=p,l().forEach(async f=>{var g;const S=this.mirror.getId(f);if(d.get(S)||f.width===0||f.height===0)return;if(d.set(S,!0),["webgl","webgl2"].includes(f.__context)){const y=f.getContext(f.__context);((g=y==null?void 0:y.getContextAttributes())==null?void 0:g.preserveDrawingBuffer)===!1&&y.clear(y.COLOR_BUFFER_BIT)}const w=f.clientWidth||f.width,v=f.clientHeight||f.height,x=await createImageBitmap(f,{resizeWidth:w,resizeHeight:v});m.postMessage({id:S,bitmap:x,width:w,height:v,dataURLOptions:a.dataURLOptions},[x])}),u=requestAnimationFrame(n)};u=requestAnimationFrame(n),this.resetObservers=()=>{c(),cancelAnimationFrame(u)}}initCanvasMutationObserver(t,s,o,i){this.startRAFTimestamping(),this.startPendingCanvasMutationFlusher();const a=Li(t,s,o,!1),c=Za(this.processMutation.bind(this),t,s,o,i),d=Qa(this.processMutation.bind(this),t,s,o,i);this.resetObservers=()=>{a(),c(),d()}}startPendingCanvasMutationFlusher(){this.rafIdFlush=requestAnimationFrame(()=>this.flushPendingCanvasMutations())}startRAFTimestamping(){const t=s=>{this.rafStamps.latestId=s,this.rafIdTimestamp=requestAnimationFrame(t)};this.rafIdTimestamp=requestAnimationFrame(t)}flushPendingCanvasMutations(){this.pendingCanvasMutations.forEach((t,s)=>{const o=this.mirror.getId(s);this.flushPendingCanvasMutationFor(s,o)}),this.rafIdFlush=requestAnimationFrame(()=>this.flushPendingCanvasMutations())}flushPendingCanvasMutationFor(t,s){if(this.frozen||this.locked)return;const o=this.pendingCanvasMutations.get(t);if(!o||s===-1)return;const i=o.map(c=>{const h=c,{type:d}=h;return Ne(h,["type"])}),{type:a}=o[0];this.mutationCb({id:s,type:a,commands:i}),this.pendingCanvasMutations.delete(t)}}class tl{constructor(t){A(this,"trackedLinkElements",new WeakSet),A(this,"mutationCb"),A(this,"adoptedStyleSheetCb"),A(this,"styleMirror",new xa),this.mutationCb=t.mutationCb,this.adoptedStyleSheetCb=t.adoptedStyleSheetCb}attachLinkElement(t,s){"_cssText"in s.attributes&&this.mutationCb({adds:[],removes:[],texts:[],attributes:[{id:s.id,attributes:s.attributes}]}),this.trackLinkElement(t)}trackLinkElement(t){this.trackedLinkElements.has(t)||(this.trackedLinkElements.add(t),this.trackStylesheetInLinkElement(t))}adoptStyleSheets(t,s){if(t.length===0)return;const o={id:s,styleIds:[]},i=[];for(const a of t){let c;this.styleMirror.has(a)?c=this.styleMirror.getId(a):(c=this.styleMirror.add(a),i.push({styleId:c,rules:Array.from(a.rules||CSSRule,(d,m)=>({rule:Ui(d,a.href),index:m}))})),o.styleIds.push(c)}i.length>0&&(o.styles=i),this.adoptedStyleSheetCb(o)}reset(){this.styleMirror.reset(),this.trackedLinkElements=new WeakSet}trackStylesheetInLinkElement(t){}}class rl{constructor(){A(this,"nodeMap",new WeakMap),A(this,"active",!1)}inOtherBuffer(t,s){const o=this.nodeMap.get(t);return o&&Array.from(o).some(i=>i!==s)}add(t,s){this.active||(this.active=!0,requestAnimationFrame(()=>{this.nodeMap=new WeakMap,this.active=!1})),this.nodeMap.set(t,(this.nodeMap.get(t)||new Set).add(s))}destroy(){}}let G,ot,_r,ft=!1;try{if(Array.from([1],e=>e*2)[0]!==2){const e=document.createElement("iframe");document.body.appendChild(e),Array.from=((ls=e.contentWindow)==null?void 0:ls.Array.from)||Array.from,document.body.removeChild(e)}}catch(e){console.debug("Unable to override Array.from",e)}const ce=oo();function xe(e={}){const{emit:t,checkoutEveryNms:s,checkoutEveryNth:o,blockClass:i="rr-block",blockSelector:a=null,ignoreClass:c="rr-ignore",ignoreSelector:d=null,maskTextClass:m="rr-mask",maskTextSelector:h=null,inlineStylesheet:r=!0,maskAllInputs:u,maskInputOptions:l,slimDOMOptions:n,maskInputFn:p,maskTextFn:f,hooks:g,packFn:S,sampling:w={},dataURLOptions:v={},mousemoveWait:x,recordDOM:y=!0,recordCanvas:b=!1,recordCrossOriginIframes:C=!1,recordAfter:R=e.recordAfter==="DOMContentLoaded"?e.recordAfter:"load",userTriggeredOnInput:I=!1,collectFonts:O=!1,inlineImages:N=!1,plugins:P,keepIframeSrcFn:ee=()=>!1,ignoreCSSAttributes:D=new Set([]),errorHandler:M}=e;Pa(M);const ie=T({type:"image/webp",quality:.4,maxBase64ImageLength:1048576},v),_=C?window.parent===window:!0;let U=!1;if(!_)try{window.parent.document&&(U=!1)}catch(k){U=!0}if(_&&!t)throw new Error("emit function is required");if(!_&&!U)return()=>{};x!==void 0&&w.mousemove===void 0&&(w.mousemove=x),ce.reset();const J=u===!0?{color:!0,date:!0,"datetime-local":!0,email:!0,month:!0,number:!0,range:!0,search:!0,tel:!0,text:!0,time:!0,url:!0,week:!0,textarea:!0,select:!0,password:!0}:l!==void 0?l:{password:!0},W=n===!0||n==="all"?{script:!0,comment:!0,headFavicon:!0,headWhitespace:!0,headMetaSocial:!0,headMetaRobots:!0,headMetaHttpEquiv:!0,headMetaVerification:!0,headMetaAuthorship:n==="all",headMetaDescKeywords:n==="all",headTitleMutations:n==="all"}:n||{};Ca();let be,me=0;const E=k=>{for(const Y of P||[])Y.eventProcessor&&(k=Y.eventProcessor(k));return S&&!U&&(k=S(k)),k};G=(k,Y)=>{var q;const Z=k;if(Z.timestamp=ct(),(q=we[0])!=null&&q.isFrozen()&&Z.type!==B.FullSnapshot&&!(Z.type===B.IncrementalSnapshot&&Z.data.source===F.Mutation)&&we.forEach(fe=>fe.unfreeze()),_)t==null||t(E(Z),Y);else if(U){const fe={type:"rrweb",event:E(Z),origin:window.location.origin,isCheckout:Y};window.parent.postMessage(fe,"*")}if(Z.type===B.FullSnapshot)be=Z,me=0;else if(Z.type===B.IncrementalSnapshot){if(Z.data.source===F.Mutation&&Z.data.isAttachIframe)return;me++;const fe=o&&me>=o,Pe=s&&Z.timestamp-be.timestamp>s;(fe||Pe)&&ot(!0)}};const oe=k=>{if(C&&k.removes&&k.removes.length>0){const Y=k.adds.length>0?new Set(k.adds.map(q=>q.node.id)):null;k.removes.forEach(({id:q})=>{(!Y||!Y.has(q))&&te.removeIframeById(q)})}G({type:B.IncrementalSnapshot,data:T({source:F.Mutation},k)})},ae=k=>G({type:B.IncrementalSnapshot,data:T({source:F.Scroll},k)}),Ae=k=>G({type:B.IncrementalSnapshot,data:T({source:F.CanvasMutation},k)}),ge=k=>G({type:B.IncrementalSnapshot,data:T({source:F.AdoptedStyleSheet},k)}),he=new tl({mutationCb:oe,adoptedStyleSheetCb:ge}),te=new Ha({mirror:ce,mutationCb:oe,stylesheetManager:he,recordCrossOriginIframes:C,wrappedEmit:G});for(const k of P||[])k.getMirror&&k.getMirror({nodeMirror:ce,crossOriginIframeMirror:te.crossOriginIframeMirror,crossOriginIframeStyleMirror:te.crossOriginIframeStyleMirror});const Re=new rl;_r=new el({recordCanvas:b,mutationCb:Ae,win:window,blockClass:i,blockSelector:a,mirror:ce,sampling:w.canvas,dataURLOptions:ie});const X=new Va({mutationCb:oe,scrollCb:ae,bypassOptions:{blockClass:i,blockSelector:a,maskTextClass:m,maskTextSelector:h,inlineStylesheet:r,maskInputOptions:J,dataURLOptions:ie,maskTextFn:f,maskInputFn:p,recordCanvas:b,inlineImages:N,sampling:w,slimDOMOptions:W,iframeManager:te,stylesheetManager:he,canvasManager:_r,keepIframeSrcFn:ee,processedNodeManager:Re},mirror:ce});ot=(k=!1)=>{if(!y)return;G({type:B.Meta,data:{href:window.location.href,width:wn(),height:yn()}},k),he.reset(),X.init(),we.forEach(q=>q.lock());const Y=To(document,{mirror:ce,blockClass:i,blockSelector:a,maskTextClass:m,maskTextSelector:h,inlineStylesheet:r,maskAllInputs:J,maskTextFn:f,maskInputFn:p,slimDOM:W,dataURLOptions:ie,recordCanvas:b,inlineImages:N,onSerialize:q=>{vn(q,ce)&&te.addIframe(q),Cn(q,ce)&&he.trackLinkElement(q),Lr(q)&&X.addShadowRoot(L.shadowRoot(q),document)},onIframeLoad:(q,Z)=>{te.attachIframe(q,Z),X.observeAttachShadow(q)},onStylesheetLoad:(q,Z)=>{he.attachLinkElement(q,Z)},keepIframeSrcFn:ee});if(!Y)return console.warn("Failed to snapshot the document");G({type:B.FullSnapshot,data:{node:Y,initialOffset:gn(window)}},k),we.forEach(q=>q.unlock()),C&&te.reattachIframes(),document.adoptedStyleSheets&&document.adoptedStyleSheets.length>0&&he.adoptStyleSheets(document.adoptedStyleSheets,ce.getId(document))};try{const k=[],Y=fe=>{var Pe;return $(ja)({mutationCb:oe,mousemoveCb:(j,Ct)=>G({type:B.IncrementalSnapshot,data:{source:Ct,positions:j}}),mouseInteractionCb:j=>G({type:B.IncrementalSnapshot,data:T({source:F.MouseInteraction},j)}),scrollCb:ae,viewportResizeCb:j=>G({type:B.IncrementalSnapshot,data:T({source:F.ViewportResize},j)}),inputCb:j=>G({type:B.IncrementalSnapshot,data:T({source:F.Input},j)}),mediaInteractionCb:j=>G({type:B.IncrementalSnapshot,data:T({source:F.MediaInteraction},j)}),styleSheetRuleCb:j=>G({type:B.IncrementalSnapshot,data:T({source:F.StyleSheetRule},j)}),styleDeclarationCb:j=>G({type:B.IncrementalSnapshot,data:T({source:F.StyleDeclaration},j)}),canvasMutationCb:Ae,fontCb:j=>G({type:B.IncrementalSnapshot,data:T({source:F.Font},j)}),selectionCb:j=>{G({type:B.IncrementalSnapshot,data:T({source:F.Selection},j)})},customElementCb:j=>{G({type:B.IncrementalSnapshot,data:T({source:F.CustomElement},j)})},blockClass:i,ignoreClass:c,ignoreSelector:d,maskTextClass:m,maskTextSelector:h,maskInputOptions:J,inlineStylesheet:r,sampling:w,recordDOM:y,recordCanvas:b,inlineImages:N,userTriggeredOnInput:I,collectFonts:O,doc:fe,maskInputFn:p,maskTextFn:f,keepIframeSrcFn:ee,blockSelector:a,slimDOMOptions:W,dataURLOptions:ie,mirror:ce,iframeManager:te,stylesheetManager:he,shadowDomManager:X,processedNodeManager:Re,canvasManager:_r,ignoreCSSAttributes:D,plugins:((Pe=P==null?void 0:P.filter(j=>j.observer))==null?void 0:Pe.map(j=>({observer:j.observer,options:j.options,callback:Ct=>G({type:B.Plugin,data:{plugin:j.name,payload:Ct}})})))||[]},g)},q=fe=>{try{k.push(Y(fe.contentDocument))}catch(Pe){console.warn(Pe)}};te.addLoadListener(q);const Z=()=>{ot(),k.push(Y(document)),ft=!0};return document.readyState==="interactive"||document.readyState==="complete"?Z():(k.push(re("DOMContentLoaded",()=>{G({type:B.DomContentLoaded,data:{}}),R==="DOMContentLoaded"&&Z()})),k.push(re("load",()=>{G({type:B.Load,data:{}}),R==="load"&&Z()},window))),()=>{k.forEach(fe=>fe()),Re.destroy(),te.removeLoadListener(),te.destroy(),ce.reset(),ft=!1,Na()}}catch(k){console.warn(k)}}xe.addCustomEvent=(e,t)=>{if(!ft)throw new Error("please add custom event after start recording");G({type:B.Custom,data:{tag:e,payload:t}})};xe.freezePage=()=>{we.forEach(e=>e.freeze())};xe.takeFullSnapshot=e=>{if(!ft)throw new Error("please take full snapshot after start recording");ot(e)};xe.mirror=ce;var $i;(function(e){e[e.NotStarted=0]="NotStarted",e[e.Running=1]="Running",e[e.Stopped=2]="Stopped"})($i||($i={}));const{addCustomEvent:il}=xe,{freezePage:nl}=xe,{takeFullSnapshot:ol}=xe;exports.record=xe;exports.resetMaxDepthState=Lo;exports.wasMaxDepthReached=Do;
|
|
150
|
+
`,Bi=typeof self!="undefined"&&self.Blob&&new Blob([Ln],{type:"text/javascript;charset=utf-8"});function tl(e){let t;try{if(t=Bi&&(self.URL||self.webkitURL).createObjectURL(Bi),!t)throw"";const s=new Worker(t,{name:e==null?void 0:e.name});return s.addEventListener("error",()=>{(self.URL||self.webkitURL).revokeObjectURL(t)}),s}catch(s){return new Worker("data:text/javascript;charset=utf-8,"+encodeURIComponent(Ln),{name:e==null?void 0:e.name})}finally{t&&(self.URL||self.webkitURL).revokeObjectURL(t)}}class rl{constructor(t){A(this,"pendingCanvasMutations",new Map),A(this,"rafStamps",{latestId:0,invokeId:null}),A(this,"mirror"),A(this,"mutationCb"),A(this,"resetObservers"),A(this,"frozen",!1),A(this,"locked",!1),A(this,"rafIdTimestamp",null),A(this,"rafIdFlush",null),A(this,"processMutation",(m,h)=>{(this.rafStamps.invokeId&&this.rafStamps.latestId!==this.rafStamps.invokeId||!this.rafStamps.invokeId)&&(this.rafStamps.invokeId=this.rafStamps.latestId),this.pendingCanvasMutations.has(m)||this.pendingCanvasMutations.set(m,[]),this.pendingCanvasMutations.get(m).push(h)});const{sampling:s="all",win:o,blockClass:i,blockSelector:a,recordCanvas:c,dataURLOptions:d}=t;this.mutationCb=t.mutationCb,this.mirror=t.mirror,c&&s==="all"&&this.initCanvasMutationObserver(o,i,a,d),c&&typeof s=="number"&&this.initCanvasFPSObserver(s,o,i,a,{dataURLOptions:d})}reset(){this.pendingCanvasMutations.clear(),this.resetObservers&&this.resetObservers(),this.rafIdTimestamp!==null&&(cancelAnimationFrame(this.rafIdTimestamp),this.rafIdTimestamp=null),this.rafIdFlush!==null&&(cancelAnimationFrame(this.rafIdFlush),this.rafIdFlush=null)}freeze(){this.frozen=!0}unfreeze(){this.frozen=!1}lock(){this.locked=!0}unlock(){this.locked=!1}initCanvasFPSObserver(t,s,o,i,a){if(!("OffscreenCanvas"in s))return;const c=Fi(s,o,i,!0),d=new Map,m=new tl;m.onmessage=p=>{const{id:f}=p.data;if(d.set(f,!1),!("base64"in p.data))return;const{base64:g,type:S,width:w,height:v}=p.data;this.mutationCb({id:f,type:Be["2D"],commands:[{property:"clearRect",args:[0,0,w,v]},{property:"drawImage",args:[{rr_type:"ImageBitmap",args:[{rr_type:"Blob",data:[{rr_type:"ArrayBuffer",base64:g}],type:S}]},0,0]}],displayWidth:w,displayHeight:v})};const h=1e3/t;let r=0,u;const l=()=>{const p=[],f=g=>{g.querySelectorAll("canvas").forEach(S=>{re(S,o,i,!0)||p.push(S)}),g.querySelectorAll("*").forEach(S=>{S.shadowRoot&&f(S.shadowRoot)})};return f(s.document),p},n=p=>{if(r&&p-r<h){u=requestAnimationFrame(n);return}r=p,l().forEach(async f=>{var g;const S=this.mirror.getId(f);if(d.get(S)||f.width===0||f.height===0)return;if(d.set(S,!0),["webgl","webgl2"].includes(f.__context)){const y=f.getContext(f.__context);((g=y==null?void 0:y.getContextAttributes())==null?void 0:g.preserveDrawingBuffer)===!1&&y.clear(y.COLOR_BUFFER_BIT)}const w=f.clientWidth||f.width,v=f.clientHeight||f.height,x=await createImageBitmap(f,{resizeWidth:w,resizeHeight:v});m.postMessage({id:S,bitmap:x,width:w,height:v,dataURLOptions:a.dataURLOptions},[x])}),u=requestAnimationFrame(n)};u=requestAnimationFrame(n),this.resetObservers=()=>{c(),cancelAnimationFrame(u)}}initCanvasMutationObserver(t,s,o,i){this.startRAFTimestamping(),this.startPendingCanvasMutationFlusher();const a=Fi(t,s,o,!1),c=Qa(this.processMutation.bind(this),t,s,o,i),d=el(this.processMutation.bind(this),t,s,o,i);this.resetObservers=()=>{a(),c(),d()}}startPendingCanvasMutationFlusher(){this.rafIdFlush=requestAnimationFrame(()=>this.flushPendingCanvasMutations())}startRAFTimestamping(){const t=s=>{this.rafStamps.latestId=s,this.rafIdTimestamp=requestAnimationFrame(t)};this.rafIdTimestamp=requestAnimationFrame(t)}flushPendingCanvasMutations(){this.pendingCanvasMutations.forEach((t,s)=>{const o=this.mirror.getId(s);this.flushPendingCanvasMutationFor(s,o)}),this.rafIdFlush=requestAnimationFrame(()=>this.flushPendingCanvasMutations())}flushPendingCanvasMutationFor(t,s){if(this.frozen||this.locked)return;const o=this.pendingCanvasMutations.get(t);if(!o||s===-1)return;const i=o.map(c=>{const h=c,{type:d}=h;return _e(h,["type"])}),{type:a}=o[0];this.mutationCb({id:s,type:a,commands:i}),this.pendingCanvasMutations.delete(t)}}class sl{constructor(t){A(this,"trackedLinkElements",new WeakSet),A(this,"mutationCb"),A(this,"adoptedStyleSheetCb"),A(this,"styleMirror",new Oa),this.mutationCb=t.mutationCb,this.adoptedStyleSheetCb=t.adoptedStyleSheetCb}attachLinkElement(t,s){"_cssText"in s.attributes&&this.mutationCb({adds:[],removes:[],texts:[],attributes:[{id:s.id,attributes:s.attributes}]}),this.trackLinkElement(t)}trackLinkElement(t){this.trackedLinkElements.has(t)||(this.trackedLinkElements.add(t),this.trackStylesheetInLinkElement(t))}adoptStyleSheets(t,s){if(t.length===0)return;const o={id:s,styleIds:[]},i=[];for(const a of t){let c;this.styleMirror.has(a)?c=this.styleMirror.getId(a):(c=this.styleMirror.add(a),i.push({styleId:c,rules:Array.from(a.rules||CSSRule,(d,m)=>({rule:zi(d,a.href),index:m}))})),o.styleIds.push(c)}i.length>0&&(o.styles=i),this.adoptedStyleSheetCb(o)}reset(){this.styleMirror.reset(),this.trackedLinkElements=new WeakSet}trackStylesheetInLinkElement(t){}}class il{constructor(){A(this,"nodeMap",new WeakMap),A(this,"active",!1)}inOtherBuffer(t,s){const o=this.nodeMap.get(t);return o&&Array.from(o).some(i=>i!==s)}add(t,s){this.active||(this.active=!0,requestAnimationFrame(()=>{this.nodeMap=new WeakMap,this.active=!1})),this.nodeMap.set(t,(this.nodeMap.get(t)||new Set).add(s))}destroy(){}}let Y,lt,Dr,dt=!1;try{if(Array.from([1],e=>e*2)[0]!==2){const e=document.createElement("iframe");document.body.appendChild(e),Array.from=((cs=e.contentWindow)==null?void 0:cs.Array.from)||Array.from,document.body.removeChild(e)}}catch(e){console.debug("Unable to override Array.from",e)}const ne=lo();function Me(e={}){const{emit:t,checkoutEveryNms:s,checkoutEveryNth:o,blockClass:i="rr-block",blockSelector:a=null,ignoreClass:c="rr-ignore",ignoreSelector:d=null,maskTextClass:m="rr-mask",maskTextSelector:h=null,inlineStylesheet:r=!0,maskAllInputs:u,maskInputOptions:l,slimDOMOptions:n,maskInputFn:p,maskTextFn:f,hooks:g,packFn:S,sampling:w={},dataURLOptions:v={},mousemoveWait:x,recordDOM:y=!0,recordCanvas:b=!1,recordCrossOriginIframes:C=!1,recordAfter:R=e.recordAfter==="DOMContentLoaded"?e.recordAfter:"load",userTriggeredOnInput:I=!1,collectFonts:O=!1,inlineImages:N=!1,plugins:P,keepIframeSrcFn:ee=()=>!1,ignoreCSSAttributes:D=new Set([]),errorHandler:M}=e;_a(M);const se=T({type:"image/webp",quality:.4,maxBase64ImageLength:1048576},v),_=C?window.parent===window:!0;let W=!1;if(!_)try{window.parent.document&&(W=!1)}catch(k){W=!0}if(_&&!t)throw new Error("emit function is required");if(!_&&!W)return()=>{};x!==void 0&&w.mousemove===void 0&&(w.mousemove=x),ne.reset();const Z=u===!0?{color:!0,date:!0,"datetime-local":!0,email:!0,month:!0,number:!0,range:!0,search:!0,tel:!0,text:!0,time:!0,url:!0,week:!0,textarea:!0,select:!0,password:!0}:l!==void 0?l:{password:!0},z=n===!0||n==="all"?{script:!0,comment:!0,headFavicon:!0,headWhitespace:!0,headMetaSocial:!0,headMetaRobots:!0,headMetaHttpEquiv:!0,headMetaVerification:!0,headMetaAuthorship:n==="all",headMetaDescKeywords:n==="all",headTitleMutations:n==="all"}:n||{};Ra();let ve,ye=0;const E=new Map;function we(){for(const[k,X]of E){const U=ne.getNode(k);if(!U){X(),E.delete(k);continue}try{(!U.contentDocument||!U.contentDocument.defaultView)&&(X(),E.delete(k))}catch(V){X(),E.delete(k)}}}const oe=k=>{for(const X of P||[])X.eventProcessor&&(k=X.eventProcessor(k));return S&&!W&&(k=S(k)),k};Y=(k,X)=>{var U;const V=k;if(V.timestamp=ft(),(U=ge[0])!=null&&U.isFrozen()&&V.type!==B.FullSnapshot&&!(V.type===B.IncrementalSnapshot&&V.data.source===F.Mutation)&&ge.forEach(ae=>ae.unfreeze()),_)t==null||t(oe(V),X);else if(W){const ae={type:"rrweb",event:oe(V),origin:window.location.origin,isCheckout:X};window.parent.postMessage(ae,"*")}if(V.type===B.FullSnapshot)ve=V,ye=0;else if(V.type===B.IncrementalSnapshot){if(V.data.source===F.Mutation&&V.data.isAttachIframe)return;ye++;const ae=o&&ye>=o,be=s&&V.timestamp-ve.timestamp>s;(ae||be)&<(!0)}};const Ce=k=>{if(C&&k.removes&&k.removes.length>0){const X=k.adds.length>0?new Set(k.adds.map(U=>U.node.id)):null;k.removes.forEach(({id:U})=>{if(!X||!X.has(U)){const V=E.get(U);V&&(V(),E.delete(U)),H.removeIframeById(U)}}),we()}Y({type:B.IncrementalSnapshot,data:T({source:F.Mutation},k)})},de=k=>Y({type:B.IncrementalSnapshot,data:T({source:F.Scroll},k)}),Ne=k=>Y({type:B.IncrementalSnapshot,data:T({source:F.CanvasMutation},k)}),Ue=k=>Y({type:B.IncrementalSnapshot,data:T({source:F.AdoptedStyleSheet},k)}),ce=new sl({mutationCb:Ce,adoptedStyleSheetCb:Ue}),H=new Ga({mirror:ne,mutationCb:Ce,stylesheetManager:ce,recordCrossOriginIframes:C,wrappedEmit:Y});for(const k of P||[])k.getMirror&&k.getMirror({nodeMirror:ne,crossOriginIframeMirror:H.crossOriginIframeMirror,crossOriginIframeStyleMirror:H.crossOriginIframeStyleMirror});const he=new il;Dr=new rl({recordCanvas:b,mutationCb:Ne,win:window,blockClass:i,blockSelector:a,mirror:ne,sampling:w.canvas,dataURLOptions:se});const me=new Ja({mutationCb:Ce,scrollCb:de,bypassOptions:{blockClass:i,blockSelector:a,maskTextClass:m,maskTextSelector:h,inlineStylesheet:r,maskInputOptions:Z,dataURLOptions:se,maskTextFn:f,maskInputFn:p,recordCanvas:b,inlineImages:N,sampling:w,slimDOMOptions:z,iframeManager:H,stylesheetManager:ce,canvasManager:Dr,keepIframeSrcFn:ee,processedNodeManager:he},mirror:ne});lt=(k=!1)=>{if(!y)return;Y({type:B.Meta,data:{href:window.location.href,width:Sn(),height:bn()}},k),ce.reset(),me.init(),ge.forEach(U=>U.lock());const X=$o(document,{mirror:ne,blockClass:i,blockSelector:a,maskTextClass:m,maskTextSelector:h,inlineStylesheet:r,maskAllInputs:Z,maskTextFn:f,maskInputFn:p,slimDOM:z,dataURLOptions:se,recordCanvas:b,inlineImages:N,onSerialize:U=>{xn(U,ne)&&H.addIframe(U),Rn(U,ne)&&ce.trackLinkElement(U),Fr(U)&&me.addShadowRoot(L.shadowRoot(U),document)},onIframeLoad:(U,V)=>{H.attachIframe(U,V),me.observeAttachShadow(U)},onStylesheetLoad:(U,V)=>{ce.attachLinkElement(U,V)},keepIframeSrcFn:ee});if(!X)return console.warn("Failed to snapshot the document");Y({type:B.FullSnapshot,data:{node:X,initialOffset:wn(window)}},k),ge.forEach(U=>U.unlock()),C&&H.reattachIframes(),document.adoptedStyleSheets&&document.adoptedStyleSheets.length>0&&ce.adoptStyleSheets(document.adoptedStyleSheets,ne.getId(document))};try{const k=[],X=ae=>{var be;return $(Va)({mutationCb:Ce,mousemoveCb:(q,Rt)=>Y({type:B.IncrementalSnapshot,data:{source:Rt,positions:q}}),mouseInteractionCb:q=>Y({type:B.IncrementalSnapshot,data:T({source:F.MouseInteraction},q)}),scrollCb:de,viewportResizeCb:q=>Y({type:B.IncrementalSnapshot,data:T({source:F.ViewportResize},q)}),inputCb:q=>Y({type:B.IncrementalSnapshot,data:T({source:F.Input},q)}),mediaInteractionCb:q=>Y({type:B.IncrementalSnapshot,data:T({source:F.MediaInteraction},q)}),styleSheetRuleCb:q=>Y({type:B.IncrementalSnapshot,data:T({source:F.StyleSheetRule},q)}),styleDeclarationCb:q=>Y({type:B.IncrementalSnapshot,data:T({source:F.StyleDeclaration},q)}),canvasMutationCb:Ne,fontCb:q=>Y({type:B.IncrementalSnapshot,data:T({source:F.Font},q)}),selectionCb:q=>{Y({type:B.IncrementalSnapshot,data:T({source:F.Selection},q)})},customElementCb:q=>{Y({type:B.IncrementalSnapshot,data:T({source:F.CustomElement},q)})},blockClass:i,ignoreClass:c,ignoreSelector:d,maskTextClass:m,maskTextSelector:h,maskInputOptions:Z,inlineStylesheet:r,sampling:w,recordDOM:y,recordCanvas:b,inlineImages:N,userTriggeredOnInput:I,collectFonts:O,doc:ae,maskInputFn:p,maskTextFn:f,keepIframeSrcFn:ee,blockSelector:a,slimDOMOptions:z,dataURLOptions:se,mirror:ne,iframeManager:H,stylesheetManager:ce,shadowDomManager:me,processedNodeManager:he,canvasManager:Dr,ignoreCSSAttributes:D,plugins:((be=P==null?void 0:P.filter(q=>q.observer))==null?void 0:be.map(q=>({observer:q.observer,options:q.options,callback:Rt=>Y({type:B.Plugin,data:{plugin:q.name,payload:Rt}})})))||[]},g)},U=ae=>{try{const be=ne.getId(ae),q=X(ae.contentDocument);k.push(q),be!==-1&&E.set(be,q)}catch(be){console.warn(be)}};H.addLoadListener(U);const V=()=>{lt(),k.push(X(document)),dt=!0};return document.readyState==="interactive"||document.readyState==="complete"?V():(k.push(te("DOMContentLoaded",()=>{Y({type:B.DomContentLoaded,data:{}}),R==="DOMContentLoaded"&&V()})),k.push(te("load",()=>{Y({type:B.Load,data:{}}),R==="load"&&V()},window))),()=>{k.forEach(ae=>ae()),he.destroy(),H.removeLoadListener(),H.destroy(),E.clear(),ne.reset(),dt=!1,ka()}}catch(k){console.warn(k)}}Me.addCustomEvent=(e,t)=>{if(!dt)throw new Error("please add custom event after start recording");Y({type:B.Custom,data:{tag:e,payload:t}})};Me.freezePage=()=>{ge.forEach(e=>e.freeze())};Me.takeFullSnapshot=e=>{if(!dt)throw new Error("please take full snapshot after start recording");lt(e)};Me.mirror=ne;var Ui;(function(e){e[e.NotStarted=0]="NotStarted",e[e.Running=1]="Running",e[e.Stopped=2]="Stopped"})(Ui||(Ui={}));const{addCustomEvent:ol}=Me,{freezePage:al}=Me,{takeFullSnapshot:ll}=Me;exports.record=Me;exports.resetMaxDepthState=Fo;exports.wasMaxDepthReached=To;
|
|
151
151
|
;if (typeof module.exports == "object" && typeof exports == "object") {
|
|
152
152
|
var __cp = (to, from, except, desc) => {
|
|
153
153
|
if ((from && typeof from === "object") || typeof from === "function") {
|